/* ============================================================
   AWS SBG AdU — Desktop & tablet adaptive layout
   ============================================================ */

/* Tablet */
@media (max-width: 1024px) {
    .join-page,
    .sbg-page,
    .events-page,
    .of-page,
    .oh-page {
        padding-top: calc(110px * var(--ui-scale));
    }
}

/* Home — index horizontal sections */
@media (max-width: 1024px) {
    .page-section {
        padding-left: var(--page-padding);
        padding-right: var(--page-padding);
    }

    .top-bar {
        left: var(--page-padding);
    }

    .section2 {
        padding: calc(56px * var(--ui-scale)) var(--page-padding) calc(16px * var(--ui-scale));
    }

    .section3-stage {
        padding: calc(60px * var(--ui-scale)) var(--page-padding) calc(30px * var(--ui-scale));
    }
}

@media (min-width: 1025px) {
    /* Scale index hero typography */
    .section1-content h1 {
        font-size: calc(var(--text-hero) * var(--ui-scale));
    }

    .section1-content p {
        font-size: calc(var(--text-subtitle) * var(--ui-scale));
    }

    .section3-stat-number {
        font-size: calc(36px * var(--ui-scale));
    }

    .section3-stat-label {
        font-size: calc(var(--text-sm) * var(--ui-scale));
    }

    /* Finder windows scale down on smaller desktops */
    .ev-finder-window,
    .oh-finder-window,
    .sbg-finder-window,
    .of-finder-window,
    .jf-finder-window,
    .section3-window {
        font-size: calc(14px * var(--ui-scale));
    }
}

/* Short viewports — keep home sections visible */
@media (max-height: 800px) and (min-width: 1025px) {
    .section2 {
        justify-content: flex-start;
        padding-top: calc(84px * var(--ui-scale));
        padding-bottom: calc(28px * var(--ui-scale));
        gap: calc(10px * var(--ui-scale));
    }

    .home-page .section2-header .section2-subtitle {
        margin-bottom: clamp(6px, 0.8vh, 12px);
    }

    .home-page .section2-events-grid {
        margin-top: clamp(24px, 3vh, 44px);
        gap: clamp(8px, 1vw, 12px);
    }

    .home-page .section2-event-card-image {
        flex: 1 1 auto;
        min-height: clamp(92px, 16vh, 155px);
        height: auto;
    }

    .home-page .section2-event-card-content {
        padding: clamp(8px, 0.9vh, 12px);
    }

    .home-page .section2-view-all-card {
        padding: clamp(8px, 1vh, 14px) clamp(10px, 1vw, 14px);
    }

    .home-page .section2-header h2 {
        font-size: clamp(1.375rem, 1rem + 1.6vw, 2rem);
    }

    .home-page .section2-header .section2-subtitle {
        font-size: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
    }

    .home-page .section2-event-card-title {
        font-size: clamp(0.8125rem, 0.74rem + 0.3vw, 0.9375rem);
    }

    .home-page .section2-event-card-desc {
        font-size: clamp(0.6875rem, 0.64rem + 0.2vw, 0.75rem);
    }
}

@media (max-height: 700px) and (min-width: 1025px) {
    .section1-content h1 {
        font-size: calc(clamp(1.5rem, 3vw, 2rem) * var(--ui-scale));
        margin-bottom: calc(12px * var(--ui-scale));
    }

    .home-page .section2-header h2 {
        font-size: clamp(1.25rem, 0.9rem + 1.4vw, 1.75rem);
    }

    .home-page .section2-header .section2-subtitle {
        font-size: clamp(0.6875rem, 0.64rem + 0.2vw, 0.8125rem);
    }

    .home-page .section2-event-card-title {
        font-size: clamp(0.75rem, 0.68rem + 0.25vw, 0.875rem);
    }

    .home-page .section2-event-card-desc {
        font-size: clamp(0.625rem, 0.58rem + 0.18vw, 0.6875rem);
    }

    .home-page .section2-event-card-speaker,
    .home-page .section2-event-card-link {
        font-size: clamp(0.625rem, 0.58rem + 0.15vw, 0.6875rem);
    }

    .home-page .section2-event-card-image {
        flex: 1 1 auto;
        min-height: clamp(76px, 13vh, 120px);
        height: auto;
    }

    .home-page .section2-view-all-card {
        padding: clamp(6px, 0.8vh, 10px) clamp(8px, 0.9vw, 12px);
    }

    .home-page .section2-view-all-card-btn {
        min-width: clamp(150px, 14vw, 170px);
        height: clamp(48px, 5.2vh, 56px);
        padding: clamp(12px, 1.2vh, 16px) clamp(24px, 2.5vw, 32px);
        font-size: clamp(0.875rem, 0.8rem + 0.2vw, 1rem);
        margin-top: clamp(14px, 1.8vh, 22px);
    }
}

