/* The sign-in page (S75): the look of the Studio v3 mockup (docs/mockups/studio-v3, `.auth`),
   with the D9 contrast corrections (button orange #c44a0c, tertiary text #676f7c, opaque
   focus ring). Light and dark follow the system. No inline style: the page's CSP refuses it. */

:root {
  --font: Inter, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --navy: #13213c;
  --brand-btn: #c44a0c;
  --bg: #f6f5f2;
  --surface: #ffffff;
  --border: #b9bec6;
  --text: #0f1b2d;
  --text-2: #4f5866;
  --text-3: #676f7c;
  --focus: #c44a0c;
  --warn-bg: #fff4dc;
  --warn-border: #e2b04a;
  --ok-bg: #e6f5ec;
  --ok-border: #5fae80;
  --danger-bg: #fdecea;
  --danger-border: #d97066;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b111c;
    --surface: #121a28;
    --border: #3a475e;
    --text: #edf1f7;
    --text-2: #a7b1c2;
    --text-3: #9aa5b8;
    --focus: #ff9a5c;
    --warn-bg: #2d2412;
    --warn-border: #8a6a24;
    --ok-bg: #11291c;
    --ok-border: #2f7a50;
    --danger-bg: #2e1513;
    --danger-border: #9c4038;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; margin: 0; }
html, body { min-height: 100%; }
body { font-family: var(--font); font-size: 15px; line-height: 1.5; color: var(--text); background: var(--bg); }
a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }

.auth { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }

.auth-art { position: relative; overflow: hidden; background: var(--navy); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-art::before { content: ""; position: absolute; inset: -20%; background: radial-gradient(circle at 70% 30%, rgba(232, 100, 27, .45), transparent 45%), radial-gradient(circle at 20% 80%, rgba(124, 108, 240, .3), transparent 40%); }
.auth-art > * { position: relative; }
.auth-art .brand { display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 17px; }
.auth-art .brand img { border-radius: 10px; }
.auth-art h2 { font-family: var(--font-display); font-size: 40px; line-height: 1.08; letter-spacing: -.03em; font-weight: 700; max-width: 14ch; }
.auth-art p { color: #c9d6f0; max-width: 40ch; margin-top: 14px; font-size: 17px; }

.auth-form { display: grid; place-items: center; padding: 72px 24px 40px; position: relative; }
.auth-lang { position: absolute; top: 20px; right: 24px; display: flex; gap: 2px; padding: 3px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.auth-lang a { text-decoration: none; font-size: 13px; font-weight: 600; padding: 4px 10px; border-radius: 7px; color: var(--text-2); }
.auth-lang a[aria-current="true"] { background: var(--navy); color: #fff; }

.auth-card { width: min(400px, 100%); display: flex; flex-direction: column; gap: 18px; }
.auth-card .logo { border-radius: 12px; }
.auth-card h1 { font-family: var(--font-display); font-size: 26px; font-weight: 700; letter-spacing: -.02em; }
.muted { color: var(--text-2); margin-top: 6px; }
.subtle { color: var(--text-3); font-size: 13px; display: flex; flex-direction: column; gap: 4px; }

.btn { display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 48px; padding: 0 18px; border-radius: 12px; font-weight: 600; text-decoration: none; }
.btn-google { background: var(--surface); color: var(--text); border: 1px solid var(--border); }
.btn-google:hover { border-color: var(--text-3); }
.btn-secondary { background: var(--brand-btn); color: #fff; }
.btn-secondary:hover { filter: brightness(1.08); }

.notice { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--warn-border); background: var(--warn-bg); }
.notice[data-tone="ok"] { border-color: var(--ok-border); background: var(--ok-bg); }
.notice[data-tone="danger"] { border-color: var(--danger-border); background: var(--danger-bg); }
.notice span { color: var(--text-2); font-size: 14px; }

[hidden] { display: none !important; }

@media (max-width: 860px) {
  .auth { grid-template-columns: 1fr; }
  .auth-art { display: none; }
}
