/* Tag & Nacht Wohnatelier – Entwurf Seetalwebsites, 31.10.2026
   Leinen am Tag, Nachtblau am Abend. Bodoni Moda + Jost.
   Abstände nur aus 8 16 24 40 64 104. */

:root {
  --leinen: #E8E3D7;
  --leinen-2: #DDD5C6;
  --tinte: #27231F;
  --t1: rgba(39, 35, 31, .92);
  --t2: rgba(39, 35, 31, .68);
  --t3: rgba(39, 35, 31, .48);
  --linie: rgba(39, 35, 31, .16);
  --nacht: #252C57;
  --akzent: #2C3566;
  --gelb: #E2B23A;
  --hell: #ECE6DA;
  --h1: rgba(236, 230, 218, .94);
  --h2: rgba(236, 230, 218, .7);
  --h3: rgba(236, 230, 218, .5);

  --serif: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --sans: "Jost", "Futura", "Avenir Next", system-ui, sans-serif;

  --rand: 20px;
  --luft: 64px;
  --expo: cubic-bezier(.19, 1, .22, 1);
  --zug: cubic-bezier(.76, 0, .24, 1);

  /* Zackenschere: Kante wie mit der Zickzackschere geschnitten */
  --zack: 7px;
}

@media (min-width: 900px) {
  :root { --rand: 40px; --luft: 104px; --zack: 9px; }
}

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

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

body {
  margin: 0;
  background: var(--leinen) url(img/leinen-grund.svg) 0 0 / 320px repeat;
  color: var(--t1);
  font: 300 17px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

@media (min-width: 900px) { body { font-size: 18px; } }


img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 400; }
ul { list-style: none; margin: 0; padding: 0; }

:focus-visible { outline: 2px solid var(--akzent); outline-offset: 4px; border-radius: 2px; }
.nacht :focus-visible, .balken :focus-visible, .fuss :focus-visible { outline-color: var(--gelb); }

.rahmen { width: 100%; max-width: calc(1200px + 2 * var(--rand)); margin: 0 auto; padding: 0 var(--rand); }

/* ---------- Abdecktuch ---------- */
.tuch { display: none; }

.tuch-an .tuch {
  display: block;
  position: fixed;
  inset: 0 0 -24px 0;
  z-index: 100;
  filter: drop-shadow(0 16px 24px rgba(39, 35, 31, .22));
  transition: transform 1250ms var(--zug);
  will-change: transform;
  cursor: pointer;
}

.tuch-stoff {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 0 var(--rand) 40px;
  text-align: center;
  background: #E3DCCD url(img/leinen.svg) 0 0 / 320px repeat;
  -webkit-mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / calc(2 * var(--zack)) 100%;
          mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / calc(2 * var(--zack)) 100%;
}

/* Naht über dem Saum */
.tuch-stoff::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 40px;
  height: 1px;
  background: repeating-linear-gradient(90deg, rgba(39, 35, 31, .38) 0 8px, transparent 8px 14px);
}

.tuch-satz {
  font: 400 clamp(34px, 8.6vw, 72px)/1.04 var(--serif);
  letter-spacing: -.02em;
  color: var(--t1);
  max-width: 13ch;
  text-wrap: balance;
}

.tuch-klein { font-size: 15px; color: var(--t2); }

.tuch.weg { transform: translateY(calc(-100% - 64px)); }

/* ---------- Balken oben (live geöffnet / geschlossen) ---------- */
.balken {
  background: var(--nacht);
  color: var(--h1);
  font-size: 14px;
  line-height: 1.3;
}

.balken-innen { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 40px; }
.balken-status { display: flex; align-items: center; gap: 8px; }
.balken-link { color: var(--h2); text-decoration: none; white-space: nowrap; transition: color 150ms ease-out; }
.balken-link:hover { color: var(--h1); }

.punkt {
  flex: none;
  width: 8px; height: 8px;
  border-radius: 50%;
  border: 1px solid var(--h2);
}
.ist-offen .punkt { background: var(--gelb); border-color: var(--gelb); }

@media (max-width: 520px) { .balken-link { display: none; } }

