/* ==========================================================================
   ThinkLab Dark — homepage (front-page.php)
   AI-first rework (2026-11): hero, shift statement, AI products, consulting
   method, marketing services, results, work carousel, client list.
   Shared shell lives in theme.css.
   ========================================================================== */

/* --- Hero --- */
.hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    text-align: left;
    position: relative;
    overflow: hidden;
    padding: 0 6vw;
    background: var(--bg-base);
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
    opacity: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        rgba(0, 0, 0, 0.75) 0%,
        rgba(0, 0, 0, 0.55) 40%,
        rgba(0, 0, 0, 0.2) 70%,
        rgba(0, 0, 0, 0.05) 100%
    );
    z-index: 1;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 620px;
}

.hero-content h1 {
    font-size: clamp(2.5rem, 3.4vw, 3.5rem);
    line-height: 1.1;
    margin-bottom: 1.25rem;
    background: linear-gradient(180deg, #FFFFFF 0%, #a1a1a6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Two halves of the slogan, each on one line: the first in white, the second in grey. */
.hero-content h1 {
    max-width: 18ch;
    background: none;
    -webkit-text-fill-color: currentColor;
    color: var(--text-primary);
}
.hero-content h1 span {
    display: block;
    text-wrap: balance;
}
.hero-content h1 span + span {
    color: rgba(255, 255, 255, 0.5);
}
@media (min-width: 768px) {
    .hero-content h1 {
        max-width: none;
        white-space: nowrap;
    }
}

.hero-content p {
    font-size: clamp(1rem, 1.5vw, 1.25rem);
    color: var(--text-secondary);
    margin-bottom: 2.25rem;
    max-width: 500px;
}

/* Desktop: the bulb and hand sit further right, and the copy moves in a little
   from the edge with more air between its parts, to balance the frame. */
@media (min-width: 768px) {
    .hero {
        padding-left: 9vw;
    }
    .hero-video {
        left: 9vw;
        -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 18%);
        mask-image: linear-gradient(90deg, transparent 0%, #000 18%);
    }
    .hero .hero-roster {
        left: 9vw;
        right: 9vw;
    }
    .hero-eyebrow {
        margin-bottom: 2.25rem;
    }
    /* An open band between the slogan above and the line and buttons below. */
    .hero-content h1 {
        margin-bottom: clamp(4rem, 16vh, 10rem);
    }
    .hero-content h1 span + span {
        margin-top: 0.15em;
    }
    .hero-content p {
        margin-bottom: 3rem;
        line-height: 1.6;
    }
}

/* Phones: tighter section spacing on the homepage (15vh leaves long empty bands). */
@media (max-width: 767px) {
    :root {
        --spacing-section: 4.5rem;
    }
    .hero + .shift-section {
        padding-top: 2.5rem;
    }
}

/* Phones: the hero splits around the video. Eyebrow and headline above it,
   the whole hand and bulb in the middle, then the line, buttons and roster below. */
@media (max-width: 767px) {
    .hero {
        height: auto;
        justify-content: flex-start;
        padding: calc(var(--header-height, 64px) + 2rem) 5vw 1rem;
    }
    .hero-content {
        display: contents;
    }
    .hero-eyebrow { order: 1; }
    .hero-content h1 { order: 2; }
    .hero-video { order: 3; }
    .hero-content p { order: 4; }
    .hero-actions { order: 5; }
    .hero-roster { order: 6; }
    .hero-video {
        position: relative;
        width: 100vw;
        max-width: none;
        height: auto;
        aspect-ratio: 10 / 9;
        margin: 0 -5vw 1.5rem;
        object-position: 56% 50%;
        /* Soft top and bottom edges so the frame melts into the black page. */
        -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 14%, #000 80%, transparent 100%);
        mask-image: linear-gradient(180deg, transparent 0%, #000 14%, #000 80%, transparent 100%);
    }
    .hero-overlay {
        display: none;
    }
    .hero-content h1 {
        font-size: clamp(2rem, 5vw, 2.5rem);
        margin-bottom: 0.5rem;
    }
    .hero-content p {
        font-size: 0.9375rem;
        line-height: 1.5;
        margin-bottom: 1.5rem;
    }
}


.hero-content {
    max-width: 1000px;
}

.hero-eyebrow {
    display: inline-block;
    margin-bottom: 1.75rem;
    color: rgba(255, 255, 255, 0.6);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.25rem 2rem;
}

/* Solid primary button: the default glass button stays for secondary use. */
.cta-solid {
    background: var(--text-primary);
    color: #000;
    border-color: var(--text-primary);
}

.hero-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.9375rem;
    font-weight: 500;
    border-bottom: 1px solid var(--border-strong);
    padding-bottom: 2px;
    transition: border-color 0.3s ease;
}

@media (max-width: 767px) {
    .hero-eyebrow {
        margin-bottom: 1rem;
    }
    .hero-actions {
        gap: 1.25rem 1.5rem;
        margin-bottom: 2.5rem;
    }
}

.hero-link:hover {
    border-bottom-color: var(--text-primary);
}

/* Quiet product roster pinned to the bottom of the hero. */
.hero-roster {
    position: absolute;
    left: 6vw;
    right: 6vw;
    bottom: 2.5rem;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 2.5rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.45);
    border-top: 1px solid var(--border-subtle);
    padding-top: 1.25rem;
}

@media (max-width: 767px) {
    .hero-roster {
        position: static;
        width: 100%;
        left: 5vw;
        right: 5vw;
        gap: 0.5rem 1.25rem;
        font-size: 0.625rem;
    }
}

/* --- Shared section intro --- */
.section-intro {
    margin-bottom: 5rem;
    max-width: 820px;
}

.section-label {
    display: inline-block;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

.section-intro h2 {
    font-size: clamp(2.25rem, 5vw, 4.25rem);
    color: var(--text-primary);
}

@media (max-width: 767px) {
    .section-intro {
        margin-bottom: 3rem;
    }
}

/* --- Shift statement --- */
.shift-section {
    padding: var(--spacing-section) 0;
}

.shift-section .section-intro {
    margin-bottom: 2.5rem;
}

/* Five tall film stills, edge to edge; a swipeable strip on phones */
.why-strip {
    list-style: none;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 72%;
    gap: 0.5rem;
    padding: 0 4vw;
    overflow-x: auto;
    overflow-y: hidden; /* cards still mid-reveal would otherwise let the strip drift up and down */
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}

.why-strip::-webkit-scrollbar {
    display: none;
}

@media (min-width: 768px) {
    .why-strip {
        grid-auto-columns: 40%;
    }
}

@media (min-width: 1024px) {
    .why-strip {
        grid-auto-flow: row;
        grid-template-columns: repeat(5, 1fr);
        overflow: visible;
        padding: 0 1rem;
    }
}

.why-shot {
    scroll-snap-align: center;
}

.why-photo {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border-radius: 14px;
    background: #07080a;
}

.why-photo img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.85;
    transition: opacity 0.8s ease, transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.why-photo::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 45%, rgba(5, 6, 7, 0.88) 100%);
}

