/* ── Geist variable font ──────────────────────────────────────────────────── */
@font-face {
    font-family: "Geist";
    src: url("../fonts/Geist-VariableFont_wght.ttf") format("truetype-variations"),
         url("../fonts/Geist-VariableFont_wght.ttf") format("truetype");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

html {
    scroll-behavior: smooth;
}

/* ── Hero split panel ─────────────────────────────────────────────────────── */
.hero-split-right {
    /* Theme-aware "screen" backdrop for the project carousel. Light mode gets a
       soft slate wash with a faint accent glow; dark mode keeps the deep slate. */
    background:
        radial-gradient(120% 80% at 100% 0%, color-mix(in oklab, var(--color-accent) 10%, transparent), transparent 60%),
        linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
}
.dark .hero-split-right {
    background:
        radial-gradient(120% 80% at 100% 0%, color-mix(in oklab, var(--color-accent) 16%, transparent), transparent 60%),
        linear-gradient(180deg, #0f172a 0%, #0b1120 100%);
}

/* Ensure the live-dot pulse animation works on the automation card */
@keyframes live-pulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 2px rgba(74,222,128,0.2); }
    50%       { opacity: 0.5; box-shadow: 0 0 0 4px rgba(74,222,128,0.1); }
}

html, body {
    font-family: "Geist", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* Animated utility */
.animated {
    opacity: 0;
}

/* Card base */
.card {
    position: relative;
    overflow: hidden;
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease, border-color 0.35s ease;
}

    /* Hover lift */
    .card:hover {
        transform: translateY(-6px);
        border-color: rgba(81, 162, 255, 0.4);
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.45), inset 0 0 0 1px rgba(81, 162, 255, 0.15);
    }

    /* Cursor glow — blue in light, orange in dark */
    .card::after {
        content: "";
        position: absolute;
        inset: 0;
        background: radial-gradient( 800px circle at var(--x, 50%) var(--y, 50%), rgba(81, 162, 255, 0.18), transparent 45% );
        opacity: 0;
        transition: opacity 0.35s ease;
        pointer-events: none;
    }

    .card:hover::after {
        opacity: 1;
    }

.dark .card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.45), inset 0 0 0 1px rgba(251, 146, 60, 0.15);
}

.dark .card::after {
    background: radial-gradient( 800px circle at var(--x, 50%) var(--y, 50%), rgba(251, 146, 60, 0.18), transparent 45% );
}

/* Scroll reveal start state */
.scroll-card {
    opacity: 0;
    transform: translateY(80px) scale(0.97);
    will-change: transform, opacity;
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.7s ease;
}

/* Ripple effect */
.card .ripple {
    position: absolute;
    inset: 0;
    background: radial-gradient( circle at center, rgba(81, 162, 255, 0.35), transparent 70% );
    transform: scale(0);
    opacity: 0;
    transition: transform 0.7s ease, opacity 0.7s ease;
    pointer-events: none;
}

/* Accessibility focus */
.card:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(81, 162, 255, 0.6);
}

/* Disable scroll animation on mobile */
@media (max-width: 768px) {
    .scroll-card {
        transform: none !important;
        opacity: 1 !important;
        transition: none !important;
    }
}

/* In your app.css or a <HeadContent> style block */

/* Anime.js splits text into these wrapper spans � descenders get clipped without this */
[data-anime-words] span,
[data-anime-chars] span {
    padding-bottom: 0.17em;
    margin-bottom: -0.17em;
}

h1 span,
h2 span {
    padding-bottom: 0.17em;
    margin-bottom: -0.17em;
}

/* ── Process rail — connected timeline ──────────────────────────────────── */
.process-rail {
    position: relative;
}

