/* ============================================
   PORTFOLIO LANDING — Jeevan Pranav
   Minimal. Typographic. Intentional.
   ============================================ */

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    min-height: 100vh;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img, picture, video, svg {
    display: block;
    max-width: 100%;
}

input, button, textarea, select { font: inherit; }
p, h1, h2, h3 { overflow-wrap: break-word; }
a { color: inherit; text-decoration: none; }
button { background: none; border: none; cursor: pointer; }
ul, ol { list-style: none; }


/* --- Design Tokens --- */
:root {
    --bg: #FFFFFF;
    --bg-elevated: #FFFFFF;
    --text: #141414;
    --text-secondary: #6B6B6B;
    --text-tertiary: #9B9B9B;
    --border: rgba(0, 0, 0, 0.06);
    --border-strong: rgba(0, 0, 0, 0.10);

    --ama-hl-bg: rgba(79, 70, 229, 0.10);
    --ama-hl-text: #4F46E5;
    --card-hover: rgba(0, 0, 0, 0.018);
    --img-bg: #EDECEB;
    --img-health: #EEF2FF;
    --img-finance: #ECFDF5;
    --img-water: #FFF7ED;
    --exp-marker: #D9614B;

    --font: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    --hero-size: clamp(3.2rem, 7.5vw, 6.5rem);
    --h2-size: clamp(1.35rem, 2.2vw, 1.85rem);
    --body-size: clamp(0.94rem, 0.95vw, 1.05rem);
    --small-size: clamp(0.82rem, 0.85vw, 0.9rem);
    --label-size: 0.7rem;

    --gutter: clamp(2rem, 5vw, 4rem);
    --section-gap: clamp(6rem, 12vw, 10rem);
    --container: 1060px;

    --ease: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --duration: 0.6s;
    --duration-fast: 0.25s;
}

[data-theme="dark"] {
    --bg: #0A0A0A;
    --bg-elevated: #141414;
    --text: #EDEDEC;
    --text-secondary: #8A8A8A;
    --text-tertiary: #5A5A5A;
    --border: rgba(255, 255, 255, 0.07);
    --border-strong: rgba(255, 255, 255, 0.11);
    --card-hover: rgba(255, 255, 255, 0.025);
    --ama-hl-bg: rgba(165, 180, 252, 0.16);
    --ama-hl-text: #A5B4FC;
    --img-bg: #1C1C1A;
    --img-health: #181C2E;
    --img-finance: #182E1C;
    --img-water: #2E2818;
    --exp-marker: #E8957D;
}


/* --- Base --- */
body {
    font-family: var(--font);
    font-size: var(--body-size);
    line-height: 1.65;
    color: var(--text);
    background: var(--bg);
    transition: background 0.4s var(--ease), color 0.3s var(--ease);
    overflow-x: hidden;
}

::selection {
    background: rgba(0, 0, 0, 0.07);
}

[data-theme="dark"] ::selection {
    background: rgba(255, 255, 255, 0.12);
}

:focus-visible {
    outline: 2px solid var(--text-tertiary);
    outline-offset: 3px;
    border-radius: 4px;
}




/* ============================================
   NAVIGATION
   ============================================ */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.1rem var(--gutter);
    background: transparent;
    transition: background 0.35s var(--ease),
                border-color 0.35s var(--ease);
    border-bottom: 1px solid transparent;
    animation: navSlideDown 0.8s var(--ease) forwards;
}

@keyframes navSlideDown {
    from {
        opacity: 0;
        transform: translateY(-12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.nav.scrolled {
    background: var(--bg);
    border-bottom-color: var(--border);
}

@supports (backdrop-filter: blur(12px)) {
    .nav.scrolled {
        background: color-mix(in srgb, var(--bg) 82%, transparent);
        backdrop-filter: blur(14px);
        -webkit-backdrop-filter: blur(14px);
    }
}

.nav-name {
    display: inline-flex;
    align-items: baseline;
    gap: 0.5rem;
    font-size: var(--small-size);
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--text);
    text-decoration: none;
}

.nav-role {
    font-family: 'Instrument Serif', Georgia, serif;
    font-style: italic;
    font-weight: 400;
    font-size: 0.95rem;
    color: var(--text-tertiary);
    letter-spacing: 0;
    position: relative;
    padding-left: 0.65rem;
}

.nav-role::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--text-tertiary);
}

@media (max-width: 640px) {
    .nav-role { display: none; }
}

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

.nav-link {
    font-size: var(--label-size);
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-secondary);
    transition: color var(--duration-fast) var(--ease);
}

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

.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: var(--text-secondary);
    transition: color var(--duration-fast), background var(--duration-fast);
}

.theme-toggle:hover {
    color: var(--text);
    background: var(--card-hover);
}

[data-theme="light"] .icon-moon { display: none; }
[data-theme="dark"] .icon-sun { display: none; }


/* ============================================
   SCROLL PROGRESS
   ============================================ */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 2px;
    width: 0%;
    background: var(--text);
    z-index: 200;
    transition: width 0.05s linear;
    opacity: 0;
    animation: progressFadeIn 0.6s var(--ease) 0.4s forwards;
}

@keyframes progressFadeIn {
    to {
        opacity: 0.25;
    }
}


/* ============================================
   STATUS BADGE (now in nav)
   ============================================ */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.65rem;
    font-weight: 500;
    color: #059669;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    background: rgba(5, 150, 105, 0.06);
    border: 1px solid rgba(5, 150, 105, 0.12);
    letter-spacing: 0.01em;
}

[data-theme="dark"] .status-badge {
    color: #34D399;
    background: rgba(52, 211, 153, 0.08);
    border-color: rgba(52, 211, 153, 0.15);
}

.status-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #059669;
    animation: pulse 2s ease-in-out infinite;
}

[data-theme="dark"] .status-dot {
    background: #34D399;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}


/* ============================================
   THEME TRANSITION — Horizon Glow
   ============================================ */
.theme-glow {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 9999;
    opacity: 0;
}

.theme-glow--sunrise {
    background: radial-gradient(ellipse 120% 40% at 50% 100%, rgba(251, 191, 36, 0.12) 0%, rgba(251, 146, 60, 0.06) 40%, transparent 70%);
    animation: glowPulse 0.8s ease-out forwards;
}

.theme-glow--sunset {
    background: radial-gradient(ellipse 120% 40% at 50% 100%, rgba(99, 102, 241, 0.08) 0%, rgba(168, 85, 247, 0.04) 40%, transparent 70%);
    animation: glowPulse 0.8s ease-out forwards;
}

@keyframes glowPulse {
    0% { opacity: 0; }
    30% { opacity: 1; }
    100% { opacity: 0; }
}


/* ============================================
   HERO
   ============================================ */
.hero {
    position: relative;
    z-index: 1;
    padding: clamp(7.5rem, 18vh, 14rem) var(--gutter) clamp(3rem, 5vw, 4.5rem);
    max-width: var(--container);
    margin: 0 auto;
    animation: heroFadeIn 0.7s var(--ease) 0.1s forwards;
    opacity: 0;
}

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

.hero-inner {
    will-change: transform;
    transition: transform 0.15s ease-out;
    position: relative;
    z-index: 1;
}

/* Cursor-aware ambient aura behind the hero */
.hero-aura {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}
.hero-aura-blob {
    position: absolute;
    top: 34%;
    left: 50%;
    width: 46vw;
    max-width: 660px;
    aspect-ratio: 1;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.55;
    transform: translate(-50%, -50%);
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform;
}
.hero-aura-blob--warm { background: radial-gradient(circle, rgba(217, 97, 75, 0.20), transparent 65%); }
.hero-aura-blob--cool { left: 58%; top: 26%; background: radial-gradient(circle, rgba(79, 70, 229, 0.16), transparent 65%); }
[data-theme="dark"] .hero-aura-blob { opacity: 0.42; }
@media (prefers-reduced-motion: reduce) {
    .hero-aura-blob { transition: none; }
}

/* Status line — top of hero */
.hero-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: clamp(1.8rem, 3vw, 2.5rem);
}

