/* ==========================================================================
   EMERGENCE STYLE - EDITORIAL DESIGN
   ========================================================================== */

:root {
    /* Colors */
    --color-bg: #F9F9F7;
    --color-text: #050505;
    --color-text-light: #555555;
    --color-accent: #460C0C;
    --color-link: #1B9AAA;
    --color-highlight: #f3f3f3;
    --color-border: #E0E0E0;
    --color-white: #FFFFFF;
    --color-progress: #000000;
    
    /* Typography */
    --font-serif: 'Playfair Display', Georgia, serif;
    --font-sans: 'IBM Plex Sans', Helvetica, Arial, sans-serif;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 8rem;
    
    /* Layout */
    --width-text: 720px; /* Slightly wider text column */
    --width-wide: 1400px; /* Wider for gallery */
    --header-height: 80px;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 18px; /* Larger base font for reading */
    scroll-behavior: smooth;
}

body {
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-serif);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Typography Helpers */
h1, h2, h3, h4, h5, h6 {
    font-weight: 400;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
}

p {
    margin-bottom: var(--spacing-md);
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

/* ==========================================================================
   PROGRESS BAR
   ========================================================================== */
.progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    z-index: 1000;
    background: transparent;
}

.progress-bar {
    height: 100%;
    background-color: var(--color-progress);
    width: 0%;
    transition: width 0.1s ease-out;
}


/* ==========================================================================
   SCROLL ANIMATIONS (Atmos Style)
   ========================================================================== */
.content-wrapper,
/* .parallax-section,  <-- Removed from here to fix background-attachment: fixed */
.double-image-grid-vertical,
.figure-wide,
.article-body > *:not(.parallax-section) { /* Exclude parallax sections from transform animations */
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

/* Explicitly reset parallax-section properties just in case */
.parallax-section {
    opacity: 1; 
    transform: none !important; 
    transition: none !important;
    will-change: auto !important; /* Critical: prevent stacking context creation */
}

.content-wrapper.aos-animate,
/* .parallax-section.aos-animate, <-- Removed */
.double-image-grid-vertical.aos-animate,
.figure-wide.aos-animate,
.article-body > *:not(.parallax-section).aos-animate {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered delay for smoother flow */
.article-body p:nth-child(odd) { transition-delay: 0.1s; }
.article-body p:nth-child(even) { transition-delay: 0.2s; }

/* Reset for Hero elements which have their own keyframe animations */
.hero, .hero * {
    opacity: initial;
    transform: none;
    transition: none;
}

.hero-content {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1s ease-out forwards 0.5s;
}

.hero-logo-wrapper {
    opacity: 0;
    animation: fadeIn 1s ease-out forwards 1.2s;
}

.hero-sidebar {
    opacity: 0;
    animation: fadeIn 1s ease-out forwards 1s;
}

.hero-bottom {
    opacity: 0;
    transform: translateY(24px);
    animation: fadeInUp 1s ease-out forwards 0.7s;
}
.hero {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    color: var(--color-white);
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-background img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.1) 0%,
        rgba(0, 0, 0, 0) 30%,
        rgba(0, 0, 0, 0) 60%,
        rgba(0, 0, 0, 0.4) 100%
    );
    z-index: 2;
}

/* Tags - Bottom Right, aligned with hero title bottom */
.hero-sidebar {
    position: absolute;
    right: var(--spacing-lg);
    bottom: calc(var(--spacing-lg) + 0.35em);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: flex-end;
    gap: 0.5rem;
    opacity: 0;
    animation: fadeIn 1s ease-out forwards 1s;
}

.hero-tags-mobile {
    display: none;
}

.hero-tag {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    color: rgba(255, 255, 255, 0.9);
    padding: 0.5rem 1rem;
    border-radius: 12px;
    font-family: var(--font-sans);
    font-size: 0.7rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    text-decoration: none;
    border: none;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.hero-tag:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

/* Bottom Title */
.hero-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: var(--spacing-lg);
    z-index: 10;
    opacity: 0;
    animation: fadeInUp 1s ease-out forwards 0.5s;
}

.hero-title {
    font-family: var(--font-serif);
    font-size: clamp(3rem, 10vw, 8rem);
    font-weight: 400;
    line-height: 0.95;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    margin: 0;
}


