/* =============================================================
   langsyn-theme.css  —  Shared design system
   Apply to all three sites. Page-specific overrides live in
   langsyn-org.css / langsyn-net.css / langsyn-com.css
   ============================================================= */

/* --- Reset -------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { overflow-x: hidden; }

/* --- Base --------------------------------------------------- */
body {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  line-height: 1.7;
  font-weight: 400;
  color: var(--ls-text);
  background-color: var(--ls-bg);
  position: relative;
  overflow-x: hidden;
}

/* Splatter dot texture — driven by per-site CSS variables */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    radial-gradient(circle, var(--ls-dot-a) 2px, transparent 2px),
    radial-gradient(circle, var(--ls-dot-b) 2px, transparent 2px),
    radial-gradient(circle, var(--ls-dot-c) 1.5px, transparent 1.5px);
  background-size: 180px 180px, 250px 250px, 140px 140px;
  background-position: 40px 30px, 110px 90px, 70px 160px;
  pointer-events: none;
  z-index: 0;
}

/* Keep all real content above texture */
body > * { position: relative; z-index: 1; }

/* --- Typography --------------------------------------------- */
h1 { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 600; line-height: 1.18; color: #fff; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 600; color: #fff; }
h3 { font-size: 15px; font-weight: 500; color: #fff; }
h4 { font-size: 13px; font-weight: 500; color: #fff; }

/* Gradient highlight on italic inside h1 */
h1 em {
  font-style: normal;
  background: var(--ls-gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Navigation -------------------------------------------- */
.ls-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 2rem;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  position: relative;
  z-index: 100;
}

.ls-nav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #fff;
  text-decoration: none;
}

.ls-nav-logo-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--ls-gradient-primary);
  flex-shrink: 0;
}

.ls-nav-tld {
  font-size: 12px;
  font-weight: 400;
  opacity: 0.42;
}

.ls-nav-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

.ls-nav-links a {
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  font-size: 13px;
  letter-spacing: 0.02em;
  transition: color 0.15s;
}

.ls-nav-links a:hover { color: #fff; }

/* Hamburger button — hidden on desktop */
.ls-nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.ls-nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: rgba(255,255,255,0.75);
  border-radius: 2px;
  transition: transform 0.2s, opacity 0.2s;
}

/* Animate to X when open */
.ls-nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.ls-nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.ls-nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 640px) {
  .ls-nav-toggle {
    display: flex;
  }

  .ls-nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--ls-bg);
    border-bottom: 1px solid rgba(255,255,255,0.07);
    padding: 0.5rem 0;
  }

  .ls-nav-links.is-open {
    display: flex;
  }

  .ls-nav-links li {
    border-top: 1px solid rgba(255,255,255,0.05);
  }

  .ls-nav-links a {
    display: block;
    padding: 0.75rem 2rem;
    font-size: 15px;
  }
}

/* --- Hero -------------------------------------------------- */
.ls-hero {
  padding: 5rem 2rem 4rem;
  max-width: 860px;
  margin: 0 auto;
  text-align: center;
  position: relative;
}

.ls-eyebrow {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  margin-bottom: 1.2rem;
}

.ls-hero h1 { margin-bottom: 1.5rem; }

.ls-hero-sub {
  font-size: 16px;
  color: var(--ls-text-muted);
  max-width: 580px;
  margin: 0 auto 2.5rem;
  line-height: 1.75;
}

.ls-ctas {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Streak bar under eyebrow */
.ls-streak-bar {
  display: flex;
  height: 4px;
  border-radius: 2px;
  overflow: hidden;
  width: 200px;
  margin: 0 auto 2rem;
}
.ls-streak-bar span { flex: 1; }

/* Decorative SVG streak — position in hero, populated per-page */
.ls-side-streak {
  position: absolute;
  right: -40px;
  top: 60px;
  width: 224px;
  height: 224px;
  pointer-events: none;
  opacity: 0.13;
}

/* --- Buttons ----------------------------------------------- */
.ls-btn-primary {
  padding: 0.6rem 1.5rem;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  background: var(--ls-gradient-primary);
  color: #fff;
  letter-spacing: 0.02em;
}

.ls-btn-outline {
  padding: 0.6rem 1.5rem;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.18);
  color: var(--ls-text-muted);
  letter-spacing: 0.02em;
}

.ls-btn-primary:hover { opacity: 0.9; }
.ls-btn-outline:hover { border-color: rgba(255,255,255,0.35); color: #fff; }

/* --- Layout helpers ---------------------------------------- */
.ls-section {
  max-width: 900px;
  margin: 0 auto;
  padding: 4rem 2rem;
}

.ls-section-label {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.28);
  margin-bottom: 0.6rem;
}

