/* ============================================================
   HelpVending — личный кабинет (вход/регистрация/дашборд/установка)
   Те же переменные и тема, что и на сайте-презентации — согласованный
   единый стиль, не два разных дизайна на одном домене.
============================================================ */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --danger: #dc2626;
    --success: #16a34a;
    --warning: #d97706;
    --radius: 14px;
    --font-display: 'Manrope', sans-serif;
    --font-body: 'Inter', sans-serif;
}

html.theme-dark {
    --bg-deep: #0f172a;
    --bg-panel: #0b1220;
    --bg-panel-hover: #1e293b;
    --line: #1e293b;
    --accent-soft: rgba(37, 99, 235, 0.16);
    --text-primary: #e2e8f0;
    --text-muted: #94a3b8;
    --text-faint: #64748b;
}

html.theme-light {
    --bg-deep: #f0f2f5;
    --bg-panel: #ffffff;
    --bg-panel-hover: #f1f5f9;
    --line: #e2e8f0;
    --accent-soft: #dbeafe;
    --text-primary: #0f172a;
    --text-muted: #64748b;
    --text-faint: #94a3b8;
}

html.theme-fade { opacity: 0; transition: opacity .2s ease; }

* { box-sizing: border-box; }

html, body {
    margin: 0; padding: 0;
    background: var(--bg-deep);
    color: var(--text-primary);
    font-family: var(--font-body);
    -webkit-font-smoothing: antialiased;
    transition: background 0.2s, color 0.2s;
}

a { color: var(--primary); }

/* ── Каркас центрированной страницы (вход/регистрация) ──────── */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

/* ── Карточка ────────────────────────────────────────── */
.card {
    background: var(--bg-panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 28px;
}

/* ── Кнопки ──────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: 10px;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: transform 0.15s, background 0.15s, border-color 0.15s;
    white-space: nowrap;
    text-decoration: none;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-light { background: var(--bg-panel-hover); border-color: var(--line); color: var(--text-primary); }
.btn-light:hover { border-color: var(--primary); color: var(--primary); }
.btn-sm { padding: 7px 14px; font-size: 13px; }
.btn:disabled { opacity: .5; cursor: default; transform: none; }
.w-full { width: 100%; }

/* ── Поля ввода ──────────────────────────────────────── */
.input {
    background: var(--bg-deep);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 11px 14px;
    font-family: var(--font-body);
    font-size: 14px;
    color: var(--text-primary);
    outline: none;
    transition: border-color 0.15s;
}
.input:focus { border-color: var(--primary); }
.input::placeholder { color: var(--text-faint); }

/* ── Бейджи-уведомления ──────────────────────────────── */
.badge { display: inline-flex; align-items: center; gap: 6px; border-radius: 8px; font-size: 13px; font-weight: 500; }
.badge-warn { background: rgba(217,119,6,0.12); color: var(--warning); }
.badge-success { background: rgba(22,163,74,0.12); color: var(--success); }

/* ── Утилиты (минимальный набор, который реально используется) ── */
.mb-1 { margin-bottom: 4px; } .mb-2 { margin-bottom: 8px; } .mb-3 { margin-bottom: 12px; } .mb-4 { margin-bottom: 16px; }
.mt-2 { margin-top: 8px; } .mt-4 { margin-top: 16px; }
.flex { display: flex; } .items-center { align-items: center; } .justify-between { justify-content: space-between; }
.gap-2 { gap: 8px; }
.text-xs { font-size: 12px; } .text-sm { font-size: 14px; } .text-lg { font-size: 18px; }
.font-semibold { font-weight: 600; }
.text-center { text-align: center; }
.text-gray-400 { color: var(--text-faint); }
.text-gray-500 { color: var(--text-muted); }
.text-gray-600 { color: var(--text-muted); }

/* ── Переключатель темы (та же кнопка, что на сайте) ─────────── */
.theme-toggle-fixed {
    position: fixed;
    top: 20px; right: 20px;
    background: var(--bg-panel);
    border: 1px solid var(--line);
    color: var(--text-muted);
    width: 36px; height: 36px;
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    font-size: 14px;
    z-index: 10;
}
.theme-toggle-fixed:hover { color: var(--text-primary); }
