/* Magnetti Lab — Dark premium static site
   Colors approximated from the previous OKLCH palette into hex/rgb. */

:root {
  --bg: #10131c;
  --bg-2: #141826;
  --surface: #161b2a;
  --surface-2: #1b2133;
  --card: #1a2032;
  --border: rgba(120, 145, 200, 0.16);
  --border-strong: rgba(120, 145, 200, 0.28);
  --fg: #eef2fa;
  --muted: #9aa6c2;
  --primary: #6cc7ff;
  --primary-2: #4fb3f7;
  --primary-ink: #0a1220;
  --accent: #7dd3ff;
  --radius: 14px;
  --radius-lg: 20px;
  --container: 1180px;
  --shadow-card: 0 1px 0 rgba(0,0,0,0.3), 0 22px 60px -20px rgba(0,0,0,0.6);
  --shadow-soft: 0 1px 2px rgba(0,0,0,0.35), 0 10px 30px rgba(0,0,0,0.3);
  --font-sans: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --font-display: 'Instrument Serif', Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; background: var(--bg); }
body {
  margin: 0;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--fg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.6;
  font-size: 16px;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--primary); }
::selection { background: rgba(108,199,255,0.35); color: var(--fg); }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--primary); color: var(--primary-ink);
  padding: .5rem 1rem; border-radius: 6px;
  z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }

/* ===== Header ===== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(16, 19, 28, 0.78);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px; gap: 24px;
}
.brand {
  display: inline-flex; align-items: center; gap: 12px;
  color: var(--fg);
}
.brand-logo {
  height: 34px; width: auto;
  /* invert the dark source logo to render bright on dark UI */
  filter: brightness(0) invert(1);
  opacity: 0.96;
}
.brand-wordmark { display: inline-flex; align-items: baseline; gap: 6px; line-height: 1; }
.brand-name { font-weight: 600; font-size: 1.15rem; letter-spacing: -0.01em; color: var(--fg); }
.brand-suffix { font-weight: 300; font-size: 1.15rem; letter-spacing: 0.04em; color: var(--primary); }

.site-nav { display: none; gap: 28px; align-items: center; }
.site-nav a {
  font-size: 14px; color: var(--muted); transition: color .2s;
}
.site-nav a:hover, .site-nav a.active { color: var(--fg); }
.site-nav a.active { font-weight: 500; }

.header-cta { display: none; }

@media (min-width: 960px) {
  .site-nav { display: inline-flex; }
  .header-cta { display: inline-flex; }
}

.nav-toggle {
  display: inline-flex; flex-direction: column; gap: 5px;
  width: 40px; height: 40px; padding: 10px;
  background: transparent; border: 1px solid var(--border); border-radius: 10px;
  cursor: pointer;
}
.nav-toggle span {
  display: block; height: 2px; background: var(--fg); border-radius: 2px;
  transition: transform .2s, opacity .2s;
}
@media (min-width: 960px) { .nav-toggle { display: none; } }

.mobile-nav {
  display: flex; flex-direction: column; gap: 14px;
  padding: 20px 24px 28px;
  border-top: 1px solid var(--border);
  background: var(--bg-2);
}
.mobile-nav a:not(.btn) { font-size: 16px; color: var(--fg); padding: 6px 0; }
.mobile-nav .btn { align-self: flex-start; margin-top: 6px; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 44px; padding: 0 22px; border-radius: 999px;
  font-weight: 500; font-size: 14px; line-height: 1;
  border: 1px solid transparent; cursor: pointer;
  transition: opacity .2s, background .2s, color .2s, border-color .2s, transform .15s;
}
.btn-sm { height: 38px; padding: 0 18px; font-size: 13.5px; }
.btn-lg { height: 50px; padding: 0 28px; font-size: 15px; }
.btn-primary {
  background: var(--primary); color: var(--primary-ink);
  box-shadow: 0 0 0 1px rgba(108,199,255,0.45), 0 12px 32px -10px rgba(108,199,255,0.55);
}
.btn-primary:hover { opacity: 0.92; color: var(--primary-ink); }
.btn-ghost {
  background: rgba(255,255,255,0.03);
  border-color: var(--border-strong);
  color: var(--fg);
}
.btn-ghost:hover { background: rgba(255,255,255,0.06); color: var(--fg); }

