/* OpenWise — public legal / developer pages */
:root {
  --bg: #f4f7fb;
  --bg-card: #ffffff;
  --text: #0f172a;
  --text-muted: #64748b;
  --accent: #0d9488;
  --accent-dark: #0f766e;
  --border: #e2e8f0;
  --shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
  --radius: 14px;
  --max: 720px;
  --max-wide: 960px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
}

a {
  color: var(--accent-dark);
  text-decoration: none;
  font-weight: 500;
}

a:hover {
  text-decoration: underline;
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.25rem 3rem;
}

.wrap-wide {
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 0 1.25rem 3rem;
}

/* Top bar */
.site-header {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header-inner {
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--text);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand:hover {
  text-decoration: none;
  color: var(--accent-dark);
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent) 0%, #0f766e 100%);
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
}

.nav-links {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
  font-size: 0.95rem;
}

.nav-links a {
  color: var(--text-muted);
}

.nav-links a:hover {
  color: var(--accent-dark);
}

/* Hero (landing) */
.hero {
  padding: 3rem 0 2.5rem;
  text-align: center;
}

.hero h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.hero .tagline {
  margin: 0 auto 1.5rem;
  max-width: 36rem;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.pill {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(13, 148, 136, 0.12);
  color: var(--accent-dark);
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

/* Cards */
.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  padding: 1.75rem 1.5rem;
  margin-bottom: 1.25rem;
}

.card h2 {
  margin: 0 0 0.75rem;
  font-size: 1.15rem;
}

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

.grid-2 {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 640px) {
  .grid-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.35rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: #fff !important;
  box-shadow: 0 4px 14px rgba(13, 148, 136, 0.35);
}

.btn-primary:hover {
  color: #fff;
}

.btn-ghost {
  background: #fff;
  color: var(--text) !important;
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent-dark) !important;
}

