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

:root {
    color-scheme: dark;
    --bg: #111111;
    --card: #1a1a1a;
    --card-hover: #1f1f1f;
    --card-secondary: #161616;
    --border: #2a2a2a;
    --border-strong: #3d3d3d;
    --text: #e5e5e5;
    --text-bright: #f0f0f0;
    --text-dim: #555555;
    --accent: #3e9e6b;
    --primary-bg: linear-gradient(180deg, #1c201e, #1a1a1a);
    --primary-bg-hover: linear-gradient(180deg, #232824, #202020);
    --icon-bg: #252525;
    --logo-1: #cfcecd;
    --logo-2: #4b4646;
    --logo-3: #f1ecec;
    --logo-4: #cfcecd;
    --logo-5: #211e1e;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

#snow {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.hub {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hub-inner {
    width: 100%;
    max-width: min(560px, 92vw);
    padding: 40px 16px;
}

.logo {
    text-align: center;
    margin-bottom: clamp(20px, 4vw, 28px);
    user-select: none;
    animation: fadeIn 1s ease backwards;
}

.logo-mark {
    width: clamp(72px, 12vw, 104px);
    height: clamp(72px, 12vw, 104px);
    margin: 0 auto clamp(12px, 2.5vw, 18px);
    display: block;
}

.logo-mark path:nth-child(1) { fill: var(--logo-1); }
.logo-mark path:nth-child(2) { fill: var(--logo-2); }
.logo-mark path:nth-child(3) { fill: var(--logo-3); }
.logo-mark path:nth-child(4) { fill: var(--logo-4); }
.logo-mark path:nth-child(5) { fill: var(--logo-5); }

.logo-caption {
    font-size: clamp(0.62rem, 1.8vw, 0.7rem);
    font-weight: 600;
    letter-spacing: 6px;
    text-transform: uppercase;
    color: var(--text-dim);
    margin-top: clamp(8px, 1.8vw, 12px);
}

.links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: clamp(8px, 2vw, 12px);
}

.links > li {
    animation: fadeIn 1s ease backwards;
}

.links > li:nth-child(1) { animation-delay: 0s; }
.links > li:nth-child(2) { animation-delay: 0.08s; }
.links > li:nth-child(3) { animation-delay: 0.16s; }

.link {
    display: flex;
    align-items: center;
    gap: clamp(10px, 3vw, 16px);
    padding: clamp(14px, 3.5vw, 22px);
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 6px;
    text-decoration: none;
    color: var(--text);
    transition: background 0.2s, border-color 0.2s, transform 0.2s ease, box-shadow 0.3s;
    touch-action: manipulation;
}

.link:hover {
    background: var(--card-hover);
    border-color: var(--border-strong);
    box-shadow: 0 0 14px -8px rgba(62, 158, 107, 0.16), 0 10px 20px -16px rgba(0, 0, 0, 0.7);
    transform: translateY(-1px);
}

.link:active {
    transform: scale(0.995);
}

.link:focus-visible {
    outline: 2px solid var(--text-dim);
    outline-offset: 2px;
}

.link-icon {
    width: clamp(38px, 8vw, 50px);
    height: clamp(38px, 8vw, 50px);
    min-width: clamp(38px, 8vw, 50px);
    border-radius: 4px;
    background: var(--icon-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: box-shadow 0.25s;
}

.link-icon svg {
    width: clamp(17px, 4vw, 22px);
    height: clamp(17px, 4vw, 22px);
    display: block;
}

.link--primary:hover .link-icon {
    box-shadow: inset 0 0 0 1px rgba(62, 158, 107, 0.26);
}

.link-title {
    flex: 1;
    min-width: 0;
    font-size: clamp(0.85rem, 2.5vw, 1.05rem);
    font-weight: 600;
    color: var(--text-bright);
    letter-spacing: 0.2px;
}

.link-arrow {
    width: clamp(18px, 3.5vw, 22px);
    height: clamp(18px, 3.5vw, 22px);
    flex-shrink: 0;
}

.link-arrow path {
    stroke: var(--text-dim);
    transition: stroke 0.2s;
}

.link:hover .link-arrow path,
.link:focus-visible .link-arrow path {
    stroke: #7d7d7d;
}

.link--primary {
    background: var(--primary-bg);
    border-color: var(--accent);
}

.link--primary:hover {
    background: var(--primary-bg-hover);
    border-color: var(--accent);
}

.link--primary .link-title {
    font-size: clamp(0.95rem, 2.7vw, 1.15rem);
}

.link--secondary {
    background: var(--card-secondary);
}

.link--secondary:hover .link-icon {
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14);
}

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

@media (hover: none) {
    .link {
        padding: 18px;
    }

    .link-icon {
        width: clamp(40px, 9vw, 50px);
        height: clamp(40px, 9vw, 50px);
        min-width: clamp(40px, 9vw, 50px);
    }

    .link-arrow path {
        stroke: #3f3f3f;
    }
}

@media (max-width: 480px) {
    .link-title {
        font-size: 1rem;
        letter-spacing: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .logo,
    .links > li {
        animation: none;
        opacity: 1;
    }

    .link {
        transition: none;
    }
}
