/* Shared styling for the legal pages (terms, privacy, refunds).
 *
 * These are plain static documents — no dc-runtime, no React, no component
 * bundle. They only need the design system's tokens and fonts, which come from
 * _ds/…/styles.css, so every colour and space below resolves to a --nu-* value
 * and the pages stay in step with the landing page automatically.
 *
 * Unlike index.html, nothing here is owned by Claude Design: these files are
 * ours and a re-pull will not touch them.
 */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--nu-color-bg);
  color: var(--nu-color-text);
  font-family: var(--nu-font-sans);
  font-size: var(--nu-text-base);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* Matches the landing page: taps fire controls rather than starting a
 * selection, but body copy here stays selectable — people legitimately copy
 * clauses out of a terms page. */
* {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: var(--nu-color-brand-text);
  text-decoration: none;
}

a:hover {
  color: var(--nu-color-text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

:where(a, button, summary):focus-visible {
  outline: 2px solid var(--nu-color-focus);
  outline-offset: 3px;
}

/* ------------------------------------------------------------------ shell */

.l-shell {
  width: 100%;
  max-width: 760px;
  margin-inline: auto;
  padding-inline: var(--nu-space-6);
}

@media (max-width: 640px) {
  .l-shell {
    padding-inline: var(--nu-space-5);
  }
}

/* ----------------------------------------------------------------- header */

.l-top {
  border-bottom: 1px solid var(--nu-color-border);
  background: var(--nu-color-surface);
}

.l-top__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--nu-space-4);
  min-height: var(--nu-space-16);
  padding-block: var(--nu-space-3);
}

.l-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--nu-space-3);
  color: var(--nu-color-text);
  text-decoration: none;
}

.l-brand:hover {
  color: var(--nu-color-text);
  text-decoration: none;
}

/* The mark SVG carries 0.35x clearspace on every side, so the visible glyph is
 * about 59% of the box — size for the glyph, not the box. */
.l-brand img {
  width: 38px;
  height: 38px;
  display: block;
}

.l-brand span {
  font-family: var(--nu-font-display);
  font-size: var(--nu-text-xl);
  font-weight: var(--nu-weight-bold);
  letter-spacing: -0.03em;
}

.l-back {
  font-family: var(--nu-font-mono);
  font-size: var(--nu-text-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nu-color-text-subtle);
}

/* ------------------------------------------------------------------- page */

.l-main {
  padding-block: clamp(var(--nu-space-12), 8vw, var(--nu-space-20));
}

