/* === SIGNUP.CSS === */
/* assets/css/signup.css */
/* НАЗНАЧЕНИЕ: стили лендинга регистрации (Dev Terminal эстетика) */
/* РАЗМЕР: ~330 строк */

:root {
    --bg-primary: oklch(0.17 0.02 265);
    --bg-card: oklch(0.21 0.025 265);
    --bg-input: oklch(0.25 0.025 265);
    --border: oklch(0.32 0.03 265);
    --border-focus: oklch(0.65 0.18 250);
    --text: oklch(0.95 0.01 265);
    --text-dim: oklch(0.68 0.02 265);
    --accent: oklch(0.68 0.17 250);
    --accent-hover: oklch(0.74 0.17 250);
    --success: oklch(0.72 0.17 155);
    --danger: oklch(0.66 0.2 25);
    --warn: oklch(0.8 0.15 85);
    --radius: 14px;
    --radius-sm: 9px;
    --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
    --mono: 'JetBrains Mono', ui-monospace, monospace;
    --sans: 'Inter', system-ui, sans-serif;
}

[data-theme="light"] {
    --bg-primary: oklch(0.97 0.01 265);
    --bg-card: oklch(1 0 0);
    --bg-input: oklch(0.96 0.01 265);
    --border: oklch(0.88 0.02 265);
    --border-focus: oklch(0.6 0.18 250);
    --text: oklch(0.22 0.02 265);
    --text-dim: oklch(0.48 0.02 265);
}

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

body {
    font-family: var(--sans);
    background: var(--bg-primary);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    position: relative;
    overflow-x: hidden;
}

/* Атмосферные orbs (без швов между секциями) */
.bg-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(90px);
    opacity: 0.18;
    pointer-events: none;
    z-index: 0;
}
.orb-1 { width: 480px; height: 480px; background: var(--accent); top: -160px; right: -120px; }
.orb-2 { width: 400px; height: 400px; background: oklch(0.6 0.18 310); bottom: -140px; left: -100px; }

.wrap { width: 100%; max-width: 460px; position: relative; z-index: 1; }

.card {
    background: color-mix(in oklch, var(--bg-card) 88%, transparent);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 34px 30px;
    box-shadow: 0 24px 60px -20px oklch(0 0 0 / 0.5);
    animation: cardIn 0.5s var(--ease-out-quart);
}
@keyframes cardIn {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

.brand {
    display: flex; align-items: center; gap: 8px;
    font-family: var(--mono); font-size: 13px; color: var(--text-dim);
    margin-bottom: 22px;
}
.brand-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 10px var(--success);
}

.title {
    font-family: var(--mono);
    font-size: 26px; font-weight: 700; line-height: 1.2;
    letter-spacing: -0.02em;
    margin-bottom: 10px;
}
.subtitle { color: var(--text-dim); font-size: 14.5px; line-height: 1.55; margin-bottom: 26px; }
.subtitle.warn { color: var(--warn); }

/* Поля */
.field { display: block; margin-bottom: 18px; }
.field-label {
    display: block; font-family: var(--mono); font-size: 12px;
    color: var(--text-dim); margin-bottom: 7px; text-transform: uppercase;
    letter-spacing: 0.04em;
}
.field input {
    width: 100%; padding: 12px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: var(--mono); font-size: 15px;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.field input:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px color-mix(in oklch, var(--accent) 25%, transparent);
}
.field input::placeholder { color: oklch(from var(--text-dim) l c h / 0.5); }

.field-suffix-wrap { position: relative; display: flex; align-items: center; }
.field-suffix-wrap input { padding-right: 0; }
.field-suffix {
    font-family: var(--mono); font-size: 13px; color: var(--text-dim);
    white-space: nowrap; padding-left: 6px;
}

.field-prefix-wrap {
    display: flex; align-items: center;
    background: var(--bg-input); border: 1px solid var(--border);
    border-radius: var(--radius-sm); transition: border-color 0.2s, box-shadow 0.2s;
}
.field-prefix-wrap:focus-within {
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px color-mix(in oklch, var(--accent) 25%, transparent);
}
.field-prefix {
    font-family: var(--mono); font-size: 15px; color: var(--text-dim);
    padding-left: 14px;
}
.field-prefix-wrap input {
    border: none; background: transparent; box-shadow: none !important;
    padding-left: 4px;
}
.field-prefix-wrap input:focus { border: none; box-shadow: none; }
.field-hint { display: block; font-size: 12px; color: var(--text-dim); margin-top: 6px; line-height: 1.4; }

