@import url('https://fonts.googleapis.com/css2?family=Instrument+Serif:ital@0;1&family=Inter:wght@300;400;500&family=JetBrains+Mono:wght@300;400&display=swap');

/* --- ROOT & BASE --- */
:root { 
    --bg: #F4F0EA; 
    --text: #1C1A17; 
    --accent: #B0A18E; 
}

body {
    background-color: var(--bg);
    font-family: 'Inter', sans-serif;
    color: var(--text);
    margin: 0;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

body.loading-locked { 
    overflow: hidden; 
    height: 100vh; 
}

.serif { font-family: 'Instrument Serif', serif; }
.mono { font-family: 'JetBrains+Mono', monospace; }
::-webkit-scrollbar { display: none; }
* { outline: none; }

/* --- PREMIUM TEXTURES --- */
.ambient-glow {
    position: fixed; inset: 0;
    background: radial-gradient(circle at center, rgba(0,0,0,0.015) 0%, rgba(244,244,242,0) 100%);
    pointer-events: none; z-index: 1;
}
.noise {
    position: fixed; inset: 0;
    background: url('https://grainy-gradients.vercel.app/noise.svg');
    opacity: 0.04; pointer-events: none; z-index: 9999;
}

/* --- HERO SECTION --- */
.hero-heading {
    font-size: clamp(4.5rem, 16vw, 18vw);
    line-height: 0.8;
    letter-spacing: -0.04em;
    font-weight: 400;
    color: var(--text);
    margin: 0;
}

#video-monolith {
    width: clamp(280px, 80vw, 750px);
    aspect-ratio: 4 / 5; 
    will-change: width, height, border-radius;
    border-radius: 6px;
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(28, 26, 23, 0.05);
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
}

@media (min-width: 768px) {
    #video-monolith {
        aspect-ratio: 16 / 9; 
        width: clamp(600px, 60vw, 900px);
    }
}

@keyframes scrollLine {
    0% { top: -100%; }
    50% { top: 0%; }
    100% { top: 100%; }
}

/* --- SYSTEM MENU --- */
#system-menu {
    clip-path: circle(0% at top right);
    transition: clip-path 0.8s cubic-bezier(0.85, 0, 0.15, 1);
    /* Add these two lines */
    will-change: clip-path; 
    backface-visibility: hidden;
}

#system-menu nav a {
    /* Prevents the large text from creating sub-pixel artifacts */
    transform: translateZ(0);
}
#system-menu.active {
    clip-path: circle(150% at top right);
    visibility: visible;
}

/* --- HOVER EFFECTS --- */
.fade-line { position: relative; display: inline-block; }
.fade-line::after {
    content: ''; position: absolute; bottom: -4px; left: 0; width: 0%; height: 1px; background: currentColor; transition: width 0.4s ease;
}
.fade-line:hover::after { width: 100%; }

