:root {
    --deep: #04080f;
    --abyss: #070d1a;
    --mid: #0a1628;
    --surface: #0d2040;
    --foam: #e8f4f8;
    --mist: #a8ccd8;
    --teal: #1ec8c8;
    --glow: #00e5ff;
    --gold: #c8a96e;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background: var(--deep);
    color: var(--foam);
    font-family: 'DM Sans', sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
    cursor: crosshair;
}

#ocean-canvas {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    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)' opacity='0.04'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 200px 200px;
    opacity: 0.5;
}

.stage {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
}

nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.6rem 3rem;
    border-bottom: 1px solid rgba(168, 204, 216, 0.08);
    backdrop-filter: blur(8px);
}

.nav-logo {
    font-family: 'Space Mono', monospace;
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--mist);
    opacity: 0.6;
}

.nav-badge {
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--teal);
    border: 1px solid rgba(30, 200, 200, 0.3);
    padding: 0.3rem 0.8rem;
    border-radius: 2px;
}

.hero {
    text-align: center;
    max-width: 800px;
}

.pre-title {
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.35em;
    text-transform: uppercase;
    color: var(--teal);
    margin-bottom: 2.5rem;
    opacity: 0;
    animation: rise 1s ease forwards 0.3s;
}

.wordmark {
    font-family: 'Instrument Sans', sans-serif;
    font-weight: 900;
    font-size: clamp(4rem, 13vw, 10.5rem);
    line-height: 0.95;
    letter-spacing: 0.12em;
    color: transparent;
    -webkit-text-stroke: 1px rgba(232, 244, 248, 0.15);
    position: relative;
    opacity: 0;
    animation: rise 1.2s ease forwards 0.5s;
}

.wordmark .fill {
    position: absolute;
    inset: 0;
    color: var(--foam);
    -webkit-text-stroke: 0;
    clip-path: inset(0 100% 0 0);
    animation: reveal 1.8s cubic-bezier(0.77, 0, 0.18, 1) forwards 0.8s;
}

.wordmark em {
    font-style: normal;
    color: var(--teal);
}

.wordmark .fill em {
    color: var(--teal);
}

@keyframes reveal {
    to {
        clip-path: inset(0 0% 0 0);
    }
}

.sub {
    font-family: 'DM Sans', sans-serif;
    font-size: clamp(0.9rem, 2vw, 1.15rem);
    font-weight: 300;
    font-style: italic;
    color: var(--mist);
    margin-top: 2rem;
    letter-spacing: 0.08em;
    opacity: 0;
    animation: rise 1s ease forwards 1.4s;
}

.rule {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin: 3.5rem auto;
    width: 360px;
    max-width: 90vw;
    opacity: 0;
    animation: rise 1s ease forwards 1.7s;
}

.rule-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(168, 204, 216, 0.3), transparent);
}

.rule-icon {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

.cta {
    opacity: 0;
    animation: rise 1s ease forwards 2s;
}

.cta-label {
    font-family: 'Space Mono', monospace;
    font-size: 0.6rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--mist);
    opacity: 0.5;
    margin-bottom: 0.8rem;
    text-align: center;
}

.cta-link {
    font-family: 'DM Sans', sans-serif;
    font-size: clamp(1rem, 2vw, 1.25rem);
    font-weight: 400;
    color: var(--foam);
    text-decoration: none;
    letter-spacing: 0.06em;
    position: relative;
    padding-bottom: 4px;
    transition: color 0.3s ease;
}

.cta-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 100%;
    height: 1px;
    background: var(--glow);
    transition: right 0.5s cubic-bezier(0.77, 0, 0.18, 1);
    box-shadow: 0 0 8px var(--glow);
}

.cta-link:hover {
    color: var(--glow);
}

.cta-link:hover::after {
    right: 0;
}

.social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    margin-top: 2.5rem;
    opacity: 0;
    animation: rise 1s ease forwards 2.2s;
}

.social-label {
    font-family: 'Space Mono', monospace;
    font-size: 0.55rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--mist);
    opacity: 0.4;
    margin-right: 0.4rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid rgba(168, 204, 216, 0.12);
    border-radius: 50%;
    color: var(--mist);
    text-decoration: none;
    font-size: 0.8rem;
    transition: color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.social-link:hover {
    color: var(--glow);
    border-color: rgba(0, 229, 255, 0.4);
    box-shadow: 0 0 12px rgba(0, 229, 255, 0.15), inset 0 0 8px rgba(0, 229, 255, 0.05);
    transform: translateY(-2px);
}

