html { scroll-behavior: smooth; }
body { margin: 0; background: #F4EFEF; font-family: Manrope, system-ui, sans-serif; }
a { color: #9E6B6B; text-decoration: none; }
a:hover { color: #181E2A; }

[data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1); }
[data-reveal].in { opacity: 1; transform: none; }

.side-list { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
[hidden] { display: none !important; }

.tab {
  padding: 12px 22px; border: none; border-radius: 14px; cursor: pointer;
  font-family: Manrope, sans-serif; font-size: 15px; font-weight: 700;
  background: transparent; color: #475569;
  transition: background .25s ease, color .25s ease;
}
.tab.is-active { background: #9E6B6B; color: #FFFFFF; box-shadow: 0 8px 20px rgba(158,107,107,.32); }

/* Fixed top bar — transparent over the hero, glass once the page scrolls */
#nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 60;
  background: transparent; border-bottom: 1px solid transparent;
  transition: background .28s ease, border-color .28s ease, box-shadow .28s ease, backdrop-filter .28s ease;
}
#nav.is-scrolled {
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(22px); -webkit-backdrop-filter: blur(22px);
  border-bottom-color: rgba(15,23,42,.07);
  box-shadow: 0 6px 24px rgba(15,23,42,.05);
}
#nav .nav-link:hover { color: #181E2A; }
#nav .nav-cta:hover { color: #FFFFFF; background: #8C5C5C !important; }

/* Back to top */
#to-top {
  position: fixed; right: 24px; bottom: 24px; z-index: 55;
  width: 46px; height: 46px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.78); border: 1px solid rgba(15,23,42,.1);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  color: #9E6B6B; box-shadow: 0 12px 30px rgba(15,23,42,.14);
  opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity .28s ease, transform .28s ease, visibility .28s ease, background .2s ease, color .2s ease;
}
#to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
#to-top:hover { background: #9E6B6B; color: #FFFFFF; }

/* Phone mockup: keep the whole frame inside the fold on shorter screens */
[data-phone-frame] { transform-origin: top center; }
@media (max-height: 940px) { [data-phone-frame] { transform: scale(.97); margin-bottom: -22px; } }
@media (max-height: 880px) { [data-phone-frame] { transform: scale(.91); margin-bottom: -66px; } }
@media (max-height: 820px) { [data-phone-frame] { transform: scale(.85); margin-bottom: -110px; } }
@media (max-height: 780px) { [data-phone-frame] { transform: scale(.82); margin-bottom: -132px; } }
@media (max-height: 740px) { [data-phone-frame] { transform: scale(.77); margin-bottom: -169px; } }
@media (max-height: 700px) { [data-phone-frame] { transform: scale(.72); margin-bottom: -206px; } }
@media (max-height: 660px) { [data-phone-frame] { transform: scale(.67); margin-bottom: -243px; } }
@media (max-height: 620px) { [data-phone-frame] { transform: scale(.62); margin-bottom: -280px; } }

/* ------------------------------------------------------------------ *
 * Legal pages — terms.html, privacy.html, data-deletion.html
 * Same tokens as the homepage: navy #181E2A, rose #9E6B6B, canvas #F4EFEF.
 * ------------------------------------------------------------------ */
.mi { font-family: 'Material Icons'; font-size: 19px; line-height: 1; }

