/* 
   LAYOUT & UTILITIES 
*/

.container {
    width: 100%;
    max-width: 1440px;
    margin-inline: auto;
    padding-inline: var(--spacing-md);
}

.grid {
    display: grid;
    gap: var(--spacing-md);
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.flex {
    display: flex;
    gap: var(--spacing-md);
}

.flex-center {
    display: flex;
    justify-content: center;
    align-items: center;
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.flex-column {
    flex-direction: column;
}

/* Section Spacing */
section {
    padding-block: var(--spacing-xl);
    position: relative;
    overflow: hidden;
    /* For animations needing containment */
}

/* Full Height Utility */
.h-screen {
    min-height: 100vh;
}

/* Text Alignment */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

/* Margins */
.mb-sm {
    margin-bottom: var(--spacing-sm);
}

.mb-md {
    margin-bottom: var(--spacing-md);
}

.mb-lg {
    margin-bottom: var(--spacing-lg);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    background-color: var(--color-red);
    color: var(--color-white);
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    border-radius: var(--radius-pill);
    letter-spacing: 1px;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), background-color 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background-color: var(--color-white);
    color: var(--color-red);
    transform: scale(1.05);
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid var(--color-white);
}

.btn-secondary:hover {
    background-color: var(--color-white);
    color: var(--color-charcoal);
}

.btn-outline-light {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: var(--about-paper, #ffffff);
    text-decoration: none;
    font-family: var(--font-body);
    letter-spacing: 0.1em;
    font-weight: 700;
    text-transform: uppercase;
    transition: all 0.3s ease;
    border-radius: var(--radius-pill);
}

.btn-outline-light:hover {
    background: var(--about-paper, #ffffff);
    color: var(--brand-dark-brown, #3C2A1E);
    transform: translateY(-2px);
}


/* ATMOSPHERIC HERO STANDARDS (Grain, Noise, Gradients) */
.hero-atmos-standard {
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Parallax effect */
}

.hero-atmos-standard::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url('https://www.transparenttextures.com/patterns/natural-paper.png');
    opacity: 0.25;
    mix-blend-mode: multiply;
    pointer-events: none;
    z-index: 1;
}

.hero-atmos-standard::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 250 250' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.04;
    mix-blend-mode: overlay;
    pointer-events: none;
    z-index: 2;
}

.hero-atmos-standard .container {
    position: relative;
    z-index: 10;
}

/* Specific Section Styles */

/* HERO SPECIFIC FIXES (Hierarchy & Contrast) */
.hero-content-wrapper {
    background: radial-gradient(circle closest-side, rgba(0, 0, 0, 0.85) 20%, rgba(0, 0, 0, 0.4) 60%, transparent 100%);
    padding: 6rem 3rem;
    border-radius: 50%;
    /* Soft circular vignette behind text */
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
    z-index: 20;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* Global Editorial Heading System (Standardizing across pages) */
.hero-heading {
    font-family: var(--font-heading);
    font-size: clamp(3.8rem, 8vw, 7.5rem);
    line-height: 0.94;
    letter-spacing: -0.04em;
    margin-bottom: 1.4rem;
    max-width: 15ch;
    color: var(--color-white);
    text-transform: none;
}

.hero-heading.light {
    color: var(--about-paper, #FDFBFA);
    text-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.section-heading-block {
    position: relative;
    max-width: 100%;
    margin-bottom: 5rem;
    display: flex;
    flex-direction: column;
}

.section-heading-block h2 {
    font-size: clamp(2.8rem, 5.5vw, 5.2rem);
    line-height: 1.0;
    margin-top: 1rem;
    max-width: 20ch;
    color: var(--about-ink, #3C2A1E);
    text-transform: none;
}

.section-heading-block h2.light {
    color: var(--about-paper, #FDFBFA);
}

.heading-decoration {
    position: absolute;
    top: -2rem;
    left: -3rem;
    font-size: 12rem;
    font-family: var(--font-heading);
    font-weight: 900;
    color: var(--about-clay, #A45D39);
    opacity: 0.08;
    z-index: -1;
    line-height: 1;
}

.section-tag {
    font-size: 0.84rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--about-ink, #3C2A1E);
    opacity: 0.85;
    font-family: var(--font-body);
}

.section-tag.light {
    color: var(--about-gold, #D4AF37);
    opacity: 1;
}

/* Enhancing Text Hierarchy */
#hero h1 {
    text-shadow: 0 4px 30px rgba(0, 0, 0, 0.9);
    font-weight: 800;
    /* Extra bold */
    line-height: 0.95;
    margin-bottom: 2rem;
    letter-spacing: -2px;
}

/* Specific hero content styles using class specificity to avoid breaking card components */
.hero-lede {
    font-size: var(--font-size-base);
    font-weight: 400;
    color: #eeeeee;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 1);
    max-width: 50ch;
    opacity: 1;
    line-height: 1.6;
    margin-bottom: 3rem;
}

/* VIEWPORT SIDE PANEL SYSTEM (Global Architectural Component) */
.viewport-side-panel {
    background: rgba(253, 251, 250, 0.9); /* Translucent Paper tint */
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    padding: clamp(4rem, 6vw, 8rem);
    
    /* Breakout formula to touch right edge */
    margin-right: calc( (100vw - 100%) / -2 - 2rem ); 
    padding-right: calc( (100vw - 100%) / 2 + 6rem ); 
    
    border-radius: 4rem 0 0 4rem; 
    box-shadow: -40px 0 100px rgba(0, 0, 0, 0.1);
    width: auto;
    max-width: 600px;
    margin-left: auto;
    border-left: 1px solid rgba(164, 93, 57, 0.1); 
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* Aligned with top narrative */
    position: relative;
    z-index: 10;
}

/* Dark variant for panels on light backgrounds */
.viewport-side-panel.dark-theme {
    background: rgba(60, 42, 30, 0.95); /* Ink tint */
    color: white;
    border-left: 1px solid rgba(255, 255, 255, 0.05);
}

.viewport-side-panel .panel-kicker {
    font-family: var(--font-body);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.25em; /* Matching hero-kicker */
    font-size: 0.85rem;
    color: var(--about-clay); /* Sophisticated clay tone */
    margin-bottom: 1.5rem;
    display: block;
}

.viewport-side-panel h2 {
    font-family: var(--font-heading);
    font-size: clamp(2.4rem, 4vw, 3.2rem);
    line-height: 1;
    margin-bottom: 2rem;
    letter-spacing: -0.02em;
}

#hero .btn {
    box-shadow: 0 0 40px rgba(217, 56, 30, 0.6);
    /* Glow for CTA */
    z-index: 30;
    padding: 1.2rem 3rem;
    font-size: 1.1rem;
}

/* Ensure canvas is behind */
#canvas-container {
    z-index: 0;
    opacity: 0.7;
    /* Slight dimming of raw particles */
}

/* Placeholder Image Styles */
.placeholder-img {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--color-charcoal) 0%, #2a2a2a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.3);
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 1.5rem;
    position: relative;
    overflow: hidden;
}

.placeholder-img::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.5s ease;
}

.placeholder-img:hover::before {
    opacity: 1;
}

/* Specific gradients for each type */
.placeholder-film {
    background: linear-gradient(135deg, #1a0505 0%, #3e1212 100%);
}

.placeholder-fashion {
    background: linear-gradient(135deg, #1a1505 0%, #3e3212 100%);
}

.placeholder-community {
    background: linear-gradient(135deg, #05151a 0%, #12323e 100%);
}

/* Horizontal Scroll Snap */
.scroll-container {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    /* Hide vertical overflow */
    gap: var(--spacing-md);
    padding-bottom: var(--spacing-md);
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
    /* Firefox */
    -webkit-overflow-scrolling: touch;
}

.scroll-container::-webkit-scrollbar {
    height: 8px;
}

.scroll-container::-webkit-scrollbar-track {
    background: #111;
}

.scroll-container::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 4px;
}

.scroll-item {
    scroll-snap-align: center;
    flex: 0 0 85%;
    /* Mobile: show part of next card */
    min-width: 300px;
}

@media (min-width: 768px) {
    .scroll-item {
        flex: 0 0 400px;
        /* Desktop: fixed width cards */
    }
}