.why-shot:hover .why-photo img {
    opacity: 1;
    transform: scale(1.03);
}

.why-cap {
    position: absolute;
    left: 1.25rem;
    right: 1.25rem;
    bottom: 1.25rem;
    z-index: 1;
}

.why-cap p {
    font-family: var(--font-display);
    font-size: clamp(1.125rem, 1.5vw, 1.375rem);
    font-weight: 600;
    line-height: 1.2;
    color: #fff;
    margin-bottom: 0.5rem;
}

/* Under each photo: how it's solved, then what runs it */
.why-fix {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    margin: 1rem 0.25rem 0.75rem;
}

.why-icon {
    flex: none;
    box-sizing: content-box;
    width: 20px;
    height: 20px;
    padding: 0.5rem;
    border: 1px solid var(--border-subtle);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    opacity: 0.9;
}

.why-fix p {
    color: var(--text-secondary);
    font-size: 0.875rem;
    line-height: 1.5;
}

.why-models {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
    margin: 0 0.25rem 0 calc(0.25rem + 36px + 0.75rem);
}

.why-models li {
    padding: 0.25rem 0.625rem;
    border: 1px solid var(--border-subtle);
    border-radius: 999px;
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    letter-spacing: 0.04em;
    color: var(--text-secondary);
}

.why-cap span {
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
}

/* --- AI stack: the orb still behind, two lanes of model logos --- */
.stack-section {
    position: relative;
    padding: var(--spacing-section) 0;
    overflow: hidden;
    isolation: isolate;
    border-top: 1px solid var(--border-subtle);
}

.stack-bg {
    position: absolute;
    top: 0;
    right: -10%;
    width: 75%;
    height: 100%;
    object-fit: cover;
    object-position: 60% 40%;
    opacity: 0.55;
    z-index: -1;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 45%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 45%);
}

