/* ==========================================================================
   LIMERI Studios Berlin – Styles
   Werte aus dem Squarespace-Original übernommen (Raster, Schriftformeln, Abstände).
   Farben und Schriften findest du oben im :root-Block.
   ========================================================================== */

@font-face {
  font-family: "Nunito Sans";
  src: local("Nunito Sans"), url("fonts/NunitoSans.woff2") format("woff2");
  font-weight: 200 1000;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Rubik";
  src: local("Rubik"), url("fonts/Rubik.woff2") format("woff2");
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Farben */
  --c-light: #eceaed;
  --c-dark: #2f3942;
  --c-black: #000;
  --c-white: #fff;
  --c-header: #23282a;      /* Header nach dem Scrollen */
  --c-accent: #513727;      /* Braun: Links, Send-Button */

  /* Schriften */
  --f-body: "Nunito Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-head: "Rubik", "Nunito Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Seitenraster */
  --maxw: 1676px;
  --gutter: 4vw;            /* Desktop-Rand */
  --m-gutter: 6vw;          /* Handy-Rand */

  /* Schriftgrößen – Handy (Hochformat bis 767px) */
  --vh-unit: calc(.012 * min(100vh, 900px));
  --fs-large: calc(.4 * var(--vh-unit) + 1rem);
  --fs-small: calc(-.1 * var(--vh-unit) + 1rem);
  --fs-h3: calc(1.2 * var(--vh-unit) + 1rem);
  --fs-h4: calc(.6 * var(--vh-unit) + 1rem);

  --ease: cubic-bezier(.19, 1, .22, 1);
}

/* Schriftgrößen – Desktop / Tablet / Querformat */
@media (min-width: 768px), (orientation: landscape) {
  :root {
    --fs-large: min(calc(.4 * 1.2vw + 1rem), max(calc(.4 * .012 * var(--maxw) + 1rem), 1.4rem));
    --fs-small: min(calc(-.1 * 1.2vw + 1rem), max(calc(-.1 * .012 * var(--maxw) + 1rem), .9rem));
    --fs-h3: min(calc(1.2 * 1.2vw + 1rem), max(calc(1.2 * .012 * var(--maxw) + 1rem), 2.2rem));
    --fs-h4: min(calc(.6 * 1.2vw + 1rem), max(calc(.6 * .012 * var(--maxw) + 1rem), 1.6rem));
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--c-light);
  color: #000;
  font-family: var(--f-body);
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body.no-scroll { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }

.skip {
  position: absolute; left: 0; top: 0; z-index: 300; transform: translateY(-200%);
  background: var(--c-accent); color: #fff; border: 2px solid var(--c-accent); border-radius: 300px;
  padding: 24px 35.2px; text-transform: uppercase; text-decoration: none;
}
.skip:focus { transform: none; }

/* ============================ HEADER ============================ */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  color: #fff; background: transparent;
  transition: background .3s ease-in-out;
}
.header.shrink { background: var(--c-header); }

.header-wrap {
  display: flex; align-items: center;
  width: 100%; max-width: calc(var(--maxw) + 8vw); margin: 0 auto;
  padding: calc(18px + .1vw) 4vw .1vw;
  /* Titel links, Menü rechts */
}
.site-title {
  font-family: var(--f-head); font-weight: 500; letter-spacing: -.02em; line-height: 1.2;
  font-size: min(calc(.6vw + 1rem), 26.056px);
  color: #fff; text-decoration: none; margin-right: auto; white-space: nowrap;
}

.nav { display: flex; align-items: center; gap: 2.3vw; margin-right: 2vw; }
.nav a {
  display: block; position: relative; color: #fff; text-decoration: none;
  font-size: 1rem; line-height: 1.5; padding-bottom: 3.2px;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .3s ease;
}
.nav a:hover, .nav a.active { background-size: 100% 1px; }

