/* =========================================================================
   InfoLyt Premium Startup Theme
   Provides sleek Dark and crisp Light modes using seamless CSS Variables.
   ========================================================================= */

:root {
    /* --- Light Mode Palette --- */
    --clr-bg-main: #FFFFFF;
    --clr-bg-surface: #F8FAFC;
    --clr-bg-surface-elevated: #F1F5F9;
    
    --clr-text-main: #0F172A;
    --clr-text-muted: #64748B;
    
    --clr-border: #E2E8F0;
    --clr-border-hover: #CBD5E1;
    
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.05), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.05), 0 4px 6px -4px rgba(0,0,0,0.05);
    
    /* Logo Brand Colors - Tuned for Light Mode */
    --clr-primary: #1E88E5;     
    --clr-primary-hover: #1565C0;
    --clr-primary-bg: rgba(30, 136, 229, 0.1);
    
    --clr-teal: #4DB6AC;
    --clr-green: #8BC34A;
    --clr-yellow: #FBC02D;
    --clr-red: #D32F2F;

    --gradient-brand: linear-gradient(135deg, #1E88E5, #4DB6AC);
    --glow-opacity: 0.15;
}

[data-theme="dark"] {
    /* --- Dark Mode Palette --- */
    --clr-bg-main: #0A0A0A;      /* True black-ish for that sleek startup feel */
    --clr-bg-surface: #121212;   
    --clr-bg-surface-elevated: #1A1A1A;
    
    --clr-text-main: #EDEDED;
    --clr-text-muted: #A1A1AA;
    
    --clr-border: #27272A;
    --clr-border-hover: #3F3F46;
    
    --shadow-sm: 0 0px 0px 1px rgba(255,255,255,0.05);
    --shadow-md: 0 0px 0px 1px rgba(255,255,255,0.05), 0 8px 16px rgba(0,0,0,0.5);
    --shadow-lg: 0 0px 0px 1px rgba(255,255,255,0.05), 0 16px 32px rgba(0,0,0,0.8);

    /* Logo Brand Colors - Tuned for Dark Mode */
    --clr-primary: #3B82F6;     /* Slightly brighter for dark mode */
    --clr-primary-hover: #60A5FA;
    --clr-primary-bg: rgba(59, 130, 246, 0.15);
    
    --clr-teal: #2DD4BF;
    --clr-green: #A3E635;
    --clr-yellow: #FACC15;
    --clr-red: #F87171;

    --gradient-brand: linear-gradient(135deg, #3B82F6, #2DD4BF);
    --glow-opacity: 0.08;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--clr-bg-main);
    color: var(--clr-text-main);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Typography Utility */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

p {
    letter-spacing: -0.01em;
}

.text-gradient {
    background: var(--gradient-brand);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

code, .code-font {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* Glow Background System */
.glow-system {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    overflow: hidden;
    z-index: -1;
    pointer-events: none;
}
.glow-orb {
    position: absolute;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: var(--glow-opacity);
    transition: opacity 0.5s ease;
}
.glow-orb.primary {
    top: -200px;
    right: -100px;
    background: var(--clr-primary);
}
.glow-orb.secondary {
    top: 300px;
    left: -200px;
    background: var(--clr-teal);
    width: 500px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.6rem 1.25rem;
    border-radius: 8px; /* Slightly sharper corners for modern look */
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid transparent;
}

.btn-large {
    padding: 0.8rem 1.75rem;
    font-size: 1.05rem;
}

.btn-primary {
    background: var(--clr-text-main);
    color: var(--clr-bg-main);
}
.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
    opacity: 0.9;
}
[data-theme="dark"] .btn-primary {
    background: var(--clr-text-main);
    color: var(--clr-bg-main);
}

.btn-secondary {
    background: var(--clr-bg-surface-elevated);
    color: var(--clr-text-main);
    border-color: var(--clr-border);
}
.btn-secondary:hover {
    background: var(--clr-bg-surface);
    border-color: var(--clr-border-hover);
}

.icon-btn {
    background: transparent;
    border: none;
    color: var(--clr-text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.2s ease;
}
.icon-btn:hover {
    background: var(--clr-bg-surface-elevated);
    color: var(--clr-text-main);
}
.icon-btn svg { width: 20px; height: 20px; }

/* Theme Toggle Logic */
.theme-btn .moon-icon { display: none; }
[data-theme="dark"] .theme-btn .sun-icon { display: none; }
[data-theme="dark"] .theme-btn .moon-icon { display: block; }

/* Navigation */
.navbar {
    position: fixed;
    top: 0; width: 100%;
    z-index: 1000;
    background: rgba(var(--clr-bg-main-rgb, 255,255,255), 0.8);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--clr-border);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
[data-theme="dark"] .navbar {
    background: rgba(10,10,10, 0.8);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    height: 64px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.nav-logo { height: 32px; width: auto; }
.brand-text {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.04em;
}

.nav-center {
    display: flex;
    gap: 2rem;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}
.nav-link {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--clr-text-muted);
}
.nav-link:hover { color: var(--clr-text-main); }

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.mobile-menu-toggle { display: none; }

.mobile-menu {
    display: none;
    flex-direction: column;
    padding: 1rem;
    background: var(--clr-bg-main);
    border-bottom: 1px solid var(--clr-border);
}
.mobile-menu.active { display: flex; }
.mobile-link {
    padding: 0.75rem 1rem;
    color: var(--clr-text-main);
    font-weight: 500;
    border-radius: 6px;
}
.mobile-link:hover { background: var(--clr-bg-surface-elevated); }

/* Layout Utils */
.section-padding { padding: 8rem 1.5rem 4rem; }
.hero-container, .bento-grid, .modern-diagram, .cta-inner {
    max-width: 1100px;
    margin: 0 auto;
}

/* Animations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}
.delay-1 { transition-delay: 0.15s; }

/* Hero Section */
.hero {
    min-height: 90vh;
    display: flex;
    align-items: center;
    padding-top: 120px;
    position: relative;
    overflow: hidden;
}
.hero-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}
.hero-content {
    max-width: 500px;
}
/* Ensure the bento side never clips the floating badges */
.hero-bento {
    overflow: visible;
}
.badge {
    display: inline-flex;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.8rem;
    font-weight: 600;
    background: var(--clr-bg-surface-elevated);
    border: 1px solid var(--clr-border);
    color: var(--clr-text-muted);
    margin-bottom: 1.5rem;
}
.hero-title {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}
.hero-subtitle {
    font-size: 1.15rem;
    color: var(--clr-text-muted);
    margin-bottom: 2.5rem;
}
.hero-ctas {
    display: flex;
    gap: 1rem;
}
.justify-center { justify-content: center; }

/* Hero Mockup (Terminal) */
.bento-mockup {
    position: relative;
    background: #000;
    border: 1px solid var(--clr-border);
    border-radius: 12px;
    overflow: visible;
    box-shadow: var(--shadow-lg);
}
[data-theme="light"] .bento-mockup { background: #0F172A; }
.mockup-header {
    background: var(--clr-bg-surface-elevated);
    border-bottom: 1px solid var(--clr-border);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
}
.mac-dots {
    display: flex;
    gap: 8px;
}
.mac-dots span {
    width: 12px; height: 12px; border-radius: 50%;
}
.mac-dots span:nth-child(1) { background: #FF5F56; }
.mac-dots span:nth-child(2) { background: #FFBD2E; }
.mac-dots span:nth-child(3) { background: #27C93F; }

.mockup-title {
    flex: 1;
    text-align: center;
    font-size: 0.8rem;
    color: var(--clr-text-muted);
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    margin-left: -40px; /* Offset the dots */
}

.mockup-body {
    padding: 1.5rem 1.5rem 11rem 1.5rem; /* large bottom padding = space for the scanner widget overlay */
    font-size: 0.9rem;
    line-height: 1.7;
    background: #000; /* Always dark for terminal */
    color: #E2E8F0;
    border-radius: 0 0 12px 12px;
}
[data-theme="light"] .mockup-body { background: #0F172A; } /* Keep dark in light mode too */
.cmd .prompt { color: var(--clr-primary); font-weight: bold; margin-right: 8px; }
.log { color: #94A3B8; }
.log.success { color: #4ADE80; }
.log.highlight { color: #FACC15; font-weight: bold; }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
.blink { animation: blink 1s infinite; }

/* =========================================================
   3D Hero Scene
   ========================================================= */

/* Background perspective grid */
.hero-3d-scene {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.scene-grid {
    position: absolute;
    bottom: -80px;
    left: 50%;
    transform: translateX(-50%) rotateX(72deg);
    width: 180%;
    height: 600px;
    background-image:
        linear-gradient(rgba(59,130,246,0.14) 1px, transparent 1px),
        linear-gradient(90deg, rgba(59,130,246,0.14) 1px, transparent 1px);
    background-size: 80px 80px;
    -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, black 30%, transparent 80%);
    mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, black 30%, transparent 80%);
    transform-origin: center bottom;
}
[data-theme="light"] .scene-grid {
    background-image:
        linear-gradient(rgba(30,136,229,0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(30,136,229,0.1) 1px, transparent 1px);
}

/* Base shape */
.shape { position: absolute; }

/* ── File Scanner Widget ────────────── */
.file-scanner {
    position: absolute;
    bottom: -2.5rem;
    left: 1.5rem;
    width: 190px;
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: 14px;
    padding: 0.75rem 0.8rem 0.7rem;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    animation: scanner-widget-float 8s ease-in-out infinite;
    z-index: 10;
}
@keyframes scanner-widget-float {
    0%, 100% { transform: translateY(0px); }
    50%       { transform: translateY(-8px); }
}

/* Sweep beam */
.scanner-beam {
    position: absolute;
    left: 0; right: 0;
    height: 26px;
    pointer-events: none;
    z-index: 10;
    animation: beam-sweep 5s linear infinite;
    background: linear-gradient(
        to bottom,
        transparent,
        rgba(59,130,246,0.10) 40%,
        rgba(59,130,246,0.10) 60%,
        transparent
    );
}
.scanner-beam::after {
    content: '';
    position: absolute;
    left: 0; right: 0;
    top: 50%;
    height: 1.5px;
    background: linear-gradient(90deg, transparent 0%, var(--clr-primary) 30%, var(--clr-teal) 70%, transparent 100%);
    box-shadow: 0 0 8px var(--clr-primary);
}
@keyframes beam-sweep {
    0%   { top: -26px; }
    100% { top: 100%; }
}

/* Header */
.scanner-header {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.55rem;
}
.scanner-pulse {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--clr-primary);
    flex-shrink: 0;
    animation: scanner-pulse-dot 1.4s ease-in-out infinite;
}
@keyframes scanner-pulse-dot {
    0%, 100% { opacity: 1;    transform: scale(1); }
    50%       { opacity: 0.35; transform: scale(0.65); }
}
.scanner-title {
    font-size: 0.6rem;
    font-weight: 600;
    color: var(--clr-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* File rows */
.scan-file {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.25rem;
    border-radius: 6px;
    margin-bottom: 0.1rem;
}
.scan-file:last-of-type { margin-bottom: 0.55rem; }

/* Coloured file-type rect */
.sf-dot {
    width: 16px; height: 19px;
    border-radius: 3px;
    flex-shrink: 0;
}
.sf-pdf { background: #ef4444; }
.sf-img { background: #a855f7; }
.sf-doc { background: var(--clr-primary); }
.sf-zip { background: #f59e0b; }

/* Filename */
.sf-name {
    flex: 1;
    font-size: 0.58rem;
    font-weight: 500;
    color: var(--clr-text-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Status pill */
.sf-tag {
    font-size: 0.58rem;
    font-weight: 700;
    border-radius: 4px;
    padding: 1px 4px;
    opacity: 0;
    flex-shrink: 0;
}
.sf-ok  { color: #4ade80; background: rgba(74,222,128,0.13); }
.sf-dup { color: var(--clr-yellow); background: rgba(250,204,21,0.13); }

/* Beam passes each row at ~26%, 38%, 52%, 65% of the 5s cycle */
.sf-1 .sf-tag { animation: tag-f1 5s linear infinite; }
.sf-2 .sf-tag { animation: tag-f2 5s linear infinite; }
.sf-3 .sf-tag { animation: tag-f3 5s linear infinite; }
.sf-4 .sf-tag { animation: tag-f4 5s linear infinite; }

@keyframes tag-f1 {
    0%, 24%  { opacity: 0; }
    28%, 92% { opacity: 1; }
    100%     { opacity: 0; }
}
@keyframes tag-f2 {
    0%, 36%  { opacity: 0; }
    40%, 92% { opacity: 1; }
    100%     { opacity: 0; }
}
@keyframes tag-f3 {
    0%, 50%  { opacity: 0; }
    54%, 92% { opacity: 1; }
    100%     { opacity: 0; }
}
@keyframes tag-f4 {
    0%, 63%  { opacity: 0; }
    67%, 92% { opacity: 1; }
    100%     { opacity: 0; }
}

/* Row highlight flash when beam passes */
.sf-1 { animation: row-glow-blue   5s linear infinite; }
.sf-2 { animation: row-glow-blue   5s linear infinite 0.6s; }
.sf-3 { animation: row-glow-yellow 5s linear infinite 1.3s; }
.sf-4 { animation: row-glow-blue   5s linear infinite 2.0s; }

@keyframes row-glow-blue {
    0%, 22% { background: transparent; }
    25%     { background: rgba(59,130,246,0.13); }
    35%     { background: transparent; }
    100%    { background: transparent; }
}
@keyframes row-glow-yellow {
    0%, 22% { background: transparent; }
    25%     { background: rgba(250,204,21,0.12); }
    35%     { background: transparent; }
    100%    { background: transparent; }
}

/* Progress bar */
.scanner-progress {
    height: 2px;
    background: var(--clr-border);
    border-radius: 2px;
    overflow: hidden;
}
.scanner-progress-fill {
    height: 100%;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--clr-primary), var(--clr-teal));
    animation: progress-cycle 5s linear infinite;
}
@keyframes progress-cycle {
    0%   { width: 0%; }
    88%  { width: 100%; }
    100% { width: 100%; }
}

/* Floating rings */
.shape-ring {
    border-radius: 50%;
    border-style: solid;
}
.ring-1 {
    width: 220px; height: 220px;
    top: 8%; right: 4%;
    border-width: 1.5px;
    border-color: rgba(45,212,191,0.22);
    animation: ring-float-1 9s ease-in-out infinite;
    transform: rotateX(68deg) rotateZ(15deg);
}
.ring-2 {
    width: 140px; height: 140px;
    bottom: 12%; left: 4%;
    border-width: 1.5px;
    border-color: rgba(59,130,246,0.28);
    animation: ring-float-2 7s ease-in-out infinite 1.5s;
    transform: rotateX(65deg) rotateZ(-10deg);
}
.ring-3 {
    width: 90px; height: 90px;
    top: 55%; left: 50%;
    border-width: 1px;
    border-color: rgba(250,204,21,0.2);
    animation: ring-float-2 11s ease-in-out infinite 3s;
    transform: rotateX(60deg);
}
@keyframes ring-float-1 {
    0%, 100% { transform: rotateX(68deg) rotateZ(15deg) translateY(0px); }
    50%       { transform: rotateX(68deg) rotateZ(15deg) translateY(-18px); }
}
@keyframes ring-float-2 {
    0%, 100% { transform: rotateX(65deg) rotateZ(-10deg) translateY(0px); }
    50%       { transform: rotateX(65deg) rotateZ(-10deg) translateY(-14px); }
}

/* Floating dots / particles */
.shape-dot { border-radius: 50%; }
.dot-1 { width: 7px; height: 7px; top: 25%; left: 12%; background: var(--clr-primary); opacity: 0.55; animation: dot-float 7s ease-in-out infinite; }
.dot-2 { width: 4px; height: 4px; top: 65%; left: 7%;  background: var(--clr-teal);    opacity: 0.4;  animation: dot-float 5.5s ease-in-out infinite 1s; }
.dot-3 { width: 9px; height: 9px; top: 12%; right: 18%; background: var(--clr-teal);    opacity: 0.45; animation: dot-float 9s ease-in-out infinite 0.5s; }
.dot-4 { width: 5px; height: 5px; bottom: 22%; right: 6%; background: var(--clr-primary); opacity: 0.5; animation: dot-float 6s ease-in-out infinite 2s; }
.dot-5 { width: 6px; height: 6px; top: 40%; right: 42%; background: var(--clr-yellow);   opacity: 0.35; animation: dot-float 8s ease-in-out infinite 3s; }
@keyframes dot-float {
    0%, 100% { transform: translateY(0px)   translateX(0px); }
    33%       { transform: translateY(-22px) translateX(10px); }
    66%       { transform: translateY(-10px) translateX(-6px); }
}

/* =========================================================
   3D Mockup Wrapper
   ========================================================= */
.mockup-3d-wrapper {
    position: relative;
    /* preserve-3d intentionally omitted — it breaks position:absolute children */
    transform: perspective(1100px) rotateX(-5deg) rotateY(-10deg);
    transition: transform 0.12s ease-out;
    will-change: transform;
    /* Padding creates room for the floating badges without needing negative offsets */
    padding: 2.5rem 3rem 4rem 3rem;
    /* Pull the padding back so the terminal card stays visually centred */
    margin: -2.5rem -3rem -4rem -3rem;
}

/* Ambient glow behind the card */
.mockup-glow {
    position: absolute;
    inset: -30px;
    border-radius: 24px;
    background: radial-gradient(ellipse at 60% 40%, rgba(59,130,246,0.18) 0%, transparent 65%);
    filter: blur(24px);
    z-index: -1;
    pointer-events: none;
}
[data-theme="light"] .mockup-glow {
    background: radial-gradient(ellipse at 60% 40%, rgba(30,136,229,0.14) 0%, transparent 65%);
}

/* Floating stat badges */
.float-badge {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 0.9rem;
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    white-space: nowrap;
    z-index: 10;
}
.float-badge-icon { font-size: 1.1rem; }
.float-badge-value { font-size: 0.9rem; font-weight: 700; line-height: 1.2; }
.float-badge-label { font-size: 0.65rem; color: var(--clr-text-muted); }

.badge-speed {
    top: 0;
    right: 0;
    animation: badge-bob 4.5s ease-in-out infinite;
}
.badge-storage {
    bottom: 0;
    left: 0;
    animation: badge-bob 4s ease-in-out infinite 1.8s;
}
.badge-files {
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    animation: badge-bob-mid 5s ease-in-out infinite 0.9s;
}
@keyframes badge-bob {
    0%, 100% { transform: translateY(0px); }
    50%       { transform: translateY(-8px); }
}
/* Separate keyframe for the mid-right badge that carries an initial translateY(-50%) */
@keyframes badge-bob-mid {
    0%, 100% { transform: translateY(-50%); }
    50%       { transform: translateY(calc(-50% - 8px)); }
}

/* Bento Box Grid */
.bento-section { padding-top: 4rem; }
.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}
.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}
.section-header p {
    color: var(--clr-text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: minmax(280px, auto);
    gap: 1.5rem;
}

.bento-card {
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: 16px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
    position: relative;
}
.bento-card:hover {
    border-color: var(--clr-border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}
.bento-card.span-2 {
    grid-column: span 2;
}
.bento-content {
    z-index: 2;
}

.icon-wrap {
    width: 48px;
    height: 48px;
    background: var(--clr-bg-surface-elevated);
    border: 1px solid var(--clr-border);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}
.color-blue { color: var(--clr-primary); }
.color-red { color: var(--clr-red); }
.color-yellow { color: var(--clr-yellow); }
.color-teal { color: var(--clr-teal); }

.bento-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}
.bento-card p {
    color: var(--clr-text-muted);
    font-size: 0.95rem;
}

.bento-visual {
    margin-top: 2rem;
    height: 100px;
    border-radius: 8px;
    background: var(--clr-bg-surface-elevated);
    border: 1px solid var(--clr-border);
}
.blue-band {
    width: 100%; height: 100%; background: var(--clr-primary-bg);
}
.flex-center {
    display: flex; align-items: center; justify-content: center; gap: 1rem;
}
.visual-node {
    padding: 0.5rem 1rem; background: var(--clr-bg-surface); border: 1px solid var(--clr-border); border-radius: 6px; font-size: 0.8rem;
}
.visual-line { flex: 1; height: 1px; background: var(--clr-border); max-width: 50px;}
.color-teal-bg { background: var(--clr-teal); color: #000; font-weight: 600; border: none; }

/* Architecture Minimal View */
.arch-section {
    padding-top: 8rem;
}
.modern-diagram {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3rem;
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: 16px;
    padding: 4rem;
}
.diagram-col {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.diagram-box {
    padding: 1rem 1.5rem;
    background: var(--clr-bg-main);
    border: 1px solid var(--clr-border);
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: var(--shadow-sm);
    text-align: center;
}
.diagram-link {
    text-align: center;
    color: var(--clr-text-muted);
    font-size: 0.8rem;
    flex: 1;
    max-width: 200px;
}
.diagram-link hr {
    border: none;
    border-top: 1px dashed var(--clr-border-hover);
    margin-top: 0.5rem;
}
.main-core {
    background: var(--clr-bg-surface-elevated);
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px dashed var(--clr-border-hover);
}
.main-core .diagram-box.core {
    border-color: var(--clr-primary);
    background: var(--clr-primary-bg);
}

/* Bottom CTA */
.bottom-cta {
    padding-bottom: 8rem;
}
.cta-inner {
    text-align: center;
    padding: 5rem 2rem;
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: 16px;
}
.cta-inner h2 { font-size: 2.5rem; margin-bottom: 1rem; }
.cta-inner p { color: var(--clr-text-muted); margin-bottom: 2rem; font-size: 1.1rem; }

/* Footer */
.footer {
    border-top: 1px solid var(--clr-border);
    padding: 4rem 1.5rem;
    background: var(--clr-bg-main);
}
.footer-grid {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
}
.footer-brand .brand-text { font-size: 1.2rem; display: block; margin: 1rem 0 0.5rem;}
.footer-logo { height: 32px; }
.footer-title { font-weight: 600; margin-bottom: 1.25rem; font-size: 0.95rem; }
.footer-links { display: flex; flex-direction: column; gap: 0.75rem; }
.footer-links a { color: var(--clr-text-muted); font-size: 0.9rem; }
.footer-links a:hover { color: var(--clr-text-main); }
.footer p { color: var(--clr-text-muted); font-size: 0.9rem;}

/* Responsiveness */
@media (max-width: 992px) {
    .bento-grid {
        grid-template-columns: 1fr;
    }
    .bento-card.span-2 { grid-column: span 1; }
    
    .modern-diagram {
        flex-direction: column;
        padding: 2rem;
    }
    .diagram-link hr {
        border-top: none;
        border-left: 1px dashed var(--clr-border-hover);
        height: 50px;
        width: 1px;
        margin: 0.5rem auto;
    }
}

@media (max-width: 768px) {
    .nav-center, .nav-actions .btn {
        display: none;
    }
    .mobile-menu-toggle {
        display: flex;
    }
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }
    .hero-content { margin: 0 auto; }
    .hero-ctas { justify-content: center; flex-direction: column; }
    .hero-title { font-size: 3rem; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
    .footer-grid { grid-template-columns: 1fr; text-align: center; }
}

/* =========================================================
   Contact Modal
   ========================================================= */
.modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}
.modal-backdrop.open {
    opacity: 1;
    pointer-events: all;
}
.modal-box {
    position: relative;
    width: 100%;
    max-width: 460px;
    background: var(--clr-bg-surface);
    border: 1px solid var(--clr-border);
    border-radius: 20px;
    padding: 2.5rem 2rem;
    box-shadow: 0 24px 60px rgba(0,0,0,0.5);
    transform: translateY(18px) scale(0.97);
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}
.modal-backdrop.open .modal-box {
    transform: translateY(0) scale(1);
}
.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
}

/* Header */
.modal-header {
    text-align: center;
    margin-bottom: 1.75rem;
}
.modal-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px; height: 48px;
    border-radius: 12px;
    background: var(--clr-primary-bg);
    color: var(--clr-primary);
    margin-bottom: 1rem;
}
.modal-icon svg { width: 24px; height: 24px; }
.modal-header h2 {
    font-size: 1.4rem;
    margin-bottom: 0.4rem;
}
.modal-header p {
    color: var(--clr-text-muted);
    font-size: 0.9rem;
}

/* Form fields */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    margin-bottom: 1rem;
}
.form-group label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--clr-text-muted);
    letter-spacing: 0.02em;
}
.form-group input,
.form-group textarea {
    background: var(--clr-bg-surface-elevated);
    border: 1px solid var(--clr-border);
    border-radius: 8px;
    padding: 0.65rem 0.85rem;
    font-size: 0.9rem;
    font-family: inherit;
    color: var(--clr-text-main);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    outline: none;
    resize: vertical;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--clr-text-muted); }
.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--clr-primary);
    box-shadow: 0 0 0 3px var(--clr-primary-bg);
}
.btn-full { width: 100%; justify-content: center; margin-top: 0.5rem; }

/* Spinner inside button */
.btn-spinner {
    display: none;
    width: 16px; height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
#form-submit-btn.loading .btn-label { display: none; }
#form-submit-btn.loading .btn-spinner { display: inline-block; }
#form-submit-btn.loading { pointer-events: none; opacity: 0.8; }

/* Success state */
.modal-success-state {
    text-align: center;
    padding: 1rem 0;
}
.modal-success-state[hidden] { display: none; }
.success-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px; height: 64px;
    border-radius: 50%;
    background: rgba(74, 222, 128, 0.12);
    color: #4ade80;
    margin-bottom: 1.25rem;
}
.success-icon svg { width: 32px; height: 32px; }
.modal-success-state h2 { font-size: 1.5rem; margin-bottom: 0.5rem; }
.modal-success-state p { color: var(--clr-text-muted); margin-bottom: 1.75rem; }

@media (max-width: 480px) {
    .modal-box { padding: 2rem 1.25rem; }
}
