/*
  ============================================================================
  LAHAT PRO — shared stylesheet for the public legal documents
  ============================================================================
  Used by every page in frontend/public/legal/. Palette is copied from
  frontend/public/landing.html (the design-system source of truth) so the
  documents read as the same site.

  These pages are plain static files: no build step, no React, no JS required
  to read them. Keep it that way — legal text has to render for a visitor with
  scripting disabled.
  ============================================================================
*/

:root {
  --cream: #f7f2ec;
  --graphite: #2d2c2c;
  --lime: #cedf97;
  --orange: #f48c45;
  --white: #ffffff;
  --line: rgba(45, 44, 44, 0.12);
  --muted: rgba(45, 44, 44, 0.62);
  --faint: rgba(45, 44, 44, 0.4);
  --line-dark: rgba(247, 242, 236, 0.16);
  --muted-dark: rgba(247, 242, 236, 0.66);
  --maxw: 820px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Heebo', system-ui, 'Segoe UI', Arial, sans-serif;
  background: var(--cream);
  color: var(--graphite);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* ── Header ──────────────────────────────────────────────────────────── */

.doc-header {
  background: var(--graphite);
  color: var(--cream);
  padding: 28px 0 24px;
}

.doc-header .logo {
  height: 26px;
  width: auto;
  margin: 0 auto 18px;
}

.doc-header h1 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 800;
  text-align: center;
  line-height: 1.3;
}

.doc-header .lede {
  text-align: center;
  color: var(--muted-dark);
  font-size: 0.95rem;
  margin-top: 8px;
}

/* ── Cross-links between the six documents ───────────────────────────── */

.doc-nav {
  border-bottom: 1px solid var(--line);
  background: var(--white);
  padding: 12px 0;
}

.doc-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.doc-nav a {
  display: inline-block;
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.85rem;
  text-decoration: none;
  color: var(--muted);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.doc-nav a:hover,
.doc-nav a:focus-visible {
  background: var(--graphite);
  border-color: var(--graphite);
  color: var(--lime);
}

.doc-nav a[aria-current='page'] {
  background: var(--graphite);
  border-color: var(--graphite);
  color: var(--lime);
  font-weight: 500;
}

/* ── Body ────────────────────────────────────────────────────────────── */

main {
  padding: 36px 0 56px;
}

section {
  margin-top: 32px;
}

section:first-of-type {
  margin-top: 0;
}

h2 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
}

h3 {
  font-size: 1rem;
  font-weight: 700;
  margin: 20px 0 6px;
}

p {
  margin-bottom: 12px;
}

ul.bullets,
ol.bullets {
  margin: 0 20px 12px 0;
  padding-inline-start: 20px;
}

ul.bullets li,
ol.bullets li {
  margin-bottom: 8px;
}

strong {
  font-weight: 700;
}

/* Emphasised clause — used for the sections a customer must not miss. */
.callout {
  background: var(--white);
  border-inline-start: 3px solid var(--orange);
  border-radius: 6px;
  padding: 16px 18px;
  margin: 0 0 20px;
}

.callout p:last-child {
  margin-bottom: 0;
}

/* ── Tables (warranty tiers, delivery price list) ────────────────────── */

.table-scroll {
  overflow-x: auto;
  margin-bottom: 16px;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: 8px;
  overflow: hidden;
  font-size: 0.92rem;
  min-width: 480px;
}

th,
td {
  text-align: start;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

thead th {
  background: rgba(45, 44, 44, 0.04);
  font-weight: 700;
  font-size: 0.85rem;
}

tbody tr:last-child td {
  border-bottom: 0;
}

td.amount {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* ── Contact block ───────────────────────────────────────────────────── */

.contact {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px 18px;
  margin-top: 20px;
}

.contact a {
  text-decoration: none;
  border-bottom: 1px solid var(--faint);
}

/* ── Footer ──────────────────────────────────────────────────────────── */

.doc-footer {
  border-top: 1px solid var(--line);
  padding: 24px 0 40px;
  color: var(--muted);
  font-size: 0.85rem;
  text-align: center;
}

.doc-footer .updated {
  color: var(--faint);
  margin-top: 6px;
}

.doc-footer a {
  color: var(--muted);
}

/* ── Print ───────────────────────────────────────────────────────────── */

@media print {
  .doc-nav {
    display: none;
  }
  body {
    background: var(--white);
  }
}
