@charset "utf-8";

/* ==========================================================================
   Der Kult der Ewigen Erdnuss — Stilblatt für das Plakat

   Ein Aushang für die Taverne: genau ein Blatt A3 hochkant (297 × 420 mm),
   aus drei Metern lesbar. Dasselbe Plakat geht auch auf A4 — dann wird der
   ganze Satzspiegel um den Faktor 210/297 kleiner gerechnet (siehe unten),
   damit die Aufteilung Zeile für Zeile dieselbe bleibt.

   Die Papiergröße selbst steht in plakat.html in zwei kleinen Stilblättern,
   weil @page nicht hinter einem Wähler stehen darf.

   css/style.css wird bewusst NICHT eingebunden. Was hier gebraucht wird,
   steht hier noch einmal, in Punkt und Millimeter.

   Aufbau:
     1. Schriften
     2. Farben und Grundwerte
     3. Blatt, Papiergröße und A4-Umrechnung
     4. Kopf: Frontispiz, Titel, Leitspruch
     5. Die Fünf Kerne
     6. Knacker werden und die Losung
     7. Fuß: Ruf, Siegel, Hinweis, Adresse
     8. Zierstücke
     9. Werkzeugleiste (nur Bildschirm)
   ========================================================================== */

/* ==========================================================================
   1. Schriften — selbst ausgeliefert (OFL, siehe assets/fonts/LIZENZ.txt)
   ========================================================================== */