/* Animations */
@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

@keyframes fadeInDown {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Top Navigation - Floating Black Pill */
.hero-top-nav {
    position: absolute;
    top: var(--spacing-sm);
    left: var(--spacing-lg);
    right: var(--spacing-lg);
    width: auto;
    padding: 0.6rem 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
    background: #000;
    border-radius: 999px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transform: translateY(-12px);
    animation: fadeInDown 0.8s ease forwards 0.2s;
}

.hero-top-nav .nav-logo {
    color: #fff;
}

.hero-top-nav .nav-btn {
    background: #fff;
    color: #000;
}

.hero-top-nav .nav-btn:hover {
    background: rgba(255, 255, 255, 0.9);
}

.hero-top-nav .nav-icon-btn {
    color: #fff;
}

.nav-logo {
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-accent);
    text-decoration: none;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-btn {
    color: var(--color-white);
    background: var(--color-accent);
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-family: var(--font-sans);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    border: none;
    transition: all 0.2s ease;
}

.nav-btn:hover {
    opacity: 0.85;
}

.nav-icon-btn {
    background: transparent;
    border: none;
    color: var(--color-accent);
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s ease;
}

.nav-icon-btn:hover {
    opacity: 0.7;
}

/* Sticky Navigation - Floating Black Pill */
.sticky-nav {
    position: fixed;
    top: var(--spacing-sm);
    left: var(--spacing-lg);
    right: var(--spacing-lg);
    width: auto;
    padding: 0.6rem 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background: #000;
    border-radius: 999px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
    transform: translateY(-200%);
    visibility: hidden;
    transition: transform 0.3s ease, visibility 0.3s ease;
}

.sticky-nav.visible {
    transform: translateY(0);
    visibility: visible;
}

.sticky-nav .nav-logo {
    color: #fff;
}

.sticky-nav .nav-btn {
    background: #fff;
    color: #000;
}

.sticky-nav .nav-btn:hover {
    background: rgba(255, 255, 255, 0.9);
}

.sticky-nav .nav-icon-btn {
    color: #fff;
}

/* ==========================================================================
   MAIN CONTENT
   ========================================================================== */
.article-body {
    padding-top: var(--spacing-xl);
    padding-bottom: var(--spacing-xl);
    counter-reset: ordered-list;
}

/* Audio Player Pill (Moved) */
.audio-player-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: var(--spacing-xl);
}

.audio-player-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background-color: var(--color-accent);
    color: var(--color-white);
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease;
    font-family: var(--font-sans);
    font-size: 0.85rem;
    font-weight: 500;
}

.audio-player-trigger:hover {
    transform: scale(1.02);
    opacity: 0.9;
}

.play-icon {
    width: 12px;
    height: 14px;
    background-color: currentColor;
    clip-path: polygon(0 0, 100% 50%, 0 100%);
}

/* Text Container */
.content-wrapper {
    max-width: var(--width-text);
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

/* Typography Styles */
.article-body p {
    font-family: var(--font-sans);
    font-size: 1.125rem;
    line-height: 1.8;
    margin-bottom: 1.75rem;
    color: var(--color-text);
    text-wrap: pretty; /* Avoid widows/orphans on modern browsers */
}

/* Lead text - same size, just in highlight box */
.article-body .lead {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-text);
}

/* Headings */
.article-body h2 {
    font-family: var(--font-serif);
    font-size: 1.65rem;
    font-weight: 700;
    color: var(--color-text);
    margin-top: var(--spacing-lg);
    margin-bottom: var(--spacing-md);
    line-height: 1.3;
    text-wrap: balance; /* Keep headings compact */
}