/* Container-based card behavior */
.ev-preview-panel,
.section2-event-card,
.of-card,
.ev-stat,
.oh-stat {
    container-type: inline-size;
}

@container (max-width: 320px) {
    .section2-event-card-footer {
        flex-wrap: nowrap;
        justify-content: space-between;
        align-items: center;
    }

    .section2-event-card-speaker {
        font-size: 10px;
    }

    .section2-event-card-link {
        font-size: 11px;
    }
}

/* Prevent horizontal overflow on all pages */
html,
body {
    overflow-x: hidden;
}

body:not(.home-page) {
    overflow-x: hidden;
    overflow-y: auto;
}

/* Mobile menu elements never show on desktop/tablet */
@media (min-width: 1025px) and (hover: hover) and (pointer: fine) {
    .mnav-toggle,
    .mnav-sheet,
    .mnav-backdrop {
        display: none !important;
    }
}

/* Laptops & desktops: always run the Section 1 moving carousel */
@media (min-width: 1025px) {
    .home-page .section1-carousel-track {
        display: flex !important;
        animation: slideCarousel 6.5s linear infinite !important;
        animation-play-state: running !important;
        width: auto;
    }

    .home-page .section1-carousel-track {
        will-change: transform;
    }

    .home-page .section1-carousel-window {
        overflow: hidden;
        padding: 0 clamp(20px, 2.5vw, 38px);
    }

    .home-page .section1-carousel-slide {
        display: block !important;
        flex: 0 0 65%;
        min-width: min(400px, 38vw);
    }

    .home-page .section1-carousel-slide:first-child,
    .home-page .section1-carousel-slide:nth-child(4) {
        opacity: 0.5;
    }
}

/* ============================================================
   Section 1 hero — keep clear of the fixed nav and scale with
   viewport height so it never clashes on smaller laptops
   (e.g. Dell 7420 at 100%/125%).
   ============================================================ */
