/* Shared presentation for Privacy, Terms, and Account Deletion pages. */

.page-legal {
  --legal-ink: #080807;
  --legal-ink-soft: #171716;
  --legal-paper: #f5eee6;
  --legal-white: #fffdfa;
  --legal-coral: #ff6d5f;
  --legal-blue: #b9cadd;
  --legal-yellow: #ffd148;
  --legal-green: #67d871;
  --legal-border: #d9d3cc;
  --legal-muted: #615d58;
  --legal-accent: var(--legal-coral);
  --font-display: "Space Grotesk", sans-serif;
  --font-body: "DM Sans", sans-serif;
  min-height: 100vh;
  background: var(--legal-white);
  color: var(--legal-ink);
  font-family: var(--font-body);
}

.page-terms {
  --legal-accent: var(--legal-blue);
}

.page-deletion {
  --legal-accent: var(--legal-yellow);
}

.page-legal h1,
.page-legal h2,
.page-legal h3 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0;
}

.page-legal p,
.page-legal a,
.page-legal li,
.page-legal span,
.page-legal small,
.page-legal strong {
  letter-spacing: 0;
}

.page-legal .container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding-inline: 32px;
}

.page-legal :focus-visible {
  outline-color: var(--legal-accent);
}

.legal-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8, 8, 7, 0.92);
  border-bottom: 1px solid rgba(255, 253, 250, 0.16);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.legal-header .nav-shell {
  height: 72px;
}

.legal-brand {
  min-width: max-content;
  gap: 10px;
}

.page-legal .brand-icon {
  width: 42px;
  height: 42px;
  overflow: hidden;
  border: 1px solid rgba(255, 253, 250, 0.18);
  border-radius: 8px;
  background: var(--legal-paper);
}

.page-legal .brand-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-legal .brand-lockup {
  display: grid;
  grid-template-columns: auto 6px auto;
  align-items: center;
  gap: 8px;
  color: var(--legal-white);
  line-height: 1;
}

.page-legal .brand-lockup strong {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
}

.page-legal .brand-lockup > span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.page-legal .brand-lockup small {
  font-size: 8px;
  font-weight: 700;
  line-height: 1.05;
}

.page-legal .legal-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.page-legal .legal-nav a {
  padding: 9px 12px;
  color: rgba(255, 253, 250, 0.66);
  border-bottom: 2px solid transparent;
  font-size: 13px;
  font-weight: 600;
  transition: color 180ms ease, border-color 180ms ease;
}

.page-legal .legal-nav a:hover {
  color: var(--legal-white);
}

.page-legal .legal-nav a[aria-current="page"] {
  color: var(--legal-white);
  border-color: var(--legal-accent);
}

.page-legal .nav-toggle {
  border-color: rgba(255, 253, 250, 0.16);
  border-radius: 6px;
}

.page-legal .nav-toggle span {
  background: var(--legal-white);
}

.legal-main {
  background: var(--legal-white);
}

.legal-hero {
  position: relative;
  overflow: hidden;
  background: var(--legal-paper);
  border-bottom: 1px solid var(--legal-border);
}

.legal-hero::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 10px;
  background: var(--legal-accent);
}

.legal-hero .container {
  min-height: 450px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 250px;
  grid-template-rows: auto auto auto;
  align-content: center;
  column-gap: 90px;
  padding-top: 66px;
  padding-bottom: 66px;
}

.legal-hero .container::after {
  content: "";
  grid-column: 2;
  grid-row: 1 / 4;
  align-self: center;
  width: 250px;
  height: 250px;
  border: 1px solid rgba(8, 8, 7, 0.16);
  border-radius: 8px;
  background: var(--legal-paper) url("assets/app-icon.png") center / cover no-repeat;
  box-shadow: 16px 16px 0 var(--legal-accent);
}

.legal-hero .eyebrow {
  grid-column: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  color: #4d4945;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.legal-hero .eyebrow::before {
  content: "";
  width: 32px;
  height: 2px;
  background: var(--legal-accent);
}

.legal-hero h1 {
  grid-column: 1;
  max-width: 800px;
  font-size: 70px;
  line-height: 0.98;
}

.legal-intro {
  grid-column: 1;
  max-width: 720px;
  margin-top: 26px;
  color: var(--legal-muted);
  font-size: 19px;
  line-height: 1.7;
}

.legal-section {
  padding: 88px 0 128px;
  background: var(--legal-white);
}

.legal-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 760px);
  justify-content: space-between;
  gap: 80px;
  align-items: start;
}

.legal-toc {
  position: sticky;
  top: 110px;
  padding-top: 22px;
  border-top: 3px solid var(--legal-accent);
}

