/* Studio Bonito – Landingpage (M2: Aubergine, Creme, Orange) */

@font-face {
  font-family: "Anton";
  src: url("/fonts/anton-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Space Grotesk";
  src: url("/fonts/space-grotesk-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Space Grotesk";
  src: url("/fonts/space-grotesk-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Space Grotesk";
  src: url("/fonts/space-grotesk-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

:root {
  --aubergine: #2a0f3d;
  --cream: #fff1e0;
  --orange: #ff6b1a;
  --muted: #5b4566;
  --display: "Anton", "Impact", sans-serif;
  --text: "Space Grotesk", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --gutter: 2rem;
}

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

html { -webkit-text-size-adjust: 100%; }
html:has(dialog[open]) { overflow: hidden; }

body {
  margin: 0;
  background: var(--aubergine);
  color: var(--cream);
  font-family: var(--text);
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--orange); color: var(--aubergine); }

a { color: var(--cream); text-underline-offset: 0.2em; }
a:hover { color: var(--orange); }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; }

.accent { color: var(--orange); }
.mono { font-family: var(--mono); font-weight: 700; }
.wrap { width: 100%; max-width: 1240px; margin-inline: auto; padding-inline: var(--gutter); }

/* ---------- Layout ---------- */

.page { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding-top: 32px;
}

.logo {
  font-family: var(--display);
  font-size: 30px;
  text-transform: uppercase;
  text-decoration: none;
  line-height: 1;
}

.pill {
  font: inherit;
  font-weight: 700;
  font-size: 16px;
  border: none;
  border-radius: 999px;
  padding: 12px 22px;
  min-height: 44px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35em;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.pill:hover { transform: translateY(-2px); }
.pill:active { transform: translateY(0); }
.pill--cream { background: var(--cream); color: var(--aubergine); }
.pill--dark { background: var(--aubergine); color: var(--cream); }
.pill--orange { background: var(--orange); color: var(--aubergine); border: 3px solid var(--aubergine); }
.pill--big { font-size: 19px; padding: 16px 32px; min-height: 56px; }
.pill[disabled] { opacity: 0.6; cursor: progress; transform: none; }

.hero {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(0, 1fr);
  grid-template-areas:
    "title art"
    "lead  art"
    "note  note";
  column-gap: 40px;
  row-gap: 28px;
  align-content: center;
  padding-top: 48px;
  padding-bottom: 48px;
}

.hero__title {
  grid-area: title;
  margin: 0;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(64px, 7.6vw, 120px);
  line-height: 0.9;
  text-transform: uppercase;
  align-self: end;
}
.hero__title .accent { display: block; }

.hero__lead {
  grid-area: lead;
  margin: 0;
  font-size: clamp(20px, 2vw, 24px);
  line-height: 1.4;
  font-weight: 500;
  max-width: 34ch;
  align-self: start;
}

.hero__art { grid-area: art; display: flex; justify-content: center; align-items: center; }
.hero__note {
  grid-area: note;
  margin: 24px 0 0;
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 700;
}

.footer {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 14px;
  padding-top: 32px;
  padding-bottom: 40px;
}

/* ---------- Hängematte & Fisch ---------- */

.hammock { width: 100%; max-width: 440px; height: auto; overflow: visible; -webkit-tap-highlight-color: transparent; }
.hammock__post { stroke: var(--cream); stroke-width: 6; stroke-linecap: round; fill: none; }
.hammock__net path { stroke: var(--cream); fill: none; }
.fish { cursor: pointer; }
.fish__body,
.fish__tail,
.fish__dorsal { fill: var(--orange); }
.fish__fin { fill: #e2560c; }
.fish__line { fill: none; stroke: var(--aubergine); stroke-width: 3; stroke-linecap: round; }
.eye-ball { fill: var(--aubergine); }
.eye-glint { fill: var(--cream); }

.hammock__net,
.fish-sway,
.fish-hop,
.fish-flip,
.fish-breathe,
.fish__tail,
.fish__fin,
.eye-open,
.eye-closed,
.zzz,
.z {
  transform-box: fill-box;
  transform-origin: 50% 50%;
}

/* Schlafen: Hängematte schaukelt, Fisch atmet, Schwanz und Flosse treiben leicht */
.hammock__net { transform-origin: 50% 0; animation: sag 4.2s ease-in-out infinite alternate; }
.fish-sway { animation: sway 4.2s ease-in-out infinite alternate; }
.fish-breathe { animation: breathe 3.4s ease-in-out infinite; }
.fish__tail { transform-origin: 0% 50%; animation: tail-drift 3.4s ease-in-out infinite; }
.fish__fin { transform-origin: 0% 0%; animation: fin-drift 3.4s ease-in-out infinite; }

/* Auge: geschlossen ist ein Strich, offen ein Punkt mit Glanzlicht */
.eye-open { transform: scaleY(0.05); opacity: 0; transition: transform 0.12s ease, opacity 0.08s ease; }
.eye-closed { transition: opacity 0.08s ease; }
.hammock.is-peek .eye-open,
.hammock.is-awake .eye-open { transform: scaleY(1); opacity: 1; }
.hammock.is-peek .eye-closed,
.hammock.is-awake .eye-closed { opacity: 0; }
.hammock.is-peek .eye-open { animation: peek 0.9s ease-in-out forwards; }

/* Wach: Schwanz und Flosse wedeln schnell */
.hammock.is-awake .fish__tail { animation: tail-wag 0.16s ease-in-out infinite alternate; }
.hammock.is-awake .fish__fin { animation: fin-flap 0.2s ease-in-out infinite alternate; }
.hammock.is-awake .fish-breathe { animation: none; }

/* Sprung: zusammenducken, hochschnellen, in der Luft drehen, platschend landen */
.hammock.is-jumping .fish-hop { animation: flop 1s cubic-bezier(0.3, 0, 0.3, 1); }
.fish-flip { transition: transform 0.38s cubic-bezier(0.45, 0, 0.3, 1); }
.hammock.is-flipped .fish-flip { transform: scaleX(-1); }
.hammock.is-landing .hammock__net { animation: land 0.7s ease-out; }
.hammock.is-landing .fish-sway { animation: land-fish 0.7s ease-out; }

/* z z z: steigen vom Kopf auf, wachsen, pendeln und verblassen */
.zzz { transition: opacity 0.35s ease; }
.zzz-pos { transition: transform 0.6s ease; }
.hammock.is-flipped .zzz-pos { transform: translateX(118px); }
.hammock.is-waking .zzz { opacity: 0; }
.z {
  font-family: var(--display);
  font-size: 36px;
  fill: var(--cream);
  opacity: 0;
  animation: z-rise-right 4.2s ease-in-out infinite;
}
.hammock.is-flipped .z { animation-name: z-rise-left; }
.z2 { animation-delay: 1.4s; }
.z3 { animation-delay: 2.8s; }

@keyframes sag { from { transform: scaleY(1); } to { transform: scaleY(1.05); } }
@keyframes sway { from { transform: translateY(0) rotate(-1deg); } to { transform: translateY(4px) rotate(1deg); } }
@keyframes breathe { 0%, 100% { transform: scale(1, 1); } 45% { transform: scale(1.02, 1.05); } }
@keyframes tail-drift { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(4deg); } }
@keyframes fin-drift { 0%, 100% { transform: rotate(0deg); } 50% { transform: rotate(10deg); } }
@keyframes tail-wag { from { transform: rotate(-22deg); } to { transform: rotate(22deg); } }
@keyframes fin-flap { from { transform: rotate(-8deg); } to { transform: rotate(28deg); } }
@keyframes peek {
  0% { transform: scaleY(0.05); }
  18% { transform: scaleY(1); }
  55% { transform: scaleY(1); }
  64% { transform: scaleY(0.1); }
  72% { transform: scaleY(1); }
  100% { transform: scaleY(1); }
}
@keyframes flop {
  0% { transform: translate(0, 0) rotate(0) scale(1, 1); }
  14% { transform: translate(0, 6px) rotate(4deg) scale(1.1, 0.84); }
  30% { transform: translate(-4px, -34px) rotate(-16deg) scale(0.94, 1.08); }
  46% { transform: translate(0, -48px) rotate(-4deg) scale(1, 1); }
  60% { transform: translate(4px, -36px) rotate(14deg) scale(0.96, 1.05); }
  78% { transform: translate(0, 4px) rotate(-3deg) scale(1.12, 0.86); }
  90% { transform: translate(0, -5px) rotate(2deg) scale(0.98, 1.03); }
  100% { transform: translate(0, 0) rotate(0) scale(1, 1); }
}
@keyframes land {
  0% { transform: scaleY(1); }
  30% { transform: scaleY(1.16); }
  60% { transform: scaleY(0.97); }
  100% { transform: scaleY(1); }
}
@keyframes land-fish {
  0% { transform: translateY(0); }
  30% { transform: translateY(9px); }
  60% { transform: translateY(-2px); }
  100% { transform: translateY(0); }
}
@keyframes z-rise-right {
  0% { opacity: 0; transform: translate(0, 0) scale(0.4) rotate(-12deg); }
  12% { opacity: 1; }
  35% { transform: translate(14px, -28px) scale(0.7) rotate(6deg); }
  70% { opacity: 0.95; transform: translate(6px, -62px) scale(1) rotate(-8deg); }
  100% { opacity: 0; transform: translate(26px, -100px) scale(1.25) rotate(10deg); }
}
@keyframes z-rise-left {
  0% { opacity: 0; transform: translate(0, 0) scale(0.4) rotate(12deg); }
  12% { opacity: 1; }
  35% { transform: translate(-14px, -28px) scale(0.7) rotate(-6deg); }
  70% { opacity: 0.95; transform: translate(-6px, -62px) scale(1) rotate(8deg); }
  100% { opacity: 0; transform: translate(-26px, -100px) scale(1.25) rotate(-10deg); }
}

@media (prefers-reduced-motion: reduce) {
  .hammock__net, .fish-sway, .fish-breathe, .fish__tail, .fish__fin, .z { animation: none !important; }
  .z { opacity: 0.9; }
  .z2 { transform: translate(10px, -26px) scale(0.75); }
  .z3 { transform: translate(20px, -52px) scale(0.55); }
  .fish-flip, .zzz, .zzz-pos { transition: none; }
}

/* ---------- Kontakt-Popup ---------- */

.contact {
  border: none;
  padding: 0;
  margin: auto;
  width: min(1176px, calc(100vw - 48px));
  max-width: none;
  min-height: min(760px, calc(100dvh - 48px));
  max-height: calc(100vh - 48px);
  max-height: calc(100dvh - 48px);
  border-radius: 28px;
  background: var(--cream);
  color: var(--aubergine);
  overflow: hidden;
}
.contact::backdrop { background: rgba(18, 5, 28, 0.72); }
.contact[open] { display: flex; animation: pop 0.28s cubic-bezier(0.16, 1, 0.3, 1); }
.contact[open]::backdrop { animation: fade 0.28s ease; }
@keyframes pop { from { opacity: 0; transform: scale(0.96) translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.contact__inner {
  position: relative;
  flex: 1;
  overflow: auto;
  padding: 96px clamp(32px, 6.5vw, 96px);
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  column-gap: clamp(48px, 7vw, 112px);
  align-items: start;
  align-content: center;
}

.contact__bar { position: absolute; top: 20px; right: 20px; left: 20px; display: flex; justify-content: flex-end; align-items: center; }
.contact__close {
  width: 52px; height: 52px; border-radius: 50%; border: none;
  background: var(--aubergine); color: var(--cream);
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.contact__close svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; }

.contact__intro { display: flex; flex-direction: column; gap: 28px; }
.contact__title {
  margin: 0;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(52px, 6.6vw, 92px);
  line-height: 0.9;
  text-transform: uppercase;
}
.contact .accent { color: #e0510f; } /* etwas dunkler, damit es auf Creme lesbar bleibt (3.5:1) */
.contact__title .accent { display: block; }
.contact__title:focus { outline: none; }
.contact__text { margin: 0; font-size: 19px; line-height: 1.55; max-width: 30ch; text-wrap: pretty; }
.req { color: #b3360a; font-weight: 700; }

.contact__form { display: flex; flex-direction: column; gap: 20px; }
.contact__form .pill--big { align-self: flex-start; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; font-weight: 700; font-size: 14px; }
.field input,
.field textarea {
  font: inherit;
  font-weight: 400;
  font-size: 17px;
  color: var(--aubergine);
  caret-color: var(--orange);
  background: #fff;
  border: 2px solid var(--aubergine);
  border-radius: 12px;
  padding: 12px 14px;
  min-height: 52px;
  width: 100%;
}
.field textarea { resize: vertical; min-height: 220px; }
.field input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 100px #fff inset;
  -webkit-text-fill-color: var(--aubergine);
}
.field input:focus-visible,
.field textarea:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }
.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] { border-color: #c2410c; background: #fff7f2; }

.form-error { margin: 0; font-weight: 700; color: #b3360a; }

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.contact__done {
  grid-column: 1 / -1;
  justify-self: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 24px;
  max-width: 560px;
}
.contact__done .contact__title { font-size: clamp(64px, 7vw, 112px); }
.contact__done .contact__text { max-width: 26ch; }
.contact__done .pill { margin-top: 8px; }
.awake-fish { width: 220px; fill: var(--aubergine); }
.awake-fish__body { fill: var(--orange); }
.awake-fish__glint { fill: var(--cream); }
.awake-fish__line { fill: none; stroke: var(--aubergine); stroke-width: 3; stroke-linecap: round; }
.contact__done:not([hidden]) .awake-fish { animation: wiggle 1.2s ease-in-out 2; transform-origin: 50% 50%; }
@keyframes wiggle { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-6deg); } 75% { transform: rotate(6deg); } }

[hidden] { display: none !important; }

/* ---------- Impressum ---------- */

.legal {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 64px;
  padding-top: 80px;
  padding-bottom: 96px;
  align-items: start;
}
.legal__title {
  margin: 0;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(64px, 6.4vw, 96px);
  line-height: 0.9;
  text-transform: uppercase;
}
.legal__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 48px; font-size: 18px; line-height: 1.55; }
.legal__grid section { display: flex; flex-direction: column; gap: 8px; }
.legal__grid .wide { grid-column: 1 / -1; border-top: 1px solid #5a3a70; padding-top: 32px; }
.legal__grid h2 {
  margin: 0;
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
  color: var(--orange);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.legal__grid p { margin: 0; }
.legal__grid .wide p { font-size: 16px; color: #e6d9e8; max-width: 62ch; }
.footer--legal { border-top: 3px solid var(--orange); }

/* ---------- Mobile ---------- */

@media (max-width: 720px) {
  :root { --gutter: 20px; }

  .topbar { padding-top: 20px; }
  .logo { font-size: 22px; }
  .pill { font-size: 14px; padding: 10px 16px; }
  .topbar .pill__arrow { display: none; }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "title" "art" "lead" "note";
    row-gap: 28px;
    align-content: start;
    padding-top: 48px;
  }
  .hero__title { font-size: clamp(56px, 18vw, 72px); }
  .hero__title .accent { display: inline; }
  .hero__lead { font-size: 19px; }
  .hero__note { margin-top: 0; font-size: 14px; }
  .hammock { max-width: 320px; }

  .footer { font-size: 14px; padding-top: 24px; padding-bottom: 32px; }

  .contact {
    width: calc(100vw - 24px);
    max-height: calc(100vh - 24px);
    max-height: calc(100dvh - 24px);
    min-height: 0;
    border-radius: 20px;
  }
  .contact__inner {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding: 20px 18px;
  }
  .contact__bar { top: 12px; right: 12px; left: auto; }
  .contact__close { width: 44px; height: 44px; }
  .contact__intro { gap: 10px; padding-right: 48px; }
  .contact__title { font-size: 44px; }
  .contact__text { font-size: 16px; line-height: 1.45; }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .contact__form { gap: 12px; }
  .field { gap: 4px; }
  .field input { min-height: 48px; padding-block: 10px; }
  .field textarea { min-height: 0; height: clamp(88px, calc(100dvh - 520px), 240px); }
  .contact__form .pill--big { align-self: stretch; font-size: 18px; min-height: 52px; padding-block: 12px; }
  .contact__done { padding-top: 24px; gap: 18px; }
  .contact__done .contact__title { font-size: 52px; }
  .awake-fish { width: 160px; }

  .legal { grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: 48px; padding-bottom: 56px; }
  .legal__title { font-size: clamp(48px, 17vw, 72px); }
  .legal__grid { grid-template-columns: minmax(0, 1fr); gap: 28px; font-size: 17px; }
  .legal__grid .wide { padding-top: 24px; }
}

/* Kleine Handys (iPhone SE 1. Gen.): Formular passt trotzdem auf einen Screen */
@media (max-width: 720px) and (max-height: 600px) {
  .contact__inner { gap: 12px; padding-block: 16px; }
  .contact__title { font-size: 36px; }
  .contact__text { font-size: 15px; }
  .contact__form { gap: 10px; }
  .field input { min-height: 44px; padding-block: 8px; }
  .field textarea { height: clamp(64px, calc(100dvh - 500px), 240px); }
  .contact__form .pill--big { min-height: 48px; }
}

@media (max-width: 360px) {
  .topbar { gap: 12px; }
  .logo { font-size: 20px; }
  .topbar .pill { padding-inline: 12px; }
}
