/* ═══════════════════════════════════════════════════════════════════
   Methodiqal — shared site stylesheet
   ───────────────────────────────────────────────────────────────────
   Loaded by every page BEFORE that page's own inline <style> block,
   so anything a page declares inline will override what is here.

   Contains only what is identical on every page: the reset, the colour
   tokens, light/dark theming, the fixed header, the mobile menu, the
   footer basics and focus styles.

   Page-specific CSS stays inline in each page. Change the nav, footer,
   theme colours or mobile menu HERE and it changes everywhere.
   ═══════════════════════════════════════════════════════════════════ */

/* ── SELF-HOSTED FONTS ──────────────────────────────────────────────
   Variable fonts: one file each covers every weight from 100 to 900.
   Subsetted to Latin plus the punctuation this site uses.
   Licensed under the SIL Open Font License — see assets/fonts/OFL-*.txt.
   NOTE: these are cached for a year. If you ever re-generate them,
   change the filename too, or returning visitors keep the old file.
   ─────────────────────────────────────────────────────────────────── */
@font-face {
  font-family: 'Outfit';
  src: url('/assets/fonts/outfit-var.woff') format('woff');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'DM Sans';
  src: url('/assets/fonts/dmsans-var.woff') format('woff');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

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

:root {
  --bg:      #07070f;
  --bg2:     #0d0d1c;
  --bg-card: #111124;
  --purple:  #6d28d9;
  --purple2: #8b5cf6;
  --teal:    #14b8a6;
  --teal2:   #2dd4bf;
  --text:    #eeeeff;
  --muted:   #8888aa;
  --border:  rgba(139,92,246,0.18);
  --glow:    0 0 40px rgba(109,40,217,0.35);
  --grad:    linear-gradient(135deg, #6d28d9 0%, #8b5cf6 50%, #14b8a6 100%);
  --grad2:   linear-gradient(135deg, rgba(109,40,217,0.15), rgba(20,184,166,0.15));
}

[data-theme="light"] {
  --bg:      #f4f4ff;
  --bg2:     #eaeaf5;
  --bg-card: #ffffff;
  --text:    #0d0d1e;
  --muted:   #5a5a7a;
  --border:  rgba(109,40,217,0.15);
  --glow:    0 0 40px rgba(109,40,217,0.15);
  --grad2:   linear-gradient(135deg, rgba(109,40,217,0.08), rgba(20,184,166,0.08));
  --teal2:   #0d9488;
}

[data-theme="light"] .hero-badge {
  background: rgba(109,40,217,0.06);
  border-color: rgba(139,92,246,0.30);
}

[data-theme="light"] .site-nav { background: rgba(244,244,255,0.9); }

html { scroll-behavior: smooth; }

body {
  background: var(--bg); color: var(--text);
  font-family: 'DM Sans', sans-serif;
  overflow-x: hidden; line-height: 1.6;
  transition: background 0.3s, color 0.3s;
}

a { text-decoration: none; color: inherit; }

button { cursor: pointer; font-family: 'DM Sans', sans-serif; }

/* ── NAV ── */
.site-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 60px; background: rgba(7,7,15,0.82);
  backdrop-filter: blur(16px); border-bottom: 1px solid var(--border);
  transition: background 0.3s;
}

.nav-logo {
  font-family: 'Outfit', sans-serif; font-weight: 900; font-size: 1.45rem;
  background: var(--grad); -webkit-background-clip: text;
  -webkit-text-fill-color: transparent; background-clip: text;
  letter-spacing: -0.5px;
}

.nav-links { display: flex; gap: 32px; list-style: none; }

/* Seven nav items: ease the spacing before the mobile breakpoint takes over. */
@media (max-width: 1080px) { .nav-links { gap: 22px; } }
@media (max-width: 900px)  { .nav-links { gap: 16px; font-size: 0.86rem; } }

.nav-links a { font-size: 0.9rem; font-weight: 500; color: var(--muted); transition: color 0.2s; }

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

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

.theme-toggle {
  width: 36px; height: 36px; border-radius: 8px;
  border: 1px solid var(--border); background: transparent;
  display: flex; align-items: center; justify-content: center;
  transition: border-color 0.2s, background 0.2s;
}

.theme-toggle:hover { background: rgba(139,92,246,0.12); border-color: rgba(139,92,246,0.45); }

.theme-toggle svg {
  width: 15px; height: 15px; stroke: var(--muted); fill: none;
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; pointer-events: none;
}

.btn-nav {
  padding: 10px 24px; background: var(--grad); border: none; border-radius: 999px;
  font-size: 0.875rem; font-weight: 700; color: #fff;
  transition: opacity 0.2s, transform 0.2s;
}

.btn-nav:hover { opacity: 0.88; transform: translateY(-1px); }

.footer-logo {
  font-family: 'Outfit', sans-serif; font-weight: 900; font-size: 1.2rem;
  background: var(--grad); -webkit-background-clip: text;
  -webkit-text-fill-color: transparent; background-clip: text;
}

footer p { color: var(--muted); font-size: 0.82rem; }

.footer-links a { color: var(--muted); font-size: 0.82rem; transition: color 0.2s; }

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

a:focus-visible, button:focus-visible { outline: 2px solid var(--teal2); outline-offset: 3px; }

/* ── MOBILE NAV ── */
.nav-toggle {
  display: none; width: 38px; height: 38px; border-radius: 9px;
  border: 1px solid var(--border); background: transparent;
  align-items: center; justify-content: center; flex-shrink: 0;
  transition: border-color 0.2s, background 0.2s;
}

.nav-toggle:hover { background: rgba(139,92,246,0.12); border-color: rgba(139,92,246,0.45); }

.nav-toggle span {
  display: block; position: relative; width: 17px; height: 2px;
  background: var(--muted); border-radius: 2px; transition: background 0.2s;
}

.nav-toggle span::before, .nav-toggle span::after {
  content: ""; position: absolute; left: 0; width: 17px; height: 2px;
  background: var(--muted); border-radius: 2px;
  transition: transform 0.28s cubic-bezier(0.22,1,0.36,1), top 0.28s;
}

.nav-toggle span::before { top: -6px; }

.nav-toggle span::after  { top: 6px; }

.nav-toggle[aria-expanded="true"] span { background: transparent; }

.nav-toggle[aria-expanded="true"] span::before { top: 0; transform: rotate(45deg); }

.nav-toggle[aria-expanded="true"] span::after  { top: 0; transform: rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 190;
  background: var(--bg);
  padding: 96px 24px 40px;
  display: flex; flex-direction: column;
  transform: translateX(100%);
  visibility: hidden;
  transition: transform 0.34s cubic-bezier(0.22,1,0.36,1), visibility 0.34s;
  overflow-y: auto;
}

.mobile-menu.open { transform: translateX(0); visibility: visible; }

.mobile-menu ul { list-style: none; }

.mobile-menu li { border-bottom: 1px solid var(--border); }

.mobile-menu li a {
  display: flex; align-items: center; justify-content: space-between;
  padding: 17px 4px; font-family: 'Outfit', sans-serif;
  font-size: 1.15rem; font-weight: 700; color: var(--text);
  letter-spacing: -0.3px; transition: color 0.2s, padding-left 0.2s;
}

.mobile-menu li a::after { content: "→"; color: var(--muted); font-size: 0.95rem; transition: transform 0.2s, color 0.2s; }

.mobile-menu li a:hover, .mobile-menu li a:focus-visible { color: var(--teal2); padding-left: 8px; }

.mobile-menu li a:hover::after { color: var(--teal2); transform: translateX(3px); }

.mm-cta {
  width: 100%; margin-top: 30px; padding: 15px;
  background: var(--grad); border: none; border-radius: 999px;
  font-size: 1rem; font-weight: 700; color: #fff;
  box-shadow: 0 6px 26px rgba(109,40,217,0.42);
}

.mm-foot { margin-top: auto; padding-top: 32px; }

.mm-foot p { color: var(--muted); font-size: 0.85rem; margin-bottom: 6px; }

.mm-foot a { color: var(--teal2); font-size: 0.92rem; font-weight: 600; }

.mm-legal { margin-top: 18px; display: flex; gap: 18px; flex-wrap: wrap; }

.mm-legal a { color: var(--muted); font-size: 0.8rem; font-weight: 400; }

body.menu-open { overflow: hidden; }

@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .btn-nav { padding: 9px 17px; font-size: 0.8rem; }
}

@media (max-width: 400px) {
  .btn-nav { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-menu { transition: visibility 0.01s; }
  .nav-toggle span, .nav-toggle span::before, .nav-toggle span::after { transition: none; }
}
