:root {
    --bg: #07080a;
    --surface: #0d0f12;
    --border: #1e2329;
    --text: #c8cdd3;
    --dim: #5c6570;
    --cyan: #22d3ee;
    --amber: #f59e0b;
    --green: #34d399;
    --red: #f87171;
}

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

body {
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    background: var(--bg);
    color: var(--text);
    line-height: 1.65;
    min-height: 100vh;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        linear-gradient(rgba(34, 211, 238, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(34, 211, 238, 0.03) 1px, transparent 1px);
    background-size: 48px 48px;
    pointer-events: none;
    z-index: 0;
}

.wrap {
    position: relative;
    z-index: 1;
    max-width: 52rem;
    margin: 0 auto;
    padding: 2rem 1.25rem 4rem;
}

header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 2.5rem;
    flex-wrap: wrap;
}

.beacon { display: flex; align-items: center; gap: 0.6rem; }

.beacon-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--cyan);
    box-shadow: 0 0 12px var(--cyan);
    animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}

.beacon-label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--dim);
}

.terminal {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.45);
}

.terminal-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0.65rem 1rem;
    background: #111418;
    border-bottom: 1px solid var(--border);
}

.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot.red { background: var(--red); }
.dot.amber { background: var(--amber); }
.dot.green { background: var(--green); }

.terminal-title {
    margin-left: 0.5rem;
    font-size: 0.68rem;
    color: var(--dim);
    letter-spacing: 0.06em;
}

.terminal-body { padding: 1.75rem 1.5rem 2rem; }

h1 {
    font-size: clamp(1.35rem, 4vw, 1.85rem);
    font-weight: 700;
    color: #e8eaed;
    margin-bottom: 0.35rem;
}

.subtitle {
    font-size: 0.82rem;
    color: var(--cyan);
    margin-bottom: 1.5rem;
}

.prompt-line {
    font-size: 0.78rem;
    color: var(--dim);
    margin-bottom: 1.25rem;
}

.prompt-line span { color: var(--green); }

p { font-size: 0.82rem; margin-bottom: 1rem; }
p strong { color: #e0e4e8; font-weight: 600; }

.actions { margin: 2rem 0 1.25rem; }

.btn {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    padding: 0.75rem 1.25rem;
    border-radius: 4px;
    border: 1px solid rgba(34, 211, 238, 0.35);
    transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
}

.btn-primary {
    color: var(--bg);
    background: var(--cyan);
    border-color: var(--cyan);
    box-shadow: 0 0 24px rgba(34, 211, 238, 0.25);
}

.btn-primary:hover {
    background: #3de4ff;
    box-shadow: 0 0 32px rgba(34, 211, 238, 0.4);
}

.btn-ghost {
    color: var(--cyan);
    background: transparent;
    padding: 0.45rem 0.75rem;
    font-size: 0.68rem;
}

.btn-ghost:hover {
    background: rgba(34, 211, 238, 0.08);
    border-color: rgba(34, 211, 238, 0.5);
}

.session-bar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.session-user {
    font-size: 0.68rem;
    color: var(--dim);
    letter-spacing: 0.06em;
}

.login-form {
    display: grid;
    gap: 1rem;
    max-width: 22rem;
    margin: 1.5rem 0;
}

.login-form label {
    display: grid;
    gap: 0.35rem;
    font-size: 0.72rem;
    color: var(--dim);
}

.login-form input {
    font: inherit;
    font-size: 0.82rem;
    color: var(--text);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 0.55rem 0.65rem;
}

.login-form input:focus {
    outline: none;
    border-color: rgba(34, 211, 238, 0.45);
}

.form-error {
    color: var(--red);
    font-size: 0.78rem;
    margin-bottom: 0.5rem;
}

.notice {
    font-size: 0.78rem;
    color: var(--green);
    margin-top: 1rem;
}

.footnote {
    font-size: 0.72rem;
    color: var(--dim);
    margin-bottom: 0;
}

.hub {
    display: grid;
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.hub-link {
    display: block;
    padding: 0.9rem 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--text);
    text-decoration: none;
    font-size: 0.78rem;
    transition: border-color 0.15s, background 0.15s;
}

.hub-link:hover {
    border-color: rgba(34, 211, 238, 0.45);
    background: rgba(34, 211, 238, 0.05);
}

.hub-tag {
    display: block;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--amber);
    margin-bottom: 0.35rem;
}

footer {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    font-size: 0.68rem;
    color: var(--dim);
    text-align: center;
}

footer a { color: var(--cyan); text-decoration: none; }
footer a:hover { text-decoration: underline; }

@media (max-width: 480px) {
    .terminal-body { padding: 1.25rem 1rem 1.5rem; }
}