@media (min-width: 1025px) {
    .home-page .page-section.section1 {
        align-items: stretch;
        justify-content: flex-start;
        padding-top: clamp(112px, 13vh, 148px);
        padding-bottom: clamp(48px, 7vh, 80px);
        padding-left: clamp(48px, 5vw, 88px);
        padding-right: clamp(48px, 5vw, 88px);
        gap: clamp(20px, 3.5vw, 56px);
        box-sizing: border-box;
    }

    .home-page .section1-content {
        flex: 0 1 clamp(280px, 32vw, 520px);
        min-width: 0;
        max-width: clamp(300px, 32vw, 520px);
        text-align: left;
        align-self: center;
        margin-top: clamp(20px, 4.5vh, 50px);
    }

    .home-page .section1-hero-logo {
        width: clamp(96px, 9vmin, 140px);
        height: clamp(96px, 9vmin, 140px);
        margin-bottom: clamp(16px, 2.5vh, 28px);
    }

    .home-page .section1-content h1 {
        margin-bottom: clamp(14px, 2vh, 20px);
    }

    .home-page .section1-content h1 .section1-title {
        font-size: clamp(1.75rem, 1rem + 1.5vw + 0.6vh, 3.25rem);
        align-items: flex-start;
    }

    .home-page .section1-content h1 .section1-title .section1-title-line1,
    .home-page .section1-content h1 .section1-title .section1-title-line2,
    .home-page .section1-content h1 .section1-title .section1-title-line3 {
        text-align: left;
    }

    .home-page .section1-lead {
        font-size: clamp(0.9375rem, 0.82rem + 0.35vw, 1.125rem);
        line-height: 1.6;
        margin-bottom: clamp(10px, 1.4vh, 16px);
    }

    .home-page .section1-motto {
        font-size: clamp(0.875rem, 0.78rem + 0.28vw, 1.0625rem);
        line-height: 1.55;
        margin-bottom: clamp(20px, 3vh, 32px);
    }

    .home-page .section1-btn {
        font-size: clamp(0.875rem, 0.8rem + 0.2vw, 1rem);
        min-width: clamp(150px, 14vw, 170px);
        height: clamp(48px, 5.2vh, 56px);
        padding: clamp(12px, 1.2vh, 16px) clamp(24px, 2.5vw, 32px);
    }

    .home-page .section1-card-wrapper {
        flex: 1 1 clamp(380px, 50vw, 960px);
        min-width: 0;
        max-width: none;
        padding-left: 0;
        padding-top: clamp(24px, 4vh, 48px);
        padding-bottom: clamp(24px, 4vh, 48px);
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        align-self: stretch;
        min-height: 0;
        height: 100%;
        box-sizing: border-box;
    }

    .home-page .section1-glass-card {
        width: 100%;
        max-width: min(960px, 100%);
        flex: 1 1 auto;
        min-height: 0;
        height: 100%;
        max-height: 100%;
    }

    .home-page .section1-card-media {
        flex: 1 1 auto;
        min-height: clamp(140px, 20vh, 220px);
        height: auto;
        width: calc(100% - clamp(24px, 2.5vw, 36px));
        margin: clamp(10px, 1.2vh, 14px) clamp(12px, 1.6vw, 18px) 0;
    }

    .home-page .section1-carousel-window,
    .home-page .section1-carousel-track,
    .home-page .section1-carousel-slide {
        height: 100%;
        min-height: 100%;
    }

    .home-page .section1-card-topbar,
    .home-page .section1-card-bottombar {
        flex-shrink: 0;
    }

    .home-page .section1-glass-card h2 {
        font-size: clamp(1rem, 0.85rem + 0.75vw, 1.5rem);
        padding: clamp(10px, 1.6vh, 18px) clamp(14px, 2vw, 24px) 0;
        flex-shrink: 0;
    }

    .home-page .section1-glass-card p {
        font-size: clamp(0.8125rem, 0.75rem + 0.25vw, 1.0625rem);
        padding: clamp(8px, 1vh, 12px) clamp(14px, 2vw, 24px) clamp(12px, 1.6vh, 16px);
        flex-shrink: 0;
    }

    .home-page .section1-carousel-slide {
        min-width: min(400px, 38vw);
    }
}

/* Home — section 2 fluid typography (scales with viewport width & height) */
@media (min-width: 1025px) {
    .home-page .section2-header .page-label {
        font-size: clamp(0.625rem, 0.54rem + 0.28vw, 0.75rem);
        margin-bottom: clamp(8px, 1.2vh, 12px);
    }

    .home-page .section2-header h2 {
        font-size: clamp(1.75rem, 1.05rem + 2vw + 0.45vh, 3.25rem);
        margin-bottom: clamp(6px, 1vh, 10px);
    }

    .home-page .section2-header .section2-subtitle {
        font-size: clamp(0.8125rem, 0.74rem + 0.38vw + 0.08vh, 1.0625rem);
    }

    .home-page .section2-event-card-content {
        padding: clamp(14px, 1.2vw + 0.6vh, 22px);
        gap: clamp(6px, 0.8vh, 10px);
        flex: 0 0 auto;
    }

    .home-page .section2-event-card-title {
        font-size: clamp(0.875rem, 0.78rem + 0.48vw, 1.125rem);
    }

    .home-page .section2-event-card-desc {
        font-size: clamp(0.6875rem, 0.64rem + 0.32vw, 0.8125rem);
    }

    .home-page .section2-event-card-speaker {
        font-size: clamp(0.625rem, 0.56rem + 0.22vw, 0.6875rem);
    }

    .home-page .section2-event-card-link {
        font-size: clamp(0.6875rem, 0.62rem + 0.28vw, 0.8125rem);
    }

    .home-page .section2-event-date-day {
        font-size: clamp(1rem, 0.88rem + 0.55vw, 1.375rem);
    }

    .home-page .section2-event-date-month {
        font-size: clamp(0.5rem, 0.46rem + 0.18vw, 0.625rem);
    }

    .home-page .section2-event-card-badge {
        font-size: clamp(0.5625rem, 0.5rem + 0.22vw, 0.6875rem);
        padding: clamp(4px, 0.5vh, 5px) clamp(10px, 1vw, 14px);
    }

    .home-page .section2-view-all-card-label {
        font-size: clamp(0.625rem, 0.55rem + 0.28vw, 0.6875rem);
    }

    .home-page .section2-view-all-card-title {
        font-size: clamp(1rem, 0.88rem + 0.65vw, 1.375rem);
    }

    .home-page .section2-view-all-card-desc {
        font-size: clamp(0.75rem, 0.68rem + 0.32vw, 0.875rem);
    }

    .home-page .section2-view-all-card-btn {
        min-width: clamp(150px, 14vw, 170px);
        height: clamp(48px, 5.2vh, 56px);
        padding: clamp(12px, 1.2vh, 16px) clamp(24px, 2.5vw, 32px);
        font-size: clamp(0.875rem, 0.8rem + 0.2vw, 1rem);
        margin-top: clamp(16px, 2vh, 24px);
    }
}

