/* ==========================================================================
   Restodoo — the legal documents (privacy.html, legal.html)

   Loaded *after* css/style.css, which supplies every colour, font and easing
   token plus .nav, .footer, .receipt, .btn, .ph-badge and .placeholder. Nothing
   is redefined here; this sheet only adds the long-form document layout the
   landing page has no use for.

   All three languages ship in the HTML. js/legal.js hides the two that are not
   active — with JavaScript off every language stays visible, which is a longer
   page but never an unreadable one, and a legal text must be readable.
   ========================================================================== */

/* ---------- Header ----------
   The landing page's nav starts light over the hero photograph and turns to
   paper on scroll. A document has no hero, so it needs the paper state from
   the first pixel — as its own variant, not as .is-scrolled, which is the
   class js/main.js owns and no document loads. */

.nav--doc {
  position: sticky;
  background: rgba(255, 250, 241, .92);
  backdrop-filter: blur(14px);
  border-color: var(--aub-faint);
  padding-block: .7rem;
  color: var(--aub);
}
.nav--doc .nav__back {
  font-family: var(--font-mono);
  font-size: .74rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--aub-dim);
  transition: color .3s;
}
.nav--doc .nav__back:hover { color: var(--orange-deep); }

/* ---------- Document ---------- */

.doc {
  max-width: 48rem;
  margin: 0 auto;
  padding: clamp(2.5rem, 6vw, 5rem) var(--pad) 4rem;
}

/* Only one of these is shown at a time — see js/legal.js. */
.doc__lang[hidden] { display: none; }

.doc__label {
  font-family: var(--font-mono);
  font-size: .74rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--orange-deep);
}
.doc__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.1rem, 1.4rem + 3.4vw, 3.6rem);
  line-height: 1.04;
  letter-spacing: -.01em;
  margin-top: .7rem;
}
.doc__lede {
  font-size: 1.12em;
  color: var(--aub-soft);
  margin-top: 1.2rem;
  max-width: 34rem;
}
.doc__updated {
  font-family: var(--font-mono);
  font-size: .78rem;
  color: var(--aub-dim);
  margin-top: 1.6rem;
}

/* The short version, set as a till receipt — because almost nobody reads the
   long version, and the summary is the part that changes someone's mind about
   filling the form in. */
.doc__gist {
  margin-top: 2.4rem;
  padding: 2rem clamp(1.2rem, 4vw, 2.2rem);
}
.doc__gist h2 {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: .74rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--aub-dim);
}
.doc__gist ul { list-style: none; margin-top: 1.1rem; }
.doc__gist li {
  display: flex;
  gap: .8rem;
  padding: .6rem 0;
  font-size: .98rem;
  line-height: 1.55;
}
.doc__gist li + li { border-top: 1.5px dashed var(--aub-faint); }
.doc__gist li::before {
  content: "·";
  flex: none;
  font-family: var(--font-mono);
  color: var(--orange);
  font-size: 1.4rem;
  line-height: 1;
}

/* ---------- Sections ---------- */

.doc section {
  margin-top: 3.4rem;
  padding-top: 2.4rem;
  border-top: 1.5px dashed var(--aub-faint);
  scroll-margin-top: 6rem;
}
.doc section > h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.4rem, 1.15rem + .8vw, 1.85rem);
  line-height: 1.18;
  /* The number sits in the margin on wide screens and inline on narrow ones. */
  display: flex;
  gap: .8rem;
  align-items: baseline;
}
.doc section > h2 .num {
  font-family: var(--font-mono);
  font-size: .8rem;
  font-weight: 400;
  color: var(--orange-deep);
  flex: none;
}
.doc h3 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.02rem;
  margin-top: 1.8rem;
}
.doc p { margin-top: 1rem; }
.doc p:first-child { margin-top: 0; }
.doc a:not(.btn):not(.nav__back) {
  color: var(--orange-deep);
  text-decoration-thickness: 1px;
  text-underline-offset: .18em;
}
.doc strong { font-weight: 600; }

.doc ul, .doc ol { margin-top: 1rem; padding-left: 1.4rem; }
.doc li { margin-top: .5rem; }
.doc li > ul { margin-top: .4rem; }

/* Definition-style rows for "who we are" and the retention table — the same
   dotted leader the bill and the pricing receipts use. */
.facts { list-style: none; margin-top: 1.2rem; padding: 0; }
.facts li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0 .6rem;
  padding: .55rem 0;
  border-bottom: 1.5px dashed var(--aub-faint);
  margin-top: 0;
}
.facts dt, .facts .k {
  font-family: var(--font-mono);
  font-size: .76rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--aub-dim);
  flex: none;
}
.facts .v { font-size: .98rem; }

/* Processors, retention periods — a real table, because the columns are the
   information. Scrolls inside itself rather than pushing the page sideways. */
.doc__table { margin-top: 1.4rem; overflow-x: auto; }
.doc__table table {
  width: 100%;
  min-width: 34rem;
  border-collapse: collapse;
  font-size: .94rem;
}
.doc__table th, .doc__table td {
  text-align: left;
  vertical-align: top;
  padding: .7rem .9rem .7rem 0;
  border-bottom: 1.5px dashed var(--aub-faint);
}
.doc__table th {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: .72rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--aub-dim);
  white-space: nowrap;
}
.doc__table td:first-child { font-weight: 600; white-space: nowrap; }

/* A framed aside for the things a reader should not skim past. */
.doc__note {
  margin-top: 1.6rem;
  padding: 1.2rem 1.4rem;
  background: var(--orange-soft);
  border-left: 3px solid var(--orange);
  border-radius: 0 6px 6px 0;
  font-size: .96rem;
}
.doc__note p:first-child { margin-top: 0; }

/* ---------- Foot of the document ---------- */

.doc__end {
  margin-top: 3.4rem;
  padding-top: 2.4rem;
  border-top: 1.5px dashed var(--aub-faint);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.6rem;
}
.doc__end p { margin: 0; color: var(--aub-dim); font-size: .94rem; }

@media (max-width: 560px) {
  .doc section > h2 { flex-direction: column; gap: .3rem; }
  .nav--doc .nav__back span { display: none; }
}