/* --- TICKER TRACK --- */
.ticker-track { display: flex; white-space: nowrap; animation: ticker 25s linear infinite; }
@keyframes ticker { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* --- EXPERTISE CARDS --- */
.expertise-card {
    transition: background-color 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s ease;
}
.title-underline::after {
    content: ''; position: absolute; bottom: -4px; left: 0; width: 0%; height: 2px;
    background-color: #1C1A17; transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.group:hover .title-underline::after { width: 100%; }

.tags-wrapper { transition: opacity 0.4s ease, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.group:hover .tags-wrapper { opacity: 0; transform: translateY(20px); pointer-events: none; }

.desc-wrapper {
    opacity: 0; transform: translateY(20px);
    transition: opacity 0.5s ease 0.1s, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.1s;
    pointer-events: none;
}
.group:hover .desc-wrapper { opacity: 1; transform: translateY(0); pointer-events: auto; }

.arrow-icon { transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.4s ease, color 0.4s ease; }
.group:hover .arrow-icon { transform: rotate(45deg); }

/* --- TECHNOLOGIES SECTION --- */
.tech-row { position: relative; overflow: hidden; }
.tech-row::after {
    content: ''; position: absolute; bottom: 0; left: 4.5rem; width: 0%; height: 1px;
    background-color: #F4F0EA; opacity: 0.1; z-index: 5;
    transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.4s ease, opacity 0.4s ease;
}
@media (max-width: 768px) { .tech-row::after { left: 2.5rem; } }
.tech-row:hover::after { width: calc(100% - 10rem); opacity: 0.8; background-color: #B0A18E; }
.tech-row:hover .tech-name { color: #F4F0EA; font-style: italic; transform: translateX(1rem); }
.tech-name { display: inline-block; transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), color 0.4s ease; }

.tech-energy {
    position: absolute; top: 50%; left: -10%; width: 60vh; height: 60vh;
    border-radius: 50%; background: radial-gradient(circle, rgba(176,161,142,0.08) 0%, rgba(28,26,23,0) 70%);
    filter: blur(60px); pointer-events: none; transform: translateY(-50%);
}

/* --- DRAFTING WORDS --- */
.drafting-word {
    display: block; font-family: 'Inter', system-ui, sans-serif; 
    letter-spacing: -0.04em; line-height: 0.8; color: #1C1A17; font-weight: 500; padding-bottom: 0.05em; 
}
.word-mask { display: block; overflow: hidden; }
.word-reveal { display: block; transform: translateY(115%); will-change: transform; }
.draft-line-solid {
    background-color: rgba(28, 26, 23, 0.2); transform-origin: left; transform: scaleX(0); will-change: transform;
}
.draft-badge { background-color: #F4F0EA; opacity: 0; transform: translateY(10px); will-change: opacity, transform; }

/* --- LIGHT STACK CARDS --- */
.light-stack-card {
    position: sticky; top: 15vh; will-change: transform, opacity;
    box-shadow: 0 -20px 40px rgba(28, 26, 23, 0.05); transform-origin: top center;
}
.light-bracket { position: absolute; width: 1.5rem; height: 1.5rem; border-color: rgba(28, 26, 23, 0.1); }
.lb-tl { top: 1.5rem; left: 1.5rem; border-top-width: 1px; border-left-width: 1px; }
.lb-tr { top: 1.5rem; right: 1.5rem; border-top-width: 1px; border-right-width: 1px; }
.lb-bl { bottom: 1.5rem; left: 1.5rem; border-bottom-width: 1px; border-left-width: 1px; }
.lb-br { bottom: 1.5rem; right: 1.5rem; border-bottom-width: 1px; border-right-width: 1px; }

/* --- FAQ & TILT CARDS --- */
#faq-container.has-active .faq-item:not(.is-active) { opacity: 0.3; filter: blur(2px); }
.faq-item {
    border-bottom: 1px solid rgba(28, 26, 23, 0.1); will-change: opacity, filter;
    transition: border-color 0.4s ease, opacity 0.6s ease, filter 0.6s ease;
}
.faq-item:hover { border-color: rgba(28, 26, 23, 0.4); }
.faq-question { transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), color 0.4s ease; }
.faq-item:hover .faq-question { transform: translateX(1.5rem); color: #B0A18E; font-style: italic; }
.faq-icon { transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.4s ease; }
.faq-item.is-active .faq-icon { transform: rotate(135deg); background-color: #1C1A17; color: #F4F0EA; }
.faq-item.is-active .faq-question { color: #1C1A17; font-style: italic; transform: translateX(1.5rem); }

.perspective-wrapper { perspective: 1000px; }
.tilt-card { transform-style: preserve-3d; will-change: transform; }
.mouse-glow {
    position: absolute; width: 400px; height: 400px; border-radius: 50%;
    background: radial-gradient(circle, rgba(176,161,142,0.15) 0%, rgba(28,26,23,0) 70%);
    pointer-events: none; transform: translate(-50%, -50%); opacity: 0; transition: opacity 0.5s ease; z-index: 0;
}
.tilt-card:hover .mouse-glow { opacity: 1; }

/* --- FOOTER & MACRO TYPOGRAPHY --- */
.marquee-track { display: flex; width: max-content; will-change: transform; }
.scroll-left { animation: scrollLeft 25s linear infinite; }
.scroll-right { animation: scrollRight 25s linear infinite; }
@keyframes scrollLeft { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
@keyframes scrollRight { 0% { transform: translateX(-50%); } 100% { transform: translateX(0); } }

.text-outline { color: transparent; -webkit-text-stroke: 1px rgba(244, 240, 234, 0.4); }

.wire-link {
    position: relative; color: rgba(244, 240, 234, 0.6); display: inline-flex; align-items: center;
    transition: color 0.3s ease, padding-left 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.wire-link::before {
    content: '→'; position: absolute; left: -15px; opacity: 0; color: #B0A18E;
    transition: opacity 0.3s ease, left 0.3s ease;
}
.wire-link:hover { color: #F4F0EA; padding-left: 15px; }
.wire-link:hover::before { opacity: 1; left: 0; }

.giant-magnetic-wrap { position: relative; width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.giant-circle {
    width: 14rem; height: 14rem; border-radius: 50%; background-color: #B0A18E; color: #1C1A17;
    display: flex; align-items: center; justify-content: center; cursor: pointer; will-change: transform;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), scale 0.4s ease;
}
.giant-circle:hover { transform: scale(1.05); background-color: #F4F0EA; }

.bg-massive {
    font-family: 'Inter', system-ui, sans-serif; font-weight: 700; letter-spacing: -0.06em;
    line-height: 0.75; color: rgba(244, 240, 234, 0.02); user-select: none; pointer-events: none;
}

/* --- DIGITAL PRELOADER --- */
.digital-grid {
    position: absolute; inset: -50%; width: 200%; height: 200%; z-index: 0; pointer-events: none;
    background-image: linear-gradient(rgba(244, 240, 234, 0.03) 1px, transparent 1px), linear-gradient(90deg, rgba(244, 240, 234, 0.03) 1px, transparent 1px);
    background-size: 40px 40px; animation: panGrid 20s linear infinite;
}
@keyframes panGrid { 0% { transform: translateY(0); } 100% { transform: translateY(-40px); } }

.scanlines {
    position: absolute; inset: 0; z-index: 50; pointer-events: none; opacity: 0.3;
    background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,0) 50%, rgba(0,0,0,0.1) 50%, rgba(0,0,0,0.1));
    background-size: 100% 4px;
}

.digital-logo {
    color: #F4F0EA; font-family: 'Inter', system-ui, sans-serif; font-weight: 600;
    letter-spacing: 0.05em; line-height: 1; text-transform: uppercase;
}

#fuzen-digital-preloader { will-change: transform, opacity; }

.segmented-bar { display: flex; gap: 4px; height: 12px; }
.segment { width: 8px; height: 100%; background-color: rgba(244, 240, 234, 0.1); transition: background-color 0.1s ease; }
.segment.filled { background-color: #B0A18E; box-shadow: 0 0 10px rgba(176, 161, 142, 0.4); }


/* about page 
 */
 /* --- EDITORIAL REFINEMENT --- */

.hero-title {
    font-size: clamp(3.5rem, 15vw, 10rem);
}

.entrance-fade {
    opacity: 0;
    transform: translateY(30px);
}

#light-portal {
    will-change: width, height, border-radius, transform;
}

#scrub-text span {
    display: inline-block;
    white-space: pre-wrap;
    transition: color 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.discipline-card {
    cursor: pointer;
}

@media (max-width: 1023px) {
    #hero-studio { padding-top: 120px; }
    #scrub-text { font-size: 2rem; line-height: 1.3; }
    .discipline-card { border: none; }
}
/* --- THE KINETIC ARCHIVE REFINEMENT --- */

#values-scroll-container {
    background-color: #FFFFFF;
}

.image-mask {
    will-change: transform, clip-path;
}

.shutter-img {
    will-change: transform;
    /* Soft ink-like contrast */
    filter: grayscale(1) contrast(1.1) brightness(1.05);
}

.text-reveal {
    will-change: transform, opacity;
}

/* Custom Horizontal Scroll Indicator */
.scroll-progress {
    width: 0%;
    mix-blend-mode: difference;
}

@media (max-width: 1023px) {
    #values-shutter {
        padding-top: 100px;
    }
    .mission-slide, .vision-slide {
        margin-bottom: 5rem;
    }
}
/* --- COFFEE STUDIO QUOTE REFINEMENT --- */

#director-quote {
    /* Deep Coffee Background */
    background-color: #12100E;
}

.serif {
    font-family: 'Playfair Display', serif;
}

.mono {
    font-family: 'Space Mono', monospace;
}

#director-quote h2 {
    /* Ensuring font rendering is ultra-crisp */
    -webkit-font-smoothing: antialiased;
    text-shadow: 0 10px 40px rgba(0,0,0,0.8);
}

/* Mouse proximity spotlight for subtle interaction */
#director-quote .spotlight {
    position: absolute;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(176, 161, 142, 0.03) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
    transform: translate(-50%, -50%);
}

@media (max-width: 768px) {
    #director-quote {
        padding-top: 100px;
        padding-bottom: 80px;
    }
}

/* capabilities page 
 */
 /* --- LIGHT ORBITAL HERO REFINEMENT --- */

#cap-hero-light {
    background-color: #FBFBFB;
}

/* --- ADAPTIVE TYPOGRAPHY REFINEMENT --- */

.hero-title {
    /* Scales perfectly:
       Minimum size: 3rem (Mobile)
       Scaling factor: 11vw (Tablet/Laptop)
       Maximum size: 12rem (Large Desktop)
    */
    font-size: clamp(3rem, 11vw, 12rem);
    /* Slightly looser line height so the tops of tall letters don't clip */
    line-height: 0.9; 
    text-align: center;
}

.title-line {
    /* Prevents the individual words from breaking, but allows the container to adapt */
    white-space: nowrap;
    will-change: transform;
}

/* Smooth SVG Rotation */
.animate-spin-slow {
    animation: spin 80s linear infinite; /* Slowed down for luxury feel */
    transform-origin: center;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.animate-fade-in-delayed {
    animation: fadeIn 2s ease 1.5s forwards;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Mobile Adjustments for Perfect Centering */
@media (max-width: 768px) {
    #cap-hero-light {
        /* Pushes content slightly up to account for mobile browser UI */
        padding-bottom: 10vh; 
    }
}
/* --- KINETIC FLEX ACCORDION REFINEMENT --- */

#capabilities-accordion {
    /* Guarantees the section takes exactly one screen height, preventing weird scrolling */
    min-height: 600px; 
}

.accordion-panel {
    /* The Awwwards "Liquid" Easing */
    transition: flex 1s cubic-bezier(0.19, 1, 0.22, 1);
}

.accordion-panel:hover {
    /* When hovered, this panel takes up 3.5x more space than the others */
    flex: 3.5;
}

/* Ensure typography remains razor sharp during the flex transitions */
.accordion-panel h2, 
.accordion-panel p, 
.accordion-panel span {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Height expansion for the hidden content */
.accordion-panel:hover .accordion-content {
    /* 200px provides plenty of room for the paragraph and tags to fade in */
    height: 160px; 
}

/* --- MOBILE SPECIFIC FIXES --- */
@media (max-width: 1023px) {
    /* On mobile, it expands vertically instead of horizontally */
    .accordion-panel:hover .accordion-content {
        height: 180px; 
    }
    
    /* Make the text slightly smaller so it doesn't break boundaries on tiny phones */
    .accordion-panel h2 {
        white-space: normal; /* Allows text to wrap on phones */
    }
}
/* --- SPLIT-PILLAR PROTOCOL REFINEMENT --- */

#process-split {
    background-color: #FBFBFB;
}

.protocol-row {
    position: relative;
    z-index: 1;
}

.protocol-row:hover {
    z-index: 10;
}

/* Premium Light Theme Shadow for the expanding images */
.shadow-premium {
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.08);
}

/* Ensure typography remains razor sharp */
.protocol-row h3, 
.protocol-row p, 
.protocol-row span {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

@media (max-width: 1023px) {
    /* On mobile, un-stick the heading so it scrolls naturally */
    #process-split .lg\:sticky {
        position: relative;
        top: auto;
    }
}
/* --- ECOSYSTEM MAP REFINEMENT --- */

#ecosystem-map {
    background-color: #FBFBFB;
}