.hero-location {
    font-size: 0.72rem;
    font-weight: 400;
    color: var(--text-tertiary);
    letter-spacing: 0.01em;
}

/* Pitch — before heading */
.hero-pitch {
    font-size: clamp(0.98rem, 1.1vw, 1.15rem);
    font-weight: 400;
    line-height: 1.75;
    color: var(--text-secondary);
    max-width: 65ch;
    margin-bottom: clamp(1.5rem, 2vw, 2rem);
}

.hero-pitch strong {
    font-weight: 500;
    color: var(--text);
}

/* Big heading — the hook */
.hero-heading {
    font-family: 'Instrument Serif', serif;
    font-size: clamp(2.8rem, 5.2vw, 4.2rem);
    font-weight: 400;
    line-height: 1.25;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: clamp(2rem, 3.5vw, 2.8rem);
    display: flex;
    flex-wrap: wrap;
    gap: 0.15em;
    align-items: baseline;
}

.hero-heading .hero-word {
    display: inline-block;
    opacity: 0;
    transform: translateY(8px);
    animation: fadeInWord 1.1s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.hero-heading .hero-word:nth-child(1)  { animation-delay: 0.10s; }
.hero-heading .hero-word:nth-child(2)  { animation-delay: 0.16s; }
.hero-heading .hero-word:nth-child(3)  { animation-delay: 0.22s; }
.hero-heading .hero-word:nth-child(4)  { animation-delay: 0.28s; }
.hero-heading .hero-word:nth-child(5)  { animation-delay: 0.34s; }
.hero-heading .hero-word:nth-child(6)  { animation-delay: 0.40s; }
.hero-heading .hero-word:nth-child(7)  { animation-delay: 0.46s; }
.hero-heading .hero-word:nth-child(8)  { animation-delay: 0.52s; }
.hero-heading .hero-word:nth-child(9)  { animation-delay: 0.58s; }
.hero-heading .hero-word:nth-child(10) { animation-delay: 0.64s; }
.hero-heading .hero-word:nth-child(11) { animation-delay: 0.70s; }

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

/* Signature moment: an ink underline draws itself under the thesis word
   once the headline has settled, then responds subtly on hover. */
.hero-heading .thesis-ink {
    position: relative;
    display: inline-block;
}

.hero-heading .thesis-ink::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0.02em;
    height: 0.07em;
    border-radius: 2px;
    background: var(--accent, #059669);
    transform: scaleX(0);
    transform-origin: left center;
    animation: thesisUnderline 0.85s cubic-bezier(0.22, 1, 0.36, 1) 1.15s forwards;
    transition: height var(--duration-fast) var(--ease), bottom var(--duration-fast) var(--ease);
}

.hero-heading .thesis-ink:hover::after {
    height: 0.16em;
    bottom: -0.02em;
}

@keyframes thesisUnderline {
    to { transform: scaleX(1); }
}

@media (prefers-reduced-motion: reduce) {
    .hero-heading .hero-word {
        opacity: 1;
        transform: none;
        animation: none;
    }
    .hero-heading .thesis-ink::after {
        animation: none;
        transform: scaleX(1);
    }
}

/* Domain color highlights */
.domain {
    transition: color var(--duration-fast);
}

.domain--health {
    color: #2563EB;
}

.domain--finance {
    color: #059669;
}

.domain--saas {
    color: #D97706;
}

[data-theme="dark"] .domain--health {
    color: #60A5FA;
}

[data-theme="dark"] .domain--finance {
    color: #34D399;
}

[data-theme="dark"] .domain--saas {
    color: #FBBF24;
}

/* Hero actions */
.hero-actions {
    display: flex;
    gap: 0.75rem;
}

.hero-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: var(--small-size);
    font-weight: 500;
    padding: 0.55rem 1.4rem;
    border-radius: 999px;
    background: var(--text);
    color: var(--bg);
    transition: opacity var(--duration-fast), transform var(--duration-fast);
    text-decoration: none;
}

.hero-btn-arrow {
    flex-shrink: 0;
    transition: transform var(--duration-fast) var(--ease);
}

.hero-btn:hover {
    opacity: 0.92;
    transform: translateY(-1px);
}

.hero-btn:hover .hero-btn-arrow {
    transform: translate(2px, -2px);
}


/* ============================================
   CLIENT LOGO STRIP
   ============================================ */
.logo-strip {
    max-width: var(--container);
    margin: 0 auto;
    padding: clamp(3rem, 5vw, 4.5rem) var(--gutter);
    animation: sectionFadeIn 0.7s var(--ease) 0.35s forwards;
    opacity: 0;
}

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

.logo-strip-label {
    display: block;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 1.6rem;
}

/* Infinite logo marquee */
.logo-marquee {
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 7%, #000 93%, transparent 100%);
            mask-image: linear-gradient(to right, transparent 0%, #000 7%, #000 93%, transparent 100%);
}

.logo-track {
    display: flex;
    align-items: center;
    width: max-content;
    animation: logoScroll 38s linear infinite;
}

.logo-track:hover {
    animation-play-state: paused;
}

@keyframes logoScroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

.client-logo {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
    margin: 0 clamp(1.5rem, 3.2vw, 2.5rem);
}

.client-logo-img {
    display: block;
    height: 28px;
    width: auto;
    max-width: none;
    object-fit: contain;
    opacity: 0.6;
    filter: grayscale(100%);
    transition: opacity var(--duration-fast) var(--ease),
                filter var(--duration-fast) var(--ease);
}

/* CNBC is a stacked peacock + wordmark — give it a touch more height
   so it reads with the same optical weight as the wordmark logos */
.client-logo--cnbc .client-logo-img {
    height: 40px;
}

.client-logo:hover .client-logo-img {
    opacity: 1;
    filter: grayscale(0%);
}

[data-theme="dark"] .client-logo-img {
    filter: grayscale(100%) invert(1);
    opacity: 0.45;
}

[data-theme="dark"] .client-logo:hover .client-logo-img {
    filter: grayscale(0%) invert(1);
    opacity: 0.75;
}


/* ============================================
   CASE STUDY ROLE TAGS
   ============================================ */
.case-roles {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
    margin-top: 0.1rem;
}

.case-role {
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    padding: 0.28rem 0.7rem;
    border-radius: 999px;
    white-space: nowrap;
    transition: opacity var(--duration-fast);
}

/* Color variants — light mode */
.case-role--blue {
    color: #2563EB;
    background: rgba(37, 99, 235, 0.07);
}

.case-role--green {
    color: #059669;
    background: rgba(5, 150, 105, 0.07);
}

.case-role--amber {
    color: #B45309;
    background: rgba(180, 83, 9, 0.07);
}

.case-role--purple {
    color: #7C3AED;
    background: rgba(124, 58, 237, 0.07);
}

/* Color variants — dark mode */
[data-theme="dark"] .case-role--blue {
    color: #93B4FD;
    background: rgba(96, 165, 250, 0.1);
}

[data-theme="dark"] .case-role--green {
    color: #6EE7B7;
    background: rgba(52, 211, 153, 0.1);
}

[data-theme="dark"] .case-role--amber {
    color: #FCD34D;
    background: rgba(252, 211, 77, 0.1);
}

[data-theme="dark"] .case-role--purple {
    color: #C4B5FD;
    background: rgba(196, 181, 253, 0.1);
}


/* ============================================
   WORK SECTION
   ============================================ */
.work {
    position: relative;
    z-index: 1;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter) var(--section-gap);
}