@media (max-width: 767px) {
    .stack-bg {
        right: -30%;
        width: 130%;
        height: 60%;
        opacity: 0.35;
        -webkit-mask-image: linear-gradient(180deg, #000 30%, transparent 100%);
        mask-image: linear-gradient(180deg, #000 30%, transparent 100%);
    }
}

.stack-lanes {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    max-width: 1000px;
}

@media (min-width: 1024px) {
    .stack-lanes {
        grid-template-columns: 1.3fr 1fr;
        gap: 5rem;
    }
}

.stack-lane-tag {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.stack-frontier {
    list-style: none;
    display: grid;
    gap: 1.5rem;
}

.stack-frontier li {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.stack-frontier img {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
}

.stack-frontier b {
    display: block;
    font-family: var(--font-display);
    font-size: 1.375rem;
    font-weight: 600;
    color: var(--text-primary);
}

.stack-frontier span {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.stack-open {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.stack-open li {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.625rem;
    text-align: center;
}

.stack-open img {
    width: 36px;
    height: 36px;
}

.stack-open b {
    font-family: var(--font-display);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

.stack-open-note {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.stack-link {
    display: inline-block;
    margin-top: 3.5rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-primary);
}

/* --- AI platforms --- */
.ai-section {
    padding: var(--spacing-section) 0;
    background: var(--bg-surface);
    border-top: 1px solid var(--border-subtle);
}

.section-sub {
    margin-top: 1.5rem;
    max-width: 560px;
    color: var(--text-secondary);
    font-size: clamp(1rem, 1.3vw, 1.1875rem);
    line-height: 1.6;
}

.ai-flagship,
.ai-card {
    display: grid;
    text-decoration: none;
    color: inherit;
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: 20px;
    overflow: hidden;
    transition: border-color 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.ai-flagship:hover,
.ai-card:hover {
    border-color: color-mix(in srgb, var(--brand, #fff) 35%, transparent);
    transform: translateY(-4px);
}

/* Brand panel: the product's logo and name lead; the film still is texture. */
/* --brand is set per card in front-page.php. */
.ai-brand {
    position: relative;
    aspect-ratio: 16 / 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    overflow: hidden;
    background:
        radial-gradient(ellipse 70% 60% at 50% 55%, color-mix(in srgb, var(--brand) 24%, transparent), transparent 72%),
        #050607;
    isolation: isolate;
}

.ai-still {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* About 70% of the photo's real exposure at rest, 90% on hover. */
    opacity: 0.78;
    z-index: -1;
    transition: opacity 0.8s ease, transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.ai-brand::after {
    content: '';
    position: absolute;
    inset: 0;
    /* Soft vignette keeps the logo legible without hiding the scene. */
    background:
        radial-gradient(ellipse 55% 45% at 50% 50%, rgba(5, 6, 7, 0.45), transparent 75%),
        linear-gradient(180deg, rgba(5, 6, 7, 0.1) 0%, rgba(5, 6, 7, 0.55) 100%);
    z-index: -1;
    transition: opacity 0.8s ease;
}

.ai-flagship:hover .ai-still,
.ai-card:hover .ai-still {
    opacity: 0.95;
    transform: scale(1.03);
}

.ai-flagship:hover .ai-brand::after,
.ai-card:hover .ai-brand::after {
    opacity: 0.6;
}

.ai-for {
    position: absolute;
    top: 1.25rem;
    left: 1.25rem;
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--brand);
    padding: 0.4rem 0.75rem;
    border: 1px solid color-mix(in srgb, var(--brand) 35%, transparent);
    border-radius: 100px;
    background: rgba(0, 0, 0, 0.35);
}

.ai-logo {
    display: flex;
    align-items: center;
    gap: clamp(0.75rem, 1.5vw, 1.25rem);
}

.ai-mark {
    width: clamp(48px, 6vw, 76px);
    height: auto;
}

.ai-lockup {
    height: clamp(44px, 5.5vw, 72px);
    width: auto;
}

.ai-word {
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.5);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(2.5rem, 5.2vw, 4.5rem);
    letter-spacing: -0.04em;
    line-height: 1;
    color: var(--text-primary);
}

.ai-word i {
    font-style: normal;
    color: var(--brand);
}

.ai-by {
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.8);
    font-family: var(--font-mono);
    font-size: 0.625rem;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.75);
}

.ai-copy {
    padding: 2rem;
    display: flex;
    flex-direction: column;
}

.ai-line {
    font-family: var(--font-display);
    font-size: clamp(1.25rem, 1.8vw, 1.5rem);
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.25;
    color: var(--text-primary);
    margin-bottom: 0.875rem;
}

.ai-desc {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 1.75rem;
}

.ai-more {
    margin-top: auto;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-primary);
}

.ai-flagship {
    margin-bottom: 1.5rem;
}

/* On phones the panel is short: keep the logo clear of the category chip. */
@media (max-width: 767px) {
    .ai-brand {
        aspect-ratio: 4 / 3;
        padding-top: 2.5rem;
    }
}

@media (min-width: 1024px) {
    .ai-flagship {
        grid-template-columns: 1.45fr 1fr;
    }
    .ai-flagship .ai-brand {
        aspect-ratio: auto;
        min-height: 480px;
    }
    .ai-flagship .ai-mark {
        width: 104px;
    }
    .ai-flagship .ai-word {
        font-size: 6rem;
    }
    .ai-flagship .ai-copy {
        padding: 3.5rem;
        justify-content: center;
    }
    .ai-flagship .ai-line {
        font-size: 2rem;
    }
    .ai-flagship .ai-more {
        margin-top: 0;
    }
}

.ai-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .ai-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.ai-card {
    grid-template-rows: auto 1fr;
}

/* Phones: all five platforms in one swipe row, the next card peeking in. */
.ai-dots {
    display: none;
}

@media (max-width: 767px) {
    .ai-rail {
        display: flex;
        gap: 0.75rem;
        overflow-x: auto;
        overflow-y: hidden;
        overscroll-behavior-x: contain;
        scroll-snap-type: x mandatory;
        scrollbar-width: none;
        margin: 0 -4vw;
        padding: 0 4vw;
        scroll-padding: 0 4vw;
    }
    .ai-rail::-webkit-scrollbar {
        display: none;
    }
    .ai-rail .ai-grid {
        display: contents;
    }
    .ai-rail .ai-flagship,
    .ai-rail .ai-card {
        flex: 0 0 84%;
        margin-bottom: 0;
        scroll-snap-align: start;
        grid-template-rows: auto 1fr;
    }
    .ai-rail .reveal {
        opacity: 1;
        transform: none;
    }
    .ai-rail .ai-copy {
        padding: 1.5rem;
    }
    .ai-rail .ai-desc {
        font-size: 0.875rem;
        margin-bottom: 1.25rem;
    }
    .ai-rail .ai-flagship:hover,
    .ai-rail .ai-card:hover {
        transform: none;
    }
    .ai-dots {
        display: flex;
        justify-content: center;
        gap: 0.5rem;
        margin-top: 1.5rem;
    }
    .ai-dots span {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.25);
        transition: width 0.3s ease, background 0.3s ease;
    }
    .ai-dots span.active {
        width: 20px;
        border-radius: 3px;
        background: var(--text-primary);
    }
}

/* --- Consulting method --- */
.method-section {
    padding: var(--spacing-section) 4vw;
}

.method-steps {
    list-style: none;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1px;
    background: var(--border-subtle);
    border: 1px solid var(--border-subtle);
    border-radius: 20px;
    overflow: hidden;
}

@media (min-width: 768px) {
    .method-steps {
        grid-template-columns: 1fr 1fr;
    }
}

@media (min-width: 1200px) {
    .method-steps {
        grid-template-columns: repeat(4, 1fr);
    }
}

.method-steps li {
    background: var(--bg-base);
    padding: 0 0 2.5rem;
}

/* A still from our own films on each step; a small thumbnail beside the text on phones */
.method-photo {
    position: relative;
    margin-bottom: 1.75rem;
    overflow: hidden;
}

.method-photo img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    opacity: 0.85;
    transition: opacity 0.4s ease, transform 0.6s ease;
}

.method-steps li:hover .method-photo img {
    opacity: 1;
    transform: scale(1.03);
}

.method-num {
    position: absolute;
    left: 1rem;
    bottom: 1rem;
    padding: 0.25rem 0.625rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: #fff;
}

.method-steps h4,
.method-steps p {
    padding: 0 2rem;
}

.method-steps h4 {
    font-size: 1.375rem;
    margin-bottom: 0.875rem;
}

.method-steps p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
}

@media (max-width: 767px) {
    .method-steps li {
        display: grid;
        grid-template-columns: 112px 1fr;
        column-gap: 1rem;
        align-content: start;
        padding: 1.25rem;
    }

    .method-photo {
        grid-row: 1 / span 2;
        align-self: start;
        margin: 0;
        border-radius: 12px;
    }

    .method-photo img {
        aspect-ratio: 1;
    }

    .method-num {
        left: 0.5rem;
        bottom: 0.5rem;
        font-size: 0.6875rem;
    }

    .method-steps h4,
    .method-steps p {
        padding: 0;
    }

    .method-steps h4 {
        font-size: 1.125rem;
        margin-bottom: 0.5rem;
    }

    .method-steps p {
        font-size: 0.875rem;
    }
}

/* --- Marketing services: six square photo tiles, like a profile grid --- */
.services-section {
    padding: var(--spacing-section) 4vw;
    border-top: 1px solid var(--border-subtle);
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
}

@media (min-width: 1024px) {
    .services-section {
        grid-template-columns: 1fr 1.6fr;
        gap: 4rem;
        align-items: center;
    }
}

.services-head h2 {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    margin-bottom: 1rem;
}

.services-head p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
    max-width: 420px;
}

.services-grid {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
}

@media (min-width: 768px) {
    .services-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.services-grid a {
    position: relative;
    display: block;
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: 6px;
    color: #fff;
    text-decoration: none;
    background: var(--bg-elevated);
}

.services-grid img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.services-grid a::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.35) 45%, transparent 70%);
}