.coords {
    position: fixed;
    bottom: 2rem;
    left: 3rem;
    z-index: 10;
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    letter-spacing: 0.12em;
    color: var(--mist);
    opacity: 0;
    animation: rise 1s ease forwards 2.3s;
}

.status {
    position: fixed;
    bottom: 2rem;
    right: 3rem;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    letter-spacing: 0.12em;
    color: var(--mist);
    opacity: 0;
    animation: rise 1s ease forwards 2.3s;
}

.dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--teal);
    box-shadow: 0 0 6px var(--teal);
    animation: pulse 2.5s ease-in-out infinite;
}

.depth-lines {
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    overflow: hidden;
}

.depth-lines span {
    display: block;
    position: absolute;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(to right, transparent 0%, rgba(30, 200, 200, 0.04) 50%, transparent 100%);
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.4;
        transform: scale(0.8);
    }
}

@media (max-width: 768px) {
    nav {
        padding: 1.2rem 1.5rem;
    }

    .stage {
        padding: 6rem 1.5rem 3rem;
    }

    .wordmark {
        letter-spacing: 0.06em;
    }
}

@media (max-width: 480px) {
    nav {
        padding: 1rem 1.2rem;
    }

    .nav-logo {
        font-size: 0.65rem;
    }

    .nav-badge {
        font-size: 0.55rem;
        padding: 0.25rem 0.6rem;
    }

    .stage {
        padding: 5rem 1.2rem 2.5rem;
        min-height: 100svh;
    }

    .hero {
        max-width: 100%;
        width: 100%;
    }

    .pre-title {
        font-size: 0.55rem;
        letter-spacing: 0.2em;
        margin-bottom: 1.5rem;
    }

    .wordmark {
        font-size: clamp(3.2rem, 18vw, 5rem);
        letter-spacing: 0.04em;
        line-height: 1;
    }

    .sub {
        font-size: 0.85rem;
        margin-top: 1.2rem;
        letter-spacing: 0.04em;
    }

    .rule {
        margin: 2rem auto;
    }

    .cta-label {
        font-size: 0.55rem;
    }

    .cta-link {
        font-size: 1rem;
        padding: 0.6rem 0;
        display: inline-block;
        min-height: 44px;
        line-height: 44px;
    }

    .social {
        margin-top: 1.8rem;
        gap: 0.5rem;
    }

    .social-label {
        display: none;
    }

    .social-link {
        width: 42px;
        height: 42px;
        font-size: 0.9rem;
    }

    body {
        cursor: default;
    }

    .coords,
    .status {
        display: none;
    }
}

@supports (padding-top: env(safe-area-inset-top)) {
    nav {
        padding-top: calc(1.2rem + env(safe-area-inset-top));
        padding-left: calc(1.5rem + env(safe-area-inset-left));
        padding-right: calc(1.5rem + env(safe-area-inset-right));
    }

    .coords {
        bottom: calc(2rem + env(safe-area-inset-bottom));
        left: calc(3rem + env(safe-area-inset-left));
    }

    .status {
        bottom: calc(2rem + env(safe-area-inset-bottom));
        right: calc(3rem + env(safe-area-inset-right));
    }
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 10;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 3rem;
    border-top: 1px solid rgba(168, 204, 216, 0.06);
    backdrop-filter: blur(8px);
    opacity: 0;
    animation: rise 1s ease forwards 2.3s;
}

.footer-side {
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    letter-spacing: 0.12em;
    color: var(--mist);
    opacity: 0.45;
    white-space: nowrap;
}

.footer-legal {
    font-family: 'Space Mono', monospace;
    font-size: 0.58rem;
    letter-spacing: 0.1em;
    color: var(--mist);
    opacity: 0.35;
    text-align: center;
    line-height: 1.6;
}

.footer-legal strong {
    font-weight: 700;
    opacity: 0.6;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

@media (max-width: 768px) {
    footer {
        padding: 1rem 1.5rem;
    }

    .footer-side {
        display: none;
    }

    .footer-legal {
        font-size: 0.55rem;
    }
}

@media (max-width: 480px) {
    footer {
        padding: 0.8rem 1.2rem;
    }
}

@supports (padding-bottom: env(safe-area-inset-bottom)) {
    footer {
        padding-bottom: calc(1.2rem + env(safe-area-inset-bottom));
    }
}