/* ==========================================================================
   Vand under kølen — Et liv i Den Blå Verden
   Statisk site · ingen eksterne afhængigheder · design bygget om bogens
   visuals: havets blå, skummets hvid og tankernes rød.
   ========================================================================== */

:root {
  --sea-950: #061726;
  --sea-900: #0b2239;
  --sea-800: #10304e;
  --sea-700: #154067;
  --sea-600: #1e5580;
  --foam: #f4f7f9;
  --paper: #ffffff;
  --sand: #e9e2d4;
  --brass: #c9a86a;
  --brass-dark: #a9884f;
  --tanker-red: #d64541;
  --tanker-red-dark: #b23532;
  --ink: #16324a;
  --ink-soft: #46617a;
  --line: #d8e1e8;
  --shadow-lg: 0 24px 60px -18px rgba(6, 23, 38, .45);
  --shadow-md: 0 12px 30px -12px rgba(6, 23, 38, .35);
  --shadow-sm: 0 4px 14px -4px rgba(6, 23, 38, .25);
  --radius: 18px;
  --radius-sm: 10px;
  --font-head: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --wrap: 72rem;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--ink);
  background: var(--foam);
}

img, svg, video { max-width: 100%; height: auto; }

::selection { background: var(--brass); color: var(--sea-950); }

/* ---------- typography ---------- */

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--sea-900);
  line-height: 1.15;
  margin: 0 0 .5em;
  text-wrap: balance;
}

h1 { font-size: clamp(2.1rem, 5.2vw, 3.6rem); letter-spacing: .01em; }
h2 { font-size: clamp(1.55rem, 3.2vw, 2.3rem); margin-top: 2.2em; }
h3 { font-size: clamp(1.2rem, 2vw, 1.45rem); }

p { margin: 0 0 1.1em; }

a { color: var(--sea-600); text-underline-offset: 3px; }
a:hover { color: var(--sea-800); }

.entry > p:first-of-type::first-letter {
  font-family: var(--font-head);
  font-size: 3.4em;
  font-weight: 700;
  float: left;
  line-height: .82;
  padding: .08em .12em 0 0;
  color: var(--sea-700);
}

/* ---------- helpers ---------- */

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: clamp(1rem, 4vw, 2rem); }

.skip {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--sea-900); color: #fff; padding: .7rem 1.1rem; border-radius: 0 0 var(--radius-sm) 0;
}
.skip:focus { left: 0; }

.eyebrow {
  display: inline-flex; align-items: center; gap: .55em;
  font-size: .78rem; font-weight: 700; letter-spacing: .22em; text-transform: uppercase;
  color: var(--brass);
}
.eyebrow::before { content: ""; width: 2.2rem; height: 2px; background: currentColor; border-radius: 2px; }

.lead { font-size: clamp(1.1rem, 1.7vw, 1.3rem); color: var(--ink-soft); }

.section { padding-block: clamp(2.5rem, 7vw, 5rem); }
.section-head { max-width: 46rem; margin-bottom: clamp(1.5rem, 4vw, 2.75rem); }

/* ---------- buttons ---------- */