.services-grid a:hover img {
    transform: scale(1.05);
}

.services-text {
    position: absolute;
    left: 0.875rem;
    right: 2.25rem;
    bottom: 0.875rem;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.services-name {
    font-family: var(--font-display);
    font-size: 0.9375rem;
    font-weight: 600;
    line-height: 1.25;
}

.services-note {
    font-size: 0.75rem;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.75);
}

@media (min-width: 1200px) {
    .services-name {
        font-size: 1.0625rem;
    }

    .services-note {
        font-size: 0.8125rem;
    }
}

/* Phones: the text sits under each photo instead of over it */
@media (max-width: 767px) {
    .services-grid {
        gap: 1.25rem 0.75rem;
    }

    .services-grid a {
        aspect-ratio: auto;
        overflow: visible;
        background: none;
    }

    .services-grid img {
        position: static;
        display: block;
        aspect-ratio: 1;
        height: auto;
        border-radius: 10px;
    }

    .services-grid a::after {
        content: none;
    }

    .services-text {
        position: static;
        margin-top: 0.75rem;
    }

    .services-note {
        color: var(--text-secondary);
    }

    .services-grid .services-arrow {
        display: none;
    }
}

.services-arrow {
    position: absolute;
    right: 0.875rem;
    bottom: 0.875rem;
    z-index: 1;
    color: rgba(255, 255, 255, 0.7);
    transition: transform 0.3s ease, color 0.3s ease;
}

.services-grid a:hover .services-arrow {
    color: #fff;
    transform: translateX(4px);
}

/* --- Partner businesses (RGRP leads, then the two cards) --- */
.partners-section {
    padding: var(--spacing-section) 0;
    background: radial-gradient(ellipse 50% 45% at 25% 38%, rgba(201, 162, 74, 0.10), transparent 70%), var(--bg-base);
    border-top: 1px solid var(--border-subtle);
}

.partners-section .pf-grid {
    margin-bottom: 6rem;
}

.partners-section .pf-grid:last-child {
    margin-bottom: 0;
}