.work-header {
    margin-bottom: clamp(2rem, 4vw, 3rem);
}

.label {
    font-size: var(--label-size);
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-secondary);
}


/* ============================================
   CASE STUDY CARDS
   ============================================ */
.case-card {
    display: flex;
    flex-direction: column;
    color: inherit;
    margin-bottom: clamp(5rem, 9vw, 8rem);
    cursor: pointer;
}

/* ── Top: brand logo + meta ── */
.case-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    margin-bottom: clamp(1.1rem, 2vw, 1.6rem);
}

.case-logo-wrap {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
}

.case-logo {
    height: 19px;
    width: auto;
    max-width: 104px;
    object-fit: contain;
    object-position: left center;
    display: block;
    opacity: 0.6;
    filter: grayscale(100%);
    transition: opacity 0.4s var(--ease), filter 0.4s var(--ease);
}

[data-theme="dark"] .case-logo {
    filter: grayscale(100%) invert(1);
    opacity: 0.55;
}

.case-card:hover .case-logo {
    opacity: 1;
    filter: grayscale(0%);
}

[data-theme="dark"] .case-card:hover .case-logo {
    filter: grayscale(0%) invert(1);
    opacity: 0.9;
}

.case-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.case-index {
    font-size: var(--label-size);
    font-weight: 600;
    letter-spacing: 0.06em;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

.case-role-label {
    font-size: var(--label-size);
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-tertiary);
}

.case-meta-sep {
    color: var(--text-tertiary);
    font-size: var(--label-size);
    line-height: 1;
}

.case-readtime {
    font-size: var(--label-size);
    font-weight: 500;
    letter-spacing: 0.02em;
    color: var(--text-tertiary);
}

/* ── Title ── */
.case-title {
    font-size: clamp(1.6rem, 3.4vw, 2.5rem);
    font-weight: 500;
    line-height: 1.18;
    letter-spacing: -0.025em;
    color: var(--text);
    max-width: 22ch;
    transition: color 0.4s var(--ease);
}

.case-problem {
    font-size: var(--body-size);
    line-height: 1.6;
    color: var(--text-secondary);
    max-width: 56ch;
    margin-top: clamp(0.7rem, 1.4vw, 1rem);
}

.case-roles {
    margin-top: clamp(1rem, 1.8vw, 1.35rem);
}

.case-improvement {
    font-size: var(--small-size);
    color: var(--text-secondary);
    margin-top: 0.9rem;
    font-weight: 500;
    font-style: italic;
}

/* ── Image ── */
.case-image {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    max-width: 880px;
    margin-top: clamp(1.8rem, 3.2vw, 2.6rem);
    background: var(--bg-elevated);
    box-shadow: 0 1px 0 var(--border);
    transition: box-shadow 0.5s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.case-card:hover .case-image {
    transform: translateY(-4px);
    box-shadow: 0 28px 60px -22px rgba(0, 0, 0, 0.22),
                0 8px 18px -10px rgba(0, 0, 0, 0.12);
}

[data-theme="dark"] .case-card:hover .case-image {
    box-shadow: 0 28px 60px -22px rgba(0, 0, 0, 0.65),
                0 8px 18px -10px rgba(0, 0, 0, 0.45);
}

.case-image::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 60%, rgba(0, 0, 0, 0.10));
    opacity: 0;
    transition: opacity 0.4s var(--ease);
    pointer-events: none;
    border-radius: inherit;
}

.case-card:hover .case-image::after {
    opacity: 1;
}

.case-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
    border-radius: inherit;
}

.case-card:hover .case-thumbnail {
    transform: scale(1.035);
}

/* ── CTA ── */
.case-cta {
    font-size: var(--small-size);
    font-weight: 500;
    color: var(--text);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: clamp(1.1rem, 2vw, 1.5rem);
}

.case-cta .arrow {
    display: inline-block;
    transition: transform 0.3s var(--ease);
}

.case-card:hover .case-cta .arrow {
    transform: translateX(5px);
}


/* ============================================
   EXPERIENCE / TIMELINE
   ============================================ */
.experience {
    position: relative;
    z-index: 1;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter) var(--section-gap);
}

.experience-wrapper {
    display: grid;
    gap: clamp(2.5rem, 4vw, 3.5rem);
}

.experience-header {
    margin-bottom: 0.5rem;
}

.experience-list {
    display: flex;
    flex-direction: column;
    gap: clamp(1.8rem, 2.5vw, 2.5rem);
}

.experience-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding-bottom: clamp(1.5rem, 2vw, 2rem);
    border-bottom: 1px solid var(--border);
}

.experience-item:last-child {
    border-bottom: none;
}

.exp-logo {
    height: 22px;
    width: auto;
    max-width: 165px;
    object-fit: contain;
    object-position: left center;
    opacity: 0.9;
    filter: grayscale(100%);
    margin-bottom: 0.15rem;
}

[data-theme="dark"] .exp-logo {
    filter: grayscale(100%) invert(1);
    opacity: 0.92;
}

.exp-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.exp-role {
    font-size: var(--body-size);
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--text);
    margin: 0;
}

.exp-date {
    font-size: var(--small-size);
    color: var(--text-tertiary);
    font-weight: 400;
    white-space: nowrap;
}

.exp-company {
    font-size: var(--small-size);
    color: var(--text-secondary);
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem;
}

.exp-location {
    font-size: 0.7rem;
    color: var(--text-tertiary);
    font-weight: 400;
}

.exp-badge {
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #7C3AED;
    background: rgba(124, 58, 237, 0.07);
    padding: 0.25rem 0.6rem;
    border-radius: 999px;
}

.exp-points {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin: 0.2rem 0 0;
}

.exp-point {
    position: relative;
    padding-left: 1.15rem;
    font-size: var(--small-size);
    line-height: 1.6;
    color: var(--text-secondary);
    max-width: 64ch;
}

.exp-point::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 3.5px 0 3.5px 5px;
    border-color: transparent transparent transparent var(--exp-marker);
}

.exp-point strong {
    font-weight: 600;
    color: var(--text);
}

@media (max-width: 680px) {
    .exp-header {
        flex-direction: column;
        gap: 0.3rem;
    }

    .exp-date {
        align-self: flex-start;
    }
}


/* ============================================
   TOOLKIT
   ============================================ */
.toolkit {
    position: relative;
    z-index: 1;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter) var(--section-gap);
}

.toolkit-wrapper {
    display: grid;
    gap: clamp(2rem, 3.5vw, 3rem);
}

