/* Shared styles for the legal pages (privacy.html, terms.html).
   Plain CSS on purpose: Tailwind's arbitrary-value classes contain square brackets,
   which would clutter a search for "[" when looking for placeholders. */

:root {
  --walnut: #35221A;
  --espresso: #1F1511;
  --parchment: #F5F0EB;
  --sand: #E3D9CB;
  /* logo lettering (logo-light.png): text on dark backgrounds */
  --copper: #C98B6B;
  --faded-copper: #99715D;
  --ink-soft: rgb(31 21 17 / .78);
  --line: rgb(31 21 17 / .15);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  margin: 0;
  background: var(--espresso);
  color: var(--espresso);
  font-family: "Manrope", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 3px;
}

/* Bigger tap areas without changing the look: an invisible layer reaching past the edges by --tap */
.header-logo,
.header-nav a,
.cta,
.menu-toggle,
.footer-submit,
.footer-nav a,
.footer-social-item,
.footer-legal a {
  position: relative;
}

.header-logo::after,
.header-nav a::after,
.cta::after,
.menu-toggle::after,
.footer-submit::after,
.footer-nav a::after,
.footer-social-item::after,
.footer-legal a::after {
  content: '';
  position: absolute;
  inset: var(--tap);
}

.header-logo { --tap: -6px 0; }
.header-nav a { --tap: -12px -10px; }
.cta { --tap: -2px 0; }
.menu-toggle { --tap: -10px; }
.footer-submit { --tap: -2px; }
.footer-nav a { --tap: -4px -10px; } /* the full 26px row */
.footer-social-item { --tap: -12.5px -8px; } /* half the 16px gap each side */
.footer-legal a { --tap: -13px -12px; } /* half the 24px gap each side */

/* Helpers used by waitlist.js */
.hidden {
  display: none !important;
}

.text-copper {
  color: var(--copper);
}

.text-parchment {
  color: var(--parchment);
}

.text-sand {
  color: var(--sand);
}

.text-espresso {
  color: var(--espresso);
}

.mt-3 {
  margin-top: 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Header (same as the home page once scrolled) ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  background: var(--parchment);
  color: var(--espresso);
  box-shadow: 0 1px 0 rgb(31 21 17 / .08);
}