/* ---------- Kopf ---------- */
.kopf-innen { display: flex; align-items: center; justify-content: space-between; min-height: 64px; }

.marke { min-height: 40px; display: flex; align-items: center; gap: 8px; text-decoration: none; font-size: 15px; font-weight: 400; color: var(--t1); }
.zeichen { width: 24px; height: 24px; flex: none; }

.nav { display: flex; gap: 24px; font-size: 15px; font-weight: 400; }
.nav a { display: inline-flex; align-items: center; min-height: 40px; text-decoration: none; color: var(--t2); transition: color 150ms ease-out; }
.nav a:hover { color: var(--t1); }
.nav .nav-kontakt { color: var(--t1); text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }

@media (max-width: 899px) {
  .nav a:not(.nav-kontakt) { display: none; }
}

/* ---------- Einstieg ---------- */
.einstieg { padding: 8px 0 0; overflow: hidden; }

.titel { display: block; }

.name {
  display: block;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 33.5vw;
  line-height: .84;
  letter-spacing: -.045em;
  color: var(--tinte);
  font-variation-settings: "opsz" 40;
  margin-left: -.04em;
}

.name i { font-style: italic; font-weight: 400; }

.zeile { display: block; overflow: hidden; padding-bottom: .06em; margin-bottom: -.06em; }
.zeile > span { display: block; }

.titel-zeilen {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--linie);
  font: 400 15px/1.35 var(--sans);
  letter-spacing: 0;
}
.titel-unter { color: var(--t1); max-width: 22ch; }
.titel-ort { color: var(--t2); text-align: right; flex: none; }

.einstieg-raster { display: grid; gap: 40px; padding-top: 24px; }

.einstieg-lead { max-width: 34ch; color: var(--t1); }

.knopf {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  margin-top: 24px;
  padding: 0 24px;
  border-radius: 999px;
  background: var(--akzent);
  color: var(--hell);
  font: 400 16px/1 var(--sans);
  text-decoration: none;
  transition: background-color 150ms ease-out, transform 150ms ease-out;
}
.knopf:hover { background-color: #1F2650; }
.knopf:active { transform: scale(.98); }

.einstieg-seit { margin-top: 16px; font-size: 15px; color: var(--t2); }

/* Stoffstreifen an der Stange */
.stoffe {
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  height: 280px;
  padding-top: 8px;
}

.stange {
  position: absolute;
  left: -8px; right: -8px; top: 0;
  height: 3px;
  border-radius: 2px;
  background: var(--tinte);
  opacity: .8;
}

.streifen {
  display: block;
  -webkit-mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / calc(2 * var(--zack)) 100%;
          mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / calc(2 * var(--zack)) 100%;
  transform-origin: 50% 0;
}

.s-leinen { height: 100%; background: url(img/leinen.svg) 0 0 / 320px; filter: brightness(1.07) saturate(.7); }
.s-samt   { height: 86%;  background: url(img/samt.svg) 30% 20% / 700px; }
.s-boucle { height: 94%;  background: url(img/boucle.svg) 0 0 / 300px; }
.s-fisch  { height: 78%;  background: url(img/fischgrat.svg) 0 0 / 48px; }
.s-nacht  { height: 90%;  background: url(img/nacht.svg) 0 0 / 320px; }

@media (min-width: 900px) {
  .einstieg { padding-top: 16px; }
  .name { font-size: min(17vw, 228px); line-height: .9; letter-spacing: -.04em; white-space: nowrap; }
  .zeile { display: inline-block; vertical-align: top; }
  .zeile + .zeile { margin-left: .22em; }
  .titel-zeilen { margin-top: 24px; font-size: 16px; }
  .titel-unter, .titel-ort { max-width: none; }

  .einstieg-raster {
    grid-template-columns: 5fr 7fr;
    gap: 64px;
    padding-top: 64px;
    align-items: start;
  }
  .einstieg-lead { font-size: 20px; line-height: 1.5; }
  .stoffe { height: 480px; gap: 16px; }
}

/* ---------- Abschnitte allgemein ---------- */
.abschnitt { padding: var(--luft) 0; }

.h2 {
  font-family: var(--serif);
  font-size: 48px;
  line-height: 1;
  letter-spacing: -.03em;
  color: var(--tinte);
}
@media (min-width: 900px) { .h2 { font-size: 88px; } }

/* ---------- Leistungen ---------- */
.leistungen { position: relative; }

.gruppe { margin-top: 40px; }
.gruppe-titel { font: 400 15px/1.4 var(--sans); color: var(--t2); padding-bottom: 16px; }

.liste { border-top: 1px solid var(--linie); }

.reihe {
  display: grid;
  grid-template-columns: 56px 1fr;
  column-gap: 16px;
  row-gap: 8px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--linie);
}

