/* ============================================
   Upstate Precast — Industrial Monolith
   ============================================ */

:root {
    --bg: #08080a;
    --bg-elevated: #111114;
    --bg-card: #141418;
    --border: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(255, 255, 255, 0.12);

    --text: #ffffff;
    --text-secondary: #8a8a9a;
    --text-muted: #55555f;

    --accent: #c8a04a;
    --accent-dim: rgba(200, 160, 74, 0.12);

    --nav-bg: rgba(255, 255, 255, 0.07);
    --nav-border: rgba(255, 255, 255, 0.04);

    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --mono: 'Space Mono', 'Courier New', monospace;

    --ease: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 clamp(24px, 5vw, 64px);
}


/* ============================================
   Intro Animation
   ============================================ */
.intro-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
}

.intro-overlay.skipped {
    display: none;
}

.intro-loader {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.intro-mask {
    position: relative;
    flex: 1;
    overflow: hidden;
    /* Opaque to the mask's own edge so the seam can't show the hero photo,
       regardless of where the absolutely-positioned inner lands. */
    background: var(--bg);
    will-change: transform;
    transition: transform 1.2s cubic-bezier(0.76, 0, 0.24, 1);
}

/* Overlap the 1px seam by 1px so flex sub-pixel rounding (Retina) can never
   open a transparent hairline at the split line. The notch sits above (z-index)
   so the gold line stays visible. */
.intro-mask-bottom {
    margin-top: -1px;
}

.intro-notch {
    height: 1px;
    width: 100%;
    flex-shrink: 0;
    position: relative;
    z-index: 2;
    overflow: hidden;
    opacity: 1;
    /* Opaque base so the hero photo never shows through the 1px seam
       while the gold line draws across. Only the line should be visible. */
    background: var(--bg);
    transition: opacity 0.5s ease;
}

.intro-notch.fade-out {
    opacity: 0;
}

.intro-notch::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%;
    background: var(--accent);
}

.intro-notch.visible::after {
    animation: drawLine 1.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes drawLine {
    0% { width: 0%; }
    100% { width: 100%; }
}

.intro-mask-inner {
    position: absolute;
    left: 0;
    width: 100%;
    height: 100svh;
    background: var(--bg);
}

/* Top mask: inner sits at bottom so full-height content is aligned */
.intro-mask-top .intro-mask-inner {
    bottom: 0;
}

/* Bottom mask: inner sits at top */
.intro-mask-bottom .intro-mask-inner {
    top: 0;
}

/* Faint blueprint pattern on the masks */
.intro-bg-pattern {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1.5s ease;
    background-image:
        linear-gradient(rgba(200, 160, 74, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(200, 160, 74, 0.06) 1px, transparent 1px);
    background-size: 40px 40px;
}

.intro-bg-pattern.visible {
    opacity: 1;
}

.intro-mask-top.split {
    transform: translateY(-100%);
}

.intro-mask-bottom.split {
    transform: translateY(100%);
}

.intro-logo {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.7);
    z-index: 10000;
    opacity: 0;
    filter: blur(8px);
    transition: opacity 1s ease, transform 1.2s cubic-bezier(0.16, 1, 0.3, 1), filter 1.2s ease;
}

.intro-logo.visible {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    filter: blur(0);
}

.intro-logo.fade-out {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.05);
    filter: blur(4px);
    transition: opacity 0.6s ease, transform 0.6s ease, filter 0.6s ease;
}

.intro-logo img {
    width: 72px;
    height: 72px;
    border-radius: 50%;
}

/* Gold ring pulse around the logo */
.intro-logo::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(1);
    border: 1px solid rgba(200, 160, 74, 0);
    opacity: 0;
    transition: none;
}

.intro-logo.visible::after {
    animation: logoPulse 2s ease-out 0.4s forwards;
}

@keyframes logoPulse {
    0% {
        transform: translate(-50%, -50%) scale(1);
        border-color: rgba(200, 160, 74, 0.6);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(2.2);
        border-color: rgba(200, 160, 74, 0);
        opacity: 0;
    }
}

/* Hide site elements until intro finishes */
body.intro-active .glass-nav,
body.intro-active .hero-bottom-bar,
body.intro-active .assistant-bar-container {
    opacity: 0;
}

