/* ============================================================
   LEDGERGUARD UK — Design System
   Foundation layer: tokens, resets, typography, utilities
   ============================================================ */

/* ----------------------------------------------------------
   1. Design Tokens
   ---------------------------------------------------------- */
:root {
  /* Backgrounds */
  --bg-primary: #060913;
  --bg-gradient: radial-gradient(ellipse at top, #0c1224 0%, #060913 70%);
  --bg-surface: rgba(17, 24, 43, 0.7);
  --bg-surface-hover: rgba(17, 24, 43, 0.9);

  /* Borders */
  --border-primary: #1e294b;
  --border-subtle: rgba(30, 41, 75, 0.5);

  /* Text */
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  /* Accent */
  --accent: #3b82f6;
  --accent-hover: #2563eb;
  --accent-glow: rgba(59, 130, 246, 0.15);
  --accent-glow-strong: rgba(59, 130, 246, 0.25);

  /* Semantic */
  --success: #10b981;
  --success-glow: rgba(16, 185, 129, 0.15);
  --warning: #f59e0b;
  --danger: #ef4444;

  /* Typography */
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
}

/* ----------------------------------------------------------
   2. Reset
   ---------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ----------------------------------------------------------
   3. Base Styles
   ---------------------------------------------------------- */
html {
  scroll-behavior: smooth;

  /* Scrollbar — WebKit */
  scrollbar-width: thin;
  scrollbar-color: var(--border-primary) var(--bg-primary);
}

html::-webkit-scrollbar {
  width: 8px;
}

html::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

html::-webkit-scrollbar-thumb {
  background: var(--border-primary);
  border-radius: 4px;
}

html::-webkit-scrollbar-thumb:hover {
  background: #2a3a6b;
}

body {
  background: var(--bg-gradient);
  background-attachment: fixed;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* ----------------------------------------------------------
   4. Links
   ---------------------------------------------------------- */
a {
  color: inherit;
  text-decoration: none;
}

/* ----------------------------------------------------------
   5. Selection
   ---------------------------------------------------------- */
::selection {
  background: var(--accent-glow-strong);
  color: var(--text-primary);
}

::-moz-selection {
  background: var(--accent-glow-strong);
  color: var(--text-primary);
}

/* ----------------------------------------------------------
   6. Typography Scale
   ---------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  line-height: 1.15;
}

h1 {
  font-weight: 800;
  font-size: 36px;
  letter-spacing: -1.5px;
  line-height: 1.08;
  background: linear-gradient(180deg, #ffffff 30%, #94a3b8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

h2 {
  font-weight: 800;
  font-size: 28px;
  letter-spacing: -0.8px;
  line-height: 1.1;
}

h3 {
  font-weight: 700;
  font-size: 18px;
  line-height: 1.25;
}

.section-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 680px;
  margin: 12px auto 0;
  line-height: 1.6;
}

/* Desktop typography */
@media (min-width: 768px) {
  h1 {
    font-size: 46px;
  }

  h2 {
    font-size: 32px;
  }

  h3 {
    font-size: 20px;
  }
}

/* ----------------------------------------------------------
   7. Layout Utilities
   ---------------------------------------------------------- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 48px 0;
}

@media (min-width: 768px) {
  .section {
    padding: 64px 0;
  }
}

/* ----------------------------------------------------------
   8. Image & Media Defaults
   ---------------------------------------------------------- */
img {
  display: block;
  max-width: 100%;
}

/* ----------------------------------------------------------
   9. List Reset (used globally, components re-style)
   ---------------------------------------------------------- */
ul, ol {
  list-style: none;
}

/* ----------------------------------------------------------
   10. Focus Visible (accessibility baseline)
   ---------------------------------------------------------- */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