@media (min-width: 1025px) and (max-width: 1280px) {
    .home-page .section2-header h2 {
        font-size: clamp(1.5rem, 0.95rem + 2.4vw, 2.25rem);
    }

    .home-page .section2-event-card-title {
        font-size: clamp(0.8125rem, 0.74rem + 0.4vw, 1rem);
    }

    .home-page .section2-events-grid {
        gap: clamp(8px, 1vw, 14px);
    }

    .home-page .section2-event-card-image {
        flex: 1 1 auto;
        min-height: clamp(68px, 11vh, 130px);
        height: auto;
    }
}

/* Home — section 2 fills viewport (no internal scroll) */
@media (min-width: 1025px) {
    .home-page .page-section.section2 {
        height: 100vh;
        max-height: 100vh;
        overflow: hidden;
        justify-content: flex-start;
        padding-top: clamp(104px, 12vh, 136px);
        padding-bottom: clamp(52px, 7vh, 88px);
        padding-left: clamp(48px, 5vw, 88px);
        padding-right: clamp(48px, 5vw, 88px);
        gap: clamp(8px, 1.2vh, 14px);
    }

    .home-page .section2-header {
        flex-shrink: 0;
    }

    .home-page .section2-events-grid {
        flex: 0 1 auto;
        min-height: 0;
        max-height: min(70vh, 620px);
        margin-top: clamp(32px, 3.5vh, 52px);
        margin-bottom: clamp(16px, 2.5vh, 32px);
        gap: clamp(10px, 1.2vw, 18px);
        max-width: min(1160px, 93vw);
        grid-template-rows: minmax(0, 1fr);
        align-self: center;
    }

    .home-page .section2-event-card,
    .home-page .section2-view-all-card {
        min-height: 0;
        max-height: 100%;
        border-radius: clamp(12px, 1.1vw, 18px);
    }

    .home-page .section2-event-card-image {
        flex: 1 1 auto;
        min-height: clamp(132px, 22vh, 290px);
        height: auto;
    }

    .home-page .section2-event-card-content {
        flex: 0 0 auto;
    }

    .home-page .section2-event-card-badge {
        top: clamp(8px, 1vh, 12px);
        right: clamp(8px, 1vw, 12px);
    }

    .home-page .section2-event-date-box {
        padding: clamp(4px, 0.5vh, 6px) clamp(8px, 0.8vw, 12px);
        min-width: clamp(40px, 3.5vw, 48px);
        border-radius: clamp(8px, 0.8vw, 12px);
    }

    .home-page .section2-view-all-card {
        padding: clamp(10px, 1.2vh, 19px) clamp(11px, 1.15vw, 19px);
    }

    .home-page .section2-view-all-card-btn {
        min-width: clamp(150px, 14vw, 170px);
        height: clamp(48px, 5.2vh, 56px);
        padding: clamp(12px, 1.2vh, 16px) clamp(24px, 2.5vw, 32px);
        font-size: clamp(0.875rem, 0.8rem + 0.2vw, 1rem);
        margin-top: clamp(14px, 1.8vh, 22px);
    }
}

/* Shorter laptop screens (e.g. Dell 7420 at 100%/125%): shrink the hero so
   it never tucks under the fixed nav. */