.ls-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.07), transparent);
  margin: 0 2rem;
}

/* --- Cards ------------------------------------------------- */
.ls-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 1.25rem;
  position: relative;
  overflow: hidden;
}

/* Top-edge streak accent — colour set per nth-child in page CSS */
.ls-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
}

.ls-card h3 { margin-bottom: 0.5rem; }
.ls-card p  { font-size: 13px; color: var(--ls-text-faint); line-height: 1.65; }

.ls-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}

/* Subtle card variant */
.ls-card-subtle {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 10px;
  padding: 1.25rem;
}

/* Left-border card (used on .net library stack) */
.ls-card-left {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.ls-card-left::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--ls-accent-primary);
}

/* Rainbow top stripe (used on support/donate card) */
.ls-rainbow-top::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--ls-gradient-full);
}

/* --- Paths grid -------------------------------------------- */
.ls-paths-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
}

.ls-path-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 10px;
  padding: 1.25rem;
  text-align: center;
}

.ls-path-icon {
  width: 32px;
  height: 3px;
  border-radius: 2px;
  margin: 0 auto 1rem;
}

.ls-path-card h3 { margin-bottom: 0.4rem; }
.ls-path-card p  { font-size: 12px; color: var(--ls-text-faint); line-height: 1.6; }

/* --- Status badge ------------------------------------------ */
.ls-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 4px;
  background: rgba(255,255,255,0.07);
  color: rgba(255,255,255,0.45);
  border: 1px solid rgba(255,255,255,0.10);
}

/* --- Footer ------------------------------------------------ */
.ls-footer {
  border-top: 1px solid rgba(255,255,255,0.07);
  padding: 1.5rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.ls-footer p { font-size: 12px; color: rgba(255,255,255,0.28); }

.ls-footer-links {
  display: flex;
  gap: 1.2rem;
  list-style: none;
}

.ls-footer-links a {
  font-size: 12px;
  color: rgba(255,255,255,0.32);
  text-decoration: none;
}

.ls-footer-links a:hover { color: rgba(255,255,255,0.75); }

/* --- Prose content (long-form reading pages) --------------- */
.ls-prose {
  max-width: 680px;
  margin: 0 auto;
  padding: 4rem 2rem 2rem;
}

.ls-prose h1 { margin-bottom: 1.5rem; }

.ls-prose h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  margin: 2.5rem 0 0.75rem;
}

.ls-prose h2:first-child { margin-top: 0; }

.ls-prose p {
  color: var(--ls-text-muted);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.ls-prose .lead {
  font-size: 16px;
  line-height: 1.75;
}

.ls-prose ul, .ls-prose ol {
  color: var(--ls-text-muted);
  padding-left: 1.5rem;
  line-height: 1.8;
  margin-bottom: 1rem;
}

.ls-prose li { margin-bottom: 0.5rem; }

.ls-prose strong { color: #fff; font-weight: 500; }

.ls-prose em { color: var(--ls-accent-primary); font-style: italic; }

.ls-prose a { color: var(--ls-accent-primary); text-decoration: none; }
.ls-prose a:hover { color: #fff; }

.ls-prose code {
  font-size: 13px;
  padding: 2px 6px;
  background: rgba(255,255,255,0.06);
  border-radius: 3px;
}

.ls-prose pre {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 1rem 1.2rem;
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.65;
  margin: 0.8rem 0 1rem;
}

.ls-prose pre code { background: none; padding: 0; }

/* --- Page navigation (prev/next between articles) ---------- */
.ls-page-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 680px;
  margin: 0 auto;
  padding: 1rem 2rem 2rem;
}

.ls-page-nav a {
  font-size: 13px;
  font-weight: 500;
  color: rgba(255,255,255,0.45);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: color 0.15s;
}

.ls-page-nav a:hover { color: var(--ls-accent-primary); }

/* --- Mobile ------------------------------------------------ */
@media (max-width: 640px) {
  .ls-hero { padding: 3.5rem 1.5rem 3rem; }
  .ls-section { padding: 2.5rem 1.5rem; }
  .ls-prose { padding: 2.5rem 1.5rem 1.5rem; }
  .ls-page-nav { padding: 1rem 1.5rem 1.5rem; }
  .ls-card-grid,
  .ls-paths-grid,
  .ls-grid-2 { grid-template-columns: 1fr !important; }
  .ls-footer { flex-direction: column; text-align: center; gap: 0.5rem; }
}