body.intro-done .glass-nav,
body.intro-done .hero-bottom-bar,
body.intro-done .assistant-bar-container {
    opacity: 1;
    transition: opacity 0.6s ease;
}


/* ============================================
   Navigation
   ============================================ */
.glass-nav {
    position: fixed;
    top: 2.25rem;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 3rem);
    max-width: 1080px;
    height: 72px;
    background: var(--nav-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--nav-border);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 0.875rem 0 1.25rem;
    z-index: 1000;
    transition: background 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

.glass-nav.scrolled {
    background: rgba(8, 8, 10, 0.85);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: -0.01em;
    flex-shrink: 0;
}

.nav-logo-img {
    width: 26px;
    height: 26px;
    border-radius: 50%;
}

.nav-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text);
    font-size: 0.8125rem;
    font-weight: 500;
    opacity: 0.7;
    transition: opacity 0.3s ease;
    letter-spacing: 0.01em;
}

.nav-links a:hover { opacity: 1; }

.btn-contact {
    background: var(--text);
    color: var(--bg);
    padding: 0.5rem 1.125rem;
    border-radius: 6px;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    transition: all 0.3s ease;
    flex-shrink: 0;
    text-transform: uppercase;
}

.btn-contact:hover {
    background: #e0e0e0;
    transform: translateY(-1px);
}

.nav-phone {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--mono);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    white-space: nowrap;
    transition: color 0.3s ease;
}

.nav-phone-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--accent);
    flex-shrink: 0;
}

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

/* Tight desktop widths: drop the phone before it can crowd the centered links */
@media (max-width: 1180px) {
    .nav-phone { display: none; }
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 1.5px;
    background: var(--text);
    border-radius: 2px;
    transition: all 0.3s var(--ease);
}

.nav-toggle.active span:first-child {
    transform: rotate(45deg) translate(2.5px, 2.5px);
}

.nav-toggle.active span:last-child {
    transform: rotate(-45deg) translate(2.5px, -2.5px);
}

/* Mobile overlay */
.mobile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(8, 8, 10, 0.96);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s var(--ease);
}

.mobile-overlay.open {
    opacity: 1;
    pointer-events: all;
}

/* While the menu is open, every floating element below it gets out of the way */
body.menu-open .hero-bottom-bar,
body.menu-open .assistant-bar-container,
body.menu-open .scroll-prompt {
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity 0.25s ease;
}

.mobile-menu {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.mobile-link {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text);
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.mobile-link:hover { opacity: 1; color: var(--accent); }

.mobile-cta {
    margin-top: 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--bg);
    background: var(--accent);
    padding: 14px 36px;
    border-radius: 6px;
}

.mobile-phone {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--mono);
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
}


/* ============================================
   Hero
   ============================================ */
/* Hero and video both pin to the viewport.
   Hero sits on top (z-index 4) and fades out
   to reveal the video (z-index 3) beneath it.
   A spacer in the document flow gives the user
   something to scroll through during the fade. */
.hero-pin {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 4;
    pointer-events: none;
    will-change: opacity;
}

.hero-pin > * {
    pointer-events: auto;
}

.hero {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
    background: var(--bg);
    background-image: linear-gradient(to bottom, rgba(8,8,10,0.2) 0%, rgba(8,8,10,0.75) 100%), url('assets/images/DSC00001-3.jpg');
    background-size: cover;
    background-position: center;
}

/* Invisible spacer — the scroll distance that drives the crossfade */
.hero-scroll-spacer {
    height: 85vh;
    position: relative;
    z-index: 1;
}

.hero-grain {
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 1;
}

.hero-bottom-bar {
    position: fixed;
    top: calc(50% - 20px);
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 3rem);
    max-width: 700px;
    z-index: 1100;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: repeat(3, auto);
    column-gap: 28px;
    row-gap: 10px;
    align-items: start;
    box-sizing: border-box;
    will-change: opacity;
    background: var(--nav-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--nav-border);
    border-radius: 10px;
    padding: 24px 28px;
}

.hero-cluster,
.hero-metrics {
    will-change: transform, opacity;
}

.hero-cluster {
    grid-column: 1;
    grid-row: 1 / 4;
    display: grid;
    grid-template-rows: subgrid;
    align-content: start;
    min-width: 0;
}