/* ===== Typography ===== */
h1, h2, h3, h4 { font-family: var(--font-sans); font-weight: 500; letter-spacing: -0.02em; color: var(--fg); margin: 0; }
h1 { font-size: clamp(2.1rem, 4.5vw, 3.4rem); line-height: 1.08; }
h2 { font-size: clamp(1.6rem, 2.8vw, 2.25rem); line-height: 1.15; }
h3 { font-size: 1.1rem; font-weight: 600; }
p { margin: 0; }
.muted { color: var(--muted); }
.lead { font-size: 1.05rem; line-height: 1.7; color: var(--muted); }
.eyebrow {
  font-size: 11.5px; font-weight: 500; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--primary); margin: 0;
}
em { font-family: var(--font-display); font-style: italic; color: var(--primary); font-weight: 400; }

/* ===== Hero ===== */
.hero {
  position: relative; overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.hero-glow {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(ellipse 55% 50% at 35% -10%, rgba(108,199,255,0.22), transparent 70%);
}
.hero-grid {
  position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: 0.045;
  background-image:
    linear-gradient(rgba(238,242,250,1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(238,242,250,1) 1px, transparent 1px);
  background-size: 48px 48px;
}
.hero-inner { position: relative; z-index: 1; padding: 96px 24px 96px; max-width: 1100px; }
.hero-sm .hero-inner { padding: 72px 24px 64px; max-width: 880px; }
.hero-lg .hero-inner { padding: 120px 24px 120px; }
.hero-title { margin-top: 18px; }
.hero-title-xl { font-size: clamp(2.4rem, 5.5vw, 4.2rem); }
.hero-lead { margin-top: 22px; max-width: 720px; font-size: 1.1rem; color: var(--muted); line-height: 1.65; }
.hero-ctas { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; }
.hero-stats {
  margin: 56px 0 0;
  display: grid; gap: 22px; grid-template-columns: 1fr;
  border-top: 1px solid var(--border); padding-top: 32px;
}
.hero-stats > div { margin: 0; }
.hero-stats dt { font-size: 14px; font-weight: 600; color: var(--fg); }
.hero-stats dd { margin: 4px 0 0; font-size: 14px; color: var(--muted); }
@media (min-width: 720px) { .hero-stats { grid-template-columns: repeat(3, 1fr); } }

/* ===== Sections ===== */
.section { border-bottom: 1px solid var(--border); padding: 84px 0; }
.section.surface { background: var(--surface); }
.section-header { max-width: 760px; }
.section-header h2 { margin-top: 14px; }
.section-header .lead { margin-top: 16px; }

.mt-lg { margin-top: 48px; }
.stack-xl > * + * { margin-top: 56px; }

.two-col { display: grid; gap: 32px; grid-template-columns: 1fr; }
@media (min-width: 880px) { .two-col { grid-template-columns: 5fr 7fr; gap: 56px; align-items: start; } }

/* ===== Grids ===== */
.grid { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 720px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 720px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 720px) { .grid-5 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .grid-5 { grid-template-columns: repeat(5, 1fr); } }

.list-reset { list-style: none; padding: 0; margin: 0; }

/* ===== Cards ===== */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-soft);
  transition: border-color .2s, transform .2s;
}
.card:hover { border-color: var(--border-strong); }
.card h3 { margin-top: 10px; }
.card p { margin-top: 12px; color: var(--muted); font-size: 14.5px; line-height: 1.65; }
.card.row { display: flex; gap: 18px; align-items: flex-start; padding: 22px; }
.card.row span:last-child { font-size: 14.5px; color: var(--fg); line-height: 1.65; padding-top: 2px; }
.card-plain { font-size: 14.5px; color: var(--fg); padding: 22px; }
.card-head { display: flex; align-items: center; gap: 14px; }
.card-title { font-size: 1.2rem; font-weight: 600; }
.num {
  font-family: var(--font-display);
  font-size: 1.9rem; line-height: 1;
  color: var(--accent);
}
.num-lg { font-size: 2.6rem; }