.toolkit-header {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.toolkit-intro {
    font-size: var(--body-size);
    color: var(--text-secondary);
    max-width: 52ch;
}

.toolkit-rows {
    display: flex;
    flex-direction: column;
}

.tk-row {
    display: grid;
    grid-template-columns: 190px 1fr;
    gap: clamp(1rem, 3vw, 2.5rem);
    align-items: start;
    padding: clamp(1.25rem, 2.2vw, 1.65rem) 0;
    border-top: 1px solid var(--border);
}

.tk-row:last-child {
    border-bottom: 1px solid var(--border);
}

.tk-cat {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    padding-top: 0.4rem;
}

.tk-items {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tk-pill {
    font-size: var(--small-size);
    font-weight: 500;
    color: var(--text-secondary);
    padding: 0.38rem 0.85rem;
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    transition: color var(--duration-fast) var(--ease),
                border-color var(--duration-fast) var(--ease),
                transform var(--duration-fast) var(--ease);
}

.tk-pill:hover {
    color: var(--text);
    border-color: var(--text-tertiary);
    transform: translateY(-1px);
}

.tk-tool {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: var(--small-size);
    font-weight: 500;
    color: var(--text);
    padding: 0.4rem 0.9rem 0.4rem 0.55rem;
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    cursor: default;
    transition: transform var(--duration-fast) var(--ease),
                border-color var(--duration-fast) var(--ease),
                box-shadow var(--duration-fast) var(--ease);
}

.tk-tool:hover {
    transform: translateY(-2px);
    border-color: var(--text-tertiary);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.07);
}

[data-theme="dark"] .tk-tool:hover {
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
}

.tk-tool-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
    flex-shrink: 0;
    transition: transform var(--duration-fast) var(--ease);
}

.tk-tool:hover .tk-tool-icon {
    transform: scale(1.13);
}

[data-theme="dark"] .tk-tool-icon--adaptive {
    filter: invert(1);
}

.tk-cert {
    cursor: pointer;
}

@media (max-width: 680px) {
    .tk-row {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .tk-cat {
        padding-top: 0;
    }
}


/* ============================================
   TESTIMONIALS — Horizontal banner
   ============================================ */
.awards {
    position: relative;
    z-index: 1;
    padding: clamp(5rem, 8vw, 7rem) 0;
}

.awards-wrapper {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.awards-head {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    margin-bottom: clamp(1.8rem, 3vw, 2.6rem);
    max-width: 42ch;
}

.awards-heading {
    font-family: 'Instrument Serif', serif;
    font-weight: 400;
    font-size: clamp(1.6rem, 2.8vw, 2.1rem);
    line-height: 1.3;
    letter-spacing: -0.015em;
    color: var(--text);
}

.awards-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border-top: 1px solid var(--border);
}

.award-row {
    display: grid;
    grid-template-columns: 4.5rem 1fr auto;
    align-items: baseline;
    gap: 1.5rem;
    padding: clamp(0.95rem, 1.8vw, 1.25rem) 0.25rem;
    border-bottom: 1px solid var(--border);
    transition: padding-left 0.35s var(--ease), background 0.35s var(--ease);
}

.award-row:hover {
    padding-left: 0.9rem;
    background: linear-gradient(90deg, var(--bg-elevated), transparent 85%);
}

.award-year {
    font-size: var(--small-size);
    font-weight: 500;
    color: var(--text-tertiary);
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.02em;
}

.award-title {
    font-size: clamp(1rem, 1.6vw, 1.15rem);
    font-weight: 500;
    color: var(--text);
    letter-spacing: -0.01em;
    line-height: 1.35;
}

.award-source {
    font-size: var(--small-size);
    color: var(--text-secondary);
    text-align: right;
    line-height: 1.35;
}

@media (max-width: 580px) {
    .award-row {
        grid-template-columns: 1fr auto;
        gap: 0.35rem 1rem;
        align-items: center;
    }

    .award-year {
        grid-column: 1;
        grid-row: 1;
        order: -1;
    }

    .award-source {
        grid-column: 2;
        grid-row: 1;
    }

    .award-title {
        grid-column: 1 / -1;
        grid-row: 2;
    }

    .award-row:hover {
        padding-left: 0.25rem;
    }
}


/* ============================================
   ABOUT / CTA
   ============================================ */
.about {
    position: relative;
    z-index: 1;
    max-width: var(--container);
    margin: 0 auto;
    padding: var(--section-gap) var(--gutter);
}

.about-wrapper {
    display: grid;
    gap: clamp(2.5rem, 4vw, 3.5rem);
}

.about-teaser {
    max-width: 720px;
    display: flex;
    flex-direction: column;
    gap: clamp(1.4rem, 2.2vw, 1.8rem);
}

.about-teaser .label {
    margin-bottom: 0.5rem;
}

.about-teaser-h {
    font-family: 'Instrument Serif', serif;
    font-weight: 400;
    font-size: clamp(1.8rem, 3.6vw, 2.85rem);
    line-height: 1.2;
    letter-spacing: -0.018em;
    color: var(--text);
}

.about-teaser-h em {
    font-style: italic;
    color: var(--text-secondary);
}

.about-teaser-p {
    font-size: clamp(1rem, 1.2vw, 1.13rem);
    line-height: 1.75;
    color: var(--text-secondary);
    max-width: 58ch;
}

.about-teaser-link {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text);
    text-decoration: none;
    padding-bottom: 0.18rem;
    border-bottom: 1px solid var(--text);
    margin-top: 0.4rem;
    transition: gap var(--duration-fast) var(--ease);
}

.about-teaser-link svg {
    transition: transform var(--duration-fast) var(--ease);
}

.about-teaser-link:hover {
    gap: 0.7rem;
}

.about-teaser-link:hover svg {
    transform: translateX(3px);
}

.about-header {
    max-width: 65ch;
}

.about-heading {
    font-size: clamp(1.8rem, 3.2vw, 2.8rem);
    font-weight: 500;
    letter-spacing: -0.025em;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text);
}

.about-intro {
    font-size: clamp(1rem, 1.05vw, 1.15rem);
    line-height: 1.65;
    color: var(--text-secondary);
    font-weight: 400;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(3rem, 4vw, 4rem);
    padding: 0;
    border-radius: 0;
    background: transparent;
    border: none;
}

@media (max-width: 768px) {
    .about-content {
        grid-template-columns: 1fr;
    }
}

.about-story,
.about-philosophy {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.about-subheading {
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--text);
    text-transform: capitalize;
    margin-bottom: 0.2rem;
}

.about-text {
    font-size: var(--body-size);
    line-height: 1.75;
    color: var(--text-secondary);
    margin: 0;
}

.about-cta {
    max-width: 65ch;
}

.about-cta .about-text {
    font-size: clamp(1rem, 1.05vw, 1.1rem);
    margin-bottom: 1.5rem;
}

.about-links {
    display: flex;
    gap: 2.5rem;
    margin-top: 2rem;
    align-items: center;
}

.about-link {
    font-size: var(--small-size);
    font-weight: 600;
    color: var(--text);
    position: relative;
    padding-bottom: 2px;
}

.about-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: currentColor;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.35s var(--ease);
}

.about-link:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}


/* ============================================
   ABOUT — DESIGN × BUILD
   ============================================ */
.about-build {
    display: flex;
    flex-direction: column;
    gap: 1.3rem;
    padding: clamp(1.6rem, 3.5vw, 2.8rem);
    border: 1px solid var(--border-strong);
    border-radius: 16px;
    background: var(--card-hover);
}