.hero-metrics {
    grid-column: 2;
    grid-row: 1 / 4;
    display: grid;
    grid-template-rows: subgrid;
    justify-items: end;
    align-content: start;
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: start;
    font-family: var(--mono);
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.tag-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
    animation: pulse 2.5s ease-in-out infinite;
}

.hero-bar-line {
    font-size: clamp(0.75rem, 1.2vw, 1.125rem);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.35;
    letter-spacing: 0.01em;
    margin: 0;
    align-self: start;
}


.metric {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    align-self: start;
}

.metric-val {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: inherit;
    text-decoration: none;
}

.metric-val:hover {
    color: var(--accent);
}

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

.metric-divider {
    display: none;
}

.scroll-prompt {
    position: fixed;
    bottom: clamp(30px, 5vh, 50px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 6;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.6s ease;
}

.scroll-prompt.visible {
    opacity: 1;
}

/* Scroll buttons — hero + panels */
.scroll-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(200, 160, 74, 0.4);
    background: rgba(200, 160, 74, 0.08);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: var(--accent);
    cursor: pointer;
    transition: all 0.3s ease;
    animation: bobDown 2.5s ease-in-out infinite;
}

.scroll-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(200, 160, 74, 0.15);
}

.panel-scroll-btn {
    margin: 24px auto 0;
    display: flex;
    pointer-events: auto;
    z-index: 1101;
}

@keyframes bobDown {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(6px); }
}

/* Panel scroll buttons bob animation */
.panel-scroll-btn {
    animation: bobDown 2.5s ease-in-out infinite;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--accent), transparent);
    animation: scrollPulse 2.5s ease-in-out infinite;
}

.scroll-prompt span {
    font-size: 0.625rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--text-secondary);
}


/* ============================================
   Video Scroll Experience
   ============================================ */
.video-experience {
    position: relative;
}

/* Video pins to viewport behind hero */
.video-sticky {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 100%;
    z-index: 3;
    overflow: hidden;
}

.video-wrap {
    position: absolute;
    inset: 0;
}

.video-wrap iframe {
    width: 100vw;
    height: 56.25vw; /* 16:9 */
    min-height: 100vh;
    min-width: 177.78vh; /* 16:9 */
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border: none;
}

/* Scrolling panels that float over the fixed video */
.scroll-panels {
    position: relative;
    z-index: 5;
    pointer-events: none;
}

.panel {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: clamp(24px, 5vw, 80px);
    position: relative;
}