.partner-kind {
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

/* --- Work (Carousel) --- */
.work-section {
    padding: var(--spacing-section) 0;
    overflow: hidden;
    position: relative;
    border-top: 1px solid var(--border-subtle);
    background: var(--bg-base);
}

.work-header {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
    z-index: 20;
}

.work-header .section-label {
    display: inline-block;
    margin-bottom: 1rem;
}

.work-header h2 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    color: var(--text-primary);
}

.carousel-container {
    position: relative;
    height: 70vh;
    min-height: 500px;
    width: 100vw;
    max-width: 100%;
    margin: 0 auto;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.carousel-slide {
    position: absolute;
    left: 50%;
    width: 70vw;
    height: 100%;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1),
                filter 0.6s cubic-bezier(0.25, 1, 0.5, 1),
                opacity 0.6s cubic-bezier(0.25, 1, 0.5, 1),
                z-index 0s 0.3s;
    filter: grayscale(1) saturate(0.4) brightness(0.8);
    opacity: 0;
    transform: translateX(-50%) scale(0.75);
    z-index: 1;
    cursor: pointer;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    border: 1px solid var(--border-subtle);
}

@media (max-width: 768px) {
    .carousel-container {
        height: min(112vw, 520px);
        min-height: 0;
    }
    .carousel-slide {
        width: 80vw;
    }
}

.carousel-slide.active {
    filter: none;
    opacity: 1;
    transform: translateX(-50%) scale(1);
    z-index: 10;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1),
                filter 0.6s cubic-bezier(0.25, 1, 0.5, 1),
                opacity 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    cursor: default;
}

.carousel-slide.prev {
    opacity: 1;
    transform: translateX(-90%) scale(0.75);
    z-index: 5;
}

.carousel-slide.next {
    opacity: 1;
    transform: translateX(-10%) scale(0.75);
    z-index: 5;
}

.slide-bg {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 0;
    background-size: cover;
    background-position: center;
}
.bg-1 { background-image: url('../img/carousel/1-phuketfit.webp'); }
.bg-2 { background-image: url('../img/carousel/2-andara.webp'); }
.bg-3 { background-image: url('../img/carousel/3-motiphysio.webp'); }
.bg-4 { background-image: url('../img/carousel/4-event.webp'); }
.bg-5 { background-image: url('../img/carousel/5-cutphuket.webp'); }
.bg-6 { background-image: url('../img/carousel/6-annybe.webp'); }

.slide-content {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 3rem;
    background: radial-gradient(circle at center, rgba(0,0,0,0.2) 0%, rgba(0,0,0,0.6) 100%);
}

.slide-content h3 {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.slide-sub {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9375rem;
    line-height: 1.4;
    max-width: 30ch;
    margin: -0.25rem auto 1rem;
}

.slide-category {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 2rem;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 100px;
    background: rgba(0,0,0,0.3);
    backdrop-filter: blur(5px);
}

.slide-cta {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s ease;
    border-bottom: 1px solid transparent;
    padding-bottom: 2px;
}

.carousel-slide.active .slide-cta {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.3s;
}

.slide-cta:hover {
    border-bottom-color: var(--text-primary);
}

/* Phones: after the base slide rules so these win. */
@media (max-width: 768px) {
    /* Text at the foot of the card, over a fade, so the photo stays readable. */
    .slide-content {
        justify-content: flex-end;
        padding: 2rem 1.25rem 1.75rem;
        background: linear-gradient(180deg, transparent 35%, rgba(0, 0, 0, 0.85) 100%);
    }
    .slide-content h3 {
        font-size: 1.75rem;
        line-height: 1.1;
    }
    .slide-sub {
        font-size: 0.875rem;
        margin-bottom: 0.875rem;
    }
    .slide-category {
        font-size: 0.6875rem;
        margin-bottom: 1.25rem;
    }
}

.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 3rem;
    position: relative;
    z-index: 20;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.carousel-dot.active {
    width: 24px;
    background: rgba(255, 255, 255, 0.9);
}

.carousel-dot:hover:not(.active) {
    background: rgba(255, 255, 255, 0.5);
}

.view-all-link {
    text-align: center;
    margin-top: 2.5rem;
    position: relative;
    z-index: 20;
}

.view-all-link a {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid var(--border-subtle);
    padding-bottom: 4px;
    transition: all 0.3s ease;
}

.view-all-link a:hover {
    color: var(--text-primary);
    border-bottom-color: var(--text-primary);
}

/* --- Trust --- */
.trust-section {
    padding: var(--spacing-section) 4vw;
    text-align: center;
    border-top: 1px solid var(--border-subtle);
}

/* One quiet row of figures between hairlines, on every screen size. */
.trust-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin-top: 6rem;
    border-top: 1px solid var(--border-subtle);
    border-bottom: 1px solid var(--border-subtle);
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.5rem;
    padding: 2.5rem 1rem;
}

.stat + .stat {
    border-left: 1px solid var(--border-subtle);
}

.stat-num {
    font-size: clamp(2.25rem, 5vw, 4.5rem);
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1;
    color: var(--text-primary);
    letter-spacing: -0.04em;
}

.stat-label {
    font-family: var(--font-mono);
    color: var(--text-secondary);
    font-size: 0.8125rem;
    letter-spacing: 0.04em;
    line-height: 1.4;
    text-transform: uppercase;
}