.about-build-head {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.about-build-statement {
    font-family: 'Instrument Serif', serif;
    font-size: clamp(1.65rem, 3.4vw, 2.5rem);
    font-weight: 400;
    line-height: 1.18;
    letter-spacing: -0.02em;
    color: var(--text);
}

.about-build-statement em {
    font-style: italic;
    color: #059669;
}

[data-theme="dark"] .about-build-statement em {
    color: #34D399;
}

.about-build-body {
    font-size: var(--body-size);
    line-height: 1.75;
    color: var(--text-secondary);
    max-width: 66ch;
}

.build-flow {
    display: flex;
    align-items: stretch;
    gap: 0.7rem;
    margin-top: 0.3rem;
}

.build-stage {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1.1rem 1.15rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg);
}

.build-stage-num {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    color: var(--text-tertiary);
}

.build-stage-name {
    font-size: var(--small-size);
    font-weight: 500;
    color: var(--text);
}

.build-stage-tools {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 0.7rem;
}

.build-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

[data-theme="dark"] .build-icon--adaptive {
    filter: invert(1);
}

.build-arrow {
    display: flex;
    align-items: center;
    color: var(--text-tertiary);
    font-size: 1.05rem;
}

.build-ship {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: var(--small-size);
    font-weight: 500;
    color: var(--text-secondary);
}

.build-ship-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #059669;
}

[data-theme="dark"] .build-ship-dot {
    background: #34D399;
}

@media (max-width: 640px) {
    .build-flow {
        flex-direction: column;
    }

    .build-arrow {
        transform: rotate(90deg);
        align-self: center;
        padding: 0.15rem 0;
    }
}


/* ============================================
   FOOTER
   ============================================ */
.footer {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter) 2.5rem;
}

.footer-inner {
    border-top: 1px solid var(--border);
    padding-top: clamp(2rem, 4vw, 3rem);
    display: flex;
    flex-direction: column;
    gap: clamp(1.3rem, 3vw, 2.4rem);
}

.footer-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem 1.8rem;
    flex-wrap: wrap;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem 1.5rem;
}

.footer-link {
    font-size: var(--label-size);
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-secondary);
    transition: color var(--duration-fast) var(--ease);
}

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

.footer-status {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: var(--label-size);
    letter-spacing: 0.04em;
    color: var(--text-secondary);
}

.footer-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #059669;
    animation: pulse 2s ease-in-out infinite;
}

[data-theme="dark"] .footer-status-dot {
    background: #34D399;
}

.footer-signature {
    display: block;
    font-family: 'Instrument Serif', serif;
    font-weight: 400;
    font-size: clamp(2.4rem, 12vw, 7.5rem);
    line-height: 0.9;
    letter-spacing: -0.02em;
    color: var(--text);
}

.footer-bar--base .footer-meta {
    font-size: var(--label-size);
    color: var(--text-tertiary);
}

@media (max-width: 580px) {
    .footer-bar--base {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.4rem;
    }
}


/* ============================================
   ANIMATIONS
   ============================================ */

/* --- Hero load animation --- */
/* ============================================
   MULTILINGUAL INTRO
   (display toggled by html.intro-running in head)
   ============================================ */
.intro {
    position: fixed;
    inset: 0;
    z-index: 9999;
    align-items: center;
    justify-content: center;
    background: var(--intro-bg, #fff);
    transition: transform 0.7s cubic-bezier(0.76, 0, 0.24, 1);
    will-change: transform;
}

.intro--lift {
    transform: translateY(-101%);
}

.intro-word {
    font-family: 'Instrument Serif', serif;
    font-weight: 400;
    font-size: clamp(2.6rem, 8vw, 5rem);
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--intro-fg, #0A0A0A);
    transition: color 0.4s ease;
}

.intro-word--accent {
    color: var(--intro-accent, #4F46E5);
}

.intro-word.is-in {
    animation: introPop 0.42s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes introPop {
    from { opacity: 0; filter: blur(10px); transform: translateY(10px) scale(0.985); }
    to   { opacity: 1; filter: blur(0);    transform: translateY(0) scale(1); }
}

.fade-up {
    opacity: 0;
    transform: translateY(22px);
    animation: fadeUp 0.85s var(--ease) forwards;
}

/* Hero stagger: status → heading → pitch → actions */
.hero-inner > .fade-up:nth-child(1) { animation-delay: 0.05s; }   /* status */
.hero-inner > .fade-up:nth-child(2) { animation-delay: 0.15s; }   /* heading */
.hero-inner > .fade-up:nth-child(3) { animation-delay: 0.28s; }   /* pitch */
.hero-inner > .fade-up:nth-child(4) { animation-delay: 0.40s; }   /* actions */

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

/* --- Scroll reveal --- */
.reveal {
    opacity: 0;
    transform: translateY(30px) scale(0.99);
    filter: blur(5px);
    transition: opacity 0.85s var(--ease),
                transform 0.85s var(--ease),
                filter 0.85s var(--ease);
}

.reveal.visible {
    opacity: 1;
    transform: none;
    filter: blur(0);
}

/* Stagger case study cards on reveal */
.work .case-card:nth-child(3) { transition-delay: 0.06s; }
.work .case-card:nth-child(4) { transition-delay: 0.12s; }

/* About section stagger */
.about .reveal:nth-child(2) { transition-delay: 0.08s; }
.about .reveal:nth-child(3) { transition-delay: 0.14s; }
.about .reveal:nth-child(4) { transition-delay: 0.20s; }


/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 580px) {
    .case-top {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.7rem;
    }

    .case-meta {
        justify-content: flex-start;
    }

    .case-image {
        aspect-ratio: 4 / 3;
        border-radius: 12px;
    }
}

@media (max-width: 680px) {
    .hero-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .testimonial-card {
        width: 280px;
    }
}

@media (max-width: 580px) {
    .nav-right {
        gap: 1rem;
    }

    .nav-link {
        display: none;
    }

    .status-badge {
        font-size: 0.6rem;
        padding: 0.25rem 0.6rem;
    }

    .about-links {
        flex-direction: column;
        gap: 0.8rem;
    }
}


/* ============================================
   REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .reveal,
    .fade-up {
        opacity: 1;
        transform: none;
        filter: none;
        animation: none;
    }

    .testimonials-track,
    .logo-track {
        animation: none;
    }

    .ambient-orb {
        display: none;
    }
}


/* ============================================
   SCROLLBAR
   ============================================ */
::-webkit-scrollbar {
    width: 5px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border-strong);
    border-radius: 999px;
}


/* ============================================
   ASK ME ANYTHING — Floating chat launcher
   ============================================ */
.ama-dock {
    position: fixed;
    left: 50%;
    bottom: clamp(1rem, 3vh, 1.75rem);
    transform: translateX(-50%);
    z-index: 150;
    width: min(540px, calc(100vw - 2rem));
    animation: amaDockIn 0.7s var(--ease) 0.9s both;
}

@keyframes amaDockIn {
    from { opacity: 0; transform: translate(-50%, 20px); }
    to   { opacity: 1; transform: translate(-50%, 0); }
}

/* --- Launcher bar (collapsed state) --- */
@property --ama-angle {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: false;
}

.ama-bar {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    width: 100%;
    padding: 0.62rem 0.62rem 0.62rem 1rem;
    border-radius: 16px;
    background: var(--bg-elevated);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.10), 0 2px 8px rgba(0, 0, 0, 0.05);
    cursor: pointer;
    isolation: isolate;
    transition: transform var(--duration-fast) var(--ease),
                box-shadow var(--duration-fast) var(--ease);
}