.process-rail-line {
    position: absolute;
    left: 36px;
    right: 36px;
    top: 20px;
    height: 2px;
    background-image: linear-gradient(to right, var(--process-line-color, #e2e8f0) 50%, transparent 50%);
    background-size: 10px 2px;
    background-repeat: repeat-x;
    pointer-events: none;
    display: none;
}

@media (min-width: 1024px) {
    .process-rail-line {
        display: block;
    }
}

.dark .process-rail-line {
    --process-line-color: rgba(255,255,255,0.10);
}

/* ── Card active state ───────────────────────────────────────────────────── */
.card:active {
    transform: scale(0.95);
    transition-duration: 100ms;
}

/* ── Card-cool (Websites) — light blue glow both modes ───────────────────── */
.card-cool:hover {
    box-shadow: 0 20px 40px rgba(0,0,0,0.10),
                inset 0 0 0 1px rgba(142,197,255,0.40); 
}
.card-cool::after {
    background: radial-gradient(800px circle at var(--x,50%) var(--y,0%),
        rgba(142,197,255,0.18), transparent 45%);
}

/* override the global .dark .card rules so website card stays light blue in dark */
.dark .card-cool:hover {
    box-shadow: 0 20px 40px rgba(0,0,0,0.50), inset 0 0 0 1px rgba(142,197,255,0.30);
}
.dark .card-cool::after {
    background: radial-gradient(800px circle at var(--x,50%) var(--y,0%),
        rgba(142,197,255,0.18), transparent 45%);
}

/* ── Card-warm (Automation) — amber light / orange dark; ambient at rest ─── */
.card-warm:hover {
    box-shadow: 0 20px 40px rgba(0,0,0,0.10),
                inset 0 0 0 1px rgba(245,158,11,0.40);
}
.card-warm::after {
    background: radial-gradient(800px circle at var(--x,50%) var(--y,0%),
        rgba(245,158,11,0.16), transparent 45%);
}
/* dark: faint ambient ember at rest, full orange on hover */
.dark .card-warm::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(ellipse 70% 50% at 100% 0%,
        rgba(251,146,60,0.07), transparent 60%);
    pointer-events: none;
}
.dark .card-warm:hover {
    box-shadow: 0 20px 40px rgba(0,0,0,0.50),
                inset 0 0 0 1px rgba(251,146,60,0.35);
}
.dark .card-warm::after {
    background: radial-gradient(800px circle at var(--x,50%) var(--y,0%),
        rgba(251,146,60,0.20), transparent 45%);
}

/* ── Portal — design tokens ──────────────────────────────────────────────── */
:root {
    --portal-track: #f1f5f9;   /* slate-100 — ring track + progress bar bg */
    --portal-rose:  #fb7185;   /* rose-400  — hero aura blob 2 */
}
.dark {
    --portal-track: #171717;   /* neutral-900 */
}

/* portal: progress ring track */
.portal-ring-track {
    stroke: var(--portal-track);
}

/* portal: progress ring fill */
.portal-ring-fill {
    stroke: var(--color-accent);
    stroke-linecap: round;
    transition: stroke-dashoffset 1s cubic-bezier(0.22, 1, 0.36, 1);
}

/* portal: single-project hero aura blobs */
.portal-hero-aura {
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.6;
}
.portal-hero-aura::before,
.portal-hero-aura::after {
    content: "";
    position: absolute;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    filter: blur(80px);
}
.portal-hero-aura::before {
    top: -120px;
    right: -80px;
    background: color-mix(in oklab, var(--color-accent) 40%, transparent);
}
.portal-hero-aura::after {
    bottom: -150px;
    right: 200px;
    background: color-mix(in oklab, var(--portal-rose) 30%, transparent);
    opacity: 0.5;
}

/* portal: milestone vertical connector */
.portal-ms-item {
    position: relative;
}
.portal-ms-item::after {
    content: "";
    position: absolute;
    left: 28px;
    top: 32px;
    bottom: -1px;
    width: 2px;
    background: var(--portal-track);
}
.portal-ms-item:last-child::after {
    display: none;
}