.form-error {
    background: color-mix(in oklch, var(--danger) 16%, transparent);
    border: 1px solid color-mix(in oklch, var(--danger) 45%, transparent);
    color: var(--danger);
    padding: 11px 14px; border-radius: var(--radius-sm);
    font-size: 13.5px; margin-bottom: 16px;
}

/* Кнопка */
.btn-primary {
    width: 100%; padding: 13px;
    background: var(--accent); color: oklch(0.16 0.02 265);
    border: none; border-radius: var(--radius-sm);
    font-family: var(--mono); font-size: 15px; font-weight: 700;
    cursor: pointer; transition: background 0.2s, transform 0.1s;
    display: flex; align-items: center; justify-content: center; gap: 10px;
}
.btn-primary:hover:not(:disabled) { background: var(--accent-hover); }
.btn-primary:active:not(:disabled) { transform: scale(0.985); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; }

.btn-spinner, .wait-spinner {
    width: 16px; height: 16px;
    border: 2px solid color-mix(in oklch, currentColor 30%, transparent);
    border-top-color: currentColor; border-radius: 50%;
    animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Экран ожидания */
.wait-spinner {
    width: 40px; height: 40px; border-width: 3px;
    color: var(--accent); margin: 0 auto 22px;
}
.wait-steps { list-style: none; margin-top: 24px; }
.wait-steps li {
    font-family: var(--mono); font-size: 13.5px;
    padding: 10px 0 10px 28px; position: relative;
    color: var(--text-dim); border-top: 1px solid var(--border);
    transition: color 0.3s;
}
.wait-steps li::before {
    content: '○'; position: absolute; left: 4px; color: var(--text-dim);
}
.wait-steps li.active { color: var(--text); }
.wait-steps li.active::before { content: '◔'; color: var(--accent); }
.wait-steps li.done { color: var(--success); }
.wait-steps li.done::before { content: '●'; color: var(--success); }

/* Экран доступов */
.done-badge {
    display: inline-block; font-family: var(--mono); font-size: 12px; font-weight: 700;
    background: color-mix(in oklch, var(--success) 18%, transparent);
    color: var(--success);
    border: 1px solid color-mix(in oklch, var(--success) 45%, transparent);
    padding: 5px 12px; border-radius: 999px; margin-bottom: 16px;
    letter-spacing: 0.04em;
}
.access-group { margin-bottom: 22px; }
.access-group h3 {
    font-family: var(--mono); font-size: 13px; color: var(--accent);
    margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.04em;
}
.access-row {
    display: flex; align-items: center; gap: 8px;
    background: var(--bg-input); border: 1px solid var(--border);
    border-radius: var(--radius-sm); padding: 9px 11px; margin-bottom: 7px;
}
.access-row .ar-key { font-family: var(--mono); font-size: 11.5px; color: var(--text-dim); min-width: 78px; }
.access-row .ar-val {
    font-family: var(--mono); font-size: 13px; color: var(--text);
    flex: 1; word-break: break-all; user-select: all;
}
.copy-btn {
    background: transparent; border: 1px solid var(--border);
    color: var(--text-dim); border-radius: 6px; padding: 4px 8px;
    font-family: var(--mono); font-size: 11px; cursor: pointer;
    transition: all 0.15s; flex-shrink: 0;
}
.copy-btn:hover { color: var(--accent); border-color: var(--accent); }
.copy-btn.copied { color: var(--success); border-color: var(--success); }

/* Theme toggle */
.theme-toggle {
    position: fixed; top: 18px; right: 18px; z-index: 5;
    width: 38px; height: 38px; border-radius: 50%;
    background: var(--bg-card); border: 1px solid var(--border);
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: border-color 0.2s;
}
.theme-toggle:hover { border-color: var(--accent); }
.theme-toggle svg { width: 18px; height: 18px; stroke: var(--text); }

.footer {
    margin-top: 28px; font-family: var(--mono); font-size: 12px;
    color: var(--text-dim); position: relative; z-index: 1;
}

@media (max-width: 520px) {
    .card { padding: 26px 20px; }
    .title { font-size: 22px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