/* Gemini-style animated conic gradient border */
.ama-bar::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1.5px;
    background: conic-gradient(
        from var(--ama-angle),
        #4285F4 0deg,
        #9B72CB 90deg,
        #D96570 180deg,
        #FBBC05 270deg,
        #4285F4 360deg
    );
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
            mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
            mask-composite: exclude;
    animation: amaBorderSpin 5s linear infinite;
    pointer-events: none;
    z-index: 1;
}

.ama-dock.open .ama-bar::before {
    animation-duration: 2.5s;
}

@keyframes amaBorderSpin {
    to { --ama-angle: 360deg; }
}

.ama-bar:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.14), 0 3px 10px rgba(0, 0, 0, 0.06);
}

[data-theme="dark"] .ama-bar {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.55), 0 2px 8px rgba(0, 0, 0, 0.4);
}

.ama-bar-icon {
    display: flex;
    color: var(--text);
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}

.ama-bar-text {
    flex: 1;
    min-width: 0;
    text-align: left;
    font-size: var(--small-size);
    font-weight: 400;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: opacity 0.35s var(--ease);
    position: relative;
    z-index: 2;
}

.ama-bar-send {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 11px;
    background: var(--text);
    color: var(--bg);
    flex-shrink: 0;
    transition: transform var(--duration) var(--ease);
    position: relative;
    z-index: 2;
}

.ama-dock.open .ama-bar-send {
    transform: rotate(180deg);
}

/* --- Chat window (expanded state) --- */
.ama-window {
    position: absolute;
    left: 0;
    right: 0;
    bottom: calc(100% + 0.7rem);
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 7rem);
    border: 1px solid var(--border-strong);
    background: var(--bg-elevated);
    border-radius: 18px;
    box-shadow: 0 16px 50px rgba(0, 0, 0, 0.16), 0 4px 14px rgba(0, 0, 0, 0.07);
    overflow: hidden;
    transform-origin: bottom center;
    opacity: 0;
    transform: translateY(14px) scale(0.97);
    pointer-events: none;
    transition: opacity 0.26s var(--ease),
                transform 0.32s var(--ease);
}

[data-theme="dark"] .ama-window {
    box-shadow: 0 16px 50px rgba(0, 0, 0, 0.6), 0 4px 14px rgba(0, 0, 0, 0.45);
}

.ama-dock.open .ama-window {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.ama-window-head {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.85rem 0.95rem;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

/* --- Bot "eyes" avatar: idle blink + thinking scan --- */
.ama-face {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: 11px;
    background: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.ama-eye {
    width: 6px;
    height: 9px;
    border-radius: 4px;
    background: var(--bg);
    display: flex;
    align-items: center;
    justify-content: center;
    /* Blink: a quick vertical squash on a long, calm loop */
    animation: amaBlink 5.4s var(--ease) infinite;
    transform-origin: center;
}

.ama-eye:nth-child(2) { animation-delay: 0.06s; }

.ama-pupil {
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: var(--bg);
    /* Scan happens here so it can stack with the eyelid blink */
    transition: transform 0.3s var(--ease);
}

@keyframes amaBlink {
    0%, 92%, 100% { transform: scaleY(1); }
    95%           { transform: scaleY(0.1); }
}

/* Thinking: pupils sweep side to side like reading */
.ama-face--thinking .ama-pupil {
    animation: amaScan 1.5s ease-in-out infinite;
}

@keyframes amaScan {
    0%, 100% { transform: translateX(-1.5px); }
    50%      { transform: translateX(1.5px); }
}

@media (prefers-reduced-motion: reduce) {
    .ama-eye,
    .ama-face--thinking .ama-pupil { animation: none; }
}

.ama-id {
    flex: 1;
    display: flex;
    flex-direction: column;
    line-height: 1.35;
}

.ama-id-name {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text);
}

.ama-id-status {
    font-size: 0.67rem;
    color: var(--text-tertiary);
    display: flex;
    align-items: center;
    gap: 0.32rem;
}

.ama-id-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #059669;
}

[data-theme="dark"] .ama-id-dot {
    background: #34D399;
}

.ama-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    color: var(--text-secondary);
    flex-shrink: 0;
    transition: background var(--duration-fast), color var(--duration-fast);
}

.ama-close:hover {
    background: color-mix(in srgb, var(--text) 8%, transparent);
    color: var(--text);
}

/* --- Message log --- */
.ama-log {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    padding: 1rem;
    overflow-y: auto;
    flex: 1 1 auto;
    min-height: 110px;
}

.ama-row {
    display: flex;
    align-items: flex-end;
    gap: 0.55rem;
    max-width: 92%;
    animation: amaIn 0.4s var(--ease) both;
}

.ama-row--bot { align-self: flex-start; }

.ama-row--user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

@keyframes amaIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.ama-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--text);
    color: var(--bg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.58rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    flex-shrink: 0;
}

.ama-bubble {
    font-size: var(--small-size);
    line-height: 1.6;
    padding: 0.68rem 0.9rem;
    border-radius: 14px;
}

.ama-row--bot .ama-bubble {
    background: rgba(0, 0, 0, 0.04);
    border: 1px solid var(--border);
    color: var(--text);
    border-bottom-left-radius: 4px;
}

[data-theme="dark"] .ama-row--bot .ama-bubble {
    background: rgba(255, 255, 255, 0.05);
}

.ama-row--user .ama-bubble {
    background: var(--text);
    color: var(--bg);
    font-weight: 500;
    border-bottom-right-radius: 4px;
}

/* Typing indicator */
.ama-bubble--typing {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 0.8rem 0.9rem;
}

.ama-bubble--typing span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--text-tertiary);
    animation: amaTyping 1.2s infinite ease-in-out;
}

.ama-bubble--typing span:nth-child(2) { animation-delay: 0.15s; }
.ama-bubble--typing span:nth-child(3) { animation-delay: 0.3s; }

@keyframes amaTyping {
    0%, 60%, 100% { opacity: 0.25; transform: translateY(0); }
    30% { opacity: 1; transform: translateY(-3px); }
}

/* --- Suggested question chips --- */
.ama-foot {
    padding: 0.85rem 1rem 1rem;
    border-top: 1px solid var(--border);
    flex-shrink: 0;
}

.ama-hint {
    font-size: var(--label-size);
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 0.7rem;
}

.ama-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.ama-chip {
    display: inline-flex;
    align-items: center;
    font-size: var(--small-size);
    font-weight: 500;
    color: var(--text);
    text-align: left;
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    border: 1px solid var(--border-strong);
    background: var(--bg);
    cursor: pointer;
    transition: background var(--duration-fast) var(--ease),
                border-color var(--duration-fast) var(--ease),
                opacity var(--duration-fast) var(--ease),
                transform var(--duration-fast) var(--ease);
}

/* Flowing answer body: clean paragraphs + inline keyword highlights */
.ama-bubble p {
    margin: 0;
}

.ama-bubble p + p {
    margin-top: 0.6rem;
}

.ama-hl {
    color: var(--ama-hl-text);
    background: var(--ama-hl-bg);
    font-weight: 500;
    padding: 0.04em 0.32em;
    border-radius: 5px;
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
}

