/* HavaBee — shared shell for the legal pages (privacy, terms, refunds) */

:root {
  --honey: #ffc400;
  --honey-deep: #f0a500;

  --bg: #fdfbf6;
  --bg-sunk: #f6f1e6;
  --surface: #ffffff;
  --border: #e9e0cd;
  --border-strong: #d9cdb2;
  --text: #1b1408;
  --text-muted: #6d6150;
  --text-faint: #9b8f7c;
  --accent-text: #9a6800;

  --r-md: .875rem;
  --r-full: 999px;

  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Outfit', 'Inter', -apple-system, sans-serif;

  --step--1: clamp(.8125rem, .79rem + .12vw, .875rem);
  --step-0: clamp(.9375rem, .91rem + .14vw, 1.0625rem);
  --step-1: clamp(1.0625rem, 1rem + .3vw, 1.25rem);
  --step-2: clamp(1.25rem, 1.13rem + .6vw, 1.625rem);
  --step-3: clamp(1.75rem, 1.45rem + 1.5vw, 2.75rem);

  --gutter: clamp(1.25rem, 5vw, 3rem);
  --measure: 44rem;
  --ease: cubic-bezier(.16, 1, .3, 1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0f0c08;
    --bg-sunk: #0a0806;
    --surface: #191309;
    --border: #33291a;
    --border-strong: #4a3c25;
    --text: #f6f0e3;
    --text-muted: #ab9c83;
    --text-faint: #7b6e59;
    --accent-text: #ffc94d;
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0f0c08;
  --bg-sunk: #0a0806;
  --surface: #191309;
  --border: #33291a;
  --border-strong: #4a3c25;
  --text: #f6f0e3;
  --text-muted: #ab9c83;
  --text-faint: #7b6e59;
  --accent-text: #ffc94d;
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  width: 100%;
  max-width: var(--measure);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* header */
.legal-header {
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.legal-header .wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 4.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  margin-right: auto;
}

.brand img {
  height: 24px;
  width: auto;
  display: block;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand img {
    filter: brightness(0) invert(1) sepia(1) saturate(6) hue-rotate(-14deg) brightness(1.05);
  }
}

:root[data-theme="dark"] .brand img {
  filter: brightness(0) invert(1) sepia(1) saturate(6) hue-rotate(-14deg) brightness(1.05);
}

.back {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: var(--step--1);
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  padding: .5rem .875rem;
  border: 1px solid var(--border);
  border-radius: var(--r-full);
  transition: color .18s var(--ease), border-color .18s var(--ease);
}

.back:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

.back svg {
  width: 14px;
  height: 14px;
}

/* document */
main {
  padding-block: clamp(2.5rem, 6vw, 4.5rem) clamp(3rem, 7vw, 5rem);
}

main h1,
main h2,
main h3 {
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: -.02em;
  text-wrap: balance;
}

main h1 {
  font-size: var(--step-3);
  font-weight: 700;
  margin: 0 0 .5rem;
}

.updated {
  color: var(--text-faint);
  font-size: var(--step--1);
  margin: 0 0 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

main h2 {
  font-size: var(--step-2);
  font-weight: 600;
  margin: 2.75rem 0 .75rem;
}

main h2 strong {
  font-weight: inherit;
}

main h3 {
  font-size: var(--step-1);
  font-weight: 600;
  margin: 2rem 0 .5rem;
}

main p {
  margin: 0 0 1.1rem;
  color: var(--text-muted);
  text-wrap: pretty;
}

main ul,
main ol {
  margin: 0 0 1.25rem;
  padding-left: 1.25rem;
  color: var(--text-muted);
}

main li {
  margin-bottom: .4rem;
}

main li::marker {
  color: var(--honey-deep);
}

main a {
  color: var(--accent-text);
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

main strong,
main b {
  color: var(--text);
  font-weight: 600;
}

:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(255, 196, 0, .45);
  border-radius: .5rem;
}

/* footer */
footer {
  border-top: 1px solid var(--border);
  padding-block: 2rem 2.5rem;
}

footer .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .75rem 1.5rem;
  font-size: var(--step--1);
  color: var(--text-faint);
}

footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: .25rem 1.25rem;
  list-style: none;
  margin: 0 0 0 auto;
  padding: 0;
}

footer a {
  color: var(--text-muted);
  text-decoration: none;
}

footer a:hover {
  color: var(--text);
  text-decoration: underline;
}
