/* ============================================================
   Amby Invest ApS — style.css
   Palette: warm concrete paper / deep slate ink / rust accent
   Type: Fraunces (display) + IBM Plex Sans (body)
   ============================================================ */

:root {
  --ink: #23292c;
  --slate: #28353a;
  --slate-2: #33444a;
  --paper: #f6f3ed;
  --surface: #ece7dd;
  --surface-2: #e2dbcb;
  --line: #d8d2c4;
  --accent: #c1622e;
  --accent-dark: #94491f;
  --accent-ink: #7a3a16;
  --white: #ffffff;
  --success: #3f6b4c;
  --error: #a3352c;
  --shadow: 0 12px 30px -14px rgba(35, 41, 44, 0.35);
  --radius: 4px;
  --maxw: 1180px;
  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body: "IBM Plex Sans", "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }
html, body { margin: 0; padding: 0; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  color: var(--slate);
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(2.1rem, 4vw + 1rem, 3.4rem); }
h2 { font-size: clamp(1.6rem, 2.4vw + 1rem, 2.35rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1em; }
.lede { font-size: 1.15rem; color: var(--slate-2); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent-dark);
  margin-bottom: 0.9em;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--accent);
  display: inline-block;
}

.icon { width: 1.2em; height: 1.2em; flex-shrink: 0; }
.icon-lg { width: 28px; height: 28px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 0.85em 1.5em;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
@media (max-width: 420px) {
  .btn { white-space: normal; text-align: center; }
}
.btn-primary { background: var(--accent); color: var(--white); }
.btn-primary:hover { background: var(--accent-dark); }
.btn-primary:disabled { background: #c79a80; cursor: not-allowed; }
.btn-ghost { background: transparent; border-color: var(--slate); color: var(--slate); }
.btn-ghost:hover { background: var(--slate); color: var(--white); }
.btn-ghost-light { background: transparent; border-color: rgba(255,255,255,0.55); color: var(--white); }
.btn-ghost-light:hover { background: rgba(255,255,255,0.14); border-color: var(--white); }
.btn-block { width: 100%; }
.btn .icon { width: 1.05em; height: 1.05em; }

/* ============ Header ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 76px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}
.brand img { width: 40px; height: 40px; border-radius: 50%; }
.brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.2rem;
  color: var(--slate);
  line-height: 1.1;
}
.brand-tagline {
  display: block;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-dark);
}

.main-nav { display: flex; align-items: center; gap: 28px; }
.main-nav a {
  text-decoration: none;
  color: var(--slate-2);
  font-weight: 500;
  font-size: 0.97rem;
  white-space: nowrap;
  padding: 4px 2px;
  border-bottom: 2px solid transparent;
}
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--accent-dark); border-bottom-color: var(--accent); }
.header-actions { display: flex; align-items: center; gap: 14px; }
.header-phone {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--slate);
  text-decoration: none;
  white-space: nowrap;
}
.header-phone .icon { color: var(--accent); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px;
  cursor: pointer;
}
.nav-toggle .icon { width: 22px; height: 22px; color: var(--slate); }

@media (max-width: 860px) {
  .main-nav {
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 8px 24px 18px;
    display: none;
  }
  .main-nav.open { display: flex; }
  .main-nav a { width: 100%; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: inline-flex; }
  .header-phone span:not(.icon-wrap) { display: none; }
}

/* ============ Hero (split layout) ============ */
.hero {
  background: var(--paper);
  background-image:
    radial-gradient(circle at 8% 12%, rgba(193,98,46,0.07), transparent 42%),
    repeating-linear-gradient(135deg, rgba(40,53,58,0.035) 0 2px, transparent 2px 26px);
  padding: 56px 0 0;
  overflow: hidden;
}
.hero .container {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: center;
}
.hero-copy { padding-bottom: 56px; }
.hero-copy h1 { margin-bottom: 0.4em; }
.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin: 26px 0 30px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}
.hero-facts div { min-width: 0; }
.hero-fact-label { display: block; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--slate-2); }
.hero-fact-value { display: block; font-weight: 600; color: var(--slate); font-size: 1.02rem; overflow-wrap: anywhere; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-media {
  position: relative;
  align-self: stretch;
  min-height: 340px;
}
.hero-media-frame {
  position: absolute;
  inset: 0;
  border: 10px solid var(--paper);
  outline: 3px solid var(--accent);
  outline-offset: -3px;
}
.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-media-caption {
  position: absolute;
  left: 20px;
  bottom: -18px;
  background: var(--slate);
  color: var(--white);
  font-size: 0.78rem;
  padding: 8px 14px;
  max-width: calc(100% - 40px);
  overflow-wrap: anywhere;
}

@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; }
  .hero-copy { padding-bottom: 8px; }
  .hero-media { min-height: 260px; margin-bottom: 48px; }
}