/* ===== Key/Value lists ===== */
.kv { margin: 22px 0 0; padding: 0; display: flex; flex-direction: column; gap: 16px; }
.kv > div { margin: 0; }
.kv dt { font-size: 11px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.kv dd { margin: 4px 0 0; font-size: 14.5px; color: var(--fg); line-height: 1.65; }

/* ===== Split row (offer-style) ===== */
.split-row {
  display: grid; gap: 28px; grid-template-columns: 1fr;
  border-top: 1px solid var(--border); padding-top: 40px;
}
@media (min-width: 900px) { .split-row { grid-template-columns: 4fr 8fr; gap: 48px; } }
.split-left h2 { margin-top: 10px; font-size: 1.6rem; }
.split-left .muted { margin-top: 12px; font-size: 14.5px; line-height: 1.65; }

.pill-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.pill-list li {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 13px; color: var(--fg);
}

.check-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .check-grid { grid-template-columns: repeat(2, 1fr); } }
.check-grid li {
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 12px 16px; font-size: 14px; color: var(--fg);
}

/* ===== CTA band ===== */
.cta-band { position: relative; overflow: hidden; background: var(--surface); border-top: 1px solid var(--border); }
.cta-glow {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 60% 80% at 50% 120%, rgba(108,199,255,0.28), transparent 70%);
}
.cta-inner { position: relative; padding: 88px 24px; max-width: 820px; text-align: center; }
.cta-inner h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
.cta-inner p { margin: 18px auto 0; color: var(--muted); max-width: 640px; line-height: 1.7; }
.cta-inner .btn { margin-top: 32px; }

/* ===== Contact ===== */
.contact-grid { display: grid; gap: 36px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .contact-grid { grid-template-columns: 4fr 8fr; gap: 56px; } }
.contact-aside { display: flex; flex-direction: column; gap: 28px; }
.h-sm { font-size: 14px; font-weight: 600; }
.note {
  border: 1px dashed var(--border-strong);
  background: rgba(108,199,255,0.05);
  color: var(--fg);
  padding: 16px 18px; border-radius: 12px;
  font-size: 13.5px; line-height: 1.6;
}
.contact-form { display: flex; flex-direction: column; gap: 18px; padding: 32px; }
.form-grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .form-grid { grid-template-columns: repeat(2, 1fr); } }
.contact-form label { display: flex; flex-direction: column; gap: 8px; font-size: 13.5px; font-weight: 500; color: var(--fg); }
.contact-form .req { color: var(--primary); }
.contact-form input[type=text],
.contact-form input[type=email],
.contact-form input[type=url],
.contact-form textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border-strong);
  color: var(--fg);
  padding: 12px 14px;
  border-radius: 10px;
  font-family: inherit; font-size: 14px;
  outline: none; transition: border-color .15s, box-shadow .15s;
}
.contact-form input:focus, .contact-form textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(108,199,255,0.18);
}
.contact-form textarea { resize: vertical; min-height: 140px; }
.contact-form .full { width: 100%; }
.contact-form .checkbox { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 400; color: var(--muted); font-size: 13px; line-height: 1.55; }
.contact-form .checkbox input { margin-top: 3px; }
.contact-form button { align-self: flex-start; margin-top: 6px; }
.form-success { font-size: 14px; color: var(--accent); }

/* ===== Footer ===== */
.site-footer { background: var(--surface); border-top: 1px solid var(--border); }
.footer-grid {
  display: grid; gap: 40px; padding: 56px 24px;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.footer-brand p { margin-top: 18px; color: var(--muted); font-size: 14px; line-height: 1.65; max-width: 360px; }
.site-footer h4 { font-size: 13.5px; font-weight: 600; color: var(--fg); margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.site-footer ul a { color: var(--muted); font-size: 14px; }
.site-footer ul a:hover { color: var(--fg); }
.footer-bottom { border-top: 1px solid var(--border); padding: 20px 24px; font-size: 12.5px; color: var(--muted); }

/* Mobile polish */
@media (max-width: 720px) {
  .container { padding: 0 20px; }
  .hero-inner, .hero-lg .hero-inner, .hero-sm .hero-inner { padding: 64px 20px 56px; }
  .hero-title { overflow-wrap: anywhere; word-break: break-word; }
  .hero-title-xl { font-size: clamp(1.9rem, 8.5vw, 2.6rem); }
  .section { padding: 56px 0; }
  .cta-inner { padding: 64px 20px; }
  .header-inner { gap: 12px; }
  .brand-logo { height: 28px; }
  .brand-name, .brand-suffix { font-size: 1rem; }
}