@media (max-width: 767px) {
    .year-section .trust-stats {
        margin-top: 3.5rem;
    }
    .stat {
        padding: 1.5rem 0.375rem;
    }
    .stat-label {
        font-size: 0.5625rem;
    }
}

.brand-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem 4rem;
    max-width: 1000px;
    margin: 0 auto;
}

.brand-item {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-tertiary);
    transition: color 0.3s ease;
    letter-spacing: -0.02em;
}

.brand-item:hover {
    color: var(--text-secondary);
}


/* Headline revenue figure on a client-of-the-year card. */
.fc-figure {
    font-family: var(--font-display);
    font-size: clamp(2.75rem, 5vw, 4rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1;
    margin-bottom: 1.5rem;
    background: linear-gradient(180deg, #FFFFFF 0%, #a1a1a6 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.fc-figure small {
    font-size: 0.35em;
    letter-spacing: 0;
    margin-left: 0.35rem;
    font-weight: 500;
}

.trust-section .section-label {
    margin-bottom: 3rem;
}

/* --- Clients of the year --- */
.year-section {
    padding: var(--spacing-section) 0;
    background: var(--bg-base);
    border-top: 1px solid var(--border-subtle);
}

.year-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 1024px) {
    .year-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.year-card {
    display: flex;
    flex-direction: column;
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: 20px;
    overflow: hidden;
}

.year-shot {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--bg-surface);
}

.year-shot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: left top;
}

.year-body {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.year-where {
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.year-body h3 {
    font-size: clamp(1.75rem, 2.4vw, 2.25rem);
    margin-bottom: 1rem;
}

.year-body .fc-figure {
    font-size: clamp(2.25rem, 3.6vw, 3rem);
    margin-bottom: 1rem;
}

.year-body p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.year-stack {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: auto;
}

.year-stack li {
    font-family: var(--font-mono);
    font-size: 0.625rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-primary);
    border: 1px solid var(--border-strong);
    border-radius: 100px;
    padding: 0.375rem 0.75rem;
}

.year-link {
    margin-top: 1.25rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-decoration: none;
}

.year-link:hover {
    color: var(--text-primary);
}

.year-section .trust-stats {
    margin-top: 6rem;
}

/* --- Websites we build --- */
.webwork-section {
    padding: var(--spacing-section) 0;
    background: var(--bg-surface);
    border-top: 1px solid var(--border-subtle);
}

.webwork-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 680px) {
    .webwork-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (min-width: 1000px) {
    .webwork-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.webwork-card {
    display: block;
    text-decoration: none;
    color: inherit;
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.webwork-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-strong);
}

.webwork-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    background: #171717;
    border-bottom: 1px solid var(--border-subtle);
}

.webwork-bar .wb-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.16);
    flex-shrink: 0;
}

.webwork-bar .wb-url {
    margin-left: 8px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.webwork-shot {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    object-position: top center;
    background: var(--bg-surface);
}

.webwork-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1.15rem 1.25rem;
}

.webwork-label h4 {
    font-size: 1.05rem;
}

.webwork-tag {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
    flex-shrink: 0;
}

.webwork-section .view-all-link {
    margin-top: 3rem;
}

/* --- Partner features (LuLuBooth, Alangkarn Films, RGRP) --- */
.pf-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
}

@media (min-width: 1024px) {
    .pf-grid {
        grid-template-columns: 1fr 1.1fr;
        gap: 5rem;
    }

    .pf-flip {
        grid-template-columns: 1.1fr 1fr;
    }

    .pf-flip .pf-visual {
        order: 2;
    }
}

.pf-visual {
    max-width: 560px;
}

.pf-visual img {
    width: 100%;
    height: auto;
    border-radius: 20px;
    border: 1px solid var(--border-subtle);
}

.pf-copy .partner-kind {
    display: block;
}

.pf-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    letter-spacing: -0.02em;
    margin-bottom: 1.25rem;
}

.pf-lede {
    color: var(--text-secondary);
    font-size: clamp(1rem, 1.3vw, 1.125rem);
    line-height: 1.65;
    margin-bottom: 1.75rem;
    max-width: 580px;
}

/* Three sample booth photos under the LuLuBooth line */
.pf-shots {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    max-width: 480px;
    margin-bottom: 2rem;
}

.pf-shots img {
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 12px;
}

/* Alangkarn Films is a photo business, so its line gets a 3 x 2 grid */
.pf-shots-grid {
    max-width: 520px;
}

/* Feature points stay folded until asked for */
.pf-more {
    margin-bottom: 2.25rem;
}

.pf-more summary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    list-style: none;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-secondary);
    transition: color 0.2s ease;
}

.pf-more summary::-webkit-details-marker {
    display: none;
}

.pf-more summary::after {
    content: "+";
    font-size: 1rem;
    line-height: 1;
    transition: transform 0.3s ease;
}

.pf-more summary:hover,
.pf-more[open] summary {
    color: var(--text-primary);
}

.pf-more[open] summary::after {
    transform: rotate(45deg);
}

.pf-more .pf-points {
    margin: 1.25rem 0 0;
}

.pf-points {
    list-style: none;
    border-top: 1px solid var(--border-subtle);
    margin-bottom: 2.5rem;
}

.pf-points li {
    padding: 1.125rem 0;
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.55;
}