#nav .legal-bar { max-width: 900px; margin: 0 auto; padding: 14px 28px; display: flex; align-items: center; box-sizing: border-box; }
.legal-home {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 9px 18px 9px 14px; border-radius: 14px;
  background: rgba(255,255,255,.72); border: 1px solid rgba(15,23,42,.09);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  color: #181E2A; font-size: 15px; font-weight: 800;
  transition: background .2s ease, color .2s ease;
}
.legal-home:hover { background: #181E2A; color: #FFFFFF; }

.legal-page {
  position: relative; min-height: 100vh; padding-top: 64px; box-sizing: border-box;
  display: flex; flex-direction: column;
  background: #F4EFEF; color: #0F172A;
  /* clip, not hidden: an overflow:hidden box whose content overflows is a scroll
     container, and anchor navigation scrolls it internally — an offset the user
     cannot undo. overflow:clip cannot be scrolled at all. */
  overflow: hidden; overflow: clip;
  font-family: Manrope, system-ui, sans-serif;
}
.legal-blob { position: absolute; border-radius: 50%; pointer-events: none; }

main.legal { position: relative; flex: 1; width: 100%; max-width: 900px; margin: 0 auto; padding: 52px 28px 90px; box-sizing: border-box; }
.legal .legal-eyebrow { display: block; font-size: 11px; letter-spacing: .06em; color: #7A4F4F; }
.legal h1 { margin: 14px 0 0; font-family: Jost, sans-serif; font-size: clamp(32px,4.6vw,50px); font-weight: 500; line-height: 1.07; letter-spacing: .01em; color: #181E2A; text-wrap: balance; }
.legal p.legal-lede { margin: 16px 0 0; font-size: 19px; line-height: 1.6; color: #475569; max-width: 660px; }
.legal p.meta { margin: 10px 0 0; font-size: 13px; line-height: 1.6; color: #7A4F4F; }

.legal-card {
  margin-top: 34px; border-radius: 26px; padding: clamp(22px,4vw,44px); box-sizing: border-box;
  background: rgba(255,255,255,.72); border: 1px solid rgba(15,23,42,.07);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 12px 34px rgba(15,23,42,.05);
}
.legal-card > :first-child { margin-top: 0 !important; padding-top: 0 !important; border-top: 0 !important; }

.legal h2 {
  margin: 36px 0 0; padding-top: 26px; border-top: 1px solid rgba(15,23,42,.09);
  font-family: Jost, sans-serif; font-size: clamp(21px,2.5vw,27px); font-weight: 600; line-height: 1.2; color: #181E2A;
}
.legal h3 { margin: 26px 0 0; font-size: 17px; font-weight: 800; line-height: 1.35; color: #181E2A; }
.legal p { margin: 12px 0 0; font-size: 16px; line-height: 1.7; color: #1E293B; text-wrap: pretty; }
.legal ul, .legal ol { margin: 12px 0 0; padding-left: 22px; font-size: 16px; line-height: 1.7; color: #1E293B; }
.legal li { margin: 0 0 9px; }
.legal strong { font-weight: 800; color: #0F172A; }
.legal p a, .legal li a, .legal td a { color: #9E6B6B; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(158,107,107,.4); }
.legal p a:hover, .legal li a:hover, .legal td a:hover { color: #181E2A; text-decoration-color: rgba(24,30,42,.4); }

.legal .box {
  margin: 22px 0 0; padding: 18px 20px; border-radius: 18px;
  background: rgba(227,196,196,.34); border: 1px solid rgba(158,107,107,.22);
}
.legal .box p { margin: 10px 0 0; font-size: 15px; }
.legal .box > :first-child { margin-top: 0; }
.legal .mail { display: inline-block; margin: 2px 0; font-size: 16px; font-weight: 800; }
.legal code {
  background: rgba(15,23,42,.05); border: 1px solid rgba(15,23,42,.09); border-radius: 6px;
  padding: .1em .4em; font-size: .88em; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.legal .scroll { margin-top: 16px; overflow-x: auto; border: 1px solid rgba(15,23,42,.08); border-radius: 16px; background: rgba(255,255,255,.55); }
.legal table { border-collapse: collapse; width: 100%; min-width: 480px; font-size: 15px; }
.legal th, .legal td { text-align: left; padding: 12px 15px; border-bottom: 1px solid rgba(15,23,42,.07); vertical-align: top; line-height: 1.6; color: #1E293B; }
.legal th { font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #7A4F4F; background: rgba(227,196,196,.26); }
.legal tbody tr:last-child td { border-bottom: 0; }
.legal table.cols2 th:first-child, .legal table.cols2 td:first-child { width: 48%; }

.legal-divider { margin: 52px 0 0; border: 0; border-top: 1px solid rgba(15,23,42,.09); }
.legal-lang { scroll-margin-top: 92px; }
.legal-lang > .legal-eyebrow { margin-top: 40px; }

.legal-actions { margin-top: 30px; display: flex; gap: 14px; flex-wrap: wrap; }
.legal-btn { display: flex; align-items: center; gap: 10px; padding: 14px 22px; border-radius: 16px; font-size: 15px; font-weight: 800; }
.legal-btn-dark { background: #181E2A; color: #FFFFFF; box-shadow: 0 14px 30px rgba(24,30,42,.22); }
.legal-btn-dark:hover { background: #242C3C; color: #FFFFFF; }
.legal-btn-glass { background: rgba(255,255,255,.8); border: 1px solid rgba(24,30,42,.12); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); color: #181E2A; font-weight: 700; }
.legal-btn-glass:hover { background: #FFFFFF; color: #181E2A; }

.legal-footer { position: relative; border-top: 1px solid rgba(15,23,42,.07); background: rgba(255,255,255,.62); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
.legal-footer > div { max-width: 900px; margin: 0 auto; padding: 26px 28px; box-sizing: border-box; display: flex; justify-content: space-between; align-items: center; gap: 18px 22px; flex-wrap: wrap; font-size: 13px; color: #475569; }
.legal-footer a { color: #475569; }
.legal-footer nav { display: flex; gap: 22px; flex-wrap: wrap; }

.btn-play:hover { background: #242C3C !important; }
.btn-ios:hover { background: #FFFFFF !important; }

@media (max-width: 980px) {
  [data-grid2] { grid-template-columns: minmax(0, 1fr) !important; }
  [data-phone] { justify-self: center; }
}
@media (max-width: 640px) {
  #nav .nav-link { display: none; }
  #to-top { right: 16px; bottom: 16px; }
}
@media (max-width: 420px) {
  [data-phone-frame] { transform: scale(.8) !important; transform-origin: top center; margin-bottom: -147px !important; }
}