/* Links */
.article-body a {
    color: var(--color-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: opacity 0.2s ease;
}

/* Text Highlight (marker style) */
.article-body mark,
.article-body .highlight {
    background-color: var(--color-accent);
    color: var(--color-white);
    padding: 0.1em 0.35em;
    border-radius: 3px;
    font-weight: 500;
}

.article-body a:hover {
    opacity: 0.7;
}

/* Blockquote */
blockquote {
    position: relative;
    border: none;
    padding: 0;
    padding-left: var(--spacing-md);
    margin: var(--spacing-lg) 0;
    border-left: 3px solid var(--color-accent);
}

blockquote p {
    font-family: var(--font-serif);
    font-size: 1.125rem;
    font-style: normal;
    line-height: 1.8;
    color: var(--color-text);
    margin-bottom: 0;
}

/* Highlight Box */
.highlight-box {
    background: var(--color-highlight);
    border-radius: 8px;
    padding: var(--spacing-md);
    margin: var(--spacing-lg) 0;
    border-left: 4px solid var(--color-accent);
}

.highlight-box p {
    margin-bottom: 0;
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-text);
}

.highlight-box strong {
    color: var(--color-accent);
}

/* Lists */
.article-body ul {
    margin: 0.5rem 0 0.5rem 0;
    padding-left: 1.1rem;
    list-style: none;
}

.article-body ul li {
    position: relative;
    padding-left: 0.75rem;
    margin-bottom: 0.5rem;
    font-family: var(--font-sans);
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-text);
}

.article-body ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.6em;
    width: 6px;
    height: 6px;
    background: var(--color-text);
    border-radius: 50%;
}

/* Nested List */
.article-body ul ul {
    margin-top: 0.25rem;
    margin-bottom: 0.25rem;
}

.article-body ul ul li {
    font-size: 1.125rem;
    color: var(--color-text);
}

.article-body ul ul li::before {
    width: 5px;
    height: 5px;
    background: transparent;
    border: 1px solid var(--color-text);
}

/* Ordered Lists */
.article-body ol {
    list-style: none;
    margin: 0.75rem 0 0.75rem 0;
    padding-left: 0;
    counter-reset: ordered-list;
}

.article-body ol li {
    counter-increment: ordered-list;
    position: relative;
    padding-left: 2.25rem;
    margin-bottom: 0.75rem;
    font-family: var(--font-sans);
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-text);
}

.article-body ol li::before {
    content: counter(ordered-list) ".";
    position: absolute;
    left: 0;
    top: 0;
    width: 1.75rem;
    text-align: right;
    font-weight: 600;
    color: var(--color-text);
}

/* Video Block */
.video-block {
    width: 100%;
    max-width: 720px;
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.video-block .plyr {
    border-radius: 8px;
    overflow: hidden;
}

.video-block figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    text-transform: none;
    letter-spacing: 0.01em;
    color: var(--color-text-light);
}

/* Plyr custom colors */
.plyr {
    --plyr-color-main: #460C0C;
}

/* Fullscreen: don't crop vertical videos */
.plyr--fullscreen video,
.plyr:fullscreen video {
    object-fit: contain !important;
    width: 100%;
    height: 100%;
    background: #000;
}

/* Wide Images */
.figure-wide {
    width: 100%;
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    position: relative;
}

.figure-full {
    width: 100%;
    margin: var(--spacing-lg) 0;
}

.figure-wide img,
.figure-full img {
    width: 100%;
    height: auto;
    display: block;
}

figcaption {
    font-family: var(--font-sans);
    font-size: 0.95rem;
    color: var(--color-text-light);
    margin-top: var(--spacing-xs);
    text-align: center;
}

/* iPhone-style horizontal + vertical pair */
.iphone-photo-row {
    display: grid;
    grid-template-columns: minmax(0, 16fr) minmax(0, 9fr);
    gap: var(--spacing-md);
    align-items: stretch;
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.iphone-photo-row figure {
    margin: 0;
    display: flex;
    flex-direction: column;
}

.iphone-photo {
    width: 100%;
    border-radius: 6px;
    overflow: hidden;
}

.iphone-horizontal .iphone-photo {
    aspect-ratio: 4 / 3; /* native iPhone landscape feel */
}

.iphone-vertical .iphone-photo {
    aspect-ratio: 3 / 4; /* native iPhone portrait feel */
}

.iphone-photo-row img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.iphone-photo-row video,
.iphone-photo-row .plyr {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.iphone-photo-row .plyr__video-wrapper {
    height: 100%;
}

.iphone-photo-row figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    text-transform: none;
    letter-spacing: 0.01em;
    color: var(--color-text-light);
}

/* Double Image Grid - Vertical iPhone (3:4 aspect ratio) */
.double-image-grid-vertical {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-md);
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.double-image-grid-vertical figure {
    margin: 0;
}

.double-image-grid-vertical img {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 3/4;
    border-radius: 4px;
    cursor: zoom-in;
}

.double-image-grid-vertical video,
.double-image-grid-vertical .plyr {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 3/4;
    border-radius: 4px;
    display: block;
}

.double-image-grid-vertical .plyr__video-wrapper {
    height: 100%;
}

.double-image-grid-vertical figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    text-transform: none;
    letter-spacing: 0.01em;
    color: var(--color-text-light);
}