.l-title {
  margin: 0;
  font-family: var(--nu-font-display);
  font-size: clamp(2.25rem, 6vw, 3.25rem);
  font-weight: var(--nu-weight-bold);
  line-height: 1.05;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.l-updated {
  margin: var(--nu-space-4) 0 0;
  font-family: var(--nu-font-mono);
  font-size: var(--nu-text-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nu-color-text-subtle);
}

.l-rule {
  width: 40px;
  height: 3px;
  margin: var(--nu-space-8) 0 0;
  border: 0;
  border-radius: var(--nu-radius-full);
  background: var(--nu-color-brand);
}

/* Lede paragraph, used for the "short version" style openers. */
.l-lede {
  margin: var(--nu-space-8) 0 0;
  font-size: var(--nu-text-lg);
  line-height: 1.6;
  color: var(--nu-color-text-muted);
  text-wrap: pretty;
}

/* --------------------------------------------------------------- sections */

.l-body h2 {
  margin: clamp(var(--nu-space-10), 6vw, var(--nu-space-16)) 0 var(--nu-space-4);
  font-family: var(--nu-font-display);
  font-size: clamp(var(--nu-text-xl), 3.2vw, var(--nu-text-2xl));
  font-weight: var(--nu-weight-bold);
  line-height: 1.2;
  letter-spacing: -0.02em;
  scroll-margin-top: var(--nu-space-8);
}

.l-body h2 .l-num {
  color: var(--nu-color-text-subtle);
  font-family: var(--nu-font-mono);
  font-size: 0.7em;
  font-weight: var(--nu-weight-medium);
  margin-inline-end: var(--nu-space-2);
}

.l-body h3 {
  margin: var(--nu-space-8) 0 var(--nu-space-3);
  font-family: var(--nu-font-display);
  font-size: var(--nu-text-lg);
  font-weight: var(--nu-weight-bold);
  letter-spacing: -0.01em;
}

.l-body p {
  margin: 0 0 var(--nu-space-4);
  color: var(--nu-color-text-muted);
  text-wrap: pretty;
}

.l-body strong {
  color: var(--nu-color-text);
  font-weight: var(--nu-weight-semibold);
}

.l-body em {
  font-style: italic;
}

.l-body ul {
  margin: 0 0 var(--nu-space-4);
  padding-inline-start: var(--nu-space-5);
  color: var(--nu-color-text-muted);
}

.l-body li {
  margin-bottom: var(--nu-space-2);
}

.l-body li::marker {
  color: var(--nu-color-brand-text);
}

/* A block that needs to be impossible to miss — the auto-charge clause, the
 * "we don't sell your data" line. Used sparingly. */
.l-callout {
  margin: var(--nu-space-6) 0;
  padding: var(--nu-space-5) var(--nu-space-6);
  border: 1px solid var(--nu-color-brand-border);
  border-inline-start: 3px solid var(--nu-color-brand);
  border-radius: var(--nu-radius-lg);
  background: color-mix(in oklab, var(--nu-color-brand) 8%, var(--nu-color-surface));
}

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

.l-callout p {
  color: var(--nu-color-text);
}

/* ----------------------------------------------------------------- tables */

/* Wide tables must scroll inside their own box rather than making the page
 * scroll sideways on a phone. */
.l-tablewrap {
  margin: 0 0 var(--nu-space-6);
  overflow-x: auto;
  border: 1px solid var(--nu-color-border);
  border-radius: var(--nu-radius-lg);
  background: var(--nu-color-surface);
}

.l-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--nu-text-sm);
}

.l-table th,
.l-table td {
  padding: var(--nu-space-3) var(--nu-space-4);
  text-align: start;
  border-bottom: 1px solid var(--nu-color-border);
  vertical-align: top;
}

.l-table thead th {
  font-family: var(--nu-font-mono);
  font-size: var(--nu-text-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--nu-color-text-subtle);
  font-weight: var(--nu-weight-medium);
  background: var(--nu-color-surface-sunken);
  white-space: nowrap;
}

.l-table tbody tr:last-child th,
.l-table tbody tr:last-child td {
  border-bottom: 0;
}

.l-table tbody th {
  font-weight: var(--nu-weight-semibold);
  color: var(--nu-color-text);
}

.l-table td {
  color: var(--nu-color-text-muted);
}

/* ---------------------------------------------------------------- address */

.l-address {
  margin: 0 0 var(--nu-space-4);
  padding: var(--nu-space-5) var(--nu-space-6);
  border: 1px solid var(--nu-color-border);
  border-radius: var(--nu-radius-lg);
  background: var(--nu-color-surface);
  font-style: normal;
  line-height: 1.7;
  color: var(--nu-color-text-muted);
}

.l-address strong {
  display: block;
  color: var(--nu-color-text);
}

/* ----------------------------------------------------------------- footer */

.l-foot {
  margin-top: clamp(var(--nu-space-12), 8vw, var(--nu-space-20));
  padding-block: var(--nu-space-10);
  border-top: 1px solid var(--nu-color-border);
  background: var(--nu-color-surface);
}

.l-foot__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--nu-space-4) var(--nu-space-6);
}

.l-foot__links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--nu-space-2) var(--nu-space-5);
  font-family: var(--nu-font-mono);
  font-size: var(--nu-text-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.l-foot__links a {
  color: var(--nu-color-text-subtle);
}

.l-foot__links a[aria-current='page'] {
  color: var(--nu-color-text);
}

.l-foot__meta {
  font-family: var(--nu-font-mono);
  font-size: var(--nu-text-xs);
  letter-spacing: 0.08em;
  color: var(--nu-color-text-subtle);
}