.ama-bubble strong {
    color: var(--text);
    font-weight: 600;
}

/* "Ask me more" follow-up prompts under an answer */
.ama-followups {
    margin-top: 0.85rem;
    animation: amaIn 0.45s var(--ease) 0.05s both;
}

.ama-followups-label {
    font-size: var(--label-size);
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: 0.55rem;
}

.ama-followups-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.ama-cite {
    color: var(--text);
    font-weight: 600;
    text-decoration: none;
    background-image: linear-gradient(currentColor, currentColor);
    background-size: 100% 1px;
    background-position: 0 calc(100% - 1px);
    background-repeat: no-repeat;
    transition: background-size var(--duration-fast) var(--ease);
}

.ama-cite:hover {
    background-size: 100% 2px;
}

.ama-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.7rem;
}

.ama-action {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.85rem;
    border-radius: 10px;
    border: 1px solid var(--border-strong);
    background: var(--bg);
    color: var(--text);
    font-size: 0.83rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform var(--duration-fast) var(--ease),
                background var(--duration-fast) var(--ease),
                border-color var(--duration-fast) var(--ease),
                color var(--duration-fast) var(--ease);
}

.ama-action svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.ama-action:hover {
    transform: translateY(-1px);
    border-color: var(--text-tertiary);
}

.ama-action--primary {
    background: var(--text);
    color: var(--bg);
    border-color: var(--text);
}

.ama-action--primary:hover {
    background: var(--text-secondary);
    border-color: var(--text-secondary);
}

.ama-logos {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    margin-top: 0.75rem;
}

.ama-logo {
    width: 22px;
    height: 22px;
    object-fit: contain;
}

[data-theme="dark"] .ama-logo--adaptive {
    filter: invert(1);
}

.ama-link {
    color: var(--text);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.ama-chip:hover {
    background: color-mix(in srgb, var(--text) 7%, var(--bg));
    border-color: var(--text-tertiary);
    transform: translateY(-1px);
}

.ama-chip--asked { opacity: 0.4; }
.ama-chip--asked:hover { opacity: 0.7; }

@media (max-width: 480px) {
    .ama-row { max-width: 100%; }
}


/* ============================================
   ABOUT PAGE (/about/)
   ============================================ */
.about-page {
    position: relative;
    max-width: var(--container);
    margin: 0 auto;
    padding: clamp(7rem, 14vh, 11rem) var(--gutter) clamp(5rem, 8vw, 8rem);
    overflow: hidden;
}

.nav-link--active {
    color: var(--text);
}

/* Soft animated gradient blob */
.about-blob {
    position: absolute;
    top: clamp(6rem, 14vh, 12rem);
    left: clamp(-6rem, -4vw, -2rem);
    width: clamp(420px, 50vw, 720px);
    height: clamp(420px, 50vw, 720px);
    background: radial-gradient(closest-side at 50% 50%,
        rgba(255, 187, 153, 0.55) 0%,
        rgba(255, 187, 153, 0.18) 45%,
        transparent 75%);
    filter: blur(60px);
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    animation: blobDrift 22s ease-in-out infinite;
    will-change: transform;
}

[data-theme="dark"] .about-blob {
    background: radial-gradient(closest-side at 50% 50%,
        rgba(165, 135, 255, 0.28) 0%,
        rgba(165, 135, 255, 0.10) 45%,
        transparent 75%);
}

@keyframes blobDrift {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    33% {
        transform: translate(60px, -40px) scale(1.08);
    }
    66% {
        transform: translate(-40px, 50px) scale(0.95);
    }
}

@media (prefers-reduced-motion: reduce) {
    .about-blob { animation: none; }
}

/* Parallax signature */
.about-signature {
    position: absolute;
    top: clamp(6rem, 18vh, 10rem);
    right: clamp(-2rem, -2vw, 0rem);
    font-family: 'Instrument Serif', serif;
    font-style: italic;
    font-weight: 400;
    font-size: clamp(7rem, 18vw, 16rem);
    line-height: 0.85;
    color: var(--text);
    opacity: 0.05;
    pointer-events: none;
    z-index: 0;
    user-select: none;
    letter-spacing: -0.02em;
    will-change: transform;
}

[data-theme="dark"] .about-signature {
    opacity: 0.08;
}

/* Hero block */
.about-hero {
    position: relative;
    z-index: 1;
    max-width: 760px;
    margin-bottom: clamp(4rem, 8vw, 7rem);
}

.about-label {
    display: block;
    margin-bottom: clamp(1.5rem, 3vw, 2.2rem);
}

.about-h1 {
    font-family: 'Instrument Serif', serif;
    font-weight: 400;
    font-size: clamp(2.4rem, 5.4vw, 4.2rem);
    line-height: 1.15;
    letter-spacing: -0.018em;
    color: var(--text);
    margin-bottom: clamp(1.8rem, 3vw, 2.5rem);
}

.about-h1 em {
    font-style: italic;
    color: var(--text-secondary);
}

.about-lede {
    font-family: 'Instrument Serif', serif;
    font-style: italic;
    font-size: clamp(1.2rem, 2vw, 1.55rem);
    line-height: 1.5;
    color: var(--text-secondary);
    max-width: 60ch;
    letter-spacing: -0.005em;
}

.about-lede em {
    font-style: italic;
    color: var(--text);
}

/* Body sections */
.about-body {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: clamp(3.5rem, 6vw, 5.5rem);
    max-width: 720px;
    margin-bottom: clamp(4rem, 7vw, 6rem);
}

.about-section {
    position: relative;
    padding-left: clamp(2.6rem, 5vw, 3.8rem);
}

.about-section-no {
    position: absolute;
    left: 0;
    top: 0.4rem;
    font-family: 'Instrument Serif', serif;
    font-style: italic;
    font-size: 1.1rem;
    color: var(--text-tertiary);
    letter-spacing: 0.04em;
}

.about-section-h {
    font-family: 'Instrument Serif', serif;
    font-weight: 400;
    font-size: clamp(1.6rem, 2.6vw, 2.1rem);
    line-height: 1.25;
    letter-spacing: -0.015em;
    color: var(--text);
    margin-bottom: clamp(1.2rem, 2vw, 1.6rem);
}

.about-section p {
    font-size: clamp(1.02rem, 1.2vw, 1.13rem);
    line-height: 1.75;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    max-width: 58ch;
}

.about-section p:last-child {
    margin-bottom: 0;
}

.about-section p em {
    font-family: 'Instrument Serif', serif;
    font-style: italic;
    font-size: 1.08em;
    color: var(--text);
}

.about-stat {
    font-weight: 600;
    color: var(--text);
    background-image: linear-gradient(currentColor, currentColor);
    background-size: 100% 1px;
    background-position: 0 calc(100% - 2px);
    background-repeat: no-repeat;
    white-space: nowrap;
}

/* Now module */
.about-now {
    position: relative;
    z-index: 1;
    max-width: 640px;
    padding: clamp(1.5rem, 2.4vw, 2rem) clamp(1.6rem, 2.4vw, 2rem);
    border: 1px solid var(--border);
    border-radius: 16px;
    background: var(--bg-elevated);
    margin-bottom: clamp(4rem, 7vw, 6rem);
}

.now-head {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 1.2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.now-pulse {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10B981;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.55);
    animation: nowPulse 2s ease-in-out infinite;
}

@keyframes nowPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.55); }
    50% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
}