@font-face { font-family: "IM Fell English"; font-style: normal; font-weight: 400; font-display: block; src: url("../assets/fonts/im-fell-english.woff2") format("woff2"); }
@font-face { font-family: "IM Fell English"; font-style: italic; font-weight: 400; font-display: block; src: url("../assets/fonts/im-fell-english-italic.woff2") format("woff2"); }
@font-face { font-family: "IM Fell English SC"; font-style: normal; font-weight: 400; font-display: block; src: url("../assets/fonts/im-fell-english-sc.woff2") format("woff2"); }
@font-face { font-family: "Pirata One"; font-style: normal; font-weight: 400; font-display: block; src: url("../assets/fonts/pirata-one.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Pirata One"; font-style: normal; font-weight: 400; font-display: block; src: url("../assets/fonts/pirata-one-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* ==========================================================================
   2. Farben und Grundwerte
   ========================================================================== */
:root {
  --papier:        #fbf6ea;
  --papier-tief:   #f3e6c8;
  --tinte:         #2a1f14;
  --tinte-blass:   #5c4a36;

  --roest:         #a5652c;
  --roest-dunkel:  #6b3f18;
  --roest-hell:    #c98a4b;

  --salz:          #fbfaf4;
  --meer:          #2f6b5e;
  --rost:          #8c3b24;

  --flaeche:       #f8f1df;
  --linie:         rgba(107, 63, 24, .32);
  --linie-stark:   rgba(107, 63, 24, .6);

  --font-titel:   "Pirata One", "IM Fell English SC", serif;
  --font-kapitel: "IM Fell English SC", "Pirata One", Georgia, serif;
  --font-text:    "IM Fell English", Georgia, "Times New Roman", serif;
}

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

body {
  margin: 0;
  font-family: var(--font-text);
  color: var(--tinte);
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; height: auto; }
p { margin: 0; }

/* ==========================================================================
   3. Blatt, Papiergröße und A4-Umrechnung
   ------------------------------------------------------------------------
   Gesetzt wird immer auf A3: .plakat ist 297 × 420 mm groß, fertig. Für A4
   bleibt derselbe Kasten stehen und wird nur verkleinert abgebildet
   (210/297 = 0,7071). Eine Verkleinerung ändert nichts am Umbruch, also
   steht auf A4 Zeile für Zeile dasselbe wie auf A3 — nur kleiner. Die Hülle
   bekommt dafür die A4-Maße und schneidet ab, was die Verkleinerung an
   Layoutfläche stehen lässt.
   ========================================================================== */
.plakat-huelle {
  width: 297mm;
  height: 420mm;
  overflow: hidden;
  background: var(--papier);
}

.plakat {
  width: 297mm;
  height: 420mm;
  padding: 13mm 15mm 11mm;
  background: var(--papier);
  background-image:
    radial-gradient(ellipse at 50% 0%, rgba(201, 138, 75, .10), rgba(201, 138, 75, 0) 55%),
    radial-gradient(ellipse at 50% 100%, rgba(107, 63, 24, .09), rgba(107, 63, 24, 0) 50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

html.a4 .plakat-huelle {
  width: 210mm;
  height: 297mm;
}
html.a4 .plakat {
  transform: scale(.7070707);   /* 210/297 */
  transform-origin: top left;
}

@media screen {
  body {
    padding: 0 0 4rem;
    background: #4a3a28;
    background-image:
      radial-gradient(ellipse at 50% 0%, rgba(255, 248, 230, .18), rgba(255, 248, 230, 0) 60%);
  }

  .plakat-ziel {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .plakat-huelle {
    flex: none;
    box-shadow: 0 14px 34px -18px rgba(0, 0, 0, .95);
  }

  /* Auf schmalen Geräten bleibt das Plakat groß und wandert seitwärts:
     zusammengequetscht wäre es unleserlich, und gedruckt wird es ohnehin. */
  @media (max-width: 319mm) {
    .plakat-ziel {
      align-items: flex-start;
      overflow-x: auto;
      padding: 0 1rem;
    }
  }
}

@media print {
  html, body { margin: 0; background: var(--papier); }
  .plakat-huelle { box-shadow: none; }
}

/* ==========================================================================
   4. Kopf: Frontispiz, Titel, Leitspruch
   ========================================================================== */
.plakat-bild {
  margin: 0 0 5mm;
  width: 120mm;
}
.plakat-bild img {
  width: 100%;
  border: .8mm solid var(--papier-tief);
  outline: .4pt solid var(--linie-stark);
}

.plakat-ober {
  font-family: var(--font-kapitel);
  font-size: 15pt;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--tinte-blass);
  margin-bottom: 3mm;
}

.plakat h1 {
  margin: 0;
  font-family: var(--font-titel);
  font-weight: 400;
  font-size: 41pt;
  line-height: .98;
  color: var(--roest-dunkel);
  hyphens: none;
}
.plakat h1 .gross-akzent {
  display: block;
  font-size: 1.5em;
  color: var(--roest);
}

.plakat-leit {
  margin-top: 4mm;
  font-family: var(--font-kapitel);
  font-size: 19pt;
  line-height: 1.32;
  color: var(--tinte);
  hyphens: none;
}

/* ==========================================================================
   5. Die Fünf Kerne
   ========================================================================== */
.plakat-teil {
  width: 100%;
  margin-top: 5mm;
}

.plakat-teil h2 {
  margin: 0 0 3mm;
  font-family: var(--font-kapitel);
  font-weight: 400;
  font-size: 20pt;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--roest-dunkel);
  hyphens: none;
}

.kerne-plakat {
  counter-reset: kern;
  list-style: none;
  margin: 0;
  padding: 0;
}
.kerne-plakat li {
  counter-increment: kern;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 4mm;
  padding: 1.2mm 0;
  font-family: var(--font-kapitel);
  font-size: 25pt;
  line-height: 1.1;
  color: var(--tinte);
  hyphens: none;
}
.kerne-plakat li + li { border-top: .4pt solid var(--linie); }
.kerne-plakat li::before {
  content: counter(kern);
  font-family: var(--font-titel);
  font-size: .95em;
  color: var(--roest);
}

/* ==========================================================================
   6. Knacker werden und die Losung
   ========================================================================== */
.schritte-plakat {
  counter-reset: schritt;
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1.4mm;
}
.schritte-plakat li {
  counter-increment: schritt;
  font-family: var(--font-kapitel);
  font-size: 22pt;
  line-height: 1.15;
  color: var(--tinte);
  hyphens: none;
}
.schritte-plakat li::before {
  content: counter(schritt) ".";
  margin-right: 2.5mm;
  color: var(--roest);
}

.losung-plakat {
  margin: 4mm auto 0;
  padding: 3mm 6mm;
  max-width: 210mm;
  font-family: var(--font-kapitel);
  font-size: 18pt;
  line-height: 1.45;
  border: .5pt dashed var(--meer);
  border-radius: 1.5mm;
  background: rgba(47, 107, 94, .07);
  hyphens: none;
}
.losung-plakat span {
  color: var(--tinte-blass);
  font-size: .62em;
  letter-spacing: .12em;
  text-transform: uppercase;
}

/* ==========================================================================
   7. Fuß: Ruf, Siegel, Hinweis, Adresse
   ========================================================================== */
.plakat-fuss {
  width: 100%;
  padding-top: 5mm;
  position: relative;
}

.plakat-ruf {
  font-family: var(--font-titel);
  font-size: 31pt;
  line-height: 1.12;
  color: var(--roest-dunkel);
  hyphens: none;
}

.plakat-schluss {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 6mm;
  margin-top: 5mm;
  padding-top: 3mm;
  border-top: 1pt double var(--roest-dunkel);
  text-align: left;
}

.plakat-ot {
  flex: 1 1 auto;
  font-size: 10.5pt;
  line-height: 1.35;
  color: var(--rost);
}
.plakat-ot strong { font-weight: 700; }
.plakat-ot .ot-marke {
  display: block;
  font-family: var(--font-kapitel);
  font-size: 9pt;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--tinte-blass);
  margin-bottom: .8mm;
}

.plakat-adresse {
  flex: 0 0 auto;
  align-self: flex-end;
  text-align: right;
}
.plakat-url {
  font-family: var(--font-kapitel);
  font-size: 15pt;
  letter-spacing: .1em;
  color: var(--roest-dunkel);
  white-space: nowrap;
}

/* Das Siegel: das KNACK-Emblem unten rechts. Es ist ein Kupferstich auf
   Pergament; Maske und „multiply“ rechnen seinen Grund gegen das Papier,
   damit dort kein aufgeklebter Kasten steht. */
.plakat-siegel {
  flex: 0 0 auto;
  width: 38mm;
  margin-bottom: -2mm;
}

/* ==========================================================================
   8. Zierstücke
   ========================================================================== */
.plakat-fleuron, .plakat-siegel {
  display: block;
  height: auto;
  -webkit-mask-image: radial-gradient(closest-side, #000 62%, transparent);
  mask-image: radial-gradient(closest-side, #000 62%, transparent);
  mix-blend-mode: multiply;
}
/* Das Zierstück leitet den Fuß ein: Was an Platz übrig bleibt, steht
   darüber, damit Zierstück, Ruf und Fußzeile unten zusammen stehen. */
.plakat-fleuron {
  width: 104mm;
  margin: auto auto 0;
  padding-top: 4mm;
}

/* ==========================================================================
   9. Werkzeugleiste — nur am Bildschirm, im Druck weg
   ========================================================================== */
@media print {
  .werkzeugleiste, .plakat-fehler { display: none !important; }
}

@media screen {
  .werkzeugleiste {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .9rem 1.4rem;
    position: sticky;
    top: 0;
    z-index: 10;
    margin: 0 0 2rem;
    padding: .9rem 1.2rem;
    background: #2a1f14;
    color: #f3e6c8;
    box-shadow: 0 6px 20px -10px rgba(0, 0, 0, .9);
  }
  .werkzeugleiste a,
  .werkzeugleiste p,
  .werkzeugleiste label,
  .werkzeugleiste legend,
  .werkzeugleiste button {
    font-family: var(--font-kapitel);
    margin: 0;
  }
  .wz-zurueck { color: #e6d3ac; text-decoration: none; font-size: 1.05rem; }
  .wz-zurueck:hover, .wz-zurueck:focus-visible { color: #fff; text-decoration: underline; }
  .wz-status { flex: 1 1 12rem; color: #f3e6c8; font-size: 1.05rem; letter-spacing: .04em; }

  .wz-wahl {
    display: flex;
    align-items: center;
    gap: .2rem 1rem;
    margin: 0;
    padding: .2rem .9rem .4rem;
    border: 1px solid #6b3f18;
    border-radius: 4px;
  }
  .wz-wahl legend {
    padding: 0 .4rem;
    font-size: .85rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #c9b894;
  }
  .wz-wahl label {
    display: flex;
    align-items: center;
    gap: .4rem;
    min-height: 40px;
    font-size: 1.05rem;
    color: #f3e6c8;
    cursor: pointer;
  }
  .wz-wahl input { width: 1.1rem; height: 1.1rem; accent-color: #a5652c; cursor: pointer; }

  .wz-knopf {
    min-height: 44px;
    padding: .5em 1.3em;
    font-size: 1.05rem;
    letter-spacing: .06em;
    color: #fbfaf4;
    background: linear-gradient(180deg, #a5652c, #6b3f18);
    border: 2px solid #c98a4b;
    border-radius: 4px;
    cursor: pointer;
  }
  .wz-knopf:hover:not(:disabled), .wz-knopf:focus-visible:not(:disabled) { background: #a5652c; }
  .wz-knopf:disabled { opacity: .5; cursor: default; }
  .wz-hinweis { flex: 1 1 100%; font-size: .9rem; line-height: 1.45; color: #c9b894; }
  .wz-hinweis strong { color: #e6d3ac; font-weight: 400; }

  .plakat-fehler:not([hidden]) {
    display: block;
    max-width: 46rem;
    margin: 0 auto 2rem;
    padding: 1rem 1.2rem;
    font-size: 1.05rem;
    line-height: 1.5;
    color: #fbe9e3;
    background: #8c3b24;
    border: 2px solid #c07a63;
    border-radius: 4px;
  }

  :focus-visible { outline: 3px solid #c98a4b; outline-offset: 3px; }
}