/* Photo + Video Grid (Vertical 3:4) */
.photo-video-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-md);
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.photo-video-grid figure {
    margin: 0;
}

.photo-video-grid .grid-photo img {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 3/4;
    border-radius: 4px;
}

.photo-video-grid .grid-video video,
.photo-video-grid .grid-video .plyr {
    width: 100%;
    height: auto;
    aspect-ratio: 3/4;
    object-fit: cover;
    border-radius: 4px;
}

.photo-video-grid .grid-video .plyr__video-wrapper {
    height: 100%;
}

.photo-video-grid figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    text-transform: none;
    letter-spacing: 0.01em;
    color: var(--color-text-light);
}

/* Triple Image Grid (Vertical 3:4) */
.triple-image-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.triple-image-grid figure {
    margin: 0;
}

.triple-image-grid img {
    width: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
    border-radius: 4px;
    cursor: zoom-in;
}

.triple-image-grid figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    text-transform: none;
    letter-spacing: 0.01em;
    color: var(--color-text-light);
}

.triple-image-grid video,
.triple-image-grid .plyr {
    width: 100%;
    height: auto;
    aspect-ratio: 3/4;
    object-fit: cover;
    border-radius: 4px;
}

.triple-image-grid .plyr__video-wrapper {
    height: 100%;
}

/* Lightbox */
.lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    padding: 2rem;
}

.lightbox-overlay.is-open {
    display: flex;
}

.lightbox-inner {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
}

.lightbox-image {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.55);
    background: #111;
}