.ig { display: block; width: 20px; height: 20px; color: #fff; }
.ig svg, .menu-ig svg { display: block; width: 100%; height: 100%; fill: currentColor; }

.burger { display: none; }

/* Handy / Tablet-Hochformat: Burger statt Menü */
@media (max-width: 799px), (pointer: coarse) and (max-width: 1024px) {
  .header-wrap { padding: calc(6vw + 18px) 6vw 6vw; min-height: 0; }
  .site-title { font-size: min(calc(1.3vw + 1rem), 21.4px); }
  .nav, .ig { display: none; }
  .burger {
    display: block; position: relative; width: 47px; height: 37px; padding: 0; margin-right: 0;
    background: none; border: 0; cursor: pointer; color: #fff;
  }
  .burger .bun {
    position: absolute; left: 6px; width: 35px; height: 1px; background: currentColor;
    transition: transform .3s ease, top .3s ease;
  }
  .burger .bun:nth-child(1) { top: 12.5px; }
  .burger .bun:nth-child(2) { top: 23.5px; }
  .menu-open .burger .bun:nth-child(1) { top: 18px; transform: rotate(45deg); }
  .menu-open .burger .bun:nth-child(2) { top: 18px; transform: rotate(-45deg); }
}

/* Vollbild-Menü */
.menu {
  position: fixed; inset: 0; z-index: 90; background: var(--c-light); color: #000;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  visibility: hidden; opacity: 0; transition: opacity .35s ease, visibility 0s linear .35s;
  overflow-y: auto;
}
.menu-open .menu { visibility: visible; opacity: 1; transition: opacity .35s ease; }
.menu-open .header { background: transparent; color: #000; }
.menu-open .site-title, .menu-open .burger { color: #000; }
.menu-nav { display: flex; flex-direction: column; align-items: center; text-align: center; font-size: max(6.6vmin, 33.15px); padding-top: .706em; }
.menu-nav a { font-size: 1em; line-height: 1; margin: .353em 0; color: #000; text-decoration: none; }
@media (min-width: 800px) { .menu-nav { font-size: 6vmin; padding-top: 1.6em; } .menu-nav a { margin: .8em 0; } }
.menu-ig { position: absolute; left: 50%; bottom: calc(6vw + 15px); margin-left: -12.5px; display: block; width: 25px; height: 25px; color: #000; }

/* ============================ SEKTIONEN ============================ */
.sec { position: relative; display: flex; align-items: center; box-sizing: border-box; }
.sec-bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.sec > .wrap { position: relative; z-index: 1; width: 100%; padding: var(--py, 0) 0; }

.theme-light { background: var(--c-light); color: #000; }
.theme-dark  { background: var(--c-dark);  color: #fff; }
.theme-black { background: #000; color: #fff; }
.theme-white { background: #fff; color: #000; }
.theme-light .sec-bg { background: var(--c-light); }
.theme-dark  .sec-bg { background: var(--c-dark); }
.theme-white .sec-bg { background: #fff; }

.hero { min-height: 47vh; padding-top: var(--hdr, 50.4375px); --py: 4.7vmax; }
.hero .sec-bg img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.hero .overlay { position: absolute; inset: 0; background: #000; opacity: .58; }
.s-small { min-height: 33vh; --py: 3.3vmax; }
.s-medium { min-height: 66vh; --py: 6.6vmax; }
.footer { --py: 0; }

/* ---------- Raster (Squarespace „Fluid Engine“) ---------- */
.fe {
  --gap: 11px;
  --gg: calc(var(--m-gutter) - var(--gap));
  --cell: calc((var(--maxw) - var(--gap) * 7) / 8);
  display: grid; position: relative;
  grid-template-columns: minmax(var(--gg), 1fr) repeat(8, minmax(0, var(--cell))) minmax(var(--gg), 1fr);
  grid-template-rows: repeat(var(--rm), minmax(24px, auto));
  row-gap: var(--gap); column-gap: var(--gap);
  overflow-x: clip;
}
.b { grid-area: var(--m); position: relative; min-width: 0; }
@media (min-width: 768px) {
  .fe {
    --gg: calc(var(--gutter) - var(--gap));
    --cell: calc((var(--maxw) - var(--gap) * 23) / 24);
    --cw: min(var(--maxw), calc(100vw - var(--gutter) * 2));
    grid-template-columns: minmax(var(--gg), 1fr) repeat(24, minmax(0, var(--cell))) minmax(var(--gg), 1fr);
    grid-template-rows: repeat(var(--rd), minmax(calc(var(--cw) * .0215), auto));
  }
  .b { grid-area: var(--d); }
}

/* ---------- Text ---------- */
.rte p { margin: 1rem 0; }
.rte *:not(h1):not(h2):not(h3), .acc-desc * { overflow-wrap: break-word; word-wrap: break-word; }
.rte > :first-child { margin-top: 0; }
.rte > :last-child { margin-bottom: 0; }
.rte p:empty { min-height: 1.5em; }
.rte > p.keep-mb:last-child { margin-bottom: 1rem; }
.rte .large { font-size: var(--fs-large); }
.rte .small { font-size: var(--fs-small); }
.tc { text-align: center; }
.vm { display: flex; flex-direction: column; justify-content: center; height: 100%; }
h3, h4 { font-family: var(--f-head); font-weight: 500; letter-spacing: -.02em; margin: 0; }
h3 { font-size: var(--fs-h3); line-height: 1.1424; }
h4 { font-size: var(--fs-h4); line-height: 1.1712; }
.rte a { display: inline-block; white-space: nowrap; overflow-wrap: normal; color: var(--c-accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .2em; }
.rte a:hover { text-decoration-thickness: 2px; }
.footer .rte p strong, .rte .large strong { font-weight: 700; }

/* ---------- Bilder ---------- */
.img { position: absolute; inset: 0; margin: 0; overflow: hidden; border-radius: 5px; }
.img img { width: 100%; height: 100%; object-fit: cover; object-position: var(--fp, 50% 50%); }

/* ---------- Akkordeon ---------- */
.acc { list-style: none; margin: 0; padding: 0; border-top: 1px solid currentColor; }
.acc-item { border-bottom: 1px solid currentColor; }
.acc h4 { margin: 0; }
.acc button {
  display: flex; align-items: center; justify-content: space-between; width: 100%;
  padding: 30px 24px 30px 0; background: none; border: 0; text-align: left; cursor: pointer;
  font: inherit; line-height: normal; letter-spacing: inherit; position: relative;
}
.acc button:focus-visible { outline: 2px solid currentColor; outline-offset: -2px; }
.plus { position: absolute; right: 0; top: 50%; width: 24px; height: 24px; transform: translateY(-50%); }
.plus::before, .plus::after {
  content: ""; position: absolute; left: 0; top: 50%; width: 24px; height: 3px; margin-top: -1.5px; background: currentColor;
  transition: transform .3s ease;
}
.plus::after { transform: rotate(90deg); }
.acc-item.open .plus::after { transform: rotate(0deg); }
.acc-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .4s var(--ease); }
.acc-item.open .acc-panel { grid-template-rows: 1fr; }
.acc-clip { overflow: hidden; min-height: 0; }
.acc-desc { padding-bottom: 30px; width: 70%; font-size: 1rem; font-family: var(--f-body); letter-spacing: normal; font-weight: 400; line-height: 1.5; }
.acc-desc p { margin: 1rem 0; }
.acc-desc > :first-child { margin-top: 0; }
.acc-desc ul { margin: 1rem 0 0; padding-left: 40px; }
.acc-desc li p { margin: 0; }
.acc-desc li { margin: 0; }
.acc-desc li + li { margin-top: 0; }
@media (max-width: 767px) { .acc-desc { width: 100%; } }

/* ---------- Formular ---------- */
.form { font-size: 1rem; }
.form .item { margin: 0 0 20px; border: 0; padding: 0; min-width: 0; }
.form legend, .form .lbl { display: block; padding: 0 0 4px; margin: 0; font-size: 1rem; line-height: 24px; height: 28px; }
.form small { font-size: .75em; opacity: .75; margin-left: .25em; }
.form .two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form .field label { display: block; font-size: .75rem; line-height: 16px; padding-bottom: 11.4px; }
.form .field label small { font-size: 1em; }
.form input, .form textarea {
  display: block; width: 100%; font: inherit; color: #000; line-height: 24px;
  padding: 5px 10px; background: var(--c-light); border: 1px solid transparent; border-radius: 10px; outline: 0;
  transition: border-color .15s, background .15s;
}
.form input { height: 36px; }
.form textarea { height: 100px; resize: vertical; }
.form input:focus, .form textarea:focus { border-color: #000; }
.form .invalid { border-color: #b3261e !important; }
.hp { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.send { text-align: center; }
.btn {
  display: inline-block; cursor: pointer; text-transform: uppercase; font-size: 1rem; line-height: 20.8px;
  padding: 24px 35.2px; background: transparent; color: var(--c-accent);
  border: 2px solid var(--c-accent); border-radius: 300px;
  transition: background-color .1s linear, color .1s linear;
}
.btn:hover { background: var(--c-accent); color: #fff; }
.btn[disabled] { opacity: .6; cursor: default; }
.form-msg { text-align: center; margin: 20px 0 0; }
.form-msg.err { color: #b3261e; }

/* ---------- Einblenden beim Scrollen ---------- */
.js .fade { opacity: 0; transition: opacity .65s ease .1s; }
.js .fade.in { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .fade { opacity: 1; transition: none; }
  .acc-panel, .menu, .header { transition: none; }
}

/* ---------- Rechtstexte ---------- */
.legal { padding: calc(var(--hdr, 50px) + 6vmax) var(--gutter) 6vmax; min-height: 70vh; display: block; }
.legal .rte { max-width: 780px; margin: 0 auto; }
.legal h1 { margin-top: 0; }
.legal h1 { font-family: var(--f-head); font-weight: 500; letter-spacing: -.02em; font-size: var(--fs-h3); line-height: 1.14; margin: 0 0 1.2em; }
.legal h2 { font-family: var(--f-head); font-weight: 500; letter-spacing: -.02em; font-size: var(--fs-h4); margin: 1.6em 0 .5em; }
.header.solid { background: var(--c-header); }
