/* ═══════════════════════════════════════════════
   VibeHarbor Landing — shared design system styles
   Byte-identical rules extracted from index / vibepet / riji.
   Page-specific rules stay inline in each page's <style>.
   ═══════════════════════════════════════════════ */

    /* Shared design tokens used by rules in this file and inline styles */
    :root {
        /* Typography colors */
        --text-title:         #ffffff;
        --text-body:          #a0a0b0;
        --text-label:         #8e8e9e;

        /* Glassmorphism */
        --glass-bg:           rgba(255, 255, 255, 0.04);
        --glass-border:       rgba(255, 255, 255, 0.08);
        --glass-border-hover: rgba(255, 255, 255, 0.15);
    }

    /* ═══════════════════════════════════════════
       1. Reset & Base
       ═══════════════════════════════════════════ */
    *, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

    html {
        scroll-behavior: smooth;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }

    ::selection {
        background: rgba(99, 102, 241, 0.35);
        color: #fff;
    }

    a { color: inherit; text-decoration: none; }

    .material-symbols-outlined {
        font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24;
    }

    /* ═══════════════════════════════════════════
       2. Background: drifting aurora glows + noise
       ═══════════════════════════════════════════ */
    .bg-glow {
        position: fixed;
        inset: -10%; /* oversized so the drift never reveals edges */
        z-index: 0;
        pointer-events: none;
        background:
            radial-gradient(600px 420px at 15% 0%, rgba(99, 102, 241, 0.20), transparent 70%),
            radial-gradient(700px 500px at 90% 100%, rgba(139, 92, 246, 0.17), transparent 70%),
            radial-gradient(520px 420px at 72% 12%, rgba(139, 92, 246, 0.09), transparent 70%);
        animation: aurora-drift 26s ease-in-out infinite alternate;
        will-change: transform;
    }

    /* Second, counter-drifting glow layer for depth */
    .bg-glow::before {
        content: '';
        position: absolute;
        inset: 0;
        background:
            radial-gradient(560px 460px at 28% 85%, rgba(99, 102, 241, 0.13), transparent 70%),
            radial-gradient(460px 380px at 60% 42%, rgba(139, 92, 246, 0.09), transparent 70%);
        animation: aurora-drift 34s ease-in-out infinite alternate-reverse;
    }

    @keyframes aurora-drift {
        0%   { transform: translate3d(-2%, -1%, 0) scale(1); }
        50%  { transform: translate3d(1.5%, 2%, 0) scale(1.04); }
        100% { transform: translate3d(2%, -1.5%, 0) scale(1.02); }
    }

    @media (prefers-reduced-motion: reduce) {
        .bg-glow, .bg-glow::before { animation: none; }
    }

    .noise-overlay {
        position: fixed;
        inset: 0;
        z-index: 1;
        pointer-events: none;
        opacity: 0.02;
        background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
        background-repeat: repeat;
        background-size: 256px 256px;
    }

    /* Breathing particles canvas */
    #stardust-canvas {
        position: fixed;
        inset: 0;
        z-index: 2;
        pointer-events: none;
    }

    /* ═══════════════════════════════════════════
       3. Reveal Animations (load stagger + scroll)
       ═══════════════════════════════════════════ */
    .reveal {
        opacity: 0;
        transform: translateY(20px);
        transition: opacity 0.6s var(--ease-fluid),
                    transform 0.6s var(--ease-fluid);
    }

    .reveal-scroll {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.5s var(--ease-fluid),
                    transform 0.5s var(--ease-fluid);
    }

    .reveal.in, .reveal-scroll.in {
        opacity: 1;
        transform: translateY(0);
    }

    /* ═══════════════════════════════════════════
       4. Navigation — transparent -> frosted glass
       ═══════════════════════════════════════════ */
    .nav-bar {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 100;
        background: transparent;
        border-bottom: 1px solid transparent;
        transition: background 0.35s ease,
                    border-color 0.35s ease,
                    backdrop-filter 0.35s ease,
                    -webkit-backdrop-filter 0.35s ease;
    }

    .nav-bar.scrolled {
        background: rgba(10, 10, 15, 0.65);
        backdrop-filter: blur(12px) saturate(1.4);
        -webkit-backdrop-filter: blur(12px) saturate(1.4);
        border-bottom-color: rgba(255, 255, 255, 0.08);
    }

    .nav-inner {
        max-width: 1200px;
        margin: 0 auto;
        padding: 0 24px;
        height: 64px;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .nav-brand-text {
        font-weight: 700;
        font-size: 17px;
        letter-spacing: -0.02em;
        color: var(--text-title);
    }

    .nav-links { display: flex; align-items: center; gap: 24px; }

    /* Link with underline expanding from the left */
    .anim-link {
        position: relative;
        font-size: 14px;
        font-weight: 500;
        color: var(--text-body);
        padding: 4px 0;
        transition: color 0.3s ease;
        white-space: nowrap;
    }

    .anim-link::after {
        content: '';
        position: absolute;
        left: 0;
        bottom: 0;
        width: 100%;
        height: 1px;
        background: var(--accent);
        transform: scaleX(0);
        transform-origin: left;
        transition: transform 0.3s var(--ease-fluid);
    }

    .anim-link:hover { color: var(--accent); }
    .anim-link:hover::after { transform: scaleX(1); }

    .nav-icon-btn {
        display: flex;
        align-items: center;
        gap: 6px;
        background: none;
        border: none;
        cursor: pointer;
        font-family: 'JetBrains Mono', monospace;
        font-size: 11px;
        letter-spacing: 0.06em;
        color: var(--text-body);
        padding: 4px 0;
        position: relative;
        transition: color 0.3s ease;
    }

    .nav-icon-btn::after {
        content: '';
        position: absolute;
        left: 0;
        bottom: 0;
        width: 100%;
        height: 1px;
        background: var(--accent);
        transform: scaleX(0);
        transform-origin: left;
        transition: transform 0.3s var(--ease-fluid);
    }

    .nav-icon-btn:hover { color: var(--accent); }
    .nav-icon-btn:hover::after { transform: scaleX(1); }

    .nav-icon-btn svg, .nav-icon-btn .material-symbols-outlined { width: 16px; height: 16px; font-size: 16px; }

    /* ═══════════════════════════════════════════
       5. Hero Badge (shared)
       ═══════════════════════════════════════════ */

    .hero-badge {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 6px 16px;
        border-radius: 999px;
        background: rgba(99, 102, 241, 0.1);
        border: 1px solid rgba(99, 102, 241, 0.22);
        font-family: 'JetBrains Mono', monospace;
        font-size: 11px;
        font-weight: 600;
        letter-spacing: 0.1em;
        text-transform: uppercase;
        color: #a5b4fc;
        margin-bottom: 32px;
    }

    .hero-badge-dot {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: var(--primary);
        animation: badgePulse 2.4s ease-in-out infinite;
    }

    @keyframes badgePulse {
        0%, 100% { opacity: 1; transform: scale(1); }
        50% { opacity: 0.45; transform: scale(0.8); }
    }

    /* Shimmer light sweeping left -> right on hover */
    .glass-card::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 45%;
        height: 100%;
        background: linear-gradient(100deg,
            transparent 0%,
            rgba(255, 255, 255, 0.05) 50%,
            transparent 100%
        );
        transform: translateX(-130%) skewX(-12deg);
        transition: transform 0.7s ease;
        pointer-events: none;
    }

    .glass-card:hover {
        transform: scale(1.02);
        border-color: var(--glass-border-hover);
        box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
    }

    .glass-card:hover::after {
        transform: translateX(320%) skewX(-12deg);
    }

    .cta-btn:hover {
        filter: brightness(1.1);
        transform: translateY(-2px);
        box-shadow: 0 8px 28px rgba(99, 102, 241, 0.35);
    }

    .cta-btn:active { transform: translateY(0); }

    .cta-btn .material-symbols-outlined {
        font-size: 18px;
        transition: transform 0.3s ease;
    }

    .footer-inner {
        max-width: 1200px;
        margin: 0 auto;
        padding: 40px 24px;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }

    @media (min-width: 768px) {
        .footer-inner {
            flex-direction: row;
            justify-content: space-between;
        }
    }

    .footer-brand {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .footer-brand-text {
        font-weight: 700;
        font-size: 14px;
        color: var(--text-body);
        letter-spacing: -0.02em;
    }

    .footer-links { display: flex; gap: 24px; }

    .footer-copy {
        font-family: 'JetBrains Mono', monospace;
        font-size: 11px;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        color: var(--text-label);
    }

    .footer-legal {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }

    .footer-icp {
        text-decoration: none;
        transition: color 0.2s ease;
    }

    .footer-icp:hover { color: var(--text-body); }
