/*
 * CoolHost offentlig hjemmeside (coolhost.dk) – layout og komponenter.
 * Bruger kun design-tokens fra tokens.css. Responsiv og tema-aware (lys/mørk).
 */

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; }

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

/* --- logo (spejler panelets Logo-komponent) --- */
.logo { display: inline-flex; align-items: center; gap: 10px; }
.logo .word { font-weight: 800; letter-spacing: -0.02em; color: var(--ink); }
.logo .word .dk { color: var(--brand); }

/* --- knapper --- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 20px; border-radius: var(--r);
  font-size: 15px; font-weight: 650; cursor: pointer;
  border: 1px solid transparent; transition: transform .06s ease, box-shadow .2s ease, background .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--brand-deep); box-shadow: var(--shadow-lg); }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line-2); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn-lg { padding: 15px 26px; font-size: 16px; }

/* --- header --- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--surface) 85%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.nav { display: flex; align-items: center; gap: 26px; }
.nav a.link { color: var(--muted); font-weight: 550; font-size: 15px; }
.nav a.link:hover { color: var(--ink); }
.header-actions { display: flex; align-items: center; gap: 12px; }

.icon-btn {
  display: inline-grid; place-items: center; width: 40px; height: 40px;
  border-radius: var(--r-sm); border: 1px solid var(--line-2);
  background: var(--surface); color: var(--muted); cursor: pointer;
}
.icon-btn:hover { color: var(--brand); border-color: var(--brand); }
.theme-icon-dark { display: none; }
:root[data-theme="dark"] .theme-icon-light,
:root:not([data-theme="light"]) .theme-icon-light {}
/* toggle-ikon styres via JS (data-theme) – vis sol i mørk, måne i lys */

/* --- hero --- */
.hero { position: relative; overflow: hidden; padding: 88px 0 72px; }
.hero::before {
  content: ""; position: absolute; inset: -40% 0 auto -10%;
  height: 620px; z-index: 0; pointer-events: none;
  background:
    radial-gradient(60% 55% at 20% 20%, color-mix(in srgb, var(--brand) 22%, transparent), transparent 70%),
    radial-gradient(50% 50% at 85% 10%, color-mix(in srgb, var(--brand-bright) 18%, transparent), transparent 70%);
  filter: blur(4px);
}
.hero .container { position: relative; z-index: 1; }
.badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px; border-radius: 999px;
  background: var(--brand-soft); color: var(--brand-deep);
  font-size: 13px; font-weight: 650; border: 1px solid var(--line-2);
}
.badge .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); }
.hero h1 {
  margin: 22px 0 0; max-width: 15ch;
  font-size: clamp(34px, 6vw, 60px); line-height: 1.05; letter-spacing: -0.03em; font-weight: 850;
}
.hero h1 .accent { color: var(--brand); }
.hero .lead { margin: 20px 0 0; max-width: 56ch; font-size: clamp(16px, 2.2vw, 20px); color: var(--muted); }
.hero-cta { margin-top: 34px; display: flex; flex-wrap: wrap; gap: 14px; }
.hero-note { margin-top: 16px; font-size: 13px; color: var(--faint); }

/* --- sektioner --- */
section { scroll-margin-top: 84px; }
.section { padding: 72px 0; }
.section-head { max-width: 60ch; margin: 0 auto 44px; text-align: center; }
.section-head .eyebrow { color: var(--brand); font-weight: 700; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.section-head h2 { margin: 10px 0 0; font-size: clamp(26px, 4vw, 38px); letter-spacing: -0.02em; font-weight: 800; }
.section-head p { margin: 12px 0 0; color: var(--muted); font-size: 17px; }

/* --- funktions-grid --- */
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 24px; box-shadow: var(--shadow);
  transition: transform .12s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--line-2); }
.card .ico {
  display: inline-grid; place-items: center; width: 46px; height: 46px; border-radius: var(--r);
  background: var(--brand-soft); color: var(--brand); margin-bottom: 14px;
}
.card h3 { margin: 0 0 6px; font-size: 18px; font-weight: 700; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }

/* --- færdige apps --- */
.apps { background: var(--surface-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.apps-inner { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center; }
.chips { display: flex; flex-wrap: wrap; gap: 12px; }
.chip {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-radius: var(--r);
  background: var(--surface); border: 1px solid var(--line-2); box-shadow: var(--shadow);
  font-weight: 650; font-size: 15px;
}
.chip .tag { color: var(--faint); font-weight: 550; font-size: 12px; }

/* --- roller --- */
.roles { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.role { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 26px; box-shadow: var(--shadow); }
.role .kicker { color: var(--brand); font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; }
.role h3 { margin: 8px 0 8px; font-size: 20px; }
.role p { margin: 0; color: var(--muted); font-size: 15px; }

/* --- CTA-band --- */
.cta-band { padding: 20px 0 84px; }
.cta-inner {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--brand-deep), var(--brand));
  color: #fff; border-radius: var(--r-lg); padding: 52px 40px; text-align: center;
  box-shadow: var(--shadow-lg);
}
.cta-inner h2 { margin: 0; font-size: clamp(24px, 4vw, 34px); letter-spacing: -0.02em; }
.cta-inner p { margin: 12px auto 26px; max-width: 52ch; color: #dbe7ff; font-size: 17px; }
.cta-inner .btn-ghost { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.4); }
.cta-inner .btn-ghost:hover { background: rgba(255,255,255,.2); color: #fff; }
.cta-inner .btn-light { background: #fff; color: var(--brand-deep); }
.cta-inner .btn-light:hover { background: #eef3fe; }

/* --- footer --- */
.site-footer { background: var(--surface); border-top: 1px solid var(--line); padding: 54px 0 30px; }
.footer-grid { display: grid; gap: 32px; grid-template-columns: 1.4fr repeat(3, 1fr); }
.footer-grid h4 { margin: 0 0 14px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-grid a { color: var(--muted); font-size: 15px; }
.footer-grid a:hover { color: var(--brand); }
.footer-about p { margin: 14px 0 0; color: var(--muted); font-size: 14px; max-width: 34ch; }
.footer-bottom {
  margin-top: 40px; padding-top: 22px; border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between;
  color: var(--faint); font-size: 14px;
}
.footer-bottom .mono { font-family: var(--font-mono); font-size: 13px; }

/* --- responsivt --- */
@media (max-width: 860px) {
  .apps-inner { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav .link { display: none; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; }
  .hero { padding: 64px 0 52px; }
  .section { padding: 56px 0; }
}
