/* Colors, fonts and buttons shared by the login page and the app. */

@font-face { font-family: 'Barlow'; font-weight: 400; font-style: normal; font-display: swap; src: url('/fonts/barlow-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Barlow'; font-weight: 500; font-style: normal; font-display: swap; src: url('/fonts/barlow-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Barlow'; font-weight: 600; font-style: normal; font-display: swap; src: url('/fonts/barlow-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Barlow'; font-weight: 700; font-style: normal; font-display: swap; src: url('/fonts/barlow-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-weight: 600; font-style: normal; font-display: swap; src: url('/fonts/barlow-condensed-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-weight: 700; font-style: normal; font-display: swap; src: url('/fonts/barlow-condensed-latin-700-normal.woff2') format('woff2'); }

:root {
  --bg: #e9ecf0;
  --surface: #ffffff;
  --surface-2: #f4f6f8;
  --ink: #1b2229;
  --muted: #55616d;
  --line: #cfd5dc;
  --steel: #2a333d;
  --steel-ink: #f2f4f6;
  --red: #c4102a;
  --red-ink: #ffffff;
  --red-text: #b00d25;
  --red-tint: #fbe9ec;
  --focus: #1b2229;
  --shadow: 0 1px 2px rgba(20, 30, 40, .08), 0 4px 14px rgba(20, 30, 40, .06);
  --font-body: 'Barlow', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-head: 'Barlow Condensed', 'Arial Narrow', 'Barlow', sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12161b;
    --surface: #1b2128;
    --surface-2: #232b34;
    --ink: #e8ecf0;
    --muted: #a0acb8;
    --line: #313b46;
    --steel: #0c0f13;
    --steel-ink: #e8ecf0;
    --red: #d3243b;
    --red-text: #ff7084;
    --red-tint: #3a1a20;
    --focus: #e8ecf0;
    --shadow: 0 1px 2px rgba(0, 0, 0, .5);
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.4;
}

h1, h2, h3 {
  font-family: var(--font-head);
  font-weight: 700;
  letter-spacing: .02em;
  line-height: 1.05;
  margin: 0;
}

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

/* Buttons: big tap targets */
.btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 6px;
  border: 2px solid var(--ink);
  background: var(--surface);
  color: var(--ink);
  font: 700 17px/1 var(--font-head);
  letter-spacing: .06em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
}
.btn:hover { background: var(--surface-2); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .45; cursor: not-allowed; }
.btn-primary { background: var(--red); border-color: var(--red); color: var(--red-ink); }
.btn-primary:hover { background: var(--red); filter: brightness(.92); }
.btn-ghost { border-color: var(--line); }
.btn-small { min-height: 44px; padding: 0 14px; font-size: 16px; }
.btn-block { width: 100%; }

/* Form fields: 16px+ so phones do not zoom */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.field > label, .field > .label, legend {
  font: 600 15px/1.2 var(--font-body);
  color: var(--muted);
  letter-spacing: .04em;
  text-transform: uppercase;
}
input[type="text"], input[type="tel"], input[type="email"], input[type="search"], input[type="password"],
input[type="date"], select, textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  border: 2px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--ink);
  font: 400 16px/1.3 var(--font-body);
}
textarea { min-height: 120px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--ink); }

.error-text { color: var(--red-text); font-weight: 600; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
