/* Arbeitszeitbetrugssimulator 3000: eine alte, abgeranzte Stempeluhr an einer Fabrikwand. */
:root {
  --wall: #3b3631;
  --metal: #8c907f;
  --metal-dark: #5e6255;
  --rust: 122, 66, 28;
  --ink: #4a2f6e;
  --paper: #efe6cc;
  --yellow: #f2c418;
  --fg: #ece4d4;
  --muted: #b3a995;
  --font-display: "Barlow Condensed", "Arial Narrow", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --noise: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .55 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  --noise-light: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .16 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  --blotch: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='400' height='800' viewBox='0 0 400 800' preserveAspectRatio='none'><filter id='b'><feTurbulence type='fractalNoise' baseFrequency='.018' numOctaves='4' seed='7' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .45  0 0 0 0 .25  0 0 0 0 .1  0 0 0 -2.4 1.35'/></filter><rect width='100%' height='100%' filter='url(%23b)'/></svg>");
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  color: var(--fg);
  font-family: var(--font-body);
  background-color: var(--wall);
  background-image:
    radial-gradient(ellipse at 50% 20%, rgba(255, 236, 190, .13), transparent 60%),
    var(--noise),
    linear-gradient(180deg, #46403a 0%, #2e2a26 100%);
  overflow-x: hidden;
}
button { font: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { color: var(--yellow); }

.stage {
  flex: 1;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  padding: 28px 16px 24px;
  position: relative;
}

/* ---------- Gehäuse ---------- */
.clock {
  position: relative;
  padding: 22px 22px 34px;
  border-radius: 14px 14px 10px 10px;
  background-color: var(--metal);
  background-image:
    var(--blotch),
    radial-gradient(ellipse 30% 14% at 88% 96%, rgba(var(--rust), .8), transparent 70%),
    radial-gradient(ellipse 12% 8% at 6% 58%, rgba(var(--rust), .7), transparent 70%),
    radial-gradient(ellipse 22% 10% at 18% 100%, rgba(var(--rust), .85), transparent 70%),
    radial-gradient(ellipse 40% 30% at 30% 30%, rgba(255, 255, 255, .12), transparent 70%),
    repeating-linear-gradient(103deg, transparent 0 37px, rgba(255, 255, 255, .07) 37px 38px, transparent 38px 91px),
    repeating-linear-gradient(-71deg, transparent 0 53px, rgba(0, 0, 0, .09) 53px 54px, transparent 54px 127px),
    var(--noise),
    linear-gradient(180deg, #9a9d8b, #7d8171 55%, #6b6f61);
  background-size: 100% 100%, auto, auto, auto, auto, auto, auto, auto, auto;
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, .25),
    inset 0 -3px 0 rgba(0, 0, 0, .35),
    inset 0 0 40px rgba(40, 30, 15, .45),
    0 2px 0 #2a2622,
    0 30px 50px rgba(0, 0, 0, .55);
  transform-origin: 50% 0;
}
.clock.wobble { animation: wobble 4s ease-in-out infinite; }
.clock.shake { animation: shake .45s linear; }
.clock.shiny {
  background-image: linear-gradient(180deg, #b9d3c9, #8fb3a6 55%, #7aa093);
  transition: background .6s;
}
@keyframes wobble { 0%,100% { transform: rotate(-1.4deg); } 50% { transform: rotate(1.6deg) translateY(2px); } }
@keyframes shake {
  0%,100% { transform: translate(0); }
  20% { transform: translate(-6px, 2px) rotate(-1deg); }
  40% { transform: translate(5px, -2px) rotate(1deg); }
  60% { transform: translate(-4px, 1px); }
  80% { transform: translate(3px, 0) rotate(.5deg); }
}

.rivet {
  position: absolute; width: 12px; height: 12px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #d8d6c8, #6d6a5c 55%, #3a382f);
  box-shadow: 0 1px 1px rgba(0, 0, 0, .6), 0 0 0 2px rgba(var(--rust), .35);
}
.r1 { top: 10px; left: 10px; } .r2 { top: 10px; right: 10px; }
.r3 { bottom: 10px; left: 10px; } .r4 { bottom: 10px; right: 10px; background: radial-gradient(circle at 35% 30%, #a0703e, #6a3c18 60%, #3a2010); }

/* Typenschild */
.nameplate {
  margin: 0 auto 18px;
  width: fit-content;
  max-width: 100%;
  padding: 8px 18px 6px;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 700;
  line-height: .95;
  color: #2a2016;
  text-transform: uppercase;
  border-radius: 4px;
  background:
    var(--noise),
    linear-gradient(170deg, #d6b571, #b08a3f 45%, #8c6a2c);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .5), inset 0 -2px 0 rgba(0, 0, 0, .3), 0 2px 3px rgba(0, 0, 0, .5);
  text-shadow: 0 1px 0 rgba(255, 240, 200, .45);
  transform: rotate(-1.2deg);
  cursor: default;
  user-select: none;
}
.np-small { display: block; font-size: clamp(15px, 4.6vw, 20px); letter-spacing: .08em; }
.np-big { display: block; font-size: clamp(30px, 10vw, 40px); letter-spacing: .14em; }

/* Zifferblatt */
.dial-wrap {
  width: min(250px, 66vw);
  margin: 0 auto 18px;
  border-radius: 50%;
  padding: 7px;
  background: radial-gradient(circle at 35% 30%, #a7a998, #55584c 70%, #34352d);
  box-shadow: 0 4px 10px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .3);
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}
.dial { display: block; width: 100%; height: auto; }
.dial .tick { stroke: #2a231b; stroke-width: 1; }
.dial .tick.big { stroke-width: 2.6; }
.dial .num { font-family: var(--font-display); font-weight: 700; font-size: 15px; fill: #2a231b; text-anchor: middle; dominant-baseline: central; }
.dial-brand { font-family: var(--font-display); font-weight: 700; font-size: 9px; letter-spacing: 2px; fill: #5b4a2c; text-anchor: middle; }
.dial-sub { font-family: var(--font-display); font-weight: 600; font-size: 6.5px; letter-spacing: 1.5px; fill: #7a6743; text-anchor: middle; }
.hand { transform-origin: 100px 100px; transform-box: view-box; }
.hand.sec { transition: transform .18s cubic-bezier(.4, 2.2, .5, 1); }
.hand.sec.jump { transition: none; }
.crack { fill: none; stroke: rgba(255, 255, 255, .55); stroke-width: .7; stroke-linecap: round; stroke-linejoin: round; }
.crack.thin { stroke-width: .4; stroke: rgba(255, 255, 255, .4); }
.dial.spin #handMin, .dial.spin #handHour { animation: spin 1.2s cubic-bezier(.3, .1, .3, 1); }
@keyframes spin { to { transform: rotate(720deg); } }

/* Zählwerk-Fenster */
.window {
  position: relative;
  margin: 0 auto 18px;
  padding: 10px 12px 9px;
  text-align: center;
  border-radius: 6px;
  background: linear-gradient(180deg, #1e1b18, #2b2723);
  box-shadow: inset 0 3px 8px rgba(0, 0, 0, .8), 0 1px 0 rgba(255, 255, 255, .25);
  overflow: hidden;
}
.win-label, .beer-label {
  font-family: var(--font-display); font-weight: 700; font-size: 13px; letter-spacing: .22em; color: #c8b98f;
}
.win-status {
  margin-top: 6px;
  font-family: var(--font-display); font-weight: 600; font-size: 15px; letter-spacing: .12em; color: #8f866f;
  min-height: 1.2em;
}
.window.on .win-status { color: #9ccf86; }
.window.alarm .win-status { color: #ff6b4a; animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: .2; } }

/* Rollen-Zählwerk */
.odo { display: inline-flex; align-items: center; gap: 3px; margin-top: 6px; }
.odo .d {
  position: relative;
  display: inline-block;
  width: 1.05em;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(34px, 11vw, 46px);
  line-height: 1.25;
  color: #f1ead8;
  text-align: center;
  border-radius: 3px;
  background: linear-gradient(180deg, #0d0c0b 0%, #2c2a27 30%, #34312d 50%, #2c2a27 70%, #0d0c0b 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06);
  overflow: hidden;
}
.odo .d::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, .65), transparent 30%, transparent 70%, rgba(0, 0, 0, .65));
}
.odo .d span { display: block; }
.odo .d.roll span { animation: roll .28s ease-out; }
@keyframes roll { from { transform: translateY(-60%); opacity: .2; } }
.odo .sep { font-family: var(--font-display); font-weight: 700; font-size: clamp(28px, 9vw, 38px); color: #c8b98f; }
.odo.small .d { font-size: clamp(28px, 8.4vw, 34px); }
.odo .d.lag span { transform: translateY(5%); }
.odo .d.lag2 span { transform: translateY(-6%); }

.sick-stamp {
  position: absolute;
  right: 4px; top: 50%;
  translate: 0 -50%;
  rotate: -14deg;
  padding: 3px 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 17px;
  line-height: 1;
  letter-spacing: .06em;
  color: rgba(225, 40, 30, .92);
  border: 3px solid rgba(225, 40, 30, .85);
  border-radius: 5px;
  mix-blend-mode: screen;
  animation: stampIn .35s cubic-bezier(.2, 1.8, .4, 1);
}
@keyframes stampIn { from { scale: 2.6; opacity: 0; } }

/* Bier + Gölb */
.controls { display: flex; gap: 12px; align-items: stretch; margin-bottom: 20px; }
.beer {
  flex: 1;
  padding: 10px 10px 12px;
  text-align: center;
  border-radius: 6px;
  background: linear-gradient(180deg, #1e1b18, #2b2723);
  box-shadow: inset 0 3px 8px rgba(0, 0, 0, .8), 0 1px 0 rgba(255, 255, 255, .25);
}
.beer-btns { display: flex; gap: 8px; justify-content: center; margin-top: 10px; }
.knob {
  min-width: 46px;
  padding: 8px 12px;
  border: 0;
  border-radius: 6px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: .04em;
  color: #1d1a15;
  background: linear-gradient(180deg, #d9d3c2, #a59f8d);
  box-shadow: 0 3px 0 #5a5547, 0 4px 6px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .6);
}
.knob.plus { flex: 1; background: linear-gradient(180deg, #f3c25a, #c8902a); box-shadow: 0 3px 0 #7d5814, 0 4px 6px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .6); }
.knob:active { transform: translateY(3px); box-shadow: 0 0 0 #5a5547, 0 1px 2px rgba(0, 0, 0, .5); }

.goelb {
  width: 108px;
  border: 0;
  border-radius: 8px;
  padding: 10px 6px;
  color: #2a2000;
  background:
    var(--noise-light),
    linear-gradient(170deg, #ffe061, var(--yellow) 50%, #d6a400);
  box-shadow: 0 5px 0 #8a6b00, 0 7px 10px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .6);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  rotate: 1deg;
}
.goelb:active { transform: translateY(5px); box-shadow: 0 0 0 #8a6b00, 0 2px 3px rgba(0, 0, 0, .5); }
.goelb-top { font-family: var(--font-display); font-weight: 700; font-size: 30px; line-height: 1; }
.goelb-sub { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; }
.goelb.active { background: linear-gradient(170deg, #c9c3b0, #9a9481); color: #2d2a22; box-shadow: 0 5px 0 #4f4b3f, 0 7px 10px rgba(0, 0, 0, .5); }

/* Stempelhebel */
.punch {
  display: block;
  width: 100%;
  border: 0;
  padding: 0;
  border-radius: 10px;
  background: #5b1410;
  box-shadow: 0 8px 0 #3b0c08, 0 10px 16px rgba(0, 0, 0, .55);
}
.punch-face {
  display: block;
  padding: 16px 10px 14px;
  border-radius: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 30px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #fbe9d9;
  text-shadow: 0 2px 0 rgba(0, 0, 0, .4);
  background:
    var(--noise),
    radial-gradient(ellipse 18% 40% at 92% 70%, rgba(40, 20, 10, .45), transparent 70%),
    linear-gradient(180deg, #d64a34, #a8291b 60%, #8e1f14);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, .3), inset 0 -3px 0 rgba(0, 0, 0, .25);
}
.punch.out { background: #173a1c; box-shadow: 0 8px 0 #0e2511, 0 10px 16px rgba(0, 0, 0, .55); }
.punch.out .punch-face { background: var(--noise), linear-gradient(180deg, #4b9a4f, #2f7334 60%, #245a28); }
.punch:active, .punch.hit { transform: translateY(8px); box-shadow: 0 0 0 #3b0c08, 0 2px 4px rgba(0, 0, 0, .5); }

.slot {
  margin: 18px auto 0;
  width: 78%;
  height: 14px;
  border-radius: 7px;
  background: linear-gradient(180deg, #0b0a09, #2b2824);
  box-shadow: inset 0 3px 5px #000, 0 1px 0 rgba(255, 255, 255, .25);
}

.maker {
  margin: 18px auto 0;
  width: fit-content;
  padding: 3px 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #ddd6c4;
  border-radius: 2px;
  background: linear-gradient(180deg, #3d3b35, #23221f);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .25);
  cursor: default;
  user-select: none;
  transition: transform .9s cubic-bezier(.5, 0, .9, .5), opacity .9s;
}
.maker.loose { transform: rotate(9deg); transform-origin: 0 50%; }
.maker.fallen { transform: translateY(70vh) rotate(160deg); opacity: 0; }
.maker.reveal { color: var(--yellow); background: transparent; box-shadow: none; transform: none; opacity: 1; letter-spacing: .04em; text-transform: none; font-size: 13px; transition: none; }

.sticker {
  position: absolute;
  left: -10px; top: 150px;
  padding: 6px 8px;
  rotate: -11deg;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  line-height: 1.05;
  text-transform: uppercase;
  color: #1a1a1a;
  background:
    linear-gradient(115deg, transparent 0 62%, rgba(80, 60, 30, .35) 62% 64%, transparent 64%),
    repeating-linear-gradient(-45deg, #f2c418 0 6px, #1a1a1a 6px 12px) top / 100% 5px no-repeat,
    #f4ecd2;
  padding-top: 10px;
  box-shadow: 0 2px 3px rgba(0, 0, 0, .45);
  opacity: .9;
}
.tape {
  position: absolute;
  right: 18px; top: 128px;
  width: 64px; height: 18px;
  rotate: 32deg;
  background: rgba(214, 198, 150, .55);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .25);
}

/* Gölb-Zettel */
.goelb-paper {
  position: absolute;
  z-index: 3;
  right: -8px;
  top: 64px;
  width: 152px;
  padding: 12px 10px 10px;
  rotate: 7deg;
  font-size: 10.5px;
  line-height: 1.3;
  color: #3a2f00;
  background:
    var(--noise-light),
    linear-gradient(170deg, #fff08a, #f6d94a);
  box-shadow: 0 6px 12px rgba(0, 0, 0, .45);
  display: flex; flex-direction: column; gap: 3px;
  animation: slap .4s cubic-bezier(.2, 1.6, .4, 1);
}
.goelb-paper::before {
  content: ""; position: absolute; top: -8px; left: 50%; translate: -50% 0;
  width: 56px; height: 16px; rotate: -4deg;
  background: rgba(235, 230, 210, .7);
}
.goelb-paper b { font-family: var(--font-display); font-size: 24px; line-height: 1; letter-spacing: .06em; }
.gp-line i { font-style: normal; font-weight: 600; }
.gp-sign { margin-top: 4px; font-style: italic; text-align: right; font-family: "Brush Script MT", "Segoe Script", cursive; font-size: 14px; color: #1b2f80; }
@keyframes slap { from { transform: scale(1.6) rotate(-14deg); opacity: 0; } }

/* Stempelkarte */
.card {
  position: relative;
  z-index: 2;
  width: 76%;
  margin: -41px auto 0;
  padding: 10px 10px 14px;
  color: #2a2418;
  background:
    var(--noise-light),
    radial-gradient(ellipse 30% 20% at 80% 85%, rgba(150, 110, 40, .25), transparent 70%),
    linear-gradient(180deg, #f1e8cf, #e3d5ae);
  box-shadow: 0 10px 18px rgba(0, 0, 0, .45);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 3% 100%, 0 97%);
  font-size: 11px;
  transition: transform .25s;
}
.card.punched { animation: cardPunch .5s ease-in-out; }
@keyframes cardPunch { 40% { transform: translateY(-46px); } }
.card-head {
  display: flex; justify-content: space-between; gap: 8px;
  padding-bottom: 6px; margin-bottom: 4px;
  border-bottom: 2px solid #8a2a20;
  font-family: var(--font-display); font-weight: 700; letter-spacing: .1em; font-size: 13px;
}
.card-head i { font-family: var(--font-body); font-weight: 400; letter-spacing: 0; font-size: 11px; }
.card table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.card th { font-family: var(--font-display); font-weight: 600; letter-spacing: .08em; text-align: left; color: #8a2a20; padding: 3px 2px; font-size: 12px; }
.card td {
  padding: 4px 2px;
  border-top: 1px solid rgba(138, 42, 32, .3);
  font-family: "Courier New", ui-monospace, monospace;
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
}
.card td span { display: inline-block; opacity: .85; }
.card td span.smudge { filter: blur(.4px); opacity: .7; }
.card td.k { color: #b3261e; }
.card .empty td { height: 22px; }
.card-stamp {
  position: absolute;
  right: 10px; bottom: 14px;
  rotate: -12deg;
  padding: 4px 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.05;
  text-align: center;
  text-transform: uppercase;
  color: rgba(40, 90, 170, .85);
  border: 2px solid rgba(40, 90, 170, .75);
  border-radius: 4px;
  animation: stampIn .35s cubic-bezier(.2, 1.8, .4, 1);
}

.eggs { margin: 26px 0 0; text-align: center; font-size: 13px; color: var(--muted); }
.eggs b { color: var(--yellow); }
.mute {
  display: block; margin: 8px auto 0;
  border: 1px solid rgba(255, 255, 255, .15); border-radius: 999px;
  padding: 4px 12px; font-size: 12px; color: var(--muted); background: transparent;
}

.wall-note {
  position: absolute;
  z-index: 4;
  left: 4px; top: 6px;
  padding: 10px 12px;
  rotate: -6deg;
  font-family: "Segoe Print", "Bradley Hand", "Comic Sans MS", cursive;
  font-size: 13px;
  line-height: 1.25;
  color: #23305c;
  background: #9fe0f0;
  box-shadow: 0 5px 10px rgba(0, 0, 0, .45);
}

/* Hinweise */
.toast {
  position: fixed;
  left: 50%; bottom: 24px;
  z-index: 20;
  max-width: min(92vw, 420px);
  padding: 12px 16px;
  translate: -50% 140%;
  opacity: 0;
  border-radius: 10px;
  text-align: center;
  font-size: 15px;
  line-height: 1.35;
  color: #1d1a15;
  background: #f4ecd2;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .55);
  transition: translate .35s cubic-bezier(.2, 1.3, .4, 1), opacity .25s;
  pointer-events: none;
}
.toast.show { translate: -50% 0; opacity: 1; }
.toast b { display: block; font-family: var(--font-display); font-size: 20px; letter-spacing: .04em; }

/* Bläschen */
.bubble {
  position: fixed;
  z-index: 15;
  bottom: -20px;
  width: 10px; height: 10px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 220, 120, .8);
  background: rgba(255, 210, 80, .15);
  pointer-events: none;
  animation: rise linear forwards;
}
@keyframes rise { to { transform: translateY(-110vh); opacity: 0; } }

/* Chef-Taste */
.boss {
  position: fixed; inset: 0; z-index: 50;
  background: #fff;
  color: #222;
  font-family: Calibri, "Segoe UI", Arial, sans-serif;
  font-size: 13px;
  overflow: hidden;
  cursor: default;
}
.boss-bar { background: #217346; color: #fff; padding: 8px 12px; display: flex; flex-direction: column; gap: 4px; }
.boss-file { font-weight: 600; }
.boss-menu { font-size: 12px; opacity: .9; white-space: nowrap; overflow: hidden; }
.boss-formula { padding: 6px 10px; border-bottom: 1px solid #d4d4d4; white-space: nowrap; overflow: hidden; }
.boss-formula b { color: #888; font-style: italic; margin-right: 10px; }
.boss-grid { display: grid; grid-template-columns: 34px repeat(8, minmax(80px, 1fr)); }
.boss-grid div { border-right: 1px solid #e1e1e1; border-bottom: 1px solid #e1e1e1; padding: 3px 6px; white-space: nowrap; overflow: hidden; min-height: 22px; }
.boss-grid .h { background: #f3f3f3; color: #555; text-align: center; }
.boss-grid .n { text-align: right; }
.boss-grid .b { font-weight: 700; }

/* Fuß */
.foot {
  display: flex; flex-wrap: wrap; gap: 6px 16px; justify-content: center;
  padding: 18px 16px 26px;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
}
.foot nav { display: flex; gap: 14px; }
.foot a { color: var(--muted); }

/* Rechtstexte */
.legal { max-width: 720px; margin: 0 auto; padding: 36px 16px 40px; line-height: 1.6; flex: 1; }
.legal h1 { font-family: var(--font-display); font-size: 40px; line-height: 1.05; margin: 18px 0 12px; }
.legal h2 { font-family: var(--font-display); font-size: 24px; margin: 30px 0 6px; color: var(--yellow); }
.legal .lead { font-size: 17px; }
.legal .back { color: var(--muted); text-decoration: none; font-size: 14px; }
.legal .date { color: var(--muted); font-size: 14px; margin-top: 30px; }
.legal code { background: rgba(255, 255, 255, .08); padding: 1px 5px; border-radius: 4px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
@media (max-width: 400px) {
  .clock { padding: 20px 14px 30px; }
  .goelb { width: 92px; }
  .goelb-paper { width: 132px; right: -6px; }
  .sticker { left: -6px; }
}

/* Ab und zu: Panzer, Öltanker, Schraubenregen */
.drive {
  position: fixed;
  left: 0;
  bottom: 4px;
  z-index: 12;
  pointer-events: none;
  animation: drive linear forwards;
}
.drive svg { display: block; filter: drop-shadow(0 4px 4px rgba(0, 0, 0, .45)); }
@keyframes drive { from { transform: translateX(-260px); } to { transform: translateX(calc(100vw + 20px)); } }
.tank svg { animation: rumble .18s steps(2) infinite; }
@keyframes rumble { 50% { transform: translateY(-1px); } }
.ship { bottom: 8px; }
.ship svg { animation: bob 2.4s ease-in-out infinite; transform-origin: 50% 100%; }
@keyframes bob { 0%, 100% { transform: rotate(-1.5deg) translateY(0); } 50% { transform: rotate(1.5deg) translateY(3px); } }
.sea {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: 18px;
  z-index: 13;
  pointer-events: none;
  background:
    radial-gradient(circle at 10px -4px, transparent 11px, #2f6f8f 12px) 0 0 / 22px 22px repeat-x,
    linear-gradient(180deg, #2f6f8f, #1f4e66);
  opacity: .92;
  animation: seaIn 19s linear forwards;
}
@keyframes seaIn { 0% { transform: translateY(100%); } 4%, 96% { transform: translateY(0); } 100% { transform: translateY(100%); } }
.screw {
  position: fixed;
  top: -40px;
  z-index: 14;
  pointer-events: none;
  animation: screwFall linear forwards;
}
@keyframes screwFall { to { transform: translateY(calc(100vh + 60px)) rotate(var(--spin, 540deg)); } }

/* Bier auf! */
.bubble { border-width: 2px; background: radial-gradient(circle at 35% 30%, rgba(255, 255, 255, .55), rgba(255, 210, 80, .18) 45%, rgba(255, 200, 60, .08)); }
.cheers { position: fixed; inset: 0; z-index: 16; pointer-events: none; display: grid; place-items: center; visibility: hidden; }
.cheers.on { visibility: visible; }
.cheers-glow {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 55%, rgba(255, 196, 60, .42), rgba(255, 170, 40, .14) 45%, transparent 75%);
  opacity: 0;
}
.cheers.on .cheers-glow { animation: glow 1.9s ease-out forwards; }
@keyframes glow { 15% { opacity: 1; } 100% { opacity: 0; } }
.cheers-mug, .cheers-text { grid-area: 1 / 1; }
.cheers-mug { opacity: 0; }
.cheers.on .cheers-mug { animation: mugPop 1.9s cubic-bezier(.2, 1.6, .4, 1) forwards; }
@keyframes mugPop {
  0% { transform: scale(.2) rotate(-20deg); opacity: 0; }
  18% { transform: scale(1.15) rotate(8deg); opacity: 1; }
  30% { transform: scale(1) rotate(-6deg); }
  45% { transform: scale(1) rotate(4deg); }
  75% { transform: translateY(-20px) rotate(0); opacity: 1; }
  100% { transform: translateY(-80px) scale(.8); opacity: 0; }
}
.cheers .drip { animation: drip 1.2s ease-in .3s infinite; }
@keyframes drip { to { transform: translateY(14px); opacity: 0; } }
.cheers-text {
  margin-top: 210px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 34px;
  color: #ffe9a8;
  text-shadow: 0 2px 0 #7a4a10, 0 0 18px rgba(255, 190, 60, .8);
  opacity: 0;
}
.cheers.on .cheers-text { animation: cheerText 1.9s ease-out forwards; }
@keyframes cheerText { 0%, 12% { opacity: 0; transform: translateY(10px) scale(.8); } 25% { opacity: 1; transform: none; } 80% { opacity: 1; } 100% { opacity: 0; transform: translateY(-30px); } }
body.happy .clock { animation: happy .6s ease-out; }
@keyframes happy { 30% { transform: scale(1.02) rotate(-.6deg); } 60% { transform: scale(.995) rotate(.4deg); } }
body.happy .clock.wobble { animation: wobble 4s ease-in-out infinite; }