.btn {
  display: inline-flex; align-items: center; gap: .55em;
  padding: .78em 1.5em; border-radius: 999px;
  font-weight: 700; font-size: .98rem; text-decoration: none;
  border: 2px solid transparent; cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn svg { width: 1.05em; height: 1.05em; flex: none; }

.btn-primary { background: var(--tanker-red); color: #fff; box-shadow: 0 10px 22px -10px rgba(214, 69, 65, .8); }
.btn-primary:hover { background: var(--tanker-red-dark); color: #fff; }

.btn-outline { border-color: var(--brass); color: var(--brass); }
.btn-outline:hover { background: var(--brass); color: var(--sea-950); }

.btn-shadow { background: var(--sea-900); color: #fff; box-shadow: var(--shadow-sm); }
.btn-shadow:hover { background: var(--sea-700); color: #fff; }

/* ---------- header / nav ---------- */

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 34, 57, .92);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(201, 168, 106, .25);
}

.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding-block: .65rem;
}

.brand {
  display: inline-flex; align-items: center; gap: .6rem;
  color: #fff; text-decoration: none; font-family: var(--font-head);
  font-size: 1.08rem; font-weight: 700; letter-spacing: .04em;
  white-space: nowrap;
}
.brand svg { width: 30px; height: 30px; flex: none; }
.brand small { display: block; font-family: var(--font-body); font-size: .62rem; font-weight: 600; letter-spacing: .28em; text-transform: uppercase; color: var(--brass); }

.nav-toggle { display: none; }

.site-nav ul { display: flex; flex-wrap: wrap; gap: .15rem; margin: 0; padding: 0; list-style: none; }

.site-nav a {
  display: block; padding: .5rem .8rem; border-radius: var(--radius-sm);
  color: rgba(255, 255, 255, .85); text-decoration: none;
  font-size: .93rem; font-weight: 600;
  transition: background .15s ease, color .15s ease;
}
.site-nav a:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.site-nav a[aria-current="page"] { background: rgba(201, 168, 106, .18); color: var(--brass); }

/* Mobile nav (checkbox-hack, ingen JS) */
@media (max-width: 860px) {
  .nav-toggle-btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 2.6rem; height: 2.6rem; border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, .08); border: 0; padding: .5rem; cursor: pointer;
  }
  .nav-toggle-btn svg { width: 100%; height: 100%; color: #fff; }
  .site-nav {
    display: none;
    position: absolute; inset-inline: 0; top: 100%;
    background: var(--sea-900); border-bottom: 1px solid rgba(201, 168, 106, .3);
    box-shadow: var(--shadow-lg);
  }
  .nav-toggle:checked ~ .site-header .site-nav { display: block; }
  .site-header { position: sticky; }
  .site-header .wrap { position: relative; }
  .site-nav ul { flex-direction: column; padding: .6rem clamp(1rem, 4vw, 2rem) 1rem; gap: .2rem; }
  .site-nav a { padding: .65rem .9rem; }
}

@media (min-width: 861px) {
  .nav-toggle-btn { display: none; }
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(30, 85, 128, .55), transparent 60%),
    radial-gradient(900px 420px at -10% 110%, rgba(20, 64, 103, .5), transparent 60%),
    linear-gradient(180deg, var(--sea-950) 0%, var(--sea-900) 58%, var(--sea-800) 100%);
  color: #eaf1f6;
  overflow: hidden;
}

.hero::after { /* subtil stjernelys/prikker */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, .055) 1px, transparent 1.4px);
  background-size: 26px 26px;
  mask-image: linear-gradient(180deg, rgba(0,0,0,.9), transparent 70%);
}

.hero .wrap {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  align-items: center; gap: clamp(2rem, 6vw, 4.5rem);
  padding-block: clamp(3.5rem, 9vw, 6.5rem) clamp(4.5rem, 10vw, 7.5rem);
}

.hero h1 { color: #fff; }
.hero h1 .accent { color: var(--brass); }

.hero .lead { color: rgba(234, 241, 246, .82); max-width: 34rem; }

.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }

.hero-visual { position: relative; text-align: center; }

.hero-visual img {
  width: min(100%, 26rem);
  filter: drop-shadow(0 40px 50px rgba(0, 0, 0, .5));
  animation: bob 7s ease-in-out infinite;
}

@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(-.4deg); }
  50% { transform: translateY(-14px) rotate(.4deg); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-visual img { animation: none; }
  .btn:hover { transform: none; }
}

.hero-wave { display: block; position: absolute; bottom: -1px; left: 0; width: 100%; height: auto; z-index: 1; color: var(--foam); }

/* ---------- kort / sektioner ---------- */

.cards {
  display: grid; gap: 1.1rem;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
}