.muster {
  grid-row: span 2;
  width: 56px; height: 64px;
  -webkit-mask:
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 10px 51% repeat-x,
    conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / 10px 51% repeat-x;
          mask:
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 10px 51% repeat-x,
    conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / 10px 51% repeat-x;
}

.m-samt   { background: url(img/samt.svg) 40% 30% / 700px; }
.m-boucle { background: url(img/boucle.svg) 0 0 / 300px; }
.m-leinen { background: url(img/leinen.svg) 0 0 / 320px; filter: brightness(.92); }
.m-fisch  { background: url(img/fischgrat.svg) 0 0 / 48px; }
.m-licht  { background: url(img/plissee.svg) 50% 50% / cover; }
.m-gaze   { background: url(img/gaze.svg) 0 0 / 6px; }
.m-karte  {
  background:
    linear-gradient(90deg, #6f7a52 0 25%, #C9B48C 25% 50%, #2C3566 50% 75%, #E2B23A 75%);
}

.reihe-name {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 28px;
  line-height: 1.05;
  letter-spacing: -.02em;
  color: var(--tinte);
}
.reihe-text { color: var(--t2); font-size: 16px; line-height: 1.45; }

.hinweis { margin-top: 24px; font-size: 15px; color: var(--t3); max-width: 52ch; }

.folger { display: none; }

@media (min-width: 900px) {
  .leistungen .rahmen { display: grid; grid-template-columns: 3fr 9fr; column-gap: 40px; }
  .leistungen .h2 { grid-column: 1 / -1; margin-bottom: 24px; }
  .gruppe { display: contents; }
  .gruppe-titel { grid-column: 1; padding-top: 24px; margin-top: 40px; }
  .liste { grid-column: 2; margin-top: 40px; }
  .hinweis { grid-column: 2; }
  .reihe { grid-template-columns: 56px 5fr 4fr; column-gap: 24px; padding: 24px 0; }
  .muster { grid-row: auto; }
  .reihe-name { font-size: 44px; }
}

/* Am Computer: statt kleiner Muster folgt ein grosses Stoffmuster der Maus */
@media (hover: hover) and (pointer: fine) and (min-width: 900px) {
  .reihe { grid-template-columns: 5fr 4fr; cursor: default; }
  .reihe .muster { display: none; }
  .reihe-name { transition: transform 450ms var(--expo), color 150ms ease-out; }
  .reihe:hover .reihe-name { transform: translateX(16px); }

  .folger {
    display: block;
    position: fixed;
    left: 0; top: 0;
    z-index: 20;
    width: 220px; height: 280px;
    margin: -140px 0 0 -110px;
    pointer-events: none;
    opacity: 0;
    transform: translate3d(var(--x, 0), var(--y, 0), 0) rotate(var(--r, -4deg)) scale(.92);
    transition: opacity 200ms ease-out;
    filter: drop-shadow(0 16px 24px rgba(39, 35, 31, .2));
  }
  .folger::before {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--folger-bild, none);
    background-size: var(--folger-groesse, auto);
    -webkit-mask:
      conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 18px 51% repeat-x,
      conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / 18px 51% repeat-x;
            mask:
      conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 18px 51% repeat-x,
      conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / 18px 51% repeat-x;
  }
  .folger.an { opacity: 1; }
}

/* ---------- Atelier ---------- */
.atelier-raster { display: grid; gap: 64px; }

