/* Minden / Sonance house style.
   Brand: Montserrat, accent #00A3E1. Follow brand.sonance.com.
   Theme: light (:root) / dark (prefers-color-scheme) / explicit override ([data-theme]).
   Style everything through the tokens below, never with raw colors, so all three
   themes stay correct. */

:root {
  --accent:   #00A3E1;
  --accent-d: #0086b8;
  --bg:       #f5f7f9;
  --surface:  #ffffff;
  --surface-2:#f0f3f6;
  --text:     #14181c;
  --muted:    #5c6b78;
  --line:     #dfe5ea;
  --good:     #1a7f3e;
  --warn:     #b6791f;
  --bad:      #b3261e;
  --radius:   10px;
  --shadow:   0 1px 3px rgba(20,24,28,.08), 0 6px 20px rgba(20,24,28,.05);
  --font:     'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg:       #0f1417;
    --surface:  #171d22;
    --surface-2:#1e262c;
    --text:     #e8edf1;
    --muted:    #9aa8b3;
    --line:     #2a343b;
    --shadow:   0 1px 3px rgba(0,0,0,.4), 0 6px 20px rgba(0,0,0,.35);
  }
}
:root[data-theme="dark"] {
  --bg:       #0f1417;
  --surface:  #171d22;
  --surface-2:#1e262c;
  --text:     #e8edf1;
  --muted:    #9aa8b3;
  --line:     #2a343b;
  --shadow:   0 1px 3px rgba(0,0,0,.4), 0 6px 20px rgba(0,0,0,.35);
}

* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.5 var(--font); -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-weight: 700; text-wrap: balance; }
a { color: var(--accent); }
img { max-width: 100%; }

/* --- Top bar --- */
.topbar {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 20px; background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.topbar .brand { font-weight: 700; font-size: 16px; letter-spacing: .2px; }
.topbar .brand span { color: var(--accent); }
.topbar .spacer { flex: 1; }
.topbar .who { color: var(--muted); font-size: 13px; }

/* --- Layout --- */
.wrap { max-width: 960px; margin: 0 auto; padding: 28px 20px; }
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px;
}

/* --- Buttons --- */
.btn {
  font: 600 14px/1 var(--font); padding: 10px 16px; border-radius: 8px;
  border: 1px solid var(--line); background: var(--surface); color: var(--text);
  cursor: pointer;
}
.btn:hover { border-color: var(--muted); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-d); border-color: var(--accent-d); }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* --- Inputs --- */
input, textarea, select {
  font: 14px var(--font); padding: 10px 12px; width: 100%;
  border: 1px solid var(--line); border-radius: 8px;
  background: var(--surface); color: var(--text);
}
input:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
label { display: block; font-size: 13px; color: var(--muted); margin: 0 0 5px; }

/* --- Login screen --- */
.login { min-height: 70vh; display: flex; align-items: center; justify-content: center; }
.login .card { width: 100%; max-width: 380px; }
.login h1 { margin: 0 0 4px; font-size: 22px; }
.login .sub { color: var(--muted); margin: 0 0 18px; font-size: 14px; }
.login .field { margin-bottom: 12px; }
.status { margin-top: 12px; font-size: 13px; }
.status.err { color: var(--bad); }
.status.ok  { color: var(--good); }

[hidden] { display: none !important; }