/* ============ Generic section rhythm ============ */
section { padding: 76px 0; }
.section-tight { padding: 56px 0; }
.section-alt { background: var(--surface); }
.section-dark { background: var(--slate); color: rgba(255,255,255,0.92); }
.section-dark h2, .section-dark h3 { color: var(--white); }
.section-head { max-width: 680px; margin-bottom: 40px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

/* ============ Facts strip ============ */
.facts-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.facts-strip > div {
  background: var(--paper);
  padding: 26px 24px;
  min-width: 0;
}
.facts-strip .icon { color: var(--accent); margin-bottom: 10px; }
.facts-strip h3 { font-size: 1.02rem; margin-bottom: 0.35em; }
.facts-strip p { font-size: 0.94rem; color: var(--slate-2); margin: 0; }

/* ============ Fokus / card grid ============ */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 26px;
}
.fokus-card {
  background: var(--paper);
  border: 1px solid var(--line);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.fokus-card-media { position: relative; aspect-ratio: 4/3; overflow: hidden; background: var(--surface-2); }
.fokus-card-media img { width: 100%; height: 100%; object-fit: cover; }
.fokus-card-body { padding: 22px; flex: 1; display: flex; flex-direction: column; min-width: 0; }
.fokus-card-body h3 { margin-bottom: 0.4em; }
.fokus-card-body p { font-size: 0.95rem; color: var(--slate-2); margin-bottom: 1em; }
.fokus-card-body ul { margin: 0 0 1em; padding-left: 1.1em; font-size: 0.92rem; color: var(--slate-2); }
.fokus-card-body li { margin-bottom: 0.35em; }
.fokus-card-link { margin-top: auto; font-weight: 600; color: var(--accent-dark); text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.fokus-card-link .icon { width: 1em; height: 1em; }

/* ============ Process ============ */
.process-list {
  counter-reset: proces;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 22px;
}
.process-step {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 28px 22px 24px;
  min-width: 0;
}
.process-step::before {
  counter-increment: proces;
  content: counter(proces);
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--accent);
  display: block;
  margin-bottom: 10px;
}
.process-step h3 { font-size: 1.08rem; }
.process-step p { font-size: 0.93rem; color: var(--slate-2); margin: 0; }

/* ============ Trust / why-us ============ */
.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
}
.trust-item { display: flex; gap: 16px; align-items: flex-start; }
.trust-item .icon-wrap {
  flex-shrink: 0;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(193,98,46,0.14);
  display: flex; align-items: center; justify-content: center;
}
.trust-item .icon { color: var(--accent); }
.trust-item h3 { font-size: 1.04rem; margin-bottom: 0.3em; }
.trust-item p { font-size: 0.93rem; color: rgba(255,255,255,0.78); margin: 0; }
.section-dark .trust-item .icon-wrap { background: rgba(255,255,255,0.12); }
.section-dark .trust-item .icon { color: #f0b28c; }

/* ============ FAQ ============ */
.faq-list { max-width: 780px; }
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 4px;
  cursor: pointer;
  font-weight: 600;
  color: var(--slate);
  list-style: none;
  font-size: 1.02rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary .icon { color: var(--accent); transition: transform 0.2s ease; flex-shrink: 0; }
.faq-item[open] summary .icon { transform: rotate(180deg); }
.faq-item p { padding: 0 4px 20px; color: var(--slate-2); font-size: 0.95rem; max-width: 66ch; }

/* ============ About + Contact combined (index) ============ */
.about-contact {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: start;
}
.about-contact-copy h2 { margin-bottom: 0.5em; }
.about-contact-copy p { color: var(--slate-2); }
.about-contact-card {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 30px;
}
.about-contact-card h3 { margin-bottom: 1em; }
.about-contact-row { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 16px; min-width: 0; }
.about-contact-row .icon { color: var(--accent); margin-top: 3px; }
.about-contact-row div { min-width: 0; overflow-wrap: anywhere; }
.about-contact-row a { text-decoration: none; font-weight: 600; }
.about-contact-row a:hover { text-decoration: underline; }

@media (max-width: 860px) {
  .about-contact { grid-template-columns: 1fr; }
}

/* ============ Contact page ============ */
.contact-info-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 20px;
  margin-bottom: 56px;
}
.contact-info-card {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 22px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  min-width: 0;
}
.contact-info-card .icon-wrap {
  width: 42px; height: 42px; border-radius: 50%;
  background: rgba(193,98,46,0.12);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.contact-info-card .icon { color: var(--accent); }
.contact-info-card div { min-width: 0; overflow-wrap: anywhere; }
.contact-info-card h3 { font-size: 0.95rem; margin-bottom: 0.3em; }
.contact-info-card a, .contact-info-card p { font-size: 0.92rem; color: var(--slate-2); margin: 0; text-decoration: none; }
.contact-info-card a:hover { text-decoration: underline; }

/* Lejemaalstype selector cards */
.selector-group { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 34px; }
.selector-card {
  position: relative;
  border: 2px solid var(--line);
  background: var(--paper);
  padding: 20px 18px;
  cursor: pointer;
  text-align: left;
  min-width: 0;
}
.selector-card .icon { color: var(--accent); margin-bottom: 10px; }
.selector-card h4 { margin: 0 0 4px; font-family: var(--font-body); font-weight: 600; font-size: 0.98rem; color: var(--slate); }
.selector-card p { margin: 0; font-size: 0.85rem; color: var(--slate-2); }
.selector-card:hover { border-color: var(--accent); }
.selector-card.selected { border-color: var(--accent); background: rgba(193,98,46,0.07); }
.selector-card.selected::after {
  content: "✓";
  position: absolute; top: 10px; right: 12px;
  color: var(--accent); font-weight: 700;
}
.selector-error { color: var(--error); font-size: 0.85rem; margin: -20px 0 24px; display: none; }
.selector-error.show { display: block; }

.contact-form-wrap {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 40px;
  max-width: 780px;
}
.form-row { margin-bottom: 20px; }
.form-row label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--slate);
  margin-bottom: 6px;
}
.form-row input[type="text"],
.form-row input[type="email"],
.form-row input[type="tel"],
.form-row textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  font-family: var(--font-body);
  font-size: 0.98rem;
  color: var(--ink);
}
.form-row textarea { resize: vertical; min-height: 120px; }
.form-row input:invalid[data-touched="true"] { border-color: var(--error); }
.field-error {
  display: none;
  color: var(--error);
  font-size: 0.82rem;
  margin-top: 6px;
}
.field-error.show { display: block; }
.form-row.has-error input,
.form-row.has-error textarea { border-color: var(--error); }