.atelier-text .h2 { margin-bottom: 40px; }
.atelier-text p { max-width: 60ch; color: var(--t2); }
.atelier-text p + p { margin-top: 24px; }
.atelier-text .gross {
  font: 500 26px/1.25 var(--serif);
  letter-spacing: -.015em;
  color: var(--t1);
  max-width: 24ch;
}

.atelier-bild { position: relative; margin: 0; }

.platzhalter {
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: flex-end;
  padding: 24px;
  background: var(--leinen-2) url(img/leinen.svg) 0 0 / 320px;
  background-blend-mode: multiply;
  border: 1px dashed rgba(39, 35, 31, .3);
  border-radius: 4px;
}
.platzhalter p { font-size: 15px; color: var(--t2); max-width: 20ch; }
@media (min-width: 900px) { .platzhalter { aspect-ratio: 1 / 1; } }

.altbild {
  position: absolute;
  top: -24px;
  right: 8px;
  width: 46%;
  max-width: 220px;
  transform: rotate(3deg);
  filter: drop-shadow(0 8px 16px rgba(39, 35, 31, .22));
}
.altbild img {
  width: 100%;
  -webkit-mask:
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 12px 51% repeat-x,
    conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / 12px 51% repeat-x;
          mask:
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 12px 51% repeat-x,
    conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / 12px 51% repeat-x;
}

.atelier-bild figcaption { margin-top: 16px; font-size: 15px; color: var(--t3); }

@media (min-width: 900px) {
  .atelier-raster { grid-template-columns: 6fr 5fr; gap: 104px; align-items: end; }
  .atelier-text .gross { font-size: 36px; }
  .altbild { right: -24px; top: -40px; }
}

/* ---------- Nacht: Besuch und Kontakt ---------- */
.nacht {
  position: relative;
  isolation: isolate;
  background: var(--nacht);
  color: var(--h1);
  padding: var(--luft) 0;
}
.nacht::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: url(img/nacht.svg) 0 0 / 320px repeat;
  opacity: .35;
}
.nacht .h2 { color: var(--h1); }

.besuch-raster { display: grid; gap: 40px; }

.adresse {
  margin-top: 24px;
  font: 500 28px/1.15 var(--serif);
  letter-spacing: -.015em;
}

.textlink {
  display: inline-block;
  padding: 8px 0;
  margin-top: 16px;
  font-weight: 400;
  color: var(--h1);
  text-decoration: underline;
  text-underline-offset: 5px;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--h3);
  transition: text-decoration-color 150ms ease-out;
}
.textlink:hover { text-decoration-color: var(--gelb); }

.jetzt { font-size: 17px; color: var(--h1); margin-bottom: 24px; min-height: 1.55em; }

.woche { display: grid; gap: 8px; }

.achse, .tag { display: grid; grid-template-columns: 96px 1fr; align-items: center; }
.achse { position: relative; height: 20px; font-size: 13px; color: var(--h3); }
.achse span { position: absolute; left: calc(96px + (var(--h) - 8) / 12 * (100% - 96px)); transform: translateX(-50%); white-space: nowrap; }
.achse span:last-child { transform: none; margin-left: -6px; }

.tag-name { font-size: 15px; color: var(--h2); display: flex; align-items: center; gap: 8px; }

.spur {
  position: relative;
  height: 32px;
  border-radius: 2px;
  background: rgba(236, 230, 218, .07);
}

.offen {
  position: absolute;
  top: 0; bottom: 0;
  left: calc((var(--von) - 8) / 12 * 100%);
  width: calc((var(--bis) - var(--von)) / 12 * 100%);
  display: flex;
  align-items: center;
  padding-left: 8px;
  border-radius: 2px;
  background: rgba(236, 230, 218, .86);
  color: var(--nacht);
  font-size: 13px;
  font-weight: 400;
  white-space: nowrap;
  overflow: hidden;
  transform-origin: 0 50%;
}

.zu { position: absolute; left: 8px; top: 50%; transform: translateY(-50%); font-size: 13px; color: var(--h3); }