.now-title {
    font-family: 'Instrument Serif', serif;
    font-size: 1.35rem;
    color: var(--text);
    letter-spacing: -0.01em;
}

.now-date {
    margin-left: auto;
    font-size: 0.78rem;
    color: var(--text-tertiary);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.now-list {
    display: flex;
    flex-direction: column;
    gap: 0.95rem;
    margin: 0;
}

.now-row {
    display: grid;
    grid-template-columns: clamp(110px, 18%, 140px) 1fr;
    gap: 1rem;
    align-items: baseline;
}

.now-row dt {
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--text-tertiary);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.now-row dd {
    font-size: 0.95rem;
    line-height: 1.55;
    color: var(--text);
    margin: 0;
}

.now-row dd em {
    font-style: italic;
    color: var(--text);
}

@media (max-width: 560px) {
    .now-row {
        grid-template-columns: 1fr;
        gap: 0.3rem;
    }
}

/* Closing CTA */
.about-cta {
    position: relative;
    z-index: 1;
    max-width: 640px;
    padding-top: clamp(2rem, 4vw, 3rem);
    border-top: 1px solid var(--border);
}

.about-cta-text {
    font-family: 'Instrument Serif', serif;
    font-size: clamp(1.4rem, 2.3vw, 1.85rem);
    line-height: 1.4;
    color: var(--text);
    letter-spacing: -0.01em;
    margin-bottom: clamp(1.6rem, 2.5vw, 2rem);
    max-width: 50ch;
}

.about-cta-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
}

.about-cta-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1.1rem;
    border-radius: 999px;
    border: 1px solid var(--border-strong);
    background: var(--bg);
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: transform var(--duration-fast) var(--ease),
                background var(--duration-fast) var(--ease);
}

.about-cta-link svg {
    transition: transform var(--duration-fast) var(--ease);
}

.about-cta-link:hover {
    transform: translateY(-1px);
}

.about-cta-link:hover svg {
    transform: translate(2px, -2px);
}

.about-cta-link--primary {
    background: var(--text);
    color: var(--bg);
    border-color: var(--text);
}

.about-cta-link--primary:hover {
    opacity: 0.92;
}

/* ============================================
   OFF THE CLOCK — hobby card stack
   ============================================ */
.off-clock {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1.05fr;
    gap: clamp(2rem, 5vw, 4rem);
    align-items: center;
    margin: clamp(4rem, 7vw, 6rem) 0;
    max-width: 1000px;
}

.off-clock-intro {
    max-width: 38ch;
}

.off-clock-intro .label {
    display: block;
    margin-bottom: 1.2rem;
}

.off-clock-h {
    font-family: 'Instrument Serif', serif;
    font-weight: 400;
    font-size: clamp(1.8rem, 3.2vw, 2.4rem);
    line-height: 1.2;
    letter-spacing: -0.015em;
    color: var(--text);
    margin-bottom: 1.2rem;
}

.off-clock-p {
    font-size: 1.02rem;
    line-height: 1.7;
    color: var(--text-secondary);
}

.off-clock-p em {
    font-family: 'Instrument Serif', serif;
    font-style: italic;
    color: var(--text);
}

/* Deck — stacked polaroid cards */
.hobby-deck {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1.18;
    max-width: 380px;
    margin-left: auto;
    cursor: pointer;
    outline: none;
}

.hobby-deck:focus-visible {
    outline: 2px solid var(--text);
    outline-offset: 12px;
    border-radius: 18px;
}

.hobby-card {
    --pos: 0;
    --n: 4;
    position: absolute;
    inset: 0;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 14px 14px 18px;
    box-shadow: 0 14px 30px -16px rgba(0, 0, 0, 0.18),
                0 3px 10px -4px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    transform-origin: 50% 100%;
    transform: translate(
            calc(var(--pos) * 8px),
            calc(var(--pos) * 10px)
        )
        rotate(calc((var(--pos) - 1.5) * 2.2deg))
        scale(calc(1 - var(--pos) * 0.025));
    transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1),
                box-shadow 0.4s var(--ease),
                opacity 0.4s var(--ease);
    opacity: calc(1 - var(--pos) * 0.18);
    pointer-events: none;
}

.hobby-card.is-top {
    pointer-events: auto;
    transform: translate(0, -4px) rotate(-1deg) scale(1);
    box-shadow: 0 28px 60px -22px rgba(0, 0, 0, 0.28),
                0 8px 22px -10px rgba(0, 0, 0, 0.14);
    opacity: 1;
}

[data-theme="dark"] .hobby-card {
    box-shadow: 0 14px 30px -16px rgba(0, 0, 0, 0.55),
                0 3px 10px -4px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] .hobby-card.is-top {
    box-shadow: 0 28px 60px -22px rgba(0, 0, 0, 0.7),
                0 8px 22px -10px rgba(0, 0, 0, 0.45);
}

.hobby-deck:hover .hobby-card.is-top {
    transform: translate(0, -8px) rotate(-1.4deg) scale(1.01);
}

.hobby-card.is-flicking {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.5s var(--ease);
    transform: translate(-160%, 30px) rotate(-18deg) scale(0.96) !important;
    opacity: 0 !important;
}

.hobby-photo {
    flex: 1;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    min-height: 0;
    background: linear-gradient(135deg, #efe7d8 0%, #d9c4a1 100%);
    position: relative;
}

/* Per-card mood gradients — show as fallback if photo missing */
.hobby-card[data-i="0"] .hobby-photo {
    background: linear-gradient(160deg, #f6c08b 0%, #d97757 55%, #6a3520 100%);
}
.hobby-card[data-i="1"] .hobby-photo {
    background: linear-gradient(180deg, #6d7280 0%, #2f3439 60%, #0f1216 100%);
}
.hobby-card[data-i="2"] .hobby-photo {
    background:
        linear-gradient(135deg, transparent 60%, rgba(0,0,0,0.15)),
        repeating-linear-gradient(135deg, #c64545 0 14%, #d97757 14% 28%, #e6c200 28% 42%, #2f8a3c 42% 56%, #2e5fb4 56% 70%, #5031a8 70% 84%, #c64545 84% 100%);
}
.hobby-card[data-i="3"] .hobby-photo {
    background: linear-gradient(180deg, #6cb1e8 0%, #c8dff5 60%, #efe7d8 100%);
}

.hobby-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    position: relative;
    z-index: 1;
}

.hobby-meta {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 0 0.1rem 0.1rem;
}

.hobby-tag {
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-tertiary);
}

.hobby-title {
    font-family: 'Instrument Serif', serif;
    font-weight: 400;
    font-style: italic;
    font-size: 1.18rem;
    line-height: 1.25;
    color: var(--text);
    letter-spacing: -0.005em;
}

.hobby-caption {
    font-size: 0.82rem;
    line-height: 1.5;
    color: var(--text-secondary);
}

.hobby-deck-hint {
    position: absolute;
    bottom: -2.2rem;
    right: 0.4rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.7rem;
    color: var(--text-tertiary);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    pointer-events: none;
    opacity: 0.7;
}

@media (max-width: 760px) {
    .off-clock {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
    .hobby-deck {
        margin-left: 0;
        max-width: 320px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hobby-card {
        transition: none;
    }
    .hobby-card.is-flicking {
        transition: opacity 0.3s linear;
    }
}