.meta {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Legal document */
.doc-title {
  padding: 2.25rem 0 1rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
}

.doc-title h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.5rem, 3vw, 1.85rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.doc-title .updated {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.legal h2 {
  margin: 2rem 0 0.75rem;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
}

.legal h2:first-of-type {
  margin-top: 0;
}

.legal h3 {
  margin: 1.25rem 0 0.5rem;
  font-size: 1rem;
  font-weight: 600;
}

.legal p {
  margin: 0 0 0.85rem;
  color: #334155;
}

.legal ol,
.legal ul {
  margin: 0 0 1rem;
  padding-left: 1.35rem;
  color: #334155;
}

.legal li {
  margin-bottom: 0.45rem;
}

.legal .note {
  padding: 1rem 1.1rem;
  border-radius: 10px;
  background: rgba(13, 148, 136, 0.08);
  border-left: 4px solid var(--accent);
  font-size: 0.92rem;
  margin: 1.5rem 0;
}

/* Footer */
.site-footer {
  margin-top: 3rem;
  padding: 1.5rem 1.25rem 2rem;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.site-footer a {
  color: var(--text-muted);
}

.site-footer a:hover {
  color: var(--accent-dark);
}

/* —— Landing homepage (minimal / premium) —— */
body.body-landing {
  font-family: "Manrope", "Segoe UI", system-ui, sans-serif;
  background: #f7f6f4;
  color: #141414;
  letter-spacing: -0.01em;
}

.site-header--minimal {
  background: rgba(247, 246, 244, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(20, 20, 20, 0.06);
}

.site-header--minimal .site-header-inner {
  justify-content: center;
  padding: 1.1rem 1.25rem;
}

.brand--landing {
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #141414;
}

.brand--landing:hover {
  color: #141414;
  opacity: 0.75;
}

.brand-mark--landing {
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e8e8e8;
}

.brand-mark--landing img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.landing-main {
  max-width: 560px;
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
}

.landing-hero {
  padding: 2.75rem 0 1rem;
  text-align: center;
}

.landing-eyebrow {
  margin: 0 0 1.25rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: #737373;
}

.landing-title {
  margin: 0 0 1.35rem;
  font-size: clamp(2.15rem, 6vw, 2.85rem);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: -0.04em;
  color: #0a0a0a;
}

.landing-lead {
  margin: 0 auto;
  max-width: 34rem;
  font-size: 1.02rem;
  font-weight: 400;
  line-height: 1.75;
  color: #525252;
}

.landing-features {
  padding: 2.5rem 0 3rem;
  border-top: 1px solid rgba(20, 20, 20, 0.08);
}

.landing-section-label {
  margin: 0 0 1.75rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #737373;
  text-align: center;
}

.feature-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.feature-item {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid rgba(20, 20, 20, 0.07);
}

.feature-item:first-child {
  padding-top: 0;
}

.feature-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.feature-item__name {
  display: block;
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #0a0a0a;
}

.feature-item__desc {
  display: block;
  font-size: 0.9rem;
  font-weight: 400;
  line-height: 1.65;
  color: #666666;
}

.landing-download-float {
  position: relative;
  z-index: 1;
  margin: 0 auto 2.75rem;
  padding: 1.35rem 1.25rem 1.25rem;
  text-align: center;
  background: #ffffff;
  border-radius: 18px;
  border: 1px solid rgba(20, 20, 20, 0.07);
  transform: translateY(-2px);
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.04),
    0 12px 32px -8px rgba(0, 0, 0, 0.12),
    0 24px 48px -16px rgba(0, 0, 0, 0.08);
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.landing-download-float:hover {
  box-shadow:
    0 4px 8px rgba(0, 0, 0, 0.06),
    0 16px 40px -8px rgba(0, 0, 0, 0.14),
    0 28px 56px -16px rgba(0, 0, 0, 0.1);
  transform: translateY(-4px);
}

.landing-download-float__label {
  margin: 0 0 1rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #737373;
}

.landing-download-float__package {
  margin: 0.85rem 0 0;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: #a3a3a3;
}

.landing-footer {
  margin-top: 0;
  padding-top: 2rem;
  border-top: 1px solid rgba(20, 20, 20, 0.08);
  text-align: center;
}

.play-badge {
  display: inline-block;
  line-height: 0;
  border-radius: 8px;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.play-badge:hover {
  opacity: 0.92;
  transform: translateY(-2px);
}

.play-badge img {
  height: auto;
  width: min(200px, 70vw);
  max-width: 200px;
  display: block;
}

.landing-footer__legal {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  margin-bottom: 1rem;
  font-size: 0.8rem;
}

.landing-footer__legal a {
  color: #737373;
  font-weight: 500;
  text-decoration: none;
  letter-spacing: 0.02em;
}

.landing-footer__legal a:hover {
  color: #141414;
  text-decoration: underline;
}

.landing-footer__dot {
  color: #d4d4d4;
  user-select: none;
}

.landing-footer__copy {
  margin: 0;
  font-size: 0.75rem;
  color: #a3a3a3;
  letter-spacing: 0.04em;
}

/* Legal pages — same theme as index (body-landing) */
body.body-landing main.landing-main.legal {
  padding-top: 0.5rem;
}

body.body-landing main.landing-main.legal .doc-title {
  padding: 1.5rem 0 1.15rem;
  border-bottom: 1px solid rgba(20, 20, 20, 0.08);
  margin-bottom: 1.75rem;
}

body.body-landing main.landing-main.legal .doc-title h1 {
  font-size: clamp(1.35rem, 3.5vw, 1.7rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  color: #0a0a0a;
}

body.body-landing main.landing-main.legal .doc-title .updated {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #a3a3a3;
}

body.body-landing main.landing-main.legal h2 {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #0a0a0a;
}

body.body-landing main.landing-main.legal h3 {
  font-size: 0.95rem;
  font-weight: 600;
  color: #262626;
}

body.body-landing main.landing-main.legal p,
body.body-landing main.landing-main.legal li {
  color: #525252;
  font-size: 0.95rem;
  line-height: 1.72;
}

body.body-landing main.landing-main.legal strong {
  color: #141414;
  font-weight: 600;
}

body.body-landing main.landing-main.legal .note {
  background: #ffffff;
  border: 1px solid rgba(20, 20, 20, 0.08);
  border-left: 3px solid #141414;
  border-radius: 14px;
  color: #525252;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

body.body-landing main.landing-main.legal code {
  font-family: ui-monospace, "Cascadia Code", "Segoe UI Mono", monospace;
  font-size: 0.88em;
  background: rgba(20, 20, 20, 0.06);
  padding: 0.15em 0.45em;
  border-radius: 6px;
  color: #141414;
}

body.body-landing main.landing-main.legal a {
  color: #141414;
  font-weight: 500;
  text-underline-offset: 3px;
}

body.body-landing main.landing-main.legal a:hover {
  color: #737373;
}

body.body-landing main.landing-main.legal + .landing-footer {
  margin-top: 3rem;
  padding-bottom: 2.5rem;
}
