/* ==========================================================================
   Halden Auth Kit — base.css
   Design tokens, reset and typography.
   Designed & built by EdinStack
   ========================================================================== */

:root {
  /* Neutrals */
  --bg: #ffffff;
  --bg-soft: #f5f6f3;
  --panel: #eef2ec;
  --text: #16181a;
  --text-2: #45494e;
  --muted: #6b7177;
  --border: #d9ddd6;
  --border-strong: #bfc5bc;

  /* Brand */
  --brand: #0e5a43;
  --brand-hover: #0b4a37;
  --brand-soft: #e3efe9;
  --on-brand: #ffffff;
  --ring: rgba(14, 90, 67, 0.2);

  /* States */
  --danger: #c0362c;
  --danger-soft: #fdf1f0;
  --danger-ring: rgba(192, 54, 44, 0.16);
  --warn: #c27a12;
  --good: #4f8a3c;
  --success: #1f7a4d;
  --success-soft: #e8f5ee;

  /* Type */
  --font: "Schibsted Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Shape */
  --radius: 8px;
  --radius-lg: 12px;
  --shadow-xs: 0 1px 2px rgba(16, 24, 40, 0.05);
  --shadow-card: 0 1px 2px rgba(16, 24, 40, 0.06), 0 24px 48px -24px rgba(16, 24, 40, 0.28);

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111312;
    --bg-soft: #161917;
    --panel: #18201c;
    --text: #eceeea;
    --text-2: #c3c8c2;
    --muted: #8d948e;
    --border: #2a302c;
    --border-strong: #3a423d;

    --brand: #4cc08f;
    --brand-hover: #63cf9f;
    --brand-soft: #1a2e25;
    --on-brand: #06261b;
    --ring: rgba(76, 192, 143, 0.25);

    --danger: #f07a6e;
    --danger-soft: #2a1715;
    --danger-ring: rgba(240, 122, 110, 0.2);
    --warn: #e3a447;
    --good: #93c47d;
    --success: #6fcf9a;
    --success-soft: #142a1e;

    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.3), 0 24px 48px -24px rgba(0, 0, 0, 0.6);

    color-scheme: dark;
  }
}

/* Reset ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 15px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, p, figure, ol, ul, fieldset, table { margin: 0; }
ol, ul { padding: 0; list-style: none; }
fieldset { padding: 0; border: 0; min-width: 0; }
legend { padding: 0; }
a { color: inherit; }
img, svg { display: block; max-width: 100%; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }

::selection { background: var(--brand-soft); color: var(--text); }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

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

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
