/* Land unter. The page is a sea chart: pale air at the top, the sea below
   the water line, and the content as land with a rim of tidal flat. */

@font-face { font-family: "Barlow"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/Barlow-400.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 400; font-style: italic; font-display: swap; src: url("../fonts/Barlow-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 500; font-style: normal; font-display: swap; src: url("../fonts/Barlow-500.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/Barlow-600.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/BarlowCondensed-600.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/BarlowCondensed-700.woff2") format("woff2"); }

:root {
  --luft: #eef5f6;      /* above the water line */
  --see: #7fb0c1;       /* the sea */
  --see-tief: #5f97ab;
  --land: #f1e3b3;      /* chart buff */
  --watt: #b3c4a1;      /* tidal flat */
  --tinte: #12222b;
  --marke: #9c1757;     /* the magenta of chart annotations */
  --mass: clamp(4.6rem, 19vw, 15rem);   /* size of the name on the first page */
  --rand: clamp(1rem, 4vw, 3rem);
  --breite: 74rem;
}

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

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

body {
  margin: 0;
  background: var(--see);
  color: var(--tinte);
  font-family: "Barlow", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.125rem;
  line-height: 1.6;
}

body:not(.start) { --mass: clamp(3rem, 9vw, 5.5rem); }

a { color: var(--marke); text-decoration-thickness: 0.08em; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 0.16em; }
:focus-visible { outline: 3px solid var(--marke); outline-offset: 3px; }

.sprung { position: absolute; left: -100rem; top: 0; background: var(--land); padding: 0.5rem 1rem; z-index: 10; }
.sprung:focus { left: 0; }

/* ---- Header: the name stands in the water ---- */

.kopf { background: var(--luft); }

.luft {
  position: relative;
  max-width: var(--breite);
  margin: 0 auto;
  padding: clamp(1.5rem, 7vw, 5.5rem) var(--rand) 0;
}

.marke {
  display: block;
  margin: 0;
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-weight: 700;
  font-size: var(--mass);
  line-height: 0.78;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--tinte);
  text-decoration: none;
  /* The bottom edge of the box is the foot of the letters. */
  padding-bottom: 0.02em;
}

/* The tide gauge at the right: black and white decimetres. */
.pegel {
  position: absolute;
  right: var(--rand);
  top: 0;
  bottom: 0;
  width: clamp(14px, 1.8vw, 26px);
  border-left: 2px solid var(--tinte);
  border-right: 2px solid var(--tinte);
  background:
    repeating-linear-gradient(to bottom, var(--tinte) 0 0.6rem, transparent 0.6rem 1.2rem) left / 50% 100% no-repeat,
    repeating-linear-gradient(to bottom, transparent 0 0.6rem, var(--tinte) 0.6rem 1.2rem) right / 50% 100% no-repeat,
    #fff;
}

.see {
  position: relative;
  background: var(--see);
  padding: 0 0 0;
}

/* The water over the lower third of the name, with a wave for an edge. */
.see::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: calc(var(--mass) * 0.3);
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='10' viewBox='0 0 72 10'%3E%3Cpath d='M0 10V6c9-8 18-8 27-2s18 6 27 0 12-4 18 2v4z' fill='%237fb0c1'/%3E%3C/svg%3E") repeat-x left top / 72px 10px,
    linear-gradient(var(--see), var(--see)) no-repeat left 9px / 100% calc(100% - 9px);
  opacity: 0.86;
}

.start .see::before { animation: flut 2.6s cubic-bezier(0.2, 0.7, 0.2, 1) 0.3s both; }

@keyframes flut {
  from { height: 0; }
  to { height: calc(var(--mass) * 0.3); }
}

@media (prefers-reduced-motion: reduce) {
  .start .see::before { animation: none; }
  html { scroll-behavior: auto; }
}

.untertitel {
  max-width: var(--breite);
  margin: 0 auto;
  padding: 0.9rem var(--rand) 0;
  font-style: italic;
  font-size: clamp(1.05rem, 2.2vw, 1.5rem);
  color: var(--tinte);
}

/* ---- Tabs: the chapters, on the edge of the land ---- */

.reiter {
  max-width: var(--breite);
  margin: clamp(1.2rem, 3vw, 2.4rem) auto 0;
  padding: 0 var(--rand);
}

.reiter ul {
  display: flex;
  gap: 0.3rem;
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
  /* Room for the outline of a focused tab. */
  padding-top: 4px;
  align-items: flex-end;
  /* The rim of the land runs along under the tabs; the open tab covers it. */
  background: linear-gradient(var(--watt), var(--watt)) left bottom / 100% 6px no-repeat;
}
.reiter li { margin: 0 0 6px; flex: none; }
.reiter li:has([aria-current="page"]) { margin-bottom: 0; }
.reiter ul::-webkit-scrollbar { display: none; }