.header-inner {
  height: 56px;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-logo {
  flex-shrink: 0;
}

.header-logo img {
  height: 32px;
  width: auto;
}

.header-nav {
  display: none;
}

.header-nav ul {
  display: flex;
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
}

.header-nav a,
.footer a {
  text-decoration: none;
  transition: color .2s;
}

.header-nav a:hover,
.footer a:hover {
  color: var(--copper);
}

.header-cta-wrap {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.cta {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 20px;
  border-radius: 999px;
  background: var(--faded-copper);
  color: var(--parchment);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: background-color .2s, color .2s;
}

.cta:hover {
  background: var(--espresso);
  color: var(--sand);
}

/* Smallest phones: a slightly smaller logo and button so the menu button fits beside them */
@media (max-width: 359px) {
  .header-logo img {
    height: 30px;
  }

  .cta {
    padding: 0 14px;
    font-size: 14px;
  }
}

/* Phone menu (nav.js): a button in the header opens the links under the bar */
.menu-toggle {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
}

.menu-toggle .menu-icon-close,
.menu-toggle[aria-expanded="true"] .menu-icon-open {
  display: none;
}

.menu-toggle[aria-expanded="true"] .menu-icon-close {
  display: block;
}

.mobile-menu {
  background: var(--parchment);
  box-shadow: 0 12px 24px rgb(31 21 17 / .12);
}

.mobile-menu ul {
  margin: 0;
  padding: 0 16px 12px;
  list-style: none;
  font-size: 16px;
  font-weight: 500;
}

.mobile-menu a {
  display: flex;
  align-items: center;
  height: 52px;
  border-top: 1px solid var(--line);
  text-decoration: none;
}

@media (min-width: 768px) {
  .header-inner {
    padding: 0 24px;
  }

  .header-logo,
  .header-cta-wrap {
    flex: 1;
  }

  .header-logo img {
    height: 36px;
  }

  .header-nav {
    display: block;
  }

  .menu-toggle,
  .mobile-menu {
    display: none;
  }
}

/* ---------- Page ---------- */
.legal {
  background: var(--parchment);
  padding: 104px 16px 96px;
}

.legal-inner {
  max-width: 680px;
  margin: 0 auto;
}

/* ~75 characters per line */
.legal-title {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 300;
  font-size: 40px;
  line-height: 1;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}

.legal-meta {
  margin: 16px 0 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink-soft);
}

.legal-meta span {
  white-space: nowrap;
}

@media (min-width: 768px) {
  .legal {
    padding: 120px 56px 128px;
  }

  .legal-title {
    font-size: 56px;
  }
}

/* Placeholders: highlighted so they're easy to spot as well as to search for */
.ph {
  background: rgb(201 139 107 / .22);
  color: var(--espresso);
  padding: 0 .2em;
  border-radius: 3px;
  font-weight: 600;
}

.legal-note {
  margin: 20px 0;
  padding: 16px 18px;
  border: 1px dashed var(--faded-copper);
  border-radius: 6px;
  font-size: 15px;
  line-height: 1.6;
  background: rgb(201 139 107 / .08);
}

/* "In plain terms" box */
.summary {
  margin: 40px 0 0;
  padding: 28px 28px 24px;
  border-radius: 8px;
  background: var(--espresso);
  color: var(--sand);
}

.summary h2 {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgb(227 217 203 / .7);
}

.summary ul {
  margin: 16px 0 0;
  padding-left: 20px;
}

.summary li {
  margin: 8px 0;
  font-size: 16px;
  line-height: 1.6;
}

.summary li::marker {
  color: var(--copper);
}

.summary p {
  margin: 16px 0 0;
  font-size: 13px;
  color: rgb(227 217 203 / .7);
}

.summary .ph {
  background: rgb(201 139 107 / .35);
  color: var(--sand);
}

/* Table of contents */
.toc {
  margin: 48px 0 0;
  padding: 24px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.toc h2 {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.toc ol {
  margin: 0;
  padding-left: 22px;
  font-size: 15px;
  line-height: 1.5;
}

.toc li {
  margin: 0;
  padding: 3px 0;
  break-inside: avoid;
}

/* padding, not margin, so both columns start level */
.toc a {
  text-decoration: none;
}

.toc a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (min-width: 768px) {
  .toc ol {
    columns: 2;
    column-gap: 40px;
  }
}

/* Body text */
.legal-body {
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink-soft);
}

.legal-body section {
  padding-top: 48px;
}

.legal-body h2 {
  margin: 0 0 16px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 400;
  font-size: 30px;
  line-height: 1.15;
  color: var(--espresso);
}

.legal-body h3 {
  margin: 28px 0 8px;
  font-size: 17px;
  font-weight: 600;
  color: var(--espresso);
}

.legal-body p {
  margin: 0 0 16px;
}

.legal-body ul,
.legal-body ol {
  margin: 0 0 16px;
  padding-left: 22px;
}

.legal-body li {
  margin: 6px 0;
}

.legal-body strong {
  color: var(--espresso);
  font-weight: 600;
}

.legal-body a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-body a:hover {
  color: var(--espresso);
}

.contact-block {
  margin: 0 0 16px;
  padding: 16px 20px;
  border-left: 3px solid var(--faded-copper);
  background: rgb(31 21 17 / .04);
}

.contact-block p {
  margin: 4px 0;
}

/* Tables (scroll sideways on small screens) */
.table-wrap {
  overflow-x: auto;
  margin: 0 0 16px;
}

.legal-body table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 15px;
  line-height: 1.55;
}

.legal-body th,
.legal-body td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}

.legal-body th {
  color: var(--espresso);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: .04em;
}

.back-to-top {
  margin-top: 56px;
  font-size: 14px;
}

/* ---------- Footer (same as the home page) ---------- */
.footer {
  background: var(--espresso);
  color: var(--sand);
}

.footer-inner {
  padding: 40px 15px 24px;
}

