:root {
    color-scheme: dark;
    --background: #090d14;
    --surface: #111824;
    --surface-2: #172131;
    --border: #263449;
    --text: #f2f6fb;
    --muted: #91a0b5;
    --accent: #5ee0a0;
    --accent-strong: #28bd78;
    --danger: #ff7890;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    margin: 0;
    background:
        radial-gradient(circle at 15% 0%, rgba(40, 189, 120, 0.14), transparent 30rem),
        var(--background);
    color: var(--text);
}

.shell {
    width: min(1080px, calc(100% - 32px));
    margin: 0 auto;
    padding: 64px 0;
}

.topbar,
.section-heading,
.status-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.topbar {
    margin-bottom: 36px;
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 8px;
    font-size: clamp(2.2rem, 5vw, 4.2rem);
    letter-spacing: -0.055em;
    line-height: 0.95;
}

h2 {
    margin-bottom: 12px;
    font-size: 1.35rem;
    letter-spacing: -0.025em;
}

.eyebrow,
.step {
    display: block;
    margin-bottom: 12px;
    color: var(--accent);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.subtitle,
.card p,
.hint {
    color: var(--muted);
    line-height: 1.6;
}

.grid {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.75fr);
    gap: 20px;
}

.card {
    padding: clamp(24px, 4vw, 40px);
    border: 1px solid var(--border);
    border-radius: 18px;
    background: linear-gradient(145deg, rgba(23, 33, 49, 0.96), rgba(14, 21, 32, 0.96));
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.24);
}

.auth-card {
    width: min(500px, 100%);
}

.stack {
    display: grid;
    gap: 18px;
}

label {
    display: grid;
    gap: 9px;
    color: #dce5f0;
    font-size: 0.88rem;
    font-weight: 700;
}

input,
textarea {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 10px;
    outline: none;
    background: #0b111a;
    color: var(--text);
    font: 500 0.95rem/1.5 ui-monospace, SFMono-Regular, Consolas, monospace;
    transition: border-color 140ms ease, box-shadow 140ms ease;
}

input {
    padding: 13px 14px;
}

textarea {
    min-height: 230px;
    padding: 16px;
    resize: vertical;
}

input:focus,
textarea:focus {
    border-color: var(--accent-strong);
    box-shadow: 0 0 0 3px rgba(40, 189, 120, 0.16);
}

.button {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    padding: 0 18px;
    border: 1px solid var(--accent);
    border-radius: 10px;
    background: var(--accent);
    color: #06130d;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
    text-decoration: none;
}

.button:hover {
    background: #7aebb3;
}

.button-secondary,
.button-ghost {
    border-color: var(--border);
    background: transparent;
    color: var(--text);
}

.button-secondary {
    width: 100%;
    margin-top: 18px;
}

.button-secondary:hover,
.button-ghost:hover {
    background: var(--surface-2);
}

.counter {
    padding: 6px 10px;
    border: 1px solid var(--border);
    border-radius: 99px;
    color: var(--muted);
    font-size: 0.75rem;
}

.hint {
    margin: -7px 0 0;
    font-size: 0.8rem;
}

code {
    color: #a4f1c8;
}

.endpoint {
    display: block;
    overflow-wrap: anywhere;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #0b111a;
    line-height: 1.55;
}

.status-row {
    justify-content: flex-start;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 0.82rem;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 14px var(--accent);
}

.notice {
    margin-bottom: 20px;
    padding: 14px 16px;
    border: 1px solid;
    border-radius: 10px;
}

.notice-error {
    border-color: rgba(255, 120, 144, 0.45);
    background: rgba(255, 120, 144, 0.09);
    color: #ffc2cc;
}

.notice-success {
    border-color: rgba(94, 224, 160, 0.4);
    background: rgba(94, 224, 160, 0.08);
    color: #aaf0ce;
}

@media (max-width: 760px) {
    .shell {
        padding: 36px 0;
    }

    .topbar {
        align-items: flex-start;
    }

    .grid {
        grid-template-columns: 1fr;
    }
}