.panel-content {
    pointer-events: auto;
    max-width: 560px;
    background: rgba(8, 8, 10, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: clamp(32px, 4vw, 56px);
}

/* First panel is just a spacer for the video fade-in */
.panel-intro {
    min-height: 80vh;
}

/* Last spacer */
.panel-spacer {
    min-height: 40vh;
}

/* Statement panel — centered */
.panel-statement {
    justify-content: center;
    align-items: center;
}

.panel-statement .panel-content {
    max-width: 700px;
    text-align: center;
    background: rgba(8, 8, 10, 0.65);
}

.statement-text {
    font-size: clamp(1.75rem, 4vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.035em;
    line-height: 1.2;
    color: var(--accent);
}

/* Panel typography */
.panel-eyebrow {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 32px;
}

.panel-headline {
    font-size: clamp(1.75rem, 3.5vw, 2.75rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.035em;
    margin-bottom: 24px;
}

.panel-headline em {
    font-style: normal;
    color: var(--accent);
}

.panel-body {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 16px;
}

.panel-body:last-child {
    margin-bottom: 0;
}

/* Product list inside panel */
.panel-product-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-bottom: 24px;
}

.panel-product {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
}

.panel-product:first-child {
    border-top: 1px solid var(--border);
}

.pp-num {
    font-family: var(--mono);
    font-size: 0.625rem;
    color: var(--text-muted);
    width: 24px;
    flex-shrink: 0;
}

.pp-name {
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

/* Values list inside panel */
.panel-values-list {
    display: flex;
    flex-direction: column;
}

.pv-row {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 18px 0;
    border-bottom: 1px solid var(--border);
}

.pv-row:first-child {
    border-top: 1px solid var(--border);
}

.pv-num {
    font-family: var(--mono);
    font-size: 0.625rem;
    font-weight: 700;
    color: var(--text-muted);
    padding-top: 3px;
    flex-shrink: 0;
    width: 24px;
}

.pv-title {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: 4px;
}

.pv-desc {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.6;
}


/* ============================================
   Shared Section Eyebrow
   ============================================ */
.section-eyebrow,
.panel-eyebrow {
    display: flex;
    align-items: center;
    gap: 16px;
}

.eyebrow-num {
    font-family: var(--mono);
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--accent);
}

.eyebrow-line {
    width: 40px;
    height: 1px;
    background: var(--border-hover);
}

.eyebrow-text {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
}


/* ============================================
   Contact
   ============================================ */
.section {
    padding: clamp(56px, 8vw, 104px) 0;
}

.section-contact {
    position: relative;
    z-index: 5;
    background: var(--bg);
    border-top: 1px solid var(--border);
}

.section-contact .section-eyebrow {
    margin-bottom: 48px;
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
}

.contact-headline {
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-weight: 800;
    letter-spacing: -0.035em;
    margin-bottom: 40px;
}

.contact-blocks {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.c-block {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.c-label {
    font-family: var(--mono);
    font-size: 0.625rem;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.c-block a,
.c-block p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
    transition: color 0.3s ease;
}

.c-block a:hover { color: var(--text); }

/* Form */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-field label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.form-field input,
.form-field textarea {
    font-family: var(--font);
    font-size: 0.9375rem;
    color: var(--text);
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 14px 16px;
    outline: none;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-field input:focus,
.form-field textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-dim);
}

.form-field textarea {
    resize: vertical;
    min-height: 100px;
}

.btn-submit {
    font-family: var(--font);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--bg);
    background: var(--text);
    border: none;
    border-radius: 6px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0.01em;
}

.btn-submit:hover {
    background: #e0e0e0;
    transform: translateY(-1px);
}


/* ============================================
   Footer
   ============================================ */
.site-footer {
    position: relative;
    z-index: 5;
    background: var(--bg-elevated);
    border-top: 1px solid var(--border);
    /* Extra bottom space so the persistent message bar floats over empty
       space at the end of the page, not over the footer's bottom row. */
    padding: 64px 0 120px;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    gap: 40px;
    margin-bottom: 56px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 240px;
}

.footer-logo-img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
}

.footer-tagline {
    font-size: 0.8125rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.footer-cols {
    display: flex;
    gap: clamp(32px, 5vw, 64px);
}

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-col h4 {
    font-size: 0.625rem;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.footer-col a,
.footer-col span {
    font-size: 0.8125rem;
    color: var(--text-muted);
    transition: color 0.3s ease;
}

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

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.footer-bottom span {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.footer-bottom a {
    color: var(--text-muted);
    transition: color 0.3s ease;
}

.footer-bottom a:hover { color: var(--accent); }

.footer-bottom svg { display: block; }

/* --- Footer easter egg + Riser Stacker --- */
.footer-egg {
    background: none;
    border: none;
    padding: 0;
    font-family: var(--mono);
    font-size: 0.68rem;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.3s ease;
}

.footer-egg:hover { color: var(--accent); }

.crane-overlay {
    position: fixed;
    inset: 0;
    z-index: 6000;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.45s ease, visibility 0s linear 0.45s;
}

.crane-overlay.is-open {
    visibility: visible;
    opacity: 1;
    transition: opacity 0.45s ease;
}

.crane-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 18px clamp(24px, 5vw, 64px);
    border-bottom: 1px solid var(--border);
}

.crane-kicker {
    font-family: var(--mono);
    font-size: 0.75rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-secondary);
}

.crane-kicker span {
    color: var(--accent);
    margin-right: 10px;
}

.crane-close,
.crane-reset {
    background: none;
    border: 1px solid var(--border-hover);
    color: var(--text-secondary);
    font-family: var(--mono);
    font-size: 0.68rem;
    letter-spacing: 0.18em;
    padding: 10px 18px;
    cursor: pointer;
    transition: color 0.25s ease, border-color 0.25s ease;
}

.crane-close:hover,
.crane-reset:hover {
    color: var(--accent);
    border-color: var(--accent);
}

.crane-stage {
    position: relative;
    flex: 1;
    background: var(--bg-elevated);
    overflow: hidden;
    touch-action: none;
    cursor: pointer;
}

.crane-stage canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
}

.crane-hint {
    position: absolute;
    top: 70%;
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--mono);
    font-size: 0.72rem;
    letter-spacing: 0.26em;
    text-align: center;
    color: var(--text-muted);
    pointer-events: none;
    transition: opacity 0.5s ease;
    white-space: nowrap;
}