.footer-row {
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.footer-label {
  display: block;
  font-size: 15px;
  line-height: 1;
}

.footer-fields {
  margin-top: 18px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--parchment);
}

.footer-input {
  flex: 1;
  min-width: 0;
  height: 42px;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--sand);
  font: inherit;
  font-size: 16px;
  /* under 16px, iPhones zoom in on focus */
}

.footer-input:focus {
  outline: none;
}

.footer-input::placeholder {
  color: rgb(227 217 203 / .7);
}

.footer-submit {
  padding: 8px;
  margin-right: 4px;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
  transition: color .2s;
}

.footer-submit:hover {
  color: var(--copper);
}

.footer-submit:disabled {
  opacity: .5;
  cursor: progress;
}

.footer-consent {
  margin: 12px 0 0;
  font-size: 12px;
  line-height: 1.6;
  color: rgb(227 217 203 / .7);
}

.footer-consent a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.wl-message {
  font-size: 15px;
}

.wl-message:focus {
  outline: none;
}

.footer-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  font-size: 15px;
}

.footer-nav h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 400;
  line-height: 1;
}

.footer-nav ul {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.footer-nav li {
  font-size: 13px;
  line-height: 26px;
}

.footer-social {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.footer-social-item {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: default;
  color: inherit;
  opacity: 0.8;
  transition: opacity 0.2s, color 0.2s;
}

.footer-social-item:hover,
.footer-social-item:focus-visible,
.footer-social-item.is-tip {
  opacity: 1;
  color: var(--copper);
}

.footer-social-tooltip {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  background: var(--parchment);
  color: var(--espresso);
  font-family: "Manrope", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 4px;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s ease, transform 0.15s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  z-index: 10;
}

.footer-social-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 4px;
  border-style: solid;
  border-color: var(--parchment) transparent transparent transparent;
}

.footer-social-item:hover .footer-social-tooltip,
.footer-social-item:focus-visible .footer-social-tooltip,
.footer-social-item.is-tip .footer-social-tooltip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Leftmost icon (LinkedIn) tooltip pinned to left so it never cuts off on mobile/narrow screens */
.footer-social-item:first-child .footer-social-tooltip {
  left: 0;
  right: auto;
  transform: translateY(4px);
}

.footer-social-item:first-child .footer-social-tooltip::after {
  left: 8px;
  right: auto;
  transform: none;
}

.footer-social-item:first-child:hover .footer-social-tooltip,
.footer-social-item:first-child:focus-visible .footer-social-tooltip,
.footer-social-item:first-child.is-tip .footer-social-tooltip {
  transform: translateY(0);
}

/* Rightmost icon (YouTube) tooltip pinned to right so it never cuts off on desktop/right edge */
.footer-social-item:last-child .footer-social-tooltip {
  left: auto;
  right: 0;
  transform: translateY(4px);
}

.footer-social-item:last-child .footer-social-tooltip::after {
  left: auto;
  right: 8px;
  transform: none;
}

.footer-social-item:last-child:hover .footer-social-tooltip,
.footer-social-item:last-child:focus-visible .footer-social-tooltip,
.footer-social-item:last-child.is-tip .footer-social-tooltip {
  transform: translateY(0);
}

.footer-mark {
  margin: 64px auto 0;
  height: 112px;
  width: auto;
}

.footer-legal {
  margin-top: 48px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 13px;
}

.footer-legal ul {
  display: flex;
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-legal p {
  margin: 0;
}

.footer-legal a {
  text-decoration: none;
}

.footer-legal a.is-current {
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (min-width: 1024px) {
  .footer-row {
    flex-direction: row;
    align-items: flex-start;
    gap: 0;
    min-height: 170px;
  }

  .footer-waitlist {
    width: 293px;
    flex-shrink: 0;
  }

  .footer-nav {
    display: flex;
    margin: 10px 0 0 clamp(24px, 12vw, 223px);
  }

  .footer-nav>div {
    width: 208px;
  }

  .footer-social {
    margin: 4px 0 0 auto;
    flex-shrink: 0;
  }

  .footer-mark {
    margin-top: -8px;
  }

  .footer-legal {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}