/* ==========================================================================
   Borealid.com — styles
   Light theme is the default. Dark theme only when data-theme="dark".
   ========================================================================== */

:root {
  --bg: #f4f8f8;
  --surface: #ffffff;
  --text: #0f1f24;
  --muted: #55696f;
  --line: #dbe5e6;
  --accent: #0b3c49;
  --accent-ink: #ffffff;
  --accent-soft: #dff5ee;
  --warn: #b45309;
  --warn-soft: #fdf1e3;
  --alt: #eaf1f2;
  --radius: 14px;
  --max: 1120px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.06), 0 4px 12px -4px rgba(16, 24, 40, 0.08);
  --shadow-lift: 0 2px 4px rgba(16, 24, 40, 0.06), 0 10px 24px -8px rgba(16, 24, 40, 0.14);
}

:root[data-theme="dark"] {
  --bg: #0a1a20;
  --surface: #0f2730;
  --text: #e6f1f0;
  --muted: #98b0b3;
  --line: #1f3b45;
  --accent: #2ed3a0;
  --accent-ink: #0b3c49;
  --accent-soft: #11392f;
  --warn: #f0a050;
  --warn-soft: #2b2112;
  --alt: #0d2229;
  --shadow: none;
  --shadow-lift: none;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--accent); }
code { font-size: 0.92em; background: var(--alt); padding: 0.1em 0.35em; border-radius: 6px; }

.wrap { width: min(100% - 32px, var(--max)); margin-inline: auto; }
.narrow { max-width: 720px; }
.dim { color: var(--muted); }

h1, h2, h3 { line-height: 1.2; margin: 0 0 0.5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.25rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }

.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}
.lead { font-size: 1.15rem; color: var(--muted); max-width: 40rem; }
.fine-print { font-size: 0.9rem; color: var(--muted); }
.trust-note { font-size: 0.92rem; font-weight: 600; color: var(--text); margin: 0 0 0.5rem; }

/* Buttons */
.btn {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-ink);
  text-decoration: none;
  font-weight: 600;
  padding: 0.8rem 1.25rem;
  border-radius: 10px;
  border: 0;
  font-size: 1rem;
  cursor: pointer;
  min-height: 44px;
  line-height: 1.2;
}
.btn:hover { filter: brightness(1.08); }
.btn:disabled { opacity: 0.6; cursor: wait; }
.btn:focus-visible, a:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--accent-soft);
  outline-offset: 2px;
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  box-shadow: inset 0 0 0 1px var(--line);
}
.btn-small { padding: 0.5rem 0.9rem; min-height: 0; font-size: 0.95rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.5rem 0 1rem; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: 0.5rem; text-decoration: none; color: var(--text); font-weight: 700; font-size: 1.1rem; }
.brand-mark { width: 34px; height: 34px; object-fit: contain; }
.brand-mark.on-dark { display: none; }
:root[data-theme="dark"] .brand-mark.on-light { display: none; }
:root[data-theme="dark"] .brand-mark.on-dark { display: inline-block; }
.brand-text { font-weight: 700; }
.nav-links { display: flex; align-items: center; gap: 1.1rem; }
.nav-links a:not(.btn) { color: var(--text); text-decoration: none; font-size: 0.95rem; }
.nav-links a:not(.btn):hover { color: var(--accent); }

/* Mobile menu: a <details> dropdown, shown only where the inline links do not fit */
.nav-menu { display: none; position: relative; margin: 0; padding: 0; background: none; border: 0; box-shadow: none; }
.nav-menu > summary {
  list-style: none;
  cursor: pointer;
  font-weight: 600;
  color: var(--text);
  box-shadow: inset 0 0 0 1px var(--line);
  border-radius: 10px;
  padding: 0.5rem 0.9rem;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
}
.nav-menu > summary::-webkit-details-marker { display: none; }
.nav-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 200px;
  display: grid;
  gap: 0.25rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lift);
  padding: 0.5rem;
  z-index: 20;
}
.nav-dropdown a {
  color: var(--text);
  text-decoration: none;
  padding: 0.6rem 0.75rem;
  border-radius: 8px;
  min-height: 44px;
  display: flex;
  align-items: center;
}
.nav-dropdown a:hover { background: var(--alt); color: var(--accent); }

/* Hero */
.hero { padding: clamp(3rem, 8vw, 6rem) 0 clamp(2.5rem, 6vw, 4rem); }
.hero-grid { display: grid; gap: 3rem; align-items: center; }
.hero-card { display: flex; justify-content: center; }

/* Band */
.band { border-block: 1px solid var(--line); background: var(--surface); }
.band-grid { display: grid; gap: 1.5rem; padding: 1.75rem 0; }
.band-grid div { display: flex; flex-direction: column; gap: 0.25rem; }
.band-grid strong { font-size: 1rem; }
.band-grid span { color: var(--muted); font-size: 0.95rem; }

/* Sections */
.section { padding: clamp(3rem, 7vw, 5rem) 0; }
.section-alt { background: var(--alt); }
.section-head { margin-bottom: 2.5rem; max-width: 46rem; }
.section-head p:not(.eyebrow) { color: var(--muted); }

.cards { display: grid; gap: 1rem; grid-template-columns: 1fr; }
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
}
.card p { color: var(--muted); margin: 0; font-size: 0.97rem; }

/* Steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.steps li {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}
.steps h3 { margin-bottom: 0.25rem; }
.steps p { color: var(--muted); margin: 0; font-size: 0.97rem; }
.step-no {
  flex: none;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
}

/* Pricing */
.price-card {
  display: grid;
  gap: 1.5rem;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 4vw, 2.5rem);
  box-shadow: var(--shadow);
}
.price-card p { color: var(--muted); }
.price-card .btn { justify-self: start; }
.cta-stack { display: flex; flex-direction: column; gap: 0.6rem; align-self: center; }
.cta-stack .btn { justify-content: center; text-align: center; }
.price-from { font-size: 1.25rem; font-weight: 700; color: var(--text) !important; margin-bottom: 0.5rem; }
.price-from span { font-weight: 400; color: var(--muted); font-size: 1rem; }
.price-list { margin: 0 0 1rem; padding-left: 1.1rem; color: var(--muted); }
.price-list li { margin-bottom: 0.35rem; }
@media (min-width: 900px) {
  .price-card { grid-template-columns: 1fr auto; }
}

/* FAQ */
details {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  margin-bottom: 0.75rem;
  box-shadow: var(--shadow);
}
summary { cursor: pointer; font-weight: 600; min-height: 32px; display: flex; align-items: center; }
details p { margin: 0.75rem 0 0; color: var(--muted); }

/* Contact form */
.contact-form { display: grid; gap: 1rem; }
.contact-form label { display: grid; gap: 0.35rem; font-weight: 600; font-size: 0.95rem; }
.field-row { display: grid; gap: 1rem; }
.contact-form input,
.contact-form textarea {
  font: inherit;
  font-weight: 400;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  width: 100%;
  min-height: 44px;
}
.contact-form input[aria-invalid="true"],
.contact-form textarea[aria-invalid="true"] { border-color: var(--warn); }
.contact-form textarea { resize: vertical; }
.contact-form .btn { justify-self: start; }
.form-status { color: var(--warn); font-weight: 600; margin: 0; }
.form-success {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
}
.form-success h3 { margin-bottom: 0.25rem; }
.form-success p { color: var(--muted); margin: 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 2.5rem 0 1.5rem; }
.footer-grid { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem; }
.footer-grid nav { display: flex; gap: 1.25rem; flex-wrap: wrap; }
.footer-grid a { color: var(--muted); text-decoration: none; }
.footer-grid a:hover { color: var(--accent); }
.footer-contact { margin: 0.5rem 0 0; }
.copy { margin-top: 2rem; }

/* Responsive */
@media (min-width: 640px) {
  .field-row { grid-template-columns: 1fr 1fr; }
  .band-grid { grid-template-columns: repeat(3, 1fr); }
  .cards { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1.15fr 0.85fr; }
  .cards { grid-template-columns: repeat(4, 1fr); }
}

/* Under 760px the inline links move into the dropdown */
@media (max-width: 759px) {
  .nav-links { display: none; }
  .nav-menu { display: block; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .switch::after { transition: none; }
}

/* Module panel (hero) */
.panel {
  width: min(100%, 380px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow-lift);
}
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; margin-bottom: 0.75rem; }
.panel-title { font-weight: 700; }
.toggle-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--line);
  padding: 0.75rem 0;
}
.switch {
  position: relative;
  width: 40px;
  height: 22px;
  border-radius: 999px;
  background: var(--line);
  flex: none;
}
.switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.2s;
}
.switch.on { background: var(--accent); }
.switch.on::after { transform: translateX(18px); }
.panel-note { font-size: 0.9rem; color: var(--muted); margin: 0.5rem 0 0; }
.pill { font-size: 0.8rem; font-weight: 600; padding: 0.25rem 0.6rem; border-radius: 999px; }
.pill-on { background: var(--accent-soft); color: var(--accent); }

/* Module cards */
.module {
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.module:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-lift);
}
.module h3 { margin-bottom: 0.75rem; }
.svc-icon { width: 44px; height: 44px; padding: 10px; margin-bottom: 0.9rem; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: block; }
.module ul { margin: 0 0 1rem; padding-left: 1.1rem; color: var(--muted); font-size: 0.97rem; }
.module ul li { margin-bottom: 0.35rem; }
.module .fine-print { margin: 0; }

.core-cards { grid-template-columns: 1fr; }
@media (min-width: 640px) { .core-cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .core-cards { grid-template-columns: repeat(4, 1fr); } }

/* Switch-on explainer */
.switch-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
.switch-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow);
}
.switch-item h3 { font-size: 1.05rem; }
.switch-item p { color: var(--muted); margin: 0; font-size: 0.97rem; }
@media (min-width: 640px) { .switch-grid { grid-template-columns: repeat(2, 1fr); } }

/* Contact module checkboxes */
.checks { border: 1px solid var(--line); border-radius: 10px; padding: 0.9rem 1rem; display: grid; gap: 0.5rem; margin: 0; }
.checks legend { font-weight: 600; font-size: 0.95rem; padding: 0 0.3rem; }
.checks label { display: flex; align-items: center; gap: 0.5rem; font-weight: 400; min-height: 32px; }
.checks input { width: 18px; height: 18px; accent-color: var(--accent); }

/* Honeypot field for spam bots: hidden from people and assistive tech. */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Language switch link in the header. */
.nav-links a.lang-switch { color: var(--muted); font-size: 0.9rem; }
.nav-links a.lang-switch:hover { color: var(--accent); }