.legal-toc > p {
  margin-bottom: 16px;
  color: var(--legal-muted);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.legal-toc a {
  display: block;
  padding: 10px 0;
  color: #605c57;
  border-bottom: 1px solid #e7e2dc;
  font-size: 13px;
  line-height: 1.35;
  transition: color 180ms ease, padding-left 180ms ease;
}

.legal-toc a:hover {
  padding-left: 6px;
  color: var(--legal-ink);
}

.legal-content {
  min-width: 0;
}

.page-legal .legal-content.reveal {
  opacity: 1;
  transform: none;
  transition: none;
}

.legal-block {
  scroll-margin-top: 112px;
  margin-bottom: 52px;
  padding-bottom: 52px;
  border-bottom: 1px solid var(--legal-border);
}

.legal-block:last-child {
  margin-bottom: 0;
}

.legal-block h2 {
  margin-bottom: 24px;
  font-size: 32px;
  line-height: 1.18;
}

.legal-block h3 {
  margin: 30px 0 12px;
  font-size: 19px;
  line-height: 1.3;
}

.legal-block p,
.legal-block li {
  color: #4f4b47;
  font-size: 16px;
  line-height: 1.8;
}

.legal-block p + p {
  margin-top: 18px;
}

.legal-block ul,
.legal-block ol {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.legal-block ul li {
  position: relative;
  padding-left: 26px;
}

.legal-block ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 13px;
  width: 12px;
  height: 2px;
  background: var(--legal-accent);
}

.legal-block ol {
  list-style: none;
  counter-reset: legal-step;
  padding: 0;
}

.legal-block ol li {
  position: relative;
  min-height: 36px;
  padding-left: 52px;
  counter-increment: legal-step;
}

.legal-block ol li::before {
  content: counter(legal-step);
  position: absolute;
  left: 0;
  top: 1px;
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--legal-ink);
  color: var(--legal-white);
  font-size: 12px;
  font-weight: 700;
}

.legal-block a {
  color: #bd3f34;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.legal-block a:hover {
  color: var(--legal-ink);
}

.legal-note {
  margin-top: 26px !important;
  padding: 24px 26px;
  border-left: 5px solid var(--legal-blue);
  background: #edf3f8;
  color: #373d42 !important;
}

.page-deletion .legal-content .legal-block:first-child {
  padding: 32px;
  border: 1px solid #e0c762;
  border-left: 6px solid var(--legal-yellow);
  background: #fff9dc;
}

.page-deletion .legal-content .legal-block:first-child h2 {
  font-size: 29px;
}

.legal-footer {
  padding: 44px 0;
  background: var(--legal-ink);
  border-top: 0;
}

.legal-footer .footer-grid {
  align-items: flex-start;
  gap: 34px;
}

.footer-title {
  color: var(--legal-white);
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
}

.footer-copy {
  max-width: 340px;
  margin-top: 8px;
  color: rgba(255, 253, 250, 0.58);
  font-size: 13px;
  line-height: 1.55;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.footer-links a {
  color: rgba(255, 253, 250, 0.68);
  font-size: 13px;
}

.footer-links a:hover {
  color: var(--legal-white);
}

.legal-footer .footer-meta {
  color: rgba(255, 253, 250, 0.5);
}

@media (max-width: 900px) {
  .legal-hero .container {
    grid-template-columns: minmax(0, 1fr) 190px;
    column-gap: 50px;
  }

  .legal-hero .container::after {
    width: 190px;
    height: 190px;
    box-shadow: 12px 12px 0 var(--legal-accent);
  }

  .legal-hero h1 {
    font-size: 58px;
  }

  .legal-layout {
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 50px;
  }
}

@media (max-width: 720px) {
  .page-legal .container {
    padding-inline: 18px;
  }

  .legal-header .nav-shell {
    height: 66px;
  }

  .page-legal .brand-icon {
    width: 38px;
    height: 38px;
  }

  .page-legal .brand-lockup strong {
    font-size: 25px;
  }

  .page-legal .legal-nav {
    position: absolute;
    top: 66px;
    left: 0;
    right: 0;
    display: none;
    align-items: stretch;
    gap: 2px;
    padding: 14px 18px 18px;
    background: rgba(8, 8, 7, 0.98);
    border-bottom: 1px solid rgba(255, 253, 250, 0.16);
  }

  .page-legal .legal-nav.is-open {
    display: flex;
  }

  .page-legal .legal-nav a {
    width: 100%;
    padding: 11px 0;
  }

  .legal-hero .container {
    min-height: 410px;
    display: block;
    padding-top: 70px;
    padding-bottom: 70px;
  }

  .legal-hero .container::after {
    display: none;
  }

  .legal-hero h1 {
    font-size: 48px;
  }

  .legal-intro {
    margin-top: 22px;
    font-size: 16px;
  }

  .legal-section {
    padding: 58px 0 88px;
  }

  .legal-layout {
    display: block;
  }

  .legal-toc {
    position: static;
    display: flex;
    gap: 22px;
    margin-bottom: 58px;
    padding: 18px 0;
    overflow-x: auto;
    border-top-width: 2px;
    border-bottom: 1px solid var(--legal-border);
    scrollbar-width: none;
  }

  .legal-toc::-webkit-scrollbar {
    display: none;
  }

  .legal-toc > p {
    display: none;
  }

  .legal-toc a {
    min-width: max-content;
    padding: 0;
    border: 0;
    font-size: 12px;
  }

  .legal-toc a:hover {
    padding-left: 0;
  }

  .legal-block {
    scroll-margin-top: 88px;
    margin-bottom: 42px;
    padding-bottom: 42px;
  }

  .legal-block h2 {
    font-size: 27px;
  }

  .legal-block p,
  .legal-block li {
    font-size: 15px;
    line-height: 1.75;
  }

  .page-deletion .legal-content .legal-block:first-child {
    padding: 24px 20px;
  }

  .legal-footer .footer-grid {
    flex-direction: column;
  }

  .legal-footer .footer-meta {
    text-align: left;
  }
}

@media (max-width: 380px) {
  .page-legal .brand-icon {
    display: none;
  }

  .legal-hero h1 {
    font-size: 42px;
  }

  .legal-hero .container {
    min-height: 380px;
    padding-top: 56px;
    padding-bottom: 56px;
  }
}