.lightbox-close {
    position: absolute;
    top: -14px;
    right: -14px;
    width: 32px;
    height: 32px;
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 999px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    font-size: 18px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
    transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.lightbox-close:hover {
    transform: translateY(-1px);
    background: rgba(27,154,170,0.9);
    box-shadow: 0 12px 32px rgba(27,154,170,0.35);
}

/* Parallax Effect (Simple CSS only) */
.parallax-section {
    height: 40vh; /* Reduced height from 80vh to 40vh */
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    margin: var(--spacing-xl) 0;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.parallax-overlay {
    display: none;
}

.parallax-text {
    position: relative;
    color: var(--color-white);
    text-align: center;
    z-index: 10;
    /* Removed white background box for a cleaner look if text is white on image */
    background: transparent; 
    padding: var(--spacing-md);
    max-width: 600px;
}

.parallax-text h3 {
    font-family: var(--font-serif);
    font-size: 3rem;
    font-style: italic;
    margin-bottom: var(--spacing-sm);
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.parallax-text p {
    font-family: var(--font-sans);
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 0;
    text-shadow: 0 2px 5px rgba(0,0,0,0.5);
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.article-footer {
    border-top: 1px solid var(--color-border);
    max-width: var(--width-wide);
    margin: 0 auto;
    padding: var(--spacing-lg) var(--spacing-md);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: var(--spacing-md);
}

.footer-bio {
    flex: 1;
    min-width: 300px;
}

.footer-bio h4 {
    font-family: var(--font-sans);
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    margin-bottom: var(--spacing-sm);
}

.share-links {
    display: flex;
    gap: var(--spacing-sm);
}

.share-link {
    font-family: var(--font-sans);
    font-size: 0.9rem;
    text-decoration: underline;
}

/* Single wide image (4:3) */
.single-wide-4x3 {
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.single-wide-4x3 figure {
    margin: 0;
}

.single-wide-4x3 img {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 4/3;
    border-radius: 6px;
}

.single-wide-4x3 figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    color: var(--color-text-light);
}

/* Single wide image (16:9) */
.single-wide-16x9 {
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.single-wide-16x9 figure {
    margin: 0;
}

.single-wide-16x9 img {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 16/9;
    border-radius: 6px;
}

.single-wide-16x9 figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    color: var(--color-text-light);
}

/* ==========================================================================
   MEDIA GRID TEMPLATES - Шаблоны для копирования
   ========================================================================== */

/* --- 3 вертикальных элемента в ряд (3:4) --- */
.triple-vertical-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.triple-vertical-grid figure {
    margin: 0;
}

.triple-vertical-grid img,
.triple-vertical-grid video,
.triple-vertical-grid .plyr {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 3/4;
    border-radius: 4px;
}

.triple-vertical-grid .plyr__video-wrapper {
    height: 100%;
}

.triple-vertical-grid figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    color: var(--color-text-light);
}

/* --- 2 вертикальных + 1 вертикальное видео (3:4) --- */
.two-img-one-video-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.two-img-one-video-grid figure {
    margin: 0;
}

.two-img-one-video-grid img,
.two-img-one-video-grid video,
.two-img-one-video-grid .plyr {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 3/4;
    border-radius: 4px;
}

.two-img-one-video-grid .plyr__video-wrapper {
    height: 100%;
}

.two-img-one-video-grid figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    color: var(--color-text-light);
}

/* --- Горизонтальный (4:3) + Вертикальный (3:4) --- */
.horizontal-vertical-grid {
    --row-height: clamp(300px, 35vw, 550px);
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: var(--spacing-md);
    align-items: stretch;
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.horizontal-vertical-grid figure {
    margin: 0;
    display: flex;
    flex-direction: column;
}

.horizontal-vertical-grid .media-container {
    width: 100%;
    height: var(--row-height);
    border-radius: 6px;
    overflow: hidden;
}

.horizontal-vertical-grid .horizontal-item .media-container {
    aspect-ratio: 4/3;
}

.horizontal-vertical-grid .vertical-item .media-container {
    aspect-ratio: 3/4;
}

.horizontal-vertical-grid img,
.horizontal-vertical-grid video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.horizontal-vertical-grid .plyr {
    width: 100%;
    height: 100%;
}

.horizontal-vertical-grid .plyr__video-wrapper {
    height: 100%;
}

.horizontal-vertical-grid figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    color: var(--color-text-light);
}

/* --- 2 вертикальных элемента (3:4) --- */
.double-vertical-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-md);
    max-width: var(--width-wide);
    margin: var(--spacing-lg) auto;
    padding: 0 var(--spacing-sm);
}

.double-vertical-grid figure {
    margin: 0;
}

.double-vertical-grid img,
.double-vertical-grid video,
.double-vertical-grid .plyr {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 3/4;
    border-radius: 4px;
}

.double-vertical-grid .plyr__video-wrapper {
    height: 100%;
}

.double-vertical-grid figcaption {
    text-align: left;
    margin-top: var(--spacing-sm);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    color: var(--color-text-light);
}

/* Footer bar */
.footer-bar {
    margin: var(--spacing-xl) 0 0;
    padding: 2.5rem var(--spacing-xl);
    width: 100%;
    border-radius: 0;
    background: rgba(5,5,5,0.9);
    border: 1px solid rgba(255,255,255,0.18);
    box-shadow: 0 14px 40px -22px rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-sm);
}

.footer-brand {
    font-family: var(--font-sans);
    font-weight: 700;
    font-size: 1.1rem;
    color: #fff;
    display: flex;
    flex-direction: column;
}

.footer-subtitle {
    font-weight: 400;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.7);
    margin-top: 2px;
}

.footer-actions {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-cta {
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
    margin-right: 1rem;
    font-family: var(--font-sans);
}

.footer-icons {
    display: inline-flex;
    gap: 0.5rem;
}

.footer-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: rgba(255,255,255,0.08);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.18);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.5);
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s ease, color 0.2s ease;
}