.shadow-premium {
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.05);
}

.integration-node {
    will-change: transform, opacity;
}

/* Ensure typography remains razor sharp */
#ecosystem-map h2, 
#ecosystem-map h3, 
#ecosystem-map p {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

@media (max-width: 1023px) {
    /* Un-stick the left column on mobile */
    #ecosystem-map .lg\:sticky {
        position: relative;
        top: auto;
    }
}

/* contact page 
 */
 /* --- AWWWARDS CONTACT TERMINAL REFINEMENT --- */

.outline-text {
    -webkit-text-stroke: 1px rgba(26, 26, 23, 0.2);
    color: transparent !important;
}

.perspective-container {
    perspective: 2000px;
}

.terminal-card-3d {
    transform-style: preserve-3d;
    transition: transform 0.2s ease-out;
}

/* Layered Shadow for Light-Theme Depth */
.shadow-premium {
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.05), inset 0 0 0 1px rgba(255, 255, 255, 1);
}

/* Custom Cursor Hide */
#contact-terminal:hover #terminal-cursor {
    opacity: 1;
}

/* Marquee Logic */
.marquee-text {
    -webkit-text-stroke: 1px rgba(26, 26, 23, 0.1);
    color: transparent;
    will-change: transform;
}

@media (max-width: 1023px) {
    #contact-terminal { height: auto; cursor: auto; }
    #terminal-cursor { display: none; }
    .terminal-card-3d { 
        width: 100% !important; 
        transform: none !important; 
        border-radius: 3rem; 
        min-height: 380px;
    }

}
/* --- THE KINETIC MONOLITH REFINEMENT --- */

.outline-text {
    -webkit-text-stroke: 1px rgba(176, 161, 142, 0.2);
    color: transparent !important;
}

.u-input {
    @apply serif text-4xl md:text-6xl bg-transparent border-none outline-none w-full text-white transition-all duration-700 pb-4;
}

.u-input::placeholder { color: rgba(255, 255, 255, 0.03); }

.u-line {
    @apply absolute bottom-0 left-0 w-full h-[1px] bg-white/5 transition-all duration-1000;
}

.group:focus-within .u-line {
    @apply h-[2px] bg-[#B0A18E];
}

/* Sharp Rendering for Typography */
#contact-ultra h1, #contact-ultra input, #contact-ultra textarea {
    -webkit-font-smoothing: antialiased;
    letter-spacing: -0.04em;
}

/* Cursor Logic */
#contact-ultra:hover #u-cursor { opacity: 1; }

@media (max-width: 1023px) {
    #contact-ultra { height: auto; }
}