.pf-points b {
    display: block;
    font-family: var(--font-display);
    font-size: 1.0625rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.pf-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.25rem 2rem;
}

/* --- AI Automation: the method section as the homepage's one light section (after AI Platforms) --- */
.method-section.full-bleed {
    padding-left: 0;
    padding-right: 0;
}

.method-section.is-light .method-steps li {
    background: #ffffff;
}

.method-section.is-light .method-photo img {
    opacity: 1;
}

/* The solid button inverts with the section: dark pill, white text. */
.is-light .cta-solid {
    color: #ffffff;
}

.method-more {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem 2rem;
    margin-top: 3rem;
}

.method-more a:not(.cta-button) {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.9375rem;
    border-bottom: 1px solid var(--border-strong);
    padding-bottom: 2px;
}

.method-more a:not(.cta-button):hover {
    border-color: var(--text-primary);
}

@media (max-width: 767px) {
    .method-more .cta-button {
        flex-basis: 100%;
    }
}

/* Each card opens its client story. */
.year-card { position: relative; transition: border-color .2s; }
.year-link::after { content: ""; position: absolute; inset: 0; }

/* Latest articles: three across at most; one or two cards stay wide. */
.home-blog-section { padding-top: var(--spacing-section); padding-bottom: var(--spacing-section); text-align: center; border-top: 1px solid var(--border-subtle); }
.home-blog-section h2 { font-size: clamp(2.5rem, 5vw, 4rem); margin-bottom: 3rem; }
.home-blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; text-align: left; }
.home-blog-grid.home-blog-count-1, .home-blog-grid.home-blog-count-2 { grid-template-columns: repeat(2, 1fr); }
.home-blog-grid a { display: block; }
.blog-card-image { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.blog-card-body { padding: 2rem; }
@media (max-width: 1023px) { .home-blog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 767px) { .home-blog-grid, .home-blog-grid.home-blog-count-1, .home-blog-grid.home-blog-count-2 { grid-template-columns: 1fr; } }

/* --- AI Fast Track (TL-72): the offer straight after the hero --- */
.fast-track {
    padding: clamp(4.5rem, 10vh, 7.5rem) 0;
    border-top: 1px solid var(--border-subtle);
    background: var(--bg-base);
}

.ft-grid {
    display: grid;
    gap: 3rem;
}

.ft-copy h2 {
    font-size: clamp(2rem, 4.2vw, 3.5rem);
    color: var(--text-primary);
    max-width: 16ch;
    text-wrap: balance;
}

.ft-sub {
    margin-top: 1.25rem;
    max-width: 34rem;
    font-size: clamp(1rem, 1.3vw, 1.125rem);
    line-height: 1.6;
    color: var(--text-secondary);
}

.ft-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.25rem 2rem;
    margin-top: 2.25rem;
}

/* Photo: a still in the same film look as the five product stills below. */
.ft-photo {
    position: relative;
    margin: 0;
    border-radius: 20px;
    overflow: hidden;
    background: var(--bg-elevated);
    aspect-ratio: 16 / 10;
    align-self: center;
}

.ft-photo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 45% 40%;
}

.ft-photo::after {
    content: '';
    position: absolute;
    inset: 55% 0 0;
    background: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.72));
    pointer-events: none;
}

.ft-photo figcaption {
    position: absolute;
    left: 1.5rem;
    right: 1.5rem;
    bottom: 1.25rem;
    z-index: 1;
    font-size: 0.875rem;
    line-height: 1.45;
    color: rgba(245, 245, 247, 0.88);
}

/* Track: the four steps of the offer (TL-409). The line fills when it scrolls in. */
.ft-track {
    --ft-dot: 14px;
    list-style: none;
    position: relative;
    display: grid;
    gap: 2rem;
    padding-left: 2rem;
}

.ft-track::before,
.ft-track::after {
    content: '';
    position: absolute;
    left: calc(var(--ft-dot) / 2 - 1px);
    top: 0.4rem;
    bottom: 0.4rem;
    width: 2px;
    background: var(--border-strong);
}

.ft-track::after {
    background: linear-gradient(to bottom, var(--text-primary), rgba(245, 245, 247, 0.35));
    transform-origin: top;
    transform: scaleY(0);
    transition: transform 1.6s cubic-bezier(0.22, 1, 0.36, 1) 0.3s;
}

.ft-track.active::after {
    transform: scaleY(1);
}

.ft-track li {
    position: relative;
}

.ft-when {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

:lang(th) .ft-when {
    text-transform: none;
    letter-spacing: 0;
    font-family: var(--font-body);
    font-size: 0.8125rem;
}

.ft-dot {
    position: absolute;
    left: -2rem;
    top: 0.15rem;
    z-index: 1;
    width: var(--ft-dot);
    height: var(--ft-dot);
    border-radius: 50%;
    background: var(--bg-base);
    border: 2px solid var(--border-strong);
    color: var(--text-primary);
    display: grid;
    place-items: center;
    transition: background 0.4s ease, border-color 0.4s ease;
}

.ft-track.active .ft-dot {
    border-color: var(--text-primary);
}

.ft-track.active li:nth-child(1) .ft-dot { transition-delay: 0.3s; }
.ft-track.active li:nth-child(2) .ft-dot { transition-delay: 0.8s; }
.ft-track.active li:nth-child(3) .ft-dot { transition-delay: 1.3s; background: var(--text-primary); }
.ft-track.active li:nth-child(4) .ft-dot { transition-delay: 1.8s; }

.ft-loop::before {
    /* phones: stop the vertical line at the loop dot */
    content: '';
    position: absolute;
    left: -2rem;
    top: 1rem;
    bottom: -1rem;
    width: 14px;
    background: var(--bg-base);
}

.ft-loop .ft-dot {
    --ft-dot: 26px;
    width: 26px;
    height: 26px;
    left: calc(-2rem - 6px);
    top: -0.2rem;
}

.ft-track h3 {
    font-size: 1.25rem;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin-bottom: 0.35rem;
}

.ft-track p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.55;
    max-width: 28ch;
}

