/*
 * CookingFriend — legal pages stylesheet
 */

/* ─── FONT ───────────────────────────────────────────────────── */
@font-face {
  font-family: 'Inter';
  src: url('/fonts/Inter-variable.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* ─── LAYERS ────────────────────────────────────────────────── */
@layer reset, tokens, base, legal;

/* ─── RESET ─────────────────────────────────────────────────── */
@layer reset {
  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
  html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
  img, svg { max-width: 100%; display: block; }
  button { cursor: pointer; border: none; background: none; font: inherit; color: inherit; }
  a { color: inherit; text-decoration: none; }
  ul, ol { list-style: none; }
}

/* ─── TOKENS ─────────────────────────────────────────────────── */
@layer tokens {
  :root {
    --bg:        #000;
    --fg:        #F5F5F5;
    --muted:     #888;
    --subtle:    #444;
    --border:    #1f1f1f;
    --accent:    #4DB87E;
    --gutter:    clamp(20px, 5vw, 40px);
    --max-prose: 68ch;
    --r-pill:    999px;
    --dur:       0.2s;
  }

  @media (prefers-color-scheme: light) {
    :root {
      --bg:     #fff;
      --fg:     #0a0a0a;
      --muted:  #555;
      --subtle: #999;
      --border: #e5e5e5;
    }
  }
}

/* ─── BASE ───────────────────────────────────────────────────── */
@layer base {
  html {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    background: var(--bg);
    color: var(--fg);
    -webkit-font-smoothing: antialiased;
    scroll-behavior: smooth;
  }

  body {
    min-height: 100svh;
    display: flex;
    flex-direction: column;
  }

  ::selection { background: var(--accent); color: #fff; }

  .legal-back {
    display: block;
    padding: 22px var(--gutter);
    font-size: 1rem;
    color: var(--subtle);
    width: fit-content;
    line-height: 1;
    transition: color var(--dur);
  }
  .legal-back:hover { color: var(--fg); }

  .legal-foot {
    border-top: 1px solid var(--border);
    padding: 24px var(--gutter);
    display: flex;
    justify-content: center;
  }
  .legal-foot nav { display: flex; align-items: center; gap: 20px; }
  .legal-foot nav a {
    font-size: 0.7rem;
    color: var(--subtle);
    letter-spacing: 0.03em;
    transition: color var(--dur);
  }
  .legal-foot nav a:hover { color: var(--fg); }
}





/* ─── LEGAL PROSE ────────────────────────────────────────────── */
@layer legal {
  .legal-main {
    flex: 1;
    max-width: var(--max-prose);
    width: 100%;
    margin-inline: auto;
    padding: 40px var(--gutter) 80px;
  }
  .meta {
    font-size: 0.8rem;
    color: var(--subtle);
    margin-block: 8px 40px;
  }
  .legal-main h1 {
    font-size: clamp(1.6rem, 5vw, 2.2rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.1;
  }
  .legal-main h2 {
    font-size: 1rem;
    font-weight: 700;
    margin-block: 36px 10px;
    color: var(--fg);
  }
  .legal-main p,
  .legal-main li {
    font-size: 0.9375rem;
    color: var(--muted);
    margin-bottom: 10px;
    line-height: 1.65;
    text-wrap: pretty;
  }
  .legal-main ul {
    list-style: disc;
    padding-left: 20px;
    margin-bottom: 10px;
  }
  .legal-main strong { color: var(--fg); font-weight: 600; }
  .legal-main a { color: var(--accent); }
  .legal-main a:hover { text-decoration: underline; }
}