.card {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem 1.5rem 1.35rem;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
  overflow: hidden;
}
.card::before {
  content: ""; position: absolute; inset: 0 auto 0 0; width: 4px;
  background: linear-gradient(180deg, var(--sea-600), var(--brass));
  opacity: 0; transition: opacity .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card:hover::before { opacity: 1; }

.card-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 3rem; height: 3rem; border-radius: 12px;
  background: linear-gradient(160deg, var(--sea-800), var(--sea-600));
  color: #fff; margin-bottom: 1rem;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.14);
}
.card-icon svg { width: 1.5rem; height: 1.5rem; }

.card h3 { margin-bottom: .3em; }
.card p { color: var(--ink-soft); font-size: .97rem; margin-bottom: 1em; }
.card .more { font-weight: 700; font-size: .93rem; text-decoration: none; }
.card .more::after { content: " →"; transition: margin .2s ease; }
.card .more:hover::after { margin-left: .25em; }

/* ---------- fakta / specsheets ---------- */

.facts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
  gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm);
}
.facts div { background: var(--paper); padding: 1rem 1.1rem; }
.facts dt, .facts .fact-label {
  font-size: .72rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink-soft); margin: 0 0 .2em;
}
.facts dd, .facts .fact-value { margin: 0; font-weight: 700; font-family: var(--font-head); font-size: 1.05rem; color: var(--sea-900); }

/* ---------- bogside (om bogen) ---------- */

.book-layout {
  display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: clamp(2rem, 6vw, 4rem); align-items: start;
}

@media (max-width: 900px) {
  .book-layout { grid-template-columns: 1fr; }
}

.book-figure { text-align: center; position: sticky; top: 5.5rem; }
.book-figure img { width: min(100%, 22rem); filter: drop-shadow(0 30px 40px rgba(6, 23, 38, .35)); border-radius: 6px; }

.buy-box {
  background: linear-gradient(160deg, var(--sea-900), var(--sea-700));
  color: #fff; border-radius: var(--radius);
  padding: clamp(1.5rem, 3.5vw, 2.25rem);
  box-shadow: var(--shadow-lg);
  margin-top: 2rem;
}
.buy-box h3 { color: #fff; margin-top: 0; }
.buy-box p { color: rgba(255, 255, 255, .85); }
.buy-box .facts div { background: rgba(255, 255, 255, .08); border: 1px solid rgba(255,255,255,.08); }
.buy-box .facts { border-color: rgba(255,255,255,.12); }
.buy-box .facts .fact-label { color: var(--brass); }
.buy-box .facts .fact-value { color: #fff; }
.buy-box .actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.5rem; }

/* ---------- indholdsfortegnelse ---------- */

.toc {
  columns: 2 18rem; column-gap: 2.5rem; counter-reset: toc;
  margin: 0; padding: 0; list-style: none;
}
.toc li {
  break-inside: avoid;
  display: flex; align-items: baseline; gap: .8rem;
  padding: .42em 0; border-bottom: 1px dashed var(--line);
  font-family: var(--font-head); color: var(--ink);
}
.toc li::before {
  counter-increment: toc;
  content: counter(toc, decimal-leading-zero);
  font-family: var(--font-body); font-size: .72rem; font-weight: 700;
  color: var(--brass-dark); letter-spacing: .08em; flex: none;
}
.toc .pgn { margin-left: auto; font-size: .8rem; font-family: var(--font-body); color: var(--ink-soft); font-variant-numeric: tabular-nums; }

/* ---------- referater / PDF-liste ---------- */

.pdf-list { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(19rem, 1fr)); }

.pdf-card {
  display: flex; gap: 1rem; align-items: flex-start;
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.15rem 1.25rem;
  box-shadow: var(--shadow-sm); text-decoration: none; color: inherit;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.pdf-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--brass); }