:lang(th) .ft-track p {
    max-width: 34ch;
}

.ft-chips {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.ft-chips li {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-secondary);
    border: 1px solid var(--border-strong);
    border-radius: 100px;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.03);
}

:lang(th) .ft-chips li {
    text-transform: none;
    letter-spacing: 0;
    font-family: var(--font-body);
    font-size: 0.8125rem;
}

@media (min-width: 1024px) {
    .ft-grid {
        grid-template-columns: 1.1fr 1fr;
        column-gap: 6vw;
        row-gap: 3rem;
    }
    .ft-chips {
        grid-column: 1 / -1;
        border-top: 1px solid var(--border-subtle);
        padding-top: 2rem;
    }
    .ft-track {
        grid-column: 1 / -1;
        grid-template-columns: repeat(4, 1fr);
        gap: 2.5rem;
        padding: 2.75rem 0 0;
        margin-top: 1rem;
    }
    .ft-track::before,
    .ft-track::after {
        left: 0;
        right: 0;
        top: calc(var(--ft-dot) / 2 - 1px);
        bottom: auto;
        width: auto;
        height: 2px;
    }
    .ft-track::before {
        background: linear-gradient(to right, var(--border-strong) 75%, transparent);
    }
    .ft-track::after {
        background: linear-gradient(to right, var(--text-primary) 60%, rgba(245, 245, 247, 0.25) 80%, transparent);
        transform-origin: left;
        transform: scaleX(0);
    }
    .ft-track.active::after {
        transform: scaleX(1);
    }
    .ft-dot {
        left: 0;
        top: -2.75rem;
    }
    .ft-loop .ft-dot {
        left: -6px;
        top: calc(-2.75rem - 6px);
    }
    .ft-loop::before {
        display: none;
    }
}

@media (max-width: 767px) {
    .fast-track {
        padding: 3.5rem 0 4rem;
    }
    .ft-grid {
        gap: 2.25rem;
        padding: 0 5vw;
    }
    .ft-actions {
        gap: 1rem 1.5rem;
    }
    .ft-photo {
        aspect-ratio: 4 / 3;
    }
}

/* The four-step offer on the track (TL-409): longer copy than the old timeline, and a price line under each step. */
.ft-ladder li {
    display: flex;
    flex-direction: column;
}

.ft-ladder p,
:lang(th) .ft-ladder p {
    max-width: 34ch;
}

.ft-ladder .ft-price {
    margin-top: auto;
    padding-top: 0.9rem;
    color: var(--text-primary);
    font-size: 0.875rem;
    line-height: 1.5;
}

.ft-ladder .ft-price + .ft-price {
    margin-top: 0;
    padding-top: 0.5rem;
}

.ft-ladder h3 + p {
    margin-bottom: 0.9rem;
}

.ft-track.active.ft-ladder li:nth-child(3) .ft-dot { background: var(--bg-base); }

/* Before the steps: training at Phuket AI Pro, for a team that is new to AI. */
.ft-first {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.6rem 1.5rem;
    padding: 1.25rem 1.5rem;
    border: 1px solid var(--border-strong);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.55;
}

.ft-first-tag {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-primary);
}

:lang(th) .ft-first-tag {
    font-family: var(--font-body);
    text-transform: none;
    letter-spacing: 0;
    font-size: 0.875rem;
    font-weight: 600;
}

.ft-first-text {
    flex: 1 1 24rem;
}

.ft-first a {
    color: var(--text-primary);
    font-weight: 500;
    white-space: nowrap;
    text-decoration: underline;
    text-underline-offset: 4px;
    text-decoration-color: var(--border-strong);
}

.ft-first a:hover {
    text-decoration-color: currentColor;
}

@media (min-width: 1024px) {
    .ft-first { grid-column: 1 / -1; }
}

@media (max-width: 767px) {
    .ft-first a { white-space: normal; }
}

/* Thai phrases kept whole when a line wraps (inc/ai-offer.php). */
.tl-ib {
    display: inline-block;
    max-width: 100%;
}

/* Fast Track: the models it runs on (the full stack section sits further down the page). */
.ft-models {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1.25rem;
    margin-top: -1.25rem;
}

.ft-models-tag {
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-right: 0.25rem;
}

:lang(th) .ft-models-tag { font-family: var(--font-body); text-transform: none; letter-spacing: 0; font-size: 0.8125rem; }

.ft-model {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-display);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.ft-model img { width: 20px; height: 20px; }

@media (min-width: 1024px) {
    .ft-models { grid-column: 1 / -1; }
}
