/* ===== Freelok — Legal & Help site ===== */

@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --bg: #0a0a0a;
  --surface: #141414;
  --surface-raised: #1a1a1a;
  --border: #262626;
  --border-soft: #1f1f1f;
  --lilac: #b19cd9;
  --lilac-bright: #c9b8e8;
  --lilac-dim: rgba(177, 156, 217, 0.12);
  --text: #f2f0f5;
  --text-secondary: #9d9aa5;
  --text-tertiary: #6b6873;
  --serif: 'DM Serif Display', Georgia, serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --radius: 14px;
  --radius-sm: 8px;
  --max-width: 780px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: var(--lilac); text-decoration: none; }
a:hover { color: var(--lilac-bright); }
a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--lilac);
  outline-offset: 3px;
  border-radius: 4px;
}

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

/* ---------- Top nav ---------- */
.topnav {
  border-bottom: 1px solid var(--border-soft);
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 50;
}

.topnav-inner {
  max-width: 1040px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.brand span {
  font-family: var(--serif);
  font-size: 1.15rem;
  letter-spacing: 0.01em;
}

.nav-links {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 999px;
  transition: color 0.15s ease, background 0.15s ease;
}

.nav-links a:hover {
  color: var(--text);
  background: var(--surface-raised);
}

.nav-links a.active {
  color: var(--bg);
  background: var(--lilac);
}

/* ---------- Hero ---------- */
.hero {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 64px 24px 40px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--lilac);
  margin-bottom: 18px;
}

.eyebrow::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lilac);
}

h1 {
  font-family: var(--serif);
  font-size: clamp(2rem, 5vw, 2.9rem);
  font-weight: 400;
  line-height: 1.15;
  margin-bottom: 14px;
}

.hero-sub {
  color: var(--text-secondary);
  font-size: 1.02rem;
  max-width: 56ch;
}

.updated {
  margin-top: 20px;
  font-size: 0.85rem;
  color: var(--text-tertiary);
}

/* ---------- Main layout for legal docs ---------- */
.doc-layout {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px 100px;
  width: 100%;
  flex: 1;
}

.doc-section {
  padding: 34px 0;
  border-top: 1px solid var(--border-soft);
}

.doc-section:first-of-type {
  border-top: 1px solid var(--border-soft);
  margin-top: 8px;
}

.doc-section h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.35rem;
  margin-bottom: 14px;
  color: var(--text);
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.doc-section h2 .num {
  color: var(--lilac);
  font-family: var(--sans);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.doc-section p {
  color: var(--text-secondary);
  margin-bottom: 12px;
  font-size: 0.98rem;
}

.doc-section ul {
  list-style: none;
  margin: 10px 0 14px;
}

.doc-section ul li {
  color: var(--text-secondary);
  font-size: 0.98rem;
  padding: 6px 0 6px 22px;
  position: relative;
}

.doc-section ul li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 15px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--lilac);
}

.doc-section strong { color: var(--text); font-weight: 600; }

/* ---------- Contact card ---------- */
.contact-card {
  margin-top: 36px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.contact-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.2rem;
  margin-bottom: 6px;
}

.contact-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--lilac);
  color: #14101c;
  font-weight: 600;
  font-size: 0.92rem;
  padding: 12px 22px;
  border-radius: 999px;
  white-space: nowrap;
  transition: background 0.15s ease, transform 0.15s ease;
}

.btn:hover {
  background: var(--lilac-bright);
  color: #14101c;
  transform: translateY(-1px);
}

/* ---------- Help center ---------- */
.help-search {
  margin: 8px 0 36px;
}

.help-search input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 14px 20px;
  color: var(--text);
  font-family: var(--sans);
  font-size: 0.95rem;
}

.help-search input::placeholder { color: var(--text-tertiary); }
.help-search input:focus { outline: none; border-color: var(--lilac); }

.help-categories {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 44px;
}

.help-cat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 18px 16px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}

.help-cat .tag {
  display: block;
  color: var(--lilac);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.faq-group {
  margin-bottom: 40px;
}

.faq-group-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.25rem;
  margin-bottom: 4px;
  padding-top: 24px;
  border-top: 1px solid var(--border-soft);
}

.faq-item {
  border-bottom: 1px solid var(--border-soft);
}

.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-weight: 500;
  font-size: 0.98rem;
  color: var(--text);
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary .plus {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--lilac);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: transform 0.2s ease, background 0.2s ease;
}

.faq-item[open] summary .plus {
  transform: rotate(45deg);
  background: var(--lilac-dim);
}

.faq-item .faq-answer {
  color: var(--text-secondary);
  font-size: 0.94rem;
  padding-bottom: 20px;
  padding-right: 38px;
}

/* ---------- Footer ---------- */
footer {
  border-top: 1px solid var(--border-soft);
  padding: 28px 24px;
  margin-top: auto;
}

.footer-inner {
  max-width: 1040px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

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

.footer-links a {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.footer-copy {
  color: var(--text-tertiary);
  font-size: 0.82rem;
}

@media (max-width: 640px) {
  .nav-links { display: none; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