@media (min-width: 1025px) and (max-height: 880px) {
    .home-page .page-section.section1 {
        padding-top: clamp(104px, 12vh, 124px);
        padding-bottom: clamp(36px, 5.5vh, 56px);
    }

    .home-page .section1-hero-logo {
        width: 92px;
        height: 92px;
        margin-bottom: 14px;
    }

    .home-page .section1-content h1 {
        margin-bottom: 12px;
    }

    .home-page .section1-content h1 .section1-title {
        font-size: clamp(2.2rem, 3.2vw, 3.1rem);
        line-height: 1.06;
    }

    .home-page .section1-lead {
        font-size: 0.95rem;
        line-height: 1.5;
        margin-bottom: 12px;
    }

    .home-page .section1-motto {
        font-size: 0.9rem;
        margin-bottom: 18px;
    }

    .home-page .section1-card-media {
        min-height: clamp(110px, 16vh, 160px);
    }

    .home-page .section1-card-wrapper {
        padding-top: clamp(16px, 3vh, 28px);
        padding-bottom: clamp(16px, 3vh, 28px);
    }

    .home-page .page-section.section2 {
        padding-top: clamp(96px, 11vh, 112px);
        padding-bottom: clamp(36px, 5vh, 56px);
        gap: clamp(6px, 1vh, 10px);
    }

    .home-page .section2-event-card-image {
        flex: 1 1 auto;
        min-height: clamp(112px, 18vh, 190px);
        height: auto;
    }

    .home-page .section2-events-grid {
        margin-top: clamp(18px, 2.2vh, 32px);
    }
}

@media (min-width: 1025px) and (max-height: 730px) {
    .home-page .page-section.section1 {
        padding-top: clamp(96px, 11vh, 112px);
        padding-bottom: clamp(28px, 4.5vh, 44px);
    }

    .home-page .section1-hero-logo {
        width: 72px;
        height: 72px;
        margin-bottom: 10px;
    }

    .home-page .section1-content h1 .section1-title {
        font-size: clamp(1.85rem, 2.8vw, 2.6rem);
    }

    .home-page .section1-lead {
        font-size: 0.9rem;
        margin-bottom: 10px;
    }

    .home-page .section1-motto {
        font-size: 0.85rem;
        margin-bottom: 14px;
    }

    .home-page .section1-card-media {
        min-height: clamp(96px, 14vh, 140px);
    }

    .home-page .section1-card-wrapper {
        padding-top: clamp(12px, 2.5vh, 20px);
        padding-bottom: clamp(12px, 2.5vh, 20px);
    }

    .home-page .section2-event-card-image {
        flex: 1 1 auto;
        min-height: clamp(76px, 13vh, 120px);
        height: auto;
    }

    .home-page .section2-view-all-card {
        padding: clamp(6px, 0.8vh, 10px) clamp(8px, 0.9vw, 12px);
    }
}

/* Narrow desktop widths: prevent the hero text from crowding the card */
@media (min-width: 1025px) and (max-width: 1100px) {
    .home-page .section1-content {
        max-width: clamp(280px, 42vw, 460px);
    }
}

/* ============================================================
   Laptop (1025px – 1279px)
   ============================================================ */
@media (min-width: 1025px) and (max-width: 1279px) {
    .home-page .section1-content {
        max-width: clamp(300px, 34vw, 460px);
        flex-basis: clamp(300px, 34vw, 460px);
    }

    .home-page .section1-glass-card {
        max-width: min(820px, 100%);
    }
}

/* ============================================================
   Large desktop — bigger community hub card
   ============================================================ */
@media (min-width: 1440px) {
    .home-page .page-section.section1 {
        padding-left: clamp(72px, 5vw, 120px);
        padding-right: clamp(72px, 5vw, 120px);
        gap: clamp(36px, 4vw, 80px);
    }

    .home-page .section1-content {
        flex: 0 1 540px;
        max-width: 540px;
    }

    .home-page .section1-card-wrapper {
        flex: 1 1 720px;
    }

    .home-page .section1-glass-card {
        max-width: min(1120px, 100%);
    }

    .home-page .section1-carousel-slide {
        min-width: min(460px, 34vw);
    }

    .home-page .section1-glass-card h2 {
        font-size: clamp(1.15rem, 0.9rem + 0.5vw, 1.625rem);
        padding: clamp(12px, 1.8vh, 20px) clamp(18px, 2.2vw, 28px) 0;
    }

    .home-page .section1-glass-card p {
        font-size: clamp(0.875rem, 0.8rem + 0.18vw, 1.0625rem);
        padding: clamp(8px, 1.2vh, 12px) clamp(18px, 2.2vw, 28px) clamp(14px, 1.8vh, 18px);
    }

    .home-page .section2-events-grid {
        max-width: min(1220px, 91vw);
        max-height: min(72vh, 640px);
    }

    .home-page .section2-event-card-image {
        min-height: clamp(158px, 24vh, 308px);
    }
}