.pdf-icon {
  flex: none; width: 2.9rem; height: 2.9rem; border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(160deg, var(--tanker-red-dark), var(--tanker-red));
  color: #fff; font-size: .68rem; font-weight: 800; letter-spacing: .05em;
  box-shadow: 0 6px 14px -6px rgba(214, 69, 65, .7);
}
.pdf-card h3 { font-size: 1.06rem; margin: 0 0 .15em; }
.pdf-card p { font-size: .9rem; color: var(--ink-soft); margin: 0; }
.pdf-card .go { display: inline-block; margin-top: .45em; font-size: .85rem; font-weight: 700; color: var(--sea-600); }
.pdf-card .go::after { content: " ↗"; }

/* ---------- prolog-fotos ---------- */

.photo-grid {
  display: grid; gap: 1.2rem; grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  max-width: 54rem;
}
figure.photo { margin: 0; }
figure.photo img {
  border-radius: var(--radius); box-shadow: var(--shadow-md);
  width: 100%; display: block; border: 6px solid var(--paper);
  outline: 1px solid var(--line);
}
figure.photo figcaption { margin-top: .6em; font-size: .9rem; color: var(--ink-soft); font-style: italic; }

/* ---------- quote ---------- */

.pullquote {
  border-left: 4px solid var(--brass);
  margin: 2rem 0; padding: .4em 0 .4em 1.4em;
  font-family: var(--font-head); font-size: clamp(1.15rem, 2.4vw, 1.5rem);
  font-style: italic; color: var(--sea-800);
}
.pullquote cite {
  display: block; margin-top: .6em; font-family: var(--font-body);
  font-style: normal; font-size: .9rem; color: var(--ink-soft);
}

/* ---------- page hero (undersider) ---------- */

.page-hero {
  position: relative;
  background:
    radial-gradient(900px 380px at 90% -20%, rgba(30, 85, 128, .5), transparent 60%),
    linear-gradient(180deg, var(--sea-950), var(--sea-900) 80%);
  color: #fff; padding-block: clamp(2.6rem, 7vw, 4.5rem) clamp(2.6rem, 7vw, 4.5rem);
  border-bottom: 4px solid var(--brass);
  overflow: hidden;
}
.page-hero h1 { color: #fff; margin-bottom: .25em; }
.page-hero .lead { color: rgba(255,255,255,.8); max-width: 44rem; }
.page-hero .eyebrow { color: var(--brass); }

/* ---------- footer ---------- */

.site-footer {
  margin-top: clamp(2rem, 6vw, 4rem);
  background: var(--sea-950);
  color: rgba(255,255,255,.75);
  font-size: .93rem;
}
.site-footer .wrap {
  display: grid; gap: 2rem; grid-template-columns: 2fr 1fr 1fr;
  padding-block: clamp(2rem, 5vw, 3.5rem);
}
.site-footer h2 { color: var(--brass); font-size: 1.05rem; margin-bottom: .6em; font-family: var(--font-body); text-transform: uppercase; letter-spacing: .18em; font-size: .8rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; }
.site-footer a { color: rgba(255,255,255,.8); text-decoration: none; }
.site-footer a:hover { color: var(--brass); }
.site-footer .colophon { border-top: 1px solid rgba(255,255,255,.1); padding-block: 1.2rem; font-size: .82rem; color: rgba(255,255,255,.5); }
.site-footer .colophon .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem; padding-block: 1.2rem; }

@media (max-width: 800px) {
  .site-footer .wrap { grid-template-columns: 1fr; }
}

/* ---------- indholdsside ---------- */

.entry { max-width: 44rem; }

.entry-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin: 2rem 0 0; }

.breadcrumb { font-size: .85rem; color: rgba(255,255,255,.55); margin-bottom: 1.2rem; }
.breadcrumb a { color: rgba(255,255,255,.75); text-decoration: none; }
.breadcrumb a:hover { color: var(--brass); }

.notice {
  background: var(--sand); border: 1px solid #d9cfb8; border-radius: var(--radius-sm);
  padding: 1rem 1.25rem; font-size: .95rem;
}
.notice :last-child { margin-bottom: 0; }
