:root {
    color-scheme: light dark;
    --bg: #f5f8f8;
    --surface: #fff;
    --surface-2: #eef5f4;
    --text: #10272d;
    --muted: #60747a;
    --border: #dce7e8;
    --blue: #1977e8;
    --green: #16a77b;
    --danger: #c73d4d;
    --shadow: 0 30px 90px rgba(16, 39, 45, .1);
}

* { box-sizing: border-box; }
body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    background:
        radial-gradient(circle at 15% 10%, rgba(25,119,232,.13), transparent 35%),
        radial-gradient(circle at 85% 85%, rgba(22,167,123,.15), transparent 36%),
        var(--bg);
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.shell { width: min(100% - 32px, 560px); margin: 0 auto; padding: 44px 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; font-weight: 800; font-size: 19px; }
.brand-mark { display: grid; place-items: center; width: 42px; height: 42px; color: #fff; background: linear-gradient(135deg, var(--blue), var(--green)); border-radius: 13px; }
.brand-logo { display: block; width: 42px; height: 42px; object-fit: contain; }
.auth-card { margin-top: 32px; padding: clamp(24px, 6vw, 44px); background: var(--surface); border: 1px solid var(--border); border-radius: 30px; box-shadow: var(--shadow); }
.eyebrow { color: var(--green); font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
h1 { margin: 10px 0 8px; font-size: clamp(32px, 8vw, 48px); line-height: 1.05; }
h2 { margin: 0 0 8px; font-size: 24px; }
p { color: var(--muted); line-height: 1.55; }
.tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: 30px 0 26px; padding: 5px; background: var(--surface-2); border-radius: 15px; }
.tab, .back { border: 0; cursor: pointer; color: var(--muted); background: transparent; }
.tab { padding: 12px; border-radius: 11px; font-weight: 700; }
.tab.active { color: var(--text); background: var(--surface); box-shadow: 0 5px 20px rgba(16,39,45,.08); }
.flow { display: none; gap: 17px; }
.flow.active { display: grid; }
.name-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
label { display: grid; gap: 7px; font-size: 13px; font-weight: 700; }
input { width: 100%; padding: 14px 15px; color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: 12px; outline: none; font: inherit; }
input:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(25,119,232,.1); }
.primary { min-height: 50px; border: 0; border-radius: 13px; cursor: pointer; color: #fff; background: linear-gradient(135deg, var(--blue), var(--green)); font: inherit; font-weight: 800; }
button:disabled { cursor: wait; opacity: .65; }
.back { padding: 8px; font-weight: 700; }
.captcha { min-height: 102px; overflow: hidden; }
.notice { margin: -10px 0 20px; padding: 12px 14px; color: #0c6d55; background: rgba(22,167,123,.1); border-radius: 11px; font-size: 14px; }
.notice.error { color: var(--danger); background: rgba(199,61,77,.1); }
.security-note { margin: 22px auto 0; max-width: 430px; text-align: center; font-size: 12px; }
@media (prefers-color-scheme: dark) {
    :root { --bg:#081417; --surface:#102328; --surface-2:#173238; --text:#edf7f8; --muted:#9db2b7; --border:#213b40; --blue:#4c9cff; --green:#2bc89a; --shadow:0 30px 90px rgba(0,0,0,.3); }
}
@media (max-width: 520px) { .name-grid { grid-template-columns: 1fr; } .shell { padding-top: 24px; } }
.vk-login{display:flex;align-items:center;justify-content:center;min-height:48px;margin:18px 0 12px;border-radius:12px;color:#fff;background:#0077ff;font-weight:800;text-decoration:none}.vk-login:hover{background:#066ee0}.auth-divider{display:flex;align-items:center;gap:12px;margin:0 0 16px;color:var(--muted);font-size:13px}.auth-divider:before,.auth-divider:after{content:"";height:1px;flex:1;background:var(--border)}