.crane-hint.is-hidden { opacity: 0; }

.crane-hud {
    position: absolute;
    top: 18px;
    right: 22px;
    font-family: var(--mono);
    font-size: 0.72rem;
    letter-spacing: 0.18em;
    color: var(--accent);
    pointer-events: none;
}

.crane-reset {
    position: absolute;
    bottom: 16px;
    right: 22px;
    font-size: 0.64rem;
    padding: 9px 16px;
}

@media (max-width: 640px) {
    .crane-hint { font-size: 0.6rem; letter-spacing: 0.18em; }
}


/* ============================================
   Assistant Bar
   ============================================ */
.assistant-bar-container {
    position: fixed;
    bottom: 2.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 3rem);
    max-width: 700px;
    z-index: 1100;
    transition: opacity 0.4s ease;
}

/* Content pages: the bar tucks away on scroll-down and returns on scroll-up
   (driven by main.js) so it never sits behind page text. The homepage bar is
   JS-positioned every frame, so it's excluded from the transform transition. */
body:not(.has-hero) .assistant-bar-container {
    transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

body:not(.has-hero) .assistant-bar-container.tucked {
    transform: translate(-50%, calc(100% + 3rem));
    opacity: 0;
    pointer-events: none;
}

/* Homepage: chat bar starts below hero text, JS drives the scroll animation.
   It moves via transform (translateY) only — top stays put — so promote
   just transform for a composited, reflow-free dock. */
body.has-hero .assistant-bar-container {
    bottom: auto;
    top: calc(50% + 180px);
    transform: translateX(-50%);
    will-change: transform;
}

.assistant-bar-container.hidden {
    opacity: 0;
    pointer-events: none;
}

.assistant-bar {
    background: #ffffff;
    border-radius: 10px;
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 14px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.chat-input {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.chat-icon {
    display: flex;
    flex-shrink: 0;
}

.chat-input input {
    border: none;
    outline: none;
    width: 100%;
    font-family: var(--font);
    font-size: 0.8125rem;
    color: #333;
    background: transparent;
    cursor: pointer;
}

.chat-input input::placeholder {
    color: #999;
}

.chat-controls {
    display: flex;
    gap: 4px;
}

.icon-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 4px;
    transition: background 0.2s ease;
    display: flex;
    align-items: center;
    color: #888;
}

.icon-btn:hover {
    background: #f0f0f0;
    color: #333;
}

/* Pill is a button to open the composer */
.chat-input[role="button"] { cursor: pointer; }

/* When the composer is open, anchor the pill visually to the panel above it */
.assistant-bar-container.open .assistant-bar {
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(200, 160, 74, 0.5);
}


/* ============================================
   Message Composer (expands from the pill)
   ============================================ */
.assistant-panel {
    position: absolute;
    left: 0;
    right: 0;
    bottom: calc(100% + 12px);
    background: #ffffff;
    border-radius: 14px;
    padding: 18px;
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
    gap: 12px;
    transform-origin: bottom center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px) scale(0.985);
    transition: opacity 0.32s var(--ease), transform 0.32s var(--ease), visibility 0.32s;
    pointer-events: none;
}

.assistant-bar-container.open .assistant-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.assistant-panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.ap-title {
    font-size: 0.9375rem;
    font-weight: 700;
    color: #16161a;
    letter-spacing: -0.01em;
}

.ap-sub {
    font-size: 0.75rem;
    color: #8a8a93;
    margin-top: 2px;
}

.ap-close {
    background: transparent;
    border: none;
    cursor: pointer;
    color: #b0b0b8;
    padding: 4px;
    margin: -4px -4px 0 0;
    border-radius: 6px;
    display: flex;
    transition: background 0.2s ease, color 0.2s ease;
}

.ap-close:hover { background: #f0f0f2; color: #333; }

.ap-fields { display: flex; flex-direction: column; gap: 10px; }

.ap-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.ap-input {
    font-family: var(--font);
    font-size: 0.875rem;
    color: #16161a;
    background: #f4f4f6;
    border: 1px solid #e4e4ea;
    border-radius: 8px;
    padding: 11px 13px;
    width: 100%;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.ap-input::placeholder { color: #a0a0a8; }

.ap-input:focus {
    border-color: var(--accent);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(200, 160, 74, 0.18);
}

.ap-textarea {
    min-height: 92px;
    resize: vertical;
    line-height: 1.5;
}

.ap-send {
    font-family: var(--font);
    font-size: 0.875rem;
    font-weight: 600;
    color: #1a1408;
    background: var(--accent);
    border: none;
    border-radius: 8px;
    padding: 12px 16px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.25s ease, transform 0.2s ease, opacity 0.2s ease;
}

.ap-send:hover { background: #d4ad55; transform: translateY(-1px); }
.ap-send:disabled { opacity: 0.7; cursor: default; transform: none; }

.ap-send-icon { transition: transform 0.25s var(--ease); }
.ap-send:hover:not(:disabled) .ap-send-icon { transform: translate(2px, -2px); }

.ap-status {
    font-size: 0.8125rem;
    font-weight: 500;
    text-align: center;
    min-height: 0;
    margin: -2px 0;
    transition: min-height 0.2s ease;
}

.ap-status.show { min-height: 1.1rem; }
.ap-status.success { color: #1a8f4a; }
.ap-status.error { color: #d23f3f; }

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


/* ============================================
   Animations
   ============================================ */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

@keyframes scrollPulse {
    0%, 100% { opacity: 1; transform: scaleY(1); }
    50% { opacity: 0.4; transform: scaleY(0.7); }
}

/* ============================================
   Apple-style Scroll Reveals
   Elements fade up with staggered timing.
   Each child within a [data-reveal] container
   animates in sequence via --stagger-index.
   ============================================ */
[data-reveal] {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 1s var(--ease), transform 1s var(--ease);
}

[data-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered children inside panels */
[data-stagger] > * {
    opacity: 0;
    transform: translateY(24px);
    transition:
        opacity 0.9s var(--ease),
        transform 0.9s var(--ease);
}

[data-stagger].revealed > * {
    opacity: 1;
    transform: translateY(0);
}

/* Generate stagger delays — each child waits longer */
[data-stagger].revealed > *:nth-child(1) { transition-delay: 0.05s; }
[data-stagger].revealed > *:nth-child(2) { transition-delay: 0.15s; }
[data-stagger].revealed > *:nth-child(3) { transition-delay: 0.25s; }
[data-stagger].revealed > *:nth-child(4) { transition-delay: 0.35s; }
[data-stagger].revealed > *:nth-child(5) { transition-delay: 0.45s; }
[data-stagger].revealed > *:nth-child(6) { transition-delay: 0.55s; }
[data-stagger].revealed > *:nth-child(7) { transition-delay: 0.65s; }
[data-stagger].revealed > *:nth-child(8) { transition-delay: 0.75s; }

/* Stagger rows inside lists (products, values) */
[data-stagger-rows] .panel-product,
[data-stagger-rows] .pv-row {
    opacity: 0;
    transform: translateY(16px);
    transition:
        opacity 0.7s var(--ease),
        transform 0.7s var(--ease);
}

[data-stagger-rows].revealed .panel-product,
[data-stagger-rows].revealed .pv-row {
    opacity: 1;
    transform: translateY(0);
}

[data-stagger-rows].revealed .panel-product:nth-child(1),
[data-stagger-rows].revealed .pv-row:nth-child(1) { transition-delay: 0.1s; }
[data-stagger-rows].revealed .panel-product:nth-child(2),
[data-stagger-rows].revealed .pv-row:nth-child(2) { transition-delay: 0.18s; }
[data-stagger-rows].revealed .panel-product:nth-child(3),
[data-stagger-rows].revealed .pv-row:nth-child(3) { transition-delay: 0.26s; }
[data-stagger-rows].revealed .panel-product:nth-child(4),
[data-stagger-rows].revealed .pv-row:nth-child(4) { transition-delay: 0.34s; }
[data-stagger-rows].revealed .panel-product:nth-child(5),
[data-stagger-rows].revealed .pv-row:nth-child(5) { transition-delay: 0.42s; }
[data-stagger-rows].revealed .panel-product:nth-child(6),
[data-stagger-rows].revealed .pv-row:nth-child(6) { transition-delay: 0.50s; }

/* Statement panel — slow dramatic fade */
.panel-statement [data-reveal] {
    transition: opacity 1.4s var(--ease-smooth), transform 1.4s var(--ease-smooth);
}

/* Contact section stagger */
.section-contact [data-stagger] > * {
    opacity: 0;
    transform: translateY(20px);
    transition:
        opacity 0.8s var(--ease),
        transform 0.8s var(--ease);
}

.section-contact [data-stagger].revealed > * {
    opacity: 1;
    transform: translateY(0);
}

.section-contact [data-stagger].revealed > *:nth-child(1) { transition-delay: 0.05s; }
.section-contact [data-stagger].revealed > *:nth-child(2) { transition-delay: 0.12s; }
.section-contact [data-stagger].revealed > *:nth-child(3) { transition-delay: 0.19s; }
.section-contact [data-stagger].revealed > *:nth-child(4) { transition-delay: 0.26s; }
.section-contact [data-stagger].revealed > *:nth-child(5) { transition-delay: 0.33s; }

/* Footer columns fade in */
.footer-top [data-reveal] {
    transition: opacity 1s var(--ease), transform 1s var(--ease);
}


/* ============================================
   Touch devices — native section magnet
   The JS glide is desktop-only (you can't cancel
   native touch momentum without fighting the
   finger). On touch, CSS scroll-snap gives the
   same settle-into-section feel, driven by the
   browser's own scroll physics. `proximity` keeps
   long flicks and the footer free-scrolling.
   ============================================ */
@media (hover: none), (pointer: coarse) {
    html:has(body.has-hero) {
        scroll-snap-type: y proximity;
    }

    body.has-hero .hero-scroll-spacer {
        scroll-snap-align: start;
    }

    body.has-hero .panel:not(.panel-spacer):not(.panel-intro) {
        scroll-snap-align: center;
    }

    body.has-hero .section-contact {
        scroll-snap-align: start;
    }
}


/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1024px) {
    .glass-nav {
        width: calc(100% - 2rem);
        top: 1rem;
    }

    .nav-center { display: none; }
    .btn-contact { display: none; }
    .nav-toggle { display: flex; }

    .hero-bottom-bar {
        column-gap: 16px;
        row-gap: 8px;
        top: calc(50% - 40px);
    }

    .hero-bar-line {
        font-size: 1rem;
    }

    .metric-val {
        font-size: 1.125rem;
    }

    .metric-label {
        font-size: 0.625rem;
    }

    .metric-divider {
        height: 24px;
    }

    /* Chat bar — JS handles positioning on homepage */

    .contact-layout {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .footer-top { flex-direction: column; }
}

@media (max-width: 640px) {
    /* Hero card: two columns can't fit — stack into a single clean column */
    .hero-bottom-bar {
        grid-template-columns: 1fr;
        grid-template-rows: none;
        row-gap: 10px;
        top: 45%;
        transform: translate(-50%, -50%);
        width: calc(100% - 2rem);
        padding: 20px;
    }

    .hero-cluster,
    .hero-metrics {
        grid-column: 1;
        grid-row: auto;
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .hero-tag {
        white-space: nowrap;
    }

    .hero-bar-line {
        font-size: 1.0625rem;
        line-height: 1.4;
        white-space: nowrap;
    }

    .hero-metrics {
        border-top: 1px solid var(--border);
        padding-top: 14px;
        margin-top: 4px;
    }

    .metric {
        width: 100%;
        justify-content: space-between;
    }

    .metric-val {
        font-size: 0.9375rem;
    }

    .metric-label {
        font-size: 0.625rem;
        text-align: right;
    }

    .panel-content {
        padding: 28px 24px;
    }

    .footer-cols {
        flex-direction: column;
        gap: 28px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

    /* Extra bottom padding so chat bar doesn't cover content */
    .site-footer {
        padding-bottom: 100px;
    }

    .hero {
        background-position: center;
    }

    .panel-content {
        padding: 24px 20px;
    }

    .panel-headline {
        font-size: 1.5rem;
        margin-bottom: 16px;
    }

    .panel-eyebrow {
        margin-bottom: 20px;
    }

    .pv-row {
        padding: 12px 0;
    }

    .panel-product {
        padding: 10px 0;
    }

    .panel-scroll-btn {
        margin-top: 16px;
    }

    .panel {
        padding-bottom: 100px;
    }
}