.reiter a {
  display: block;
  padding: 0.55rem 0.95rem 0.5rem;
  border: 6px solid transparent;
  border-bottom: 0;
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-weight: 600;
  font-size: 1.3rem;
  line-height: 1.1;
  white-space: nowrap;
  color: var(--tinte);
  text-decoration: none;
  background: rgb(255 255 255 / 0.3);
}
.reiter a:hover { background: rgb(255 255 255 / 0.6); }
.reiter a[aria-current="page"] {
  background: var(--land);
  border-color: var(--watt);
  padding-bottom: calc(0.5rem + 6px);
}

/* ---- The land ---- */

.blatt {
  max-width: var(--breite);
  margin: 0 auto;
  background: var(--land);
  border: 6px solid var(--watt);
  border-top: 0;
  padding: clamp(1.5rem, 5vw, 4rem) clamp(1.1rem, 5vw, 4.5rem) clamp(2rem, 5vw, 4rem);
}

@media (min-width: 78rem) {
  .blatt, .reiter, .luft, .untertitel { width: calc(100% - 2 * var(--rand)); }
  .reiter { padding: 0; }
  .luft, .untertitel { padding-left: 0; padding-right: 0; }
  .pegel { right: 0; }
}
@media (max-width: 77.99rem) {
  .blatt { margin-left: var(--rand); margin-right: var(--rand); }
}

.text > * { max-width: 41rem; }
.text > .bilder, .text > .kennzahlen { max-width: none; }

h1, h2, h3 {
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-weight: 700;
  line-height: 1.02;
  margin: 0;
  text-wrap: balance;
}
h1 { font-size: clamp(2.6rem, 6vw, 4.2rem); margin-bottom: 1.2rem; }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.5rem); margin-top: 3.2rem; margin-bottom: 0.7rem; }
h3 { font-size: 1.45rem; font-weight: 600; margin-top: 2rem; margin-bottom: 0.3rem; }

p { margin: 0 0 1.05rem; }
ul, ol { margin: 0 0 1.05rem; padding-left: 1.2rem; }
li { margin-bottom: 0.3rem; }
li::marker { color: var(--marke); }
strong { font-weight: 600; }

.vorspann, .text > p:first-child {
  font-size: clamp(1.25rem, 2.3vw, 1.55rem);
  line-height: 1.42;
  font-weight: 500;
}

/* Figures: screenshots of a phone, side by side. */
.bilder {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
  gap: clamp(0.9rem, 2.5vw, 1.8rem);
  margin: 2rem 0 2.4rem;
  align-items: start;
}
.bild { margin: 0; max-width: 17rem; }
.bild img {
  display: block;
  width: 100%;
  height: auto;
  border: 3px solid var(--tinte);
  border-radius: 1.5rem;
  background: var(--tinte);
}
.bild figcaption {
  margin-top: 0.55rem;
  font-size: 0.95rem;
  line-height: 1.35;
  font-style: italic;
}

/* The facts of the first page. */
.kennzahlen {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  gap: 0 2rem;
  margin: 1.6rem 0 0;
}
.kennzahlen div { border-top: 2px solid var(--tinte); padding: 0.6rem 0 1.1rem; }
.kennzahlen dt { font-family: "Barlow Condensed", "Arial Narrow", sans-serif; font-weight: 600; font-size: 1.3rem; }
.kennzahlen dd { margin: 0; }

table { border-collapse: collapse; width: 100%; margin: 0.4rem 0 1.4rem; font-size: 1.02rem; }
th, td { text-align: left; vertical-align: top; padding: 0.45rem 1rem 0.45rem 0; border-top: 1px solid rgb(18 34 43 / 0.35); }
th { font-family: "Barlow Condensed", "Arial Narrow", sans-serif; font-weight: 600; font-size: 1.2rem; border-top: 2px solid var(--tinte); }

.quellen p { font-size: 1rem; }

.weiter {
  margin: 3.4rem 0 0;
  padding-top: 1rem;
  border-top: 2px solid var(--tinte);
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
  font-weight: 600;
  font-size: 1.6rem;
}

.fuss {
  max-width: var(--breite);
  margin: 0 auto;
  padding: 2.2rem var(--rand) 3.5rem;
  font-size: 0.98rem;
}
.fuss p { max-width: 44rem; margin-bottom: 0.5rem; }
.fuss a { color: var(--tinte); }
@media (min-width: 78rem) { .fuss { padding-left: 0; padding-right: 0; width: calc(100% - 2 * var(--rand)); } }
