/* ===========================================================
   Selzer Renovering ApS — frontpage design system
   Warm-neutral palette · 3 directions (Arkitekt / Håndværk / Studio)
   Tokens are driven by CSS variables set on #root by the React app.
   =========================================================== */

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

:root {
  --maxw: 1200px;
  --gutter: clamp(20px, 5vw, 64px);
  /* tokens below are overwritten inline by the app per direction/mode */
  --bg: #f4f1ec;
  --surface: #faf8f3;
  --surface-2: #ece7dc;
  --text: #2b2b28;
  --muted: #6f6a60;
  --line: #ddd6c9;
  --accent: #a87c4f;
  --on-accent: #fbf9f5;
  --radius: 4px;
  --font-head: "Manrope", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

#root { min-height: 100vh; }
#root-theme { background: var(--bg); color: var(--text); min-height: 100vh; }

/* ---------- layout helpers ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }
.wrap-wide { max-width: 1360px; }
.section { padding-block: clamp(64px, 9vw, 132px); }
.eyebrow {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 26px; height: 1px;
  background: var(--accent);
  display: inline-block;
}
.section-head { max-width: 720px; }
.section-head h2 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(30px, 4vw, 50px);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin-top: 18px;
  text-wrap: balance;
}
.section-head p {
  margin-top: 18px;
  color: var(--muted);
  font-size: 19px;
  max-width: 60ch;
  text-wrap: pretty;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  letter-spacing: .01em;
  padding: 15px 26px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform .18s ease, background .18s ease, color .18s ease, border-color .18s ease;
  line-height: 1;
}
.btn svg { width: 17px; height: 17px; }
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { transform: translateY(-2px); filter: brightness(1.05); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-lg { padding: 18px 32px; font-size: 17px; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in oklab, var(--bg) 86%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s ease, background .25s ease;
}
.site-header.scrolled { border-bottom-color: var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 78px; gap: 24px; }
.brand { display: flex; align-items: center; gap: 13px; text-decoration: none; color: var(--text); flex: none; }
.brand-logo { height: 40px; width: auto; display: block; }
@media (max-width: 560px) { .brand-logo { height: 34px; } }
.brand-mark {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  background: var(--accent); color: var(--on-accent);
  font-family: var(--font-head); font-weight: 600; font-size: 20px;
  border-radius: calc(var(--radius) * .8);
}
.brand-name { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name b { font-family: var(--font-head); font-weight: 600; font-size: 19px; letter-spacing: .01em; white-space: nowrap; }
.brand-name span { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a { color: var(--text); text-decoration: none; font-size: 15.5px; font-weight: 500; opacity: .8; white-space: nowrap; transition: opacity .15s, color .15s; }
.nav-links a:hover { opacity: 1; color: var(--accent); }
.nav-cta { display: flex; align-items: center; gap: 16px; }
.nav-phone { font-weight: 600; font-size: 15.5px; color: var(--text); text-decoration: none; white-space: nowrap; }
.nav-phone:hover { color: var(--accent); }
.menu-btn { display: none; background: none; border: 1px solid var(--line); border-radius: var(--radius); padding: 9px 11px; cursor: pointer; color: var(--text); }
@media (max-width: 980px) {
  .nav-links, .nav-phone { display: none; }
  .menu-btn { display: inline-flex; }
}

/* ---------- hero ---------- */
.hero { position: relative; }
.hero-kicker { color: var(--accent); }
.hero h1 {
  font-family: var(--font-head);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.06;
  text-wrap: pretty;
}
.hero-sub { color: var(--muted); font-size: clamp(18px, 1.5vw, 21px); max-width: 52ch; text-wrap: pretty; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.hero-trust { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 8px; }
.hero-trust .ht { display: flex; align-items: center; gap: 10px; font-size: 15px; color: var(--text); }
.hero-trust .ht svg { width: 19px; height: 19px; color: var(--accent); flex: none; }

/* layout: SPLIT */
.hero--split .hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(32px, 5vw, 72px); align-items: center; padding-block: clamp(56px, 8vw, 104px); }
.hero--split h1 { font-size: clamp(38px, 5vw, 66px); }
.hero--split .hero-copy { display: flex; flex-direction: column; gap: 26px; }
.hero--split .hero-media { aspect-ratio: 4/5; }

/* layout: FULL bleed */
.hero--full { margin-top: calc(-1 * var(--header-h, 78px)); }
.hero--full .hero-stage { position: relative; min-height: clamp(560px, 84vh, 820px); display: flex; align-items: flex-end; padding-top: var(--header-h, 78px); }
.hero--full .hero-media-bg { position: absolute; inset: 0; background: linear-gradient(150deg, #3a342c 0%, #2a2620 55%, #211d18 100%); }
.hero--full .hero-media-bg image-slot { background: transparent; }
.hero--full .hero-scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20,18,15,.18) 0%, rgba(20,18,15,.10) 38%, rgba(20,18,15,.74) 100%); pointer-events: none; }
.hero--full .hero-copy { position: relative; color: #f6f3ec; padding-bottom: clamp(48px, 7vw, 88px); display: flex; flex-direction: column; gap: 24px; max-width: 760px; }
.hero--full h1 { font-size: clamp(40px, 6vw, 78px); color: #fff; }
.hero--full .hero-sub { color: rgba(246,243,236,.86); }
.hero--full .hero-trust .ht { color: #f6f3ec; }
.hero--full .hero-kicker { color: #e8c79f; }

/* ghost button over the photo hero — white text + border so it stays readable */
.hero--full .btn-ghost { color: #fff; border-color: rgba(255,255,255,.6); }
.hero--full .btn-ghost:hover { color: var(--accent); border-color: var(--accent); background: transparent; }

/* layout: CENTER */
.hero--center .hero-stage { text-align: center; padding-block: clamp(72px, 11vw, 150px) 0; display: flex; flex-direction: column; align-items: center; gap: 26px; }
.hero--center h1 { font-size: clamp(42px, 6.4vw, 88px); max-width: 16ch; }
.hero--center .hero-sub { margin-inline: auto; }
.hero--center .hero-actions { justify-content: center; }
.hero--center .hero-trust { justify-content: center; }
.hero--center .hero-media { margin-top: clamp(40px, 6vw, 80px); aspect-ratio: 21/9; }

/* image slot styling */
image-slot {
  --slot-bg: var(--surface-2);
  display: block; width: 100%; height: 100%;
  background: var(--surface-2);
}
.hero-media { width: 100%; overflow: hidden; border-radius: var(--radius); }
.hero-media image-slot, .hero--full .hero-media-bg image-slot { width: 100%; height: 100%; }
.hero-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero--full .hero-img { position: absolute; inset: 0; }

/* ---------- services ---------- */
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(18px, 2.4vw, 30px); margin-top: 54px; }
@media (max-width: 820px) { .services-grid { grid-template-columns: 1fr; } }
.svc {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0;
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.svc:hover { transform: translateY(-4px); border-color: color-mix(in oklab, var(--accent) 55%, var(--line)); box-shadow: 0 22px 48px -28px rgba(40,34,24,.45); }
.svc-media { aspect-ratio: 16/11; width: 100%; background: var(--surface-2); overflow: hidden; }
.svc-media image-slot { width: 100%; height: 100%; }
.svc-media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.svc:hover .svc-media img { transform: scale(1.04); }
.svc-body { padding: 26px 26px 30px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.svc-num { font-family: var(--font-head); font-size: 14px; color: var(--accent); letter-spacing: .04em; }
.svc h3 { font-family: var(--font-head); font-weight: 600; font-size: 26px; line-height: 1.1; }
.svc p { color: var(--muted); font-size: 16px; flex: 1; text-wrap: pretty; }
.svc-link { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 15px; color: var(--text); text-decoration: none; margin-top: 4px; }
.svc-link svg { width: 16px; height: 16px; transition: transform .18s ease; }
.svc:hover .svc-link { color: var(--accent); }
.svc:hover .svc-link svg { transform: translateX(4px); }

/* vibe: editorial → flatter cards (arkitekt) */
[data-vibe="editorial"] .svc { background: transparent; border-color: transparent; border-top: 1px solid var(--line); border-radius: 0; }
[data-vibe="editorial"] .svc:hover { transform: translateY(-4px); box-shadow: none; border-color: transparent; border-top-color: var(--accent); }
[data-vibe="editorial"] .svc-media { border-radius: var(--radius); margin-top: 2px; }
[data-vibe="editorial"] .svc-body { padding-inline: 0; }

/* ---------- process ---------- */
.process { background: var(--surface); border-block: 1px solid var(--line); }
[data-mode="dark"] .process { background: color-mix(in oklab, var(--bg) 60%, #000 4%); }
.process-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(20px, 3vw, 44px); margin-top: 56px; counter-reset: step; }
@media (max-width: 900px) { .process-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 540px) { .process-grid { grid-template-columns: 1fr; } }
.step { position: relative; padding-top: 30px; border-top: 2px solid var(--line); }
.step-num { position: absolute; top: -16px; left: 0; font-family: var(--font-head); font-size: 15px; font-weight: 600; color: var(--on-accent); background: var(--accent); width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; }
.step h3 { font-family: var(--font-head); font-weight: 600; font-size: 22px; margin-bottom: 10px; }
.step p { color: var(--muted); font-size: 16px; text-wrap: pretty; }

/* positioning band inside process intro */
.process .section-head h2 em { font-style: italic; color: var(--accent); }

/* ---------- service area ---------- */
.area-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 76px); align-items: center; }
@media (max-width: 860px) { .area-grid { grid-template-columns: 1fr; } }
.area-media { aspect-ratio: 5/4; border-radius: var(--radius); overflow: hidden; background: var(--surface-2); }
.area-media image-slot { width: 100%; height: 100%; }
.area-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.area-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.area-chip { font-size: 14.5px; font-weight: 500; padding: 8px 15px; border: 1px solid var(--line); border-radius: 999px; color: var(--text); background: var(--surface); white-space: nowrap; }
.area-note { margin-top: 24px; color: var(--muted); font-size: 15px; }

/* ---------- contact ---------- */
.contact { background: var(--surface); border-top: 1px solid var(--line); }
[data-mode="dark"] .contact { background: color-mix(in oklab, var(--bg) 60%, #000 4%); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 5vw, 80px); }
@media (max-width: 820px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-aside { display: flex; flex-direction: column; gap: 26px; }
.contact-points { display: flex; flex-direction: column; gap: 18px; margin-top: 6px; }
.cp { display: flex; gap: 14px; align-items: flex-start; }
.cp-text { display: flex; flex-direction: column; gap: 2px; }
.cp-text b { font-family: var(--font-head); font-weight: 700; font-size: 17px; }
.cp-text span { color: var(--muted); font-size: 15.5px; }
.cp-ic { width: 42px; height: 42px; flex: none; border-radius: var(--radius); display: grid; place-items: center; background: color-mix(in oklab, var(--accent) 14%, var(--surface)); color: var(--accent); }
.cp-ic svg { width: 20px; height: 20px; }
.cp b { font-family: var(--font-head); font-weight: 600; font-size: 17px; display: block; }
.cp span { color: var(--muted); font-size: 15.5px; }

/* transparent light header over full-bleed photo hero */
.site-header.hdr-light { background: transparent; border-bottom-color: transparent; }
.site-header.hdr-light .brand-name b,
.site-header.hdr-light .nav-links a,
.site-header.hdr-light .nav-phone { color: #f6f3ec; }
.site-header.hdr-light .nav-links a { opacity: .92; }
.site-header.hdr-light .nav-links a:hover { color: #fff; opacity: 1; }
.site-header.hdr-light .brand-name span { color: rgba(246,243,236,.7); }
.site-header.hdr-light .menu-btn { color: #f6f3ec; border-color: rgba(246,243,236,.4); }

/* footer brand */
.footer-brand { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.footer-logo { height: 34px; width: auto; display: block; }
.footer-cvr { font-size: 14px; color: color-mix(in oklab, var(--bg) 64%, #fff); }

form.lead { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 3vw, 34px); display: flex; flex-direction: column; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field label { font-size: 13.5px; font-weight: 600; letter-spacing: .02em; }
.field .req { color: var(--accent); }
.field input, .field textarea, .field select {
  font-family: var(--font-body); font-size: 16px; color: var(--text);
  background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) * .8);
  padding: 13px 15px; width: 100%; transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--accent) 22%, transparent);
}
.field textarea { resize: vertical; min-height: 104px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 520px) { .field-row { grid-template-columns: 1fr; } }
.form-meta { font-size: 13px; color: var(--muted); }
.form-ok { background: color-mix(in oklab, var(--accent) 12%, var(--bg)); border: 1px solid color-mix(in oklab, var(--accent) 40%, var(--line)); border-radius: var(--radius); padding: 30px; text-align: center; }
.form-ok h3 { font-family: var(--font-head); font-weight: 600; font-size: 26px; margin-bottom: 8px; }
.form-ok p { color: var(--muted); }

/* ---------- footer ---------- */
.site-footer { background: var(--text); color: color-mix(in oklab, var(--bg) 86%, #fff); }
[data-mode="dark"] .site-footer { background: #131210; }
.footer-cta { padding-block: clamp(56px, 8vw, 104px); text-align: center; display: flex; flex-direction: column; align-items: center; gap: 22px; border-bottom: 1px solid rgba(255,255,255,.12); }
.footer-cta h2 { font-family: var(--font-head); font-weight: 700; font-size: clamp(30px, 4.4vw, 56px); line-height: 1.05; color: var(--bg); max-width: 18ch; text-wrap: balance; }
.footer-cta p { color: color-mix(in oklab, var(--bg) 70%, #fff); max-width: 52ch; }
.footer-cta .btn-primary { background: var(--accent); color: var(--on-accent); }
.footer-bottom { padding-block: 34px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 18px; font-size: 14px; color: color-mix(in oklab, var(--bg) 64%, #fff); }
.footer-bottom .brand-name b { color: var(--bg); }
.footer-bottom a { color: inherit; text-decoration: none; }
.footer-bottom a:hover { color: var(--accent); }
.footer-cols { display: flex; gap: 40px; flex-wrap: wrap; }

/* ---------- misc placeholder caption styling (for image-slot empty state) ---------- */
image-slot::part(placeholder) { font-family: ui-monospace, "SF Mono", Menlo, monospace; }

/* reveal-on-scroll */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- client-facing direction switcher (preview pill) ---------- */
.dirswitch {
  position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%);
  z-index: 60; display: flex; align-items: center; gap: 14px;
  background: rgba(17,24,39,.92); backdrop-filter: blur(12px);
  color: #F5F5F4; padding: 7px 7px 7px 18px; border-radius: 999px;
  box-shadow: 0 16px 44px -14px rgba(0,0,0,.55); font-family: var(--font-body);
  border: 1px solid rgba(255,255,255,.08);
}
.dirswitch-label { font-size: 11.5px; letter-spacing: .16em; text-transform: uppercase; color: rgba(245,245,244,.55); font-weight: 600; white-space: nowrap; }
.dirswitch-track { display: flex; gap: 3px; }
.dirswitch-btn { font-family: var(--font-body); font-size: 14px; font-weight: 600; color: #F5F5F4; background: transparent; border: none; padding: 9px 17px; border-radius: 999px; cursor: pointer; transition: background .15s, color .15s; white-space: nowrap; }
.dirswitch-btn:hover { background: rgba(255,255,255,.1); }
.dirswitch-btn.active { background: var(--accent); color: #fff; }
@media (max-width: 560px) { .dirswitch-label { display: none; } .dirswitch { padding-left: 7px; gap: 0; } }
@media print {
  .dirswitch, .menu-btn { display: none !important; }
  * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
  @page { size: A4 portrait; margin: 11mm 9mm; }

  html, body { background: #fff !important; }
  /* de-stick header; keep it as a dark band that flows into the dark hero */
  .site-header { position: static !important; background: #111827 !important; border-bottom: none !important; backdrop-filter: none !important; }

  /* full hero no longer overlaps the (now static) header */
  .hero--full { margin-top: 0 !important; }
  .hero--full .hero-stage { min-height: 0 !important; padding: 56px 0 64px !important; }

  /* scroll-reveal would otherwise stay hidden when printed */
  .reveal { opacity: 1 !important; transform: none !important; }

  /* tighter rhythm + keep blocks intact across pages */
  .section { padding-block: 46px !important; }
  .svc, .step, form.lead, .area-media, .cp,
  .section-head, .footer-cta, .hero-copy { break-inside: avoid; }
  .process, .contact, .site-footer { break-inside: avoid; }
  a[href]::after { content: "" !important; }
}