.ist-heute .tag-name { color: var(--h1); }
.ist-heute .tag-name::after { content: "heute"; font-size: 13px; color: var(--gelb); }
.ist-heute .offen { background: var(--gelb); color: #2a2208; }

.zeiger {
  position: absolute;
  top: -4px; bottom: -4px;
  width: 2px;
  margin-left: -1px;
  background: var(--hell);
  border-radius: 1px;
}

.woche-fuss { margin-top: 16px; font-size: 15px; color: var(--h2); }

@media (min-width: 900px) {
  .besuch-raster { grid-template-columns: 4fr 7fr; gap: 104px; align-items: start; }
  .adresse { font-size: 40px; margin-top: 40px; }
  .woche-block { padding-top: 16px; }
  .achse, .tag { grid-template-columns: 128px 1fr; }
  .achse span { left: calc(128px + (var(--h) - 8) / 12 * (100% - 128px)); }
  .tag-name { font-size: 16px; }
  .spur { height: 40px; }
}

/* Kontakt: Mittelpunkt */
.kontakt {
  margin-top: var(--luft);
  padding-top: var(--luft);
  border-top: 1px solid rgba(236, 230, 218, .18);
}

.kontakt-titel { font: 400 15px/1.4 var(--sans); color: var(--h2); }

.mail {
  display: inline-block;
  margin-top: 16px;
  font-family: var(--serif);
  font-weight: 500;
  font-variation-settings: "opsz" 28;
  font-size: 10vw;
  line-height: 1.1;
  white-space: nowrap;
  letter-spacing: -.035em;
  color: var(--h1);
  text-decoration: none;
  background: linear-gradient(var(--gelb), var(--gelb)) 0 100% / 0 1px no-repeat;
  transition: background-size 600ms var(--expo);
}
.mail:hover { background-size: 100% 1px; }

.kontakt-text { margin-top: 24px; max-width: 44ch; color: var(--h2); }

.knopf-hell { background: var(--hell); color: var(--nacht); }
.knopf-hell:hover { background-color: #fff8ea; }

@media (min-width: 900px) {
  .mail { font-size: min(9vw, 116px); }
}

/* ---------- Fuss ---------- */
.fuss {
  background: var(--nacht);
  color: var(--h2);
  font-size: 15px;
  line-height: 1.5;
  padding: 40px 0;
  border-top: 1px solid rgba(236, 230, 218, .12);
}
.fuss-innen { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; align-items: flex-end; }
.fuss a { display: inline-block; padding: 8px 0; color: var(--h1); text-decoration-color: var(--h3); text-underline-offset: 4px; }
.entwurf { color: var(--h3); }

/* ---------- Bewegung ---------- */
/* Titel steigt aus der Maske, sobald das Tuch weg ist (oder direkt beim Laden) */
.js .zeile > span { transform: translateY(105%); }
.js .titel-zeilen, .js .einstieg-raster { opacity: 0; transform: translateY(16px); }
.js .streifen { transform: scaleY(.0001); }

.bereit .zeile > span { transform: none; transition: transform 1000ms var(--expo); }
.bereit .zeile + .zeile > span { transition-delay: 90ms; }
.bereit .titel-zeilen, .bereit .einstieg-raster { opacity: 1; transform: none; transition: opacity 800ms var(--expo) 250ms, transform 800ms var(--expo) 250ms; }
.bereit .streifen { transform: none; transition: transform 1100ms var(--expo); }
.bereit .s-leinen { transition-delay: 320ms; }
.bereit .s-samt   { transition-delay: 380ms; }
.bereit .s-boucle { transition-delay: 440ms; }
.bereit .s-fisch  { transition-delay: 500ms; }
.bereit .s-nacht  { transition-delay: 560ms; }

/* Öffnungsbalken wachsen beim Hereinscrollen */
.js .woche .offen { transform: scaleX(0); }
.js .woche.sichtbar .offen { transform: none; transition: transform 900ms var(--expo); transition-delay: calc(var(--i, 0) * 60ms); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .tuch-an .tuch { display: none; }
  .js .zeile > span,
  .js .titel-zeilen, .js .einstieg-raster,
  .js .streifen,
  .js .woche .offen { transform: none !important; opacity: 1 !important; transition: none !important; }
  .reihe-name, .mail { transition: none !important; }
  .folger { display: none !important; }
}