.form-consent { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 26px; }
.form-consent input { margin-top: 4px; flex-shrink: 0; }
.form-consent label { font-size: 0.86rem; color: var(--slate-2); font-weight: 400; }
.form-consent a { color: var(--accent-dark); font-weight: 600; }

.form-note { font-size: 0.82rem; color: var(--slate-2); margin-top: 14px; }

.form-status {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  margin-bottom: 20px;
}
.form-status.show { display: flex; }
.form-status.error { background: rgba(163,53,44,0.1); color: var(--error); }

.spinner {
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.5);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .spinner { animation: none; }
  html { scroll-behavior: auto; }
}

/* Map card (click-to-load) */
.map-band { margin-top: 60px; }
.map-placeholder {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 24px;
  text-align: center;
}
.map-placeholder-inner { max-width: 420px; }
.map-placeholder .icon { color: var(--accent); margin: 0 auto 14px; }
.map-placeholder h3 { margin-bottom: 0.4em; }
.map-placeholder p { font-size: 0.9rem; color: var(--slate-2); }
.map-embed-container { display: none; }
.map-embed-container.show { display: block; }
.map-embed-container iframe { width: 100%; height: 380px; border: 0; display: block; }

/* ============ Profil page ============ */
.profile-hero {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.profile-columns { display: grid; grid-template-columns: 1.3fr 0.7fr; gap: 44px; align-items: start; }
.profile-columns > * { min-width: 0; }
.profile-fact-card {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 26px;
}
.profile-fact-card dl { margin: 0; }
.profile-fact-card .fact-row { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.profile-fact-card .fact-row:last-child { border-bottom: none; }
.profile-fact-card dt { color: var(--slate-2); font-size: 0.88rem; flex-shrink: 0; }
.profile-fact-card dd { margin: 0; font-weight: 600; text-align: right; overflow-wrap: anywhere; min-width: 0; }
@media (max-width: 900px) { .profile-columns { grid-template-columns: 1fr; } }

.values-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.value-card { border-left: 3px solid var(--accent); padding-left: 18px; }
.value-card h3 { font-size: 1.05rem; }
.value-card p { font-size: 0.94rem; color: var(--slate-2); margin: 0; }

/* ============ Legal pages ============ */
.legal-page main { padding: 0; }
.legal-hero { background: var(--surface); border-bottom: 1px solid var(--line); padding: 48px 0 40px; }
.legal-hero p { color: var(--slate-2); margin: 0; }
.legal-body { padding: 48px 0 76px; }
.legal-body .container { max-width: 820px; }
.legal-body h2 { margin-top: 1.6em; }
.legal-body h2:first-child { margin-top: 0; }
.legal-body h3 { margin-top: 1.2em; font-size: 1.1rem; }
.legal-body ul, .legal-body ol { padding-left: 1.3em; }
.legal-body li { margin-bottom: 0.5em; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 1.4em 0; border: 1px solid var(--line); }
.legal-body table { width: 100%; min-width: 560px; border-collapse: collapse; margin: 0; font-size: 0.92rem; }
.legal-body th, .legal-body td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; }
.legal-body th { background: var(--surface); }

/* ============ Thank you page ============ */
.thankyou-wrap {
  min-height: 60vh;
  display: flex;
  align-items: center;
  padding: 76px 0;
}
.thankyou-card { max-width: 640px; }
.thankyou-check {
  width: 60px; height: 60px;
  border-radius: 50%;
  background: rgba(63,107,76,0.14);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
}
.thankyou-check .icon { color: var(--success); width: 30px; height: 30px; }
.thankyou-next { background: var(--surface); border: 1px solid var(--line); padding: 24px; margin: 26px 0; }
.thankyou-next ol { margin: 0; padding-left: 1.2em; }
.thankyou-next li { margin-bottom: 0.6em; }

/* ============ Footer ============ */
.site-footer { background: var(--slate); color: rgba(255,255,255,0.82); padding: 60px 0 26px; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 36px;
  margin-bottom: 40px;
}
.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; text-decoration: none; }
.footer-brand img { width: 36px; height: 36px; border-radius: 50%; }
.footer-brand span { font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; color: var(--white); }
.site-footer p { font-size: 0.9rem; color: rgba(255,255,255,0.65); }
.footer-col h4 { color: var(--white); font-family: var(--font-body); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 16px; }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: rgba(255,255,255,0.78); text-decoration: none; font-size: 0.92rem; overflow-wrap: anywhere; }
.footer-col a:hover { color: var(--white); text-decoration: underline; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.14);
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.55);
}
@media (max-width: 860px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* ============ Cookie banner ============ */
.cookie-banner {
  position: fixed;
  left: 16px; right: 16px; bottom: 16px;
  max-width: 640px;
  margin: 0 auto;
  background: var(--slate);
  color: rgba(255,255,255,0.92);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 24px;
  z-index: 100;
}
.cookie-banner[hidden] { display: none; }
.cookie-banner p { font-size: 0.88rem; margin: 0 0 16px; color: rgba(255,255,255,0.85); }
.cookie-banner-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.cookie-banner-actions .btn { font-size: 0.88rem; padding: 0.7em 1.2em; }
.cookie-link-btn {
  background: none; border: none; color: rgba(255,255,255,0.75);
  text-decoration: underline; cursor: pointer; font-size: 0.88rem; padding: 0.7em 0.2em;
}

.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(35,41,44,0.55);
  z-index: 110;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay[hidden] { display: none !important; }
.modal-overlay.visible { display: flex; }
.modal-card {
  background: var(--paper);
  max-width: 520px;
  width: 100%;
  padding: 32px;
  border-radius: var(--radius);
  max-height: 85vh;
  overflow-y: auto;
}
.modal-card h2 { margin-bottom: 0.3em; }
.modal-card > p { color: var(--slate-2); font-size: 0.92rem; }
.consent-category { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.consent-category:last-of-type { border-bottom: none; }
.consent-category h3 { font-size: 0.98rem; margin-bottom: 0.25em; }
.consent-category p { font-size: 0.85rem; color: var(--slate-2); margin: 0; }
.switch { position: relative; width: 44px; height: 24px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch-track {
  position: absolute; inset: 0; background: var(--line); border-radius: 999px; transition: background 0.15s;
}
.switch-track::before {
  content: ""; position: absolute; width: 18px; height: 18px; left: 3px; top: 3px;
  background: var(--white); border-radius: 50%; transition: transform 0.15s;
}
.switch input:checked + .switch-track { background: var(--accent); }
.switch input:checked + .switch-track::before { transform: translateX(20px); }
.switch input:disabled + .switch-track { opacity: 0.55; }
.modal-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 24px; }

/* Skip link */
.skip-link {
  position: absolute; left: 16px; top: 0;
  background: var(--slate); color: var(--white);
  padding: 10px 16px; z-index: 200;
  transform: translateY(-150%);
  transition: transform 0.15s ease;
}
.skip-link:focus { transform: translateY(16px); }

/* Utility */
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