.footer-btn:hover {
    transform: translateY(-1px);
    background: #1B9AAA;
    color: #fff;
    box-shadow: 0 6px 16px -12px rgba(27, 154, 170, 0.55);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 768px) {
    /* Base font size on mobile (tuned down from previous bump) */
    html {
        font-size: 18px;
    }

    /* Hero */
    .hero {
        height: 85vh;
    }

    .hero-title {
        font-size: clamp(1.75rem, 10vw, 3rem);
    }

    .hero-top-nav,
    .sticky-nav {
        left: var(--spacing-sm);
        right: var(--spacing-sm);
        padding: 0.5rem 1rem;
    }

    .hero-bottom {
        padding: var(--spacing-sm);
        padding-right: 0;
        bottom: 5%;
    }

    /* Tags - horizontal on mobile, bottom left */
    .hero-sidebar {
        display: none;
    }

    .hero-tags-mobile {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
        margin-top: 1rem;
    }

    .hero-tag {
        padding: 0.3rem 0.6rem;
        font-size: 0.55rem;
        border-radius: 6px;
    }

    .nav-logo {
        font-size: 0.9rem;
    }

    .nav-btn {
        padding: 0.35rem 0.75rem;
        font-size: 0.7rem;
    }

    .nav-icon-btn svg {
        width: 18px;
        height: 18px;
    }

    .sticky-nav {
        padding: 0.6rem var(--spacing-sm);
    }

    /* Content typography - all same size on mobile */
    .article-body p,
    .article-body .lead,
    blockquote p,
    .highlight-box p,
    .article-body ul li,
    .article-body ul ul li,
    .article-body ol li {
        font-size: 1rem;
        line-height: 1.7;
    }

    .article-body p {
        margin-bottom: 1.25rem;
    }

    .article-body h2 {
        font-size: 1.35rem;
        margin-top: var(--spacing-md);
        margin-bottom: var(--spacing-sm);
    }

    blockquote {
        padding-left: var(--spacing-sm);
        margin: var(--spacing-md) 0;
    }

    .highlight-box {
        padding: var(--spacing-sm);
        margin: var(--spacing-md) 0;
    }

    .article-body ul li {
        padding-left: 0.75rem;
    }

    .article-body ol li {
        padding-left: 2rem;
        margin-bottom: 0.75rem;
    }

    .article-body ol li::before {
        width: 1.5rem;
    }

    /* Images */
    .iphone-photo-row,
    .double-image-grid-vertical,
    .photo-video-grid {
        grid-template-columns: 1fr;
    }

    .iphone-photo-row {
        --iphone-row-height: auto;
    }

    .iphone-photo {
        height: auto;
    }

    .triple-image-grid,
    .triple-vertical-grid,
    .two-img-one-video-grid {
        grid-template-columns: 1fr;
    }

    .horizontal-vertical-grid {
        grid-template-columns: 1fr;
        --row-height: auto;
    }

    .horizontal-vertical-grid .media-container {
        height: auto;
    }

    .double-vertical-grid {
        grid-template-columns: 1fr;
    }

    /* Spacing */
    :root {
        --spacing-lg: 1.5rem;
        --spacing-xl: 3rem;
    }

    .content-wrapper {
        padding: 0 1rem;
    }

    .parallax-section {
        background-attachment: scroll;
        height: 30vh;
    }

    .parallax-text h3 {
        font-size: 2rem;
    }

    .parallax-text p {
        font-size: 0.9rem;
    }

    /* Footer Mobile Adjustments */
    .footer-bar {
        padding: 2rem 1.5rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }
    
    .footer-brand {
        margin-bottom: 0.5rem;
    }
    
    .footer-actions {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
        width: 100%;
    }
    
    .footer-cta {
        margin-right: 0;
        margin-bottom: 0.25rem;
        display: block;
        max-width: 100%;
    }
    
    .footer-icons {
        margin-top: 0.25rem;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .hero-title {
        font-size: clamp(1.5rem, 9vw, 2.5rem);
    }

    .hero-sidebar {
        max-width: 70%;
    }

    .hero-tag {
        font-size: 0.5rem;
        padding: 0.25rem 0.5rem;
    }

    .nav-btn {
        display: none;
    }

    /* All text same size on extra small */
    .article-body p,
    blockquote p,
    .highlight-box p,
    .article-body ul li,
    .article-body ul ul li {
        font-size: 0.95rem;
    }
}
