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

:root {
    --bg: #0e1117;
    --bg-2: #161b22;
    --bg-3: #1f242c;
    --border: #2a313c;
    --text: #e6edf3;
    --text-dim: #9da7b3;
    --accent: #4f9eff;
    --accent-2: #2563eb;
    --red: #f85149;
    --purple: #a371f7;
}

html, body {
    height: 100%;
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 14px;
    line-height: 1.45;
}

button {
    font-family: inherit;
    font-size: 14px;
    cursor: pointer;
    border: none;
    background: var(--accent);
    color: white;
    padding: 9px 16px;
    border-radius: 6px;
    font-weight: 600;
    transition: background 120ms ease, opacity 120ms ease;
}
button:hover:not(:disabled) { background: var(--accent-2); }
button:disabled { opacity: 0.45; cursor: not-allowed; }

input {
    font-family: inherit;
    font-size: 14px;
    background: var(--bg-2);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 10px 12px;
    width: 100%;
    transition: border-color 140ms ease, box-shadow 140ms ease;
}
input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(79, 158, 255, 0.18);
}

.screen { display: none; min-height: 100vh; }
.screen.active { display: block; }

#gate.screen.active {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 20px 60px;
    min-height: 100vh;
}
.site-foot {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    color: var(--text-dim);
    font-size: 11px;
    letter-spacing: 0.3px;
    opacity: 0.75;
    text-align: center;
    padding: 12px;
    pointer-events: none;
}
.gate-card {
    width: 100%;
    max-width: 420px;
    background: var(--bg-2);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 44px 36px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 18px 50px -16px rgba(0,0,0,0.55);
}
.gate-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--accent), var(--purple));
    color: white;
    font-weight: 800;
    font-size: 18px;
    letter-spacing: 1px;
    margin-bottom: 20px;
}
.gate-logo-img {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    margin-bottom: 20px;
    box-shadow: 0 12px 28px -10px rgba(79, 158, 255, 0.55);
    transition: transform 280ms cubic-bezier(0.16, 1, 0.3, 1);
}
.gate-logo-img:hover { transform: translateY(-2px) rotate(-3deg); }
.gate-card h1 {
    font-size: 22px;
    margin: 0 0 22px;
    text-align: center;
}
.gate-card h1:has(+ .gate-sub) { margin-bottom: 6px; }
.gate-sub {
    color: var(--text-dim);
    margin: 0 0 22px;
    text-align: center;
}
#gate-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    align-items: stretch;
}
#gate-input {
    text-align: center;
    letter-spacing: 1px;
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 13px;
    text-transform: uppercase;
}
.gate-error {
    color: var(--red);
    font-size: 13px;
    margin-top: 14px;
    padding: 10px;
    background: rgba(248, 81, 73, 0.08);
    border-radius: 6px;
    width: 100%;
    text-align: center;
}

#toasts {
    position: fixed;
    top: 16px;
    right: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 200;
}