@media (min-width: 1920px) {
    .home-page .page-section.section1 {
        padding-left: clamp(96px, 6vw, 140px);
        padding-right: clamp(96px, 6vw, 140px);
    }

    .home-page .section1-glass-card {
        max-width: min(1320px, 100%);
    }

    .home-page .section1-carousel-slide {
        min-width: min(520px, 30vw);
    }

    .home-page .section1-glass-card h2 {
        font-size: clamp(1.25rem, 1rem + 0.4vw, 1.75rem);
    }

    .home-page .section1-glass-card p {
        font-size: clamp(0.9375rem, 0.88rem + 0.12vw, 1.125rem);
    }

    .home-page .section2-events-grid {
        max-width: min(1280px, 89vw);
        max-height: min(74vh, 660px);
    }

    .home-page .section2-event-card-image {
        min-height: clamp(182px, 27vh, 335px);
    }
}

/* ============================================================
   Desktop browser zoom > ~110% — mobile-like section 1 stack.
   Applied via body.desktop-zoom-stack (set by JS from estimated
   browser zoom). At 110% and below the side-by-side hero with
   the moving carousel card is kept exactly as designed.
   ============================================================ */
.home-page.desktop-zoom-stack .horizontal-container {
    scroll-snap-type: y proximity;
}

.home-page.desktop-zoom-stack .page-section.section1 {
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    height: auto;
    min-height: 100vh;
    overflow: visible;
    scroll-snap-stop: normal;
    padding: clamp(96px, 14vh, 128px) clamp(24px, 5vw, 48px) clamp(32px, 6vh, 56px);
    gap: 0;
}

.home-page.desktop-zoom-stack .section1-content {
    flex: none;
    width: 100%;
    max-width: 640px;
    text-align: center;
    padding-top: 0;
}

.home-page.desktop-zoom-stack .section1-hero-logo {
    width: 120px;
    height: 120px;
    margin: 0 auto 24px;
}

.home-page.desktop-zoom-stack .section1-content h1 {
    margin-bottom: 16px;
}

.home-page.desktop-zoom-stack .section1-content h1 .section1-title {
    align-items: center;
    font-size: clamp(2rem, 5vw, 2.6rem);
}

.home-page.desktop-zoom-stack .section1-content h1 .section1-title .section1-title-line1,
.home-page.desktop-zoom-stack .section1-content h1 .section1-title .section1-title-line2,
.home-page.desktop-zoom-stack .section1-content h1 .section1-title .section1-title-line3 {
    text-align: center;
}

.home-page.desktop-zoom-stack .section1-content p {
    font-size: clamp(0.95rem, 2vw, 1.05rem);
    margin-bottom: 24px;
}

.home-page.desktop-zoom-stack .section1-buttons {
    justify-content: center;
    margin-top: 0;
}

.home-page.desktop-zoom-stack .section1-card-wrapper {
    flex: none;
    width: 100%;
    max-width: 640px;
    margin-top: 32px;
    padding-left: 0;
    justify-content: center;
}

.home-page.desktop-zoom-stack .section1-glass-card {
    max-width: 100%;
    padding: 0;
    transform: none !important;
    transition: none !important;
}

.home-page.desktop-zoom-stack .section1-card-topbar {
    margin: 0;
}

.home-page.desktop-zoom-stack .section1-card-bottombar {
    margin: 0;
    margin-top: auto;
}

.home-page.desktop-zoom-stack .section1-glass-card h2 {
    font-size: 1.15rem;
    padding: 16px 16px 0;
}

.home-page.desktop-zoom-stack .section1-glass-card p {
    font-size: 0.9rem;
    padding: 10px 16px 16px;
}

.home-page.desktop-zoom-stack .section1-card-media {
    width: calc(100% - 32px);
    margin: 16px 16px 0;
    height: 200px;
}

.home-page.desktop-zoom-stack .page-section.section2 {
    height: auto;
    min-height: 100vh;
    overflow: visible;
    scroll-snap-stop: normal;
    padding-top: clamp(96px, 14vh, 124px);
    padding-bottom: clamp(32px, 6vh, 52px);
}

.home-page.desktop-zoom-stack .section3-stage {
    height: auto;
    min-height: 100vh;
    overflow: visible;
    scroll-snap-stop: normal;
    padding-top: clamp(88px, 12vh, 112px);
    padding-bottom: clamp(28px, 5vh, 48px);
}

/* Section 3 finder — compact typography & flexible grid when zoomed > ~110% */
.home-page.desktop-zoom-stack .section3-window {
    height: auto;
    max-height: none;
    min-height: 0;
}

.home-page.desktop-zoom-stack .section3-body {
    overflow: visible;
}

.home-page.desktop-zoom-stack .section3-main {
    overflow: hidden;
    padding: 0;
}

.home-page.desktop-zoom-stack .section3-notes-toolbar {
    padding: 8px 10px;
    min-height: 44px;
}

.home-page.desktop-zoom-stack .section3-notes-toolbar-actions {
    display: none;
}

.home-page.desktop-zoom-stack .section3-notes-list {
    width: 36%;
    min-width: 160px;
}

.home-page.desktop-zoom-stack .section3-notes-list-item-title {
    font-size: 12px;
}

.home-page.desktop-zoom-stack .section3-notes-list-item-snippet,
.home-page.desktop-zoom-stack .section3-notes-list-item-meta {
    font-size: 10px;
}

.home-page.desktop-zoom-stack .section3-notes-detail {
    padding: 16px 18px 20px;
}

.home-page.desktop-zoom-stack .section3-notes-pane-title {
    font-size: 20px;
}

.home-page.desktop-zoom-stack .section3-notes-pane-body {
    font-size: 12px;
    line-height: 1.5;
}

.home-page.desktop-zoom-stack .section3-notes-pane-tags span {
    font-size: 12px;
}

.home-page.desktop-zoom-stack .section3-stat-grid {
    gap: 8px;
    grid-template-rows: auto auto;
    flex: none;
}

.home-page.desktop-zoom-stack .section3-stat-item {
    padding: 8px 6px;
}

.home-page.desktop-zoom-stack .section3-stat-number {
    font-size: 22px;
}

.home-page.desktop-zoom-stack .section3-stat-label {
    font-size: 9px;
    margin-top: 2px;
}

.home-page.desktop-zoom-stack .section3-feature-grid {
    gap: 6px;
    margin-top: 0;
}

.home-page.desktop-zoom-stack .section3-feature-item {
    font-size: 11px;
    padding: 6px 8px;
    gap: 6px;
}

.home-page.desktop-zoom-stack .section3-join-wrap {
    margin-top: 8px;
    padding: 4px 6px 2px 2px;
}

.home-page.desktop-zoom-stack .section3-join-wrap .section1-btn {
    min-width: 120px;
    height: 36px;
    padding: 8px 18px;
    font-size: 12px;
}

.home-page.desktop-zoom-stack .section3-sidebar {
    width: 148px;
}

.home-page.desktop-zoom-stack .section3-sidebar-item {
    font-size: 11px;
    padding: 5px 10px;
}

.home-page.desktop-zoom-stack .section3-sidebar-label {
    font-size: 9px;
    padding: 6px 12px 3px;
}

.home-page.desktop-zoom-stack .section3-title {
    font-size: 11px;
}

.home-page.desktop-zoom-stack .section3-footer {
    font-size: 10px;
    padding: 6px 14px;
}

.home-page.desktop-zoom-stack .section3-footer-items {
    gap: 10px;
}

/* ============================================================
   iPad / tablet — keep Section 1 slideshow slides rectangular
   (Mini, Air, Pro — portrait & landscape). Flex-grown media
   height was squaring the 65%-width carousel slides.
   ============================================================ */
@media (min-width: 1025px) and (max-width: 1366px) {
    .home-page .section1-card-wrapper {
        align-self: center;
        height: auto;
    }

    .home-page .section1-glass-card {
        flex: 0 1 auto;
        height: auto;
        max-height: none;
    }

    .home-page .section1-card-media {
        flex: 0 0 auto;
        height: clamp(220px, 26vh, 275px);
        min-height: 220px;
        max-height: 275px;
    }

    .home-page .section1-carousel-window,
    .home-page .section1-carousel-track,
    .home-page .section1-carousel-slide {
        height: 100%;
        min-height: 0;
    }

    .home-page .section1-carousel-slide {
        flex: 0 0 65%;
        min-width: min(340px, 44vw);
    }
}
