@font-face {
  font-family: "Host Grotesk";
  src: url("assets/fonts/host-grotesk-latin-wght-normal.woff2") format("woff2");
  font-weight: 300 800;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Host Grotesk";
  src: url("assets/fonts/host-grotesk-latin-ext-wght-normal.woff2") format("woff2");
  font-weight: 300 800;
  font-display: swap;
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Martian Mono";
  src: url("assets/fonts/martian-mono-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Martian Mono";
  src: url("assets/fonts/martian-mono-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}

:root {
  /* The card itself: black and its gold */
  --card: #050708;
  --card-gold: #cfa14b;
  --card-cream: #f5f1ea;
  /* The drawing: paper, ink, and the card gold darkened so it reads on paper */
  --paper: #f5f1ea; /* the cream of the card */
  --paper-hi: #fbf9f5;
  --ink: #15171a;
  --ink-soft: #4a4d52;
  --ocher: #8a5f17;

  --fg: var(--card-cream);
  --fg-soft: rgba(245, 241, 234, 0.68);
  --accent: var(--card-gold);
  --rule: rgba(245, 241, 234, 0.22);

  --sans: "Host Grotesk", system-ui, sans-serif;
  --mono: "Martian Mono", ui-monospace, monospace;
  --gutter: clamp(16px, 4vw, 56px);
  --bar-h: 64px;
}

/* Switched by script once the paper has slid in */
body.on-paper {
  --fg: var(--ink);
  --fg-soft: var(--ink-soft);
  --accent: var(--ocher);
  --rule: rgba(21, 23, 26, 0.28);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { background: var(--card); }

body {
  background: var(--card);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  transition: color 0.5s ease;
  overflow-x: hidden;
}

a { color: inherit; }

/* ---------- Stage: fixed behind the page ---------- */

#stage {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

#paper {
  position: absolute;
  inset: 0;
  opacity: 0;
  background-color: var(--paper);
}

#rays {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

#scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.6s ease;
}
#scene.ready { opacity: 1; }

#card-still {
  position: absolute;
  width: min(36vw, 560px);
  right: 10vw;
  top: 44%;
  transform: translateY(-50%) perspective(1400px) rotateX(18deg) rotateY(-24deg) rotateZ(4deg);
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.55);
  transition: opacity 0.6s ease;
}
#card-still.gone { opacity: 0; }

/* ---------- The dot and its line ---------- */

#dot {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 5;
  width: 14px;
  height: 14px;
  margin: -7px 0 0 -7px;
  border-radius: 50%;
  background: var(--accent);
  pointer-events: none;
  opacity: 0;
  transition: background 0.5s ease, opacity 0.4s ease;
  will-change: transform;
}
#dot.on { opacity: 1; }
#dot i {
  /* a slow pulse, as if the dot were waiting to be sent */
  position: absolute;
  inset: -7px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  animation: pulse 2.4s ease-out infinite;
}
#dot.morph { transition: background 0.5s ease; } /* opacity follows the scroll directly here */
#dot.morph i { display: none; } /* no pulse while it turns into the avatar */
@keyframes pulse {
  from { transform: scale(0.6); opacity: 0.9; }
  to { transform: scale(1.9); opacity: 0; }
}

main { position: relative; z-index: 1; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  padding: var(--gutter);
  padding-bottom: calc(var(--bar-h) + clamp(32px, 7vh, 88px));
}

.hero-text { max-width: min(46rem, 52vw); }

h1 {
  font-size: clamp(2.5rem, 5.2vw, 5.4rem);
  line-height: 1.02;
  font-weight: 560;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.hero-sub {
  margin-top: 1.6rem;
  max-width: 32rem;
  color: var(--fg-soft);
  font-size: clamp(1rem, 1.25vw, 1.15rem);
}


/* ---------- Buttons: sharp rectangle, corner marks close into a frame on hover ---------- */

.btn {
  --c: var(--accent);
  --m: 10px;
  position: relative;
  display: inline-flex;
  align-items: center;
  margin-top: 2.2rem;
  padding: 1.05rem 1.6rem;
  border: 0;
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-decoration: none;
  color: var(--fg);
  cursor: pointer;
  background:
    linear-gradient(var(--c), var(--c)) top left / var(--m) 1px,
    linear-gradient(var(--c), var(--c)) top left / 1px var(--m),
    linear-gradient(var(--c), var(--c)) top right / var(--m) 1px,
    linear-gradient(var(--c), var(--c)) top right / 1px var(--m),
    linear-gradient(var(--c), var(--c)) bottom left / var(--m) 1px,
    linear-gradient(var(--c), var(--c)) bottom left / 1px var(--m),
    linear-gradient(var(--c), var(--c)) bottom right / var(--m) 1px,
    linear-gradient(var(--c), var(--c)) bottom right / 1px var(--m);
  background-repeat: no-repeat;
  transition: background-size 0.45s cubic-bezier(0.65, 0, 0.35, 1), color 0.3s ease;
}
.btn::before {
  /* filled plate that slides in once the frame is closed */
  content: "";
  position: absolute;
  inset: 0;
  background: var(--c);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s cubic-bezier(0.65, 0, 0.35, 1) 0.12s;
}
.btn span { position: relative; }
.btn:hover, .btn:focus-visible, .btn.filled {
  --m: 100%;
  color: var(--card);
  outline: none;
}
body.on-paper .btn:hover, body.on-paper .btn:focus-visible, body.on-paper .btn.filled { color: var(--paper); }
.btn:hover::before, .btn:focus-visible::before, .btn.filled::before { transform: scaleX(1); }
.btn[disabled] { cursor: wait; }

.btn-small { margin: 0; padding: 0.7rem 1rem; font-size: 0.72rem; }

/* the bag's dark inside, over everything at the end of the dive */
.dive-fade { position: absolute; inset: 0; background: var(--card); opacity: 0; pointer-events: none; }

/* ---------- Request: a letter sheet; on sending it becomes a light dot that shoots away ---------- */

#anfrage {
  --acc: #3fc9b8; /* turquoise, the accent of this part */
  position: relative;
  overflow: clip; /* the light dot leaves upwards without scrollbars */
  z-index: 2;
  background: var(--card);
  color: var(--card-cream);
  padding: clamp(96px, 16vh, 180px) var(--gutter) clamp(72px, 12vh, 140px);
  display: grid;
  justify-items: center;
}
.anfrage-head { max-width: 15em; text-align: center; font-size: clamp(2rem, 4.2vw, 4rem); line-height: 1.05; font-weight: 560; letter-spacing: -0.025em; }
.env-stage { --k: 1; position: relative; width: min(36rem, 100%); margin-top: clamp(2.4rem, 6vh, 4rem); perspective: 1400px; container-type: inline-size; }

/* the sheet: rises out of the dark and tips upright with the scroll (--k, main.js) */
.sheet {
  position: relative;
  z-index: 2;
  padding: clamp(24px, 3.2vw, 44px);
  background: var(--paper-hi);
  color: var(--ink);
  border-radius: 6px;
  box-shadow: 0 60px 120px -50px rgba(0, 0, 0, 0.95);
  transform-origin: 50% 100%;
  transform: translateY(calc((1 - var(--k)) * 26vh)) rotateX(calc((1 - var(--k)) * 20deg));
  opacity: calc(0.1 + var(--k) * 0.9);
  transition: transform 0.75s cubic-bezier(0.6, 0, 0.3, 1), opacity 0.4s ease;
}
.sheet-head { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding-bottom: 1rem; border-bottom: 1px solid rgba(21, 23, 26, 0.12); font-family: var(--mono); font-size: 0.66rem; color: var(--ink-soft); }
.sheet-head span:first-child { color: var(--acc); }
.sheet-lead { margin: 1.2rem 0 0.4rem; font-size: clamp(1.15rem, 1.6vw, 1.4rem); line-height: 1.3; font-weight: 500; letter-spacing: -0.01em; }
.sheet label { display: grid; gap: 0.3rem; margin-top: 1.1rem; }
.sheet label > span { font-family: var(--mono); font-size: 0.68rem; color: var(--ink-soft); }
.sheet label em { font-style: normal; opacity: 0.7; }
.sheet input:not([type="checkbox"]) { width: 100%; padding: 0.55rem 0; border: 0; border-bottom: 1px solid rgba(21, 23, 26, 0.26); border-radius: 0; background: transparent; font: inherit; font-size: 1.05rem; color: var(--ink); transition: border-color 0.25s ease; }
.sheet input::placeholder { color: rgba(21, 23, 26, 0.3); }
.sheet input:focus { outline: none; border-bottom-color: var(--acc); box-shadow: 0 1px 0 var(--acc); }
.sheet input[aria-invalid="true"] { border-bottom-color: var(--acc); }
.sheet .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.sheet .consent { grid-template-columns: 18px 1fr; gap: 0.75rem; align-items: start; margin-top: 1.4rem; }
.sheet .consent > span { font-family: var(--sans); font-size: 0.8rem; line-height: 1.45; color: var(--ink-soft); }
.sheet .consent input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--acc); }
.sheet .btn { --c: var(--acc); color: var(--ink); margin-top: 1.5rem; }
.sheet .btn:hover, .sheet .btn:focus-visible { color: var(--paper-hi); }

/* sending (classes set by main.js):
   s1 the fields fade and the sheet draws together into a small turquoise circle,
   s2 the light dot takes over and pulses once,
   s3 it shoots up out of the picture, a fine trail behind it */
.sheet > * { transition: opacity 0.3s ease; }
.env-stage.s1 .sheet > * { opacity: 0; }
@keyframes sheet-to-dot {
  0% { transform: none; border-radius: 6px; background-color: var(--paper-hi); }
  45% { transform: scale(0.42, 0.3); border-radius: 30px; background-color: #d9f6f1; }
  100% { transform: scale(var(--dx), var(--dy)); border-radius: 50%; background-color: var(--acc); }
}
.env-stage.s1 .sheet { transform-origin: 50% 50%; animation: sheet-to-dot 0.75s cubic-bezier(0.6, 0, 0.25, 1) forwards; opacity: 1; box-shadow: 0 0 40px rgba(63, 201, 184, 0.4); }
.env-stage.s2 .sheet { visibility: hidden; }

.send-dot {
  position: absolute;
  left: calc(50% - 9px);
  top: calc(50% - 9px);
  z-index: 3;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle, #e9fffb 0 30%, var(--acc) 70%);
  box-shadow: 0 0 18px 4px rgba(63, 201, 184, 0.75), 0 0 60px 12px rgba(63, 201, 184, 0.35);
  opacity: 0;
  pointer-events: none;
}
/* the trail: a thin line of light below the dot, only while it flies */
.send-dot::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 2px;
  height: 0;
  translate: -50% 0;
  background: linear-gradient(rgba(63, 201, 184, 0.9), transparent);
  border-radius: 2px;
  transition: height 0.5s cubic-bezier(0.5, 0, 0.75, 0.3);
}
@keyframes dot-pulse {
  0% { opacity: 0; transform: scale(0.4); }
  45% { opacity: 1; transform: scale(1.5); }
  100% { opacity: 1; transform: scale(1); }
}
.env-stage.s2 .send-dot { animation: dot-pulse 0.45s ease-out forwards; }
.env-stage.s3 .send-dot { animation: none; opacity: 1; transform: translateY(-120vh); transition: transform 0.75s cubic-bezier(0.6, 0, 0.85, 0.35); }
.env-stage.s3 .send-dot::after { height: 46vh; }
/* coming back for a new request: no movement, just there again */
.env-stage.resetting, .env-stage.resetting * { transition: none !important; }

#anfrage .form-msg { margin-top: 1.4rem; min-height: 1.4em; text-align: center; font-size: 0.95rem; color: rgba(245, 241, 234, 0.75); }
#anfrage .form-msg.ok { color: var(--card-cream); }
#anfrage .form-msg.err { color: #ff8a7d; }
.thanks { display: grid; justify-items: center; text-align: center; margin-top: clamp(1.6rem, 4vh, 2.6rem); }
.thanks[hidden] { display: none; }
.thanks-title { font-size: clamp(1.9rem, 3.6vw, 3.2rem); line-height: 1.08; font-weight: 560; letter-spacing: -0.022em; }
.thanks p { margin-top: 0.9rem; max-width: 28rem; font-size: clamp(1.02rem, 1.3vw, 1.18rem); line-height: 1.5; color: rgba(245, 241, 234, 0.7); opacity: 0; transition: opacity 0.5s ease 0.5s; }
.thanks .btn { --c: var(--acc); color: var(--card-cream); margin-top: 1.8rem; opacity: 0; transition: opacity 0.5s ease 0.7s, background-size 0.45s cubic-bezier(0.65, 0, 0.35, 1), color 0.3s ease; }
.thanks .btn:hover, .thanks .btn:focus-visible { color: var(--card); }
.thanks.in p, .thanks.in .btn, .thanks.in .env-again { opacity: 1; }
.env-again { margin-top: 1.2rem; font-family: var(--mono); font-size: 0.72rem; color: rgba(245, 241, 234, 0.55); opacity: 0; transition: opacity 0.5s ease 0.9s; }
.letter-direct { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.4rem 1.6rem; margin-top: clamp(2.4rem, 6vh, 3.6rem); font-family: var(--mono); font-size: 0.76rem; color: rgba(245, 241, 234, 0.5); }
.letter-direct a { overflow-wrap: anywhere; color: var(--card-cream); text-decoration: none; background: linear-gradient(var(--acc), var(--acc)) 0 100% / 0 1px no-repeat; padding-bottom: 2px; transition: background-size 0.35s ease; }
.letter-direct a:hover, .letter-direct a:focus-visible { background-size: 100% 1px; outline: none; }
@media (prefers-reduced-motion: reduce) {
  .sheet, .send-dot { transition: opacity 0.2s ease; animation-duration: 0.01s !important; }
}
.link { padding: 0; border: 0; background: none; font: inherit; color: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

.foot {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 1.6rem var(--gutter);
  border-top: 1px solid rgba(245, 241, 234, 0.1);
  background: var(--card);
  color: rgba(245, 241, 234, 0.55);
  font-family: var(--mono);
  font-size: 0.72rem;
}
.foot-links { display: flex; gap: 1.4rem; }
.foot .link { text-decoration: none; }
.foot .link:hover, .foot .link:focus-visible { color: var(--card-cream); text-decoration: underline; outline: none; }


/* ---------- Care packages: two cards open out of the button ---------- */

.svc-care .btn { margin-top: 1.6rem; }
#pakete {
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: clamp(20px, 5vh, 56px) clamp(16px, 4vw, 56px);
  border: 0;
  background: transparent;
  color: var(--card-cream);
  overflow-y: auto;
  text-align: center;
}
#pakete::backdrop { background: rgba(5, 7, 8, 0); backdrop-filter: blur(0); transition: background 0.5s ease, backdrop-filter 0.5s ease; }
#pakete.shown::backdrop { background: rgba(5, 7, 8, 0.82); backdrop-filter: blur(8px); }
#pakete .pakete-close { --c: var(--card-gold); position: fixed; top: clamp(14px, 3vh, 28px); right: clamp(14px, 3vw, 28px); color: var(--card-cream); z-index: 2; }
#pakete h2 {
  font-size: clamp(1.8rem, 3.4vw, 3rem);
  font-weight: 560;
  letter-spacing: -0.02em;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s ease, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
#pakete.shown h2 { opacity: 1; transform: none; }
.pakete-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 25rem));
  justify-content: center;
  gap: clamp(14px, 2vw, 28px);
  margin-top: clamp(1.2rem, 4vh, 2.6rem);
  perspective: 1400px;
}
/* both cards start stacked in the middle, tilted back, and swing out to their places */
.paket {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: clamp(22px, 2.4vw, 34px);
  border-radius: 18px;
  background: linear-gradient(165deg, #16191c, #0b0d0f 62%);
  box-shadow: 0 0 0 1px rgba(245, 241, 234, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 50px 90px -40px rgba(0, 0, 0, 0.95);
  text-align: left;
  opacity: 0;
  transform: translateX(calc((0.5 - var(--i)) * 52%)) translateY(60px) rotateX(18deg) scale(0.92);
  transition: opacity 0.5s ease calc(0.08s + var(--i) * 0.08s), transform 0.8s cubic-bezier(0.2, 0.75, 0.15, 1) calc(0.08s + var(--i) * 0.08s);
}
#pakete.shown .paket { opacity: 1; transform: none; }
.paket-plus { box-shadow: 0 0 0 1px rgba(61, 95, 158, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 50px 90px -40px rgba(0, 0, 0, 0.95), 0 0 70px -30px rgba(61, 95, 158, 0.45); }
.paket h3 { font-size: 1.5rem; font-weight: 560; letter-spacing: -0.01em; }
.paket-price { margin-top: 0.9rem; font-size: clamp(2.2rem, 3.4vw, 3rem); font-weight: 560; letter-spacing: -0.03em; line-height: 1; }
.paket-price small { font-family: var(--mono); font-size: 0.72rem; font-weight: 400; letter-spacing: 0; color: rgba(245, 241, 234, 0.55); }
.paket-price small:first-child { margin-right: 0.35rem; }
.paket-price small:last-child { margin-left: 0.4rem; }
.paket-lead { margin-top: 1rem; color: rgba(245, 241, 234, 0.78); line-height: 1.45; }
.paket-plus-note { margin-top: 1.2rem; font-family: var(--mono); font-size: 0.7rem; color: var(--card-gold); }
.paket ul { list-style: none; margin-top: 1.1rem; padding-top: 1.1rem; border-top: 1px solid rgba(245, 241, 234, 0.1); display: grid; gap: 0.65rem; }
.paket-plus-note + ul { margin-top: 0.6rem; }
.paket li { display: grid; grid-template-columns: 18px 1fr; gap: 0.7rem; font-size: 0.92rem; line-height: 1.4; color: rgba(245, 241, 234, 0.82); }
.paket li svg { width: 18px; height: 18px; margin-top: 1px; }
.paket li path { fill: none; stroke: var(--card-gold); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.paket-term { margin-top: auto; padding-top: 1.3rem; font-family: var(--mono); font-size: 0.68rem; color: rgba(245, 241, 234, 0.5); }
.pakete-note { max-width: 44rem; margin: clamp(1rem, 3vh, 1.8rem) auto 0; font-size: 0.85rem; color: rgba(245, 241, 234, 0.55); opacity: 0; transition: opacity 0.5s ease 0.4s; }
.pakete-cta { --c: var(--card-gold); color: var(--card-cream); margin-top: 1.2rem; opacity: 0; transition: opacity 0.5s ease 0.45s, background-size 0.45s cubic-bezier(0.65, 0, 0.35, 1), color 0.3s ease; }
#pakete.shown .pakete-note, #pakete.shown .pakete-cta { opacity: 1; }
@media (max-width: 760px) {
  .pakete-cards { grid-template-columns: minmax(0, 1fr); }
  .paket { transform: translateY(60px) rotateX(18deg) scale(0.92); }
  #pakete h2 { margin-top: 2.6rem; }
}
@media (prefers-reduced-motion: reduce) {
  .paket, #pakete h2 { transform: none; transition: opacity 0.2s ease; }
}

/* ---------- Legal dialog ---------- */

#legal {
  width: min(48rem, 100%);
  max-height: 100%;
  height: 100%;
  margin: 0 0 0 auto;
  padding: clamp(24px, 5vw, 64px);
  border: 0;
  border-left: 1px solid var(--ink);
  background: var(--paper-hi);
  color: var(--ink);
  font-size: 0.95rem;
}
#legal::backdrop { background: rgba(5, 7, 8, 0.45); }
#legal .legal-close { --c: var(--ocher); position: sticky; top: 0; float: right; color: var(--ink); }
#legal .legal-doc { display: none; }
#legal .legal-doc.open { display: block; }
#legal h1 { font-size: 2.2rem; margin-bottom: 0.8rem; }
#legal h2 { font-size: 1.1rem; letter-spacing: 0; margin: 1.8rem 0 0.5rem; }
#legal p, #legal ul { margin-bottom: 0.7rem; color: var(--ink-soft); }
#legal ul { padding-left: 1.2rem; }
#legal .legal-lead { font-size: 1.05rem; color: var(--ink); }

/* ---------- Scroll hint in the hero ---------- */

.scroll-hint {
  position: absolute;
  left: 50%;
  bottom: clamp(16px, 3vh, 28px);
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 0.6rem;
  font-family: var(--mono);
  font-size: 0.66rem;
  color: var(--fg-soft);
  transition: opacity 0.4s ease;
}
.scroll-hint.gone { opacity: 0; }
.scroll-hint i {
  /* a short gold piece runs down a hairline, again and again */
  position: relative;
  width: 1px;
  height: 44px;
  overflow: hidden;
  background: rgba(245, 241, 234, 0.18);
}
.scroll-hint i::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 1px;
  height: 14px;
  background: var(--card-gold);
  animation: hint 2.2s cubic-bezier(0.65, 0, 0.35, 1) infinite;
}
@keyframes hint {
  from { transform: translateY(-14px); }
  to { transform: translateY(44px); }
}
@media (prefers-reduced-motion: reduce) {
  .scroll-hint i::after { animation: none; transform: translateY(15px); }
}

/* ---------- Brand icon, floating top left ---------- */

.corner-brand {
  position: fixed;
  top: clamp(16px, 3vh, 28px);
  left: var(--gutter);
  z-index: 10;
}
.corner-brand img { display: block; transition: transform 0.3s ease; }
.corner-brand:hover img, .corner-brand:focus-visible img { transform: scale(1.06); }

/* ---------- Requests: hand with phone, the dot becomes the first notification ---------- */

#anfragen { position: relative; height: 640vh; } /* phone scene, then the scan */
/* in the phone scene the accent is a light green instead of the card gold */
#anfragen { --card-gold: #a6ec7c; --accent: #a6ec7c; }
#dot.green { --accent: #a6ec7c; } /* the card's dot turns green once it arrives on the phone */

#anfragen .pin {
  position: sticky;
  top: 0;
  height: 100svh;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  background: var(--card); /* backdrop for the blend below */
}

.phone {
  position: relative;
  align-self: end;
  justify-self: center;
  height: 100svh;
  aspect-ratio: 1122 / 1402;
  opacity: 0;
  will-change: transform, opacity;
  /* the photo black is a touch deeper than the card black: lighten lifts it to the page colour */
  mix-blend-mode: lighten;
}
.phone img {
  display: block;
  width: 100%;
  height: 100%;
  /* edges run out into the page black, the arm leaves at the bottom */
  /* edges run out into the page black; the second layer softens the cut of the arm on the left */
  -webkit-mask-image: radial-gradient(120% 95% at 50% 62%, #000 62%, transparent 100%), linear-gradient(90deg, transparent, #000 14%);
  -webkit-mask-composite: source-in;
  mask-image: radial-gradient(120% 95% at 50% 62%, #000 62%, transparent 100%), linear-gradient(90deg, transparent, #000 14%);
  mask-composite: intersect;
}
.phone-px {
  position: absolute;
  left: 0;
  top: 0;
  width: 1122px;
  height: 1402px;
  transform-origin: 0 0;
}

.pin-rays {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.screen-glow {
  position: absolute;
  left: 0;
  top: 0;
  width: 900px;
  height: 900px;
  margin: -450px 0 0 -450px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(232, 236, 245, 0.16) 0%, rgba(232, 236, 245, 0.06) 30%, transparent 62%);
  opacity: 0;
  will-change: transform, opacity;
}

/* the glass, in its own unwarped pixels (437 x 927); script maps it onto the four corners */
.screen {
  position: absolute;
  left: 0;
  top: 0;
  width: 437px;
  height: 927px;
  transform-origin: 0 0;
  border-radius: 54px;
  overflow: hidden;
  color: #f4f2ee;
  font-family: var(--sans);
}

.lock {
  position: absolute;
  top: 70px;
  left: 0;
  right: 0;
  text-align: center;
  opacity: 0;
}
.lock-date { font-size: 21px; font-weight: 500; opacity: 0.8; }
.lock-time { font-size: 104px; line-height: 1; font-weight: 600; letter-spacing: -0.03em; }

.notes { list-style: none; }
.note {
  position: absolute;
  left: 16px;
  right: 16px;
  top: 254px; /* NOTE_TOP in main.js */
  display: grid;
  grid-template-columns: 52px 1fr auto;
  column-gap: 14px;
  row-gap: 2px;
  padding: 16px 20px 17px 16px;
  border-radius: 28px;
  /* a real notification card on a dark lock screen */
  background: rgba(44, 46, 50, 0.94);
  opacity: 0;
  will-change: transform, opacity, clip-path;
}
.note-icon {
  /* the person who asks: round avatar with initials, like a messenger */
  position: relative;
  grid-row: 1 / span 3;
  align-self: start;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--c);
  display: grid;
  place-items: center;
  font-size: 19px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #f4f2ee;
}
/* small badge: it came in through the website, shown as the gold dot of the card */
.note-icon i {
  position: absolute;
  right: -3px;
  bottom: -3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 3px solid rgb(44, 46, 50);
  background: radial-gradient(circle, var(--card-gold) 0 4px, var(--card) 4.5px);
}
.note-app { font-size: 17px; opacity: 0.6; }
.note-when { font-size: 17px; opacity: 0.6; text-align: right; }
.note strong { grid-column: 2 / -1; font-size: 21px; font-weight: 600; }
.note-text { grid-column: 2 / -1; font-size: 20px; line-height: 1.3; opacity: 0.88; }

.anfragen-text {
  max-width: 34rem;
  padding-right: var(--gutter);
  padding-bottom: var(--bar-h);
}
.anfragen-text h2 {
  font-size: clamp(2rem, 3.6vw, 3.8rem);
  line-height: 1.04;
  font-weight: 560;
  letter-spacing: -0.022em;
  text-wrap: balance;
}
.anfragen-text p {
  margin-top: 1.2rem;
  max-width: 28rem;
  color: var(--fg-soft);
  font-size: clamp(1.02rem, 1.2vw, 1.15rem);
}
/* revealed letter by letter with a green veil (veil.js) */

/* ---------- Scan: photo becomes a line drawing, one sentence is written over it ---------- */

.scan-fx { position: absolute; inset: 0; visibility: hidden; pointer-events: none; }
.scan-stars { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; }
.scan-grid {
  position: absolute;
  inset: 0;
  opacity: 0;
  background:
    linear-gradient(rgba(214, 226, 245, 0.07) 1px, transparent 1px) 0 0 / 88px 88px,
    linear-gradient(90deg, rgba(214, 226, 245, 0.07) 1px, transparent 1px) 0 0 / 88px 88px;
  -webkit-mask-image: radial-gradient(60% 55% at 50% 40%, #000, transparent);
  mask-image: radial-gradient(60% 55% at 50% 40%, #000, transparent);
}
.scan { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }

.scan-text {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 0 var(--gutter);
  pointer-events: none;
}
.scan-s {
  max-width: 13em;
  text-align: center;
  font-size: clamp(2.3rem, 6.2vw, 7rem);
  line-height: 1.05;
  font-weight: 500;
  letter-spacing: -0.022em;
  color: var(--card-cream);
}
/* texts with a colour veil (veil.js): words never break, the letters are coloured by script */
.veil-word { white-space: nowrap; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- White part after the dark sequence ---------- */

.sheet-up {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  background: var(--card-cream);
  color: var(--ink);
  display: grid;
  place-items: center;
}
/* the dark of the sequence reaches into the white as a tab, like a drawer handle */
.sheet-tab { position: absolute; left: 0; top: 0; width: 100%; height: 44px; }
.sheet-tab path { fill: var(--card); }
/* ---------- Projects: three places on a turntable, turned by scrolling ---------- */

.sheet-up { display: block; height: 420vh; }
.projekte { width: 100%; height: 100%; }
.projekte-pin {
  position: sticky;
  top: 0;
  height: 100svh;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  padding: clamp(78px, 12vh, 150px) var(--gutter) clamp(20px, 4vh, 56px);
  overflow: hidden;
}
.projekte-head { max-width: 40rem; }
.projekte-head h2 {
  font-size: clamp(2rem, 3.8vw, 3.9rem);
  line-height: 1.04;
  font-weight: 560;
  letter-spacing: -0.022em;
  text-wrap: balance;
}
.projekte-head p { margin-top: 1rem; max-width: 30rem; color: var(--ink-soft); font-size: clamp(1rem, 1.15vw, 1.1rem); }

.turntable {
  position: relative;
  display: grid;
  place-items: center;
  margin: clamp(20px, 4vh, 48px) 0 clamp(12px, 2vh, 24px); /* air between text and turntable */
  perspective: 1600px;
  perspective-origin: 50% 50%; /* the flight goes straight through the middle of the front place */
}
/* width is set by script from the free width and height, so all three places fit */
.ring { position: relative; width: 44vw; aspect-ratio: 16 / 10; transform-style: preserve-3d; }
.slot3d {
  --shade: 0;
  position: absolute;
  inset: 0;
  border-radius: 14px;
  background: var(--card);
  overflow: hidden;
  /* a soft mirror on the floor (Chrome, Safari) */
  -webkit-box-reflect: below 10px linear-gradient(transparent 55%, rgba(0, 0, 0, 0.18));
}
.slot3d::after {
  /* the further it turns away, the darker */
  content: "";
  position: absolute;
  inset: 0;
  background: var(--card-cream);
  opacity: calc(var(--shade) * 0.55);
  pointer-events: none;
}
.slot3d svg { position: absolute; inset: 6%; width: 88%; height: 88%; }
.slot3d svg * { fill: none; stroke: rgba(245, 241, 234, 0.22); stroke-width: 2; }
.slot3d svg .thick { stroke: rgba(245, 241, 234, 0.32); stroke-width: 14; stroke-linecap: round; }
.slot3d svg .cross { stroke: rgba(245, 241, 234, 0.1); }
.slot-label {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.75rem 1.1rem;
  background: var(--card);
  border: 1px solid rgba(207, 161, 75, 0.45);
  color: var(--card-cream);
  font-family: var(--mono);
  font-size: clamp(0.62rem, 0.9vw, 0.78rem);
  white-space: nowrap;
}
.slot-label i { width: 9px; height: 9px; border-radius: 50%; background: var(--card-gold); }
.slot3d.front .slot-label i { animation: pulse-dot 2s ease-in-out infinite; }
@keyframes pulse-dot { 50% { box-shadow: 0 0 0 6px rgba(207, 161, 75, 0.18); } }

.ring-caption { position: relative; height: 1.6em; text-align: center; font-family: var(--mono); font-size: 0.74rem; color: var(--ink-soft); }
.ring-caption span { position: absolute; inset: 0; opacity: 0; pointer-events: none; transition: opacity 0.35s ease; }
.ring-caption span.on { opacity: 1; pointer-events: auto; }
.ring-caption a { color: var(--ink); text-underline-offset: 4px; text-decoration-color: var(--ocher); }

@media (max-width: 760px) {
  .slot-label { font-size: 0.58rem; padding: 0.55rem 0.8rem; }
}

/* ---------- About me: photos and text in a zigzag on the paper ---------- */

#ueber {
  position: relative;
  z-index: 2; /* lies above the services, which start underneath its last screen */
  background: var(--card-cream);
  color: var(--ink);
  padding: clamp(40px, 8vh, 100px) var(--gutter) clamp(90px, 16vh, 180px);
}
.ueber-grid {
  max-width: 72rem;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  column-gap: clamp(32px, 7vw, 110px);
  row-gap: clamp(56px, 12vh, 140px);
  align-items: center;
}
/* the photos open like a slit from the bottom (--r: 0..1, set by ueber.js) */
.ueber-photo { --r: 0; position: relative; margin: 0; overflow: hidden; border-radius: 4px; clip-path: inset(calc((1 - var(--r)) * 100%) 0 0 0); }
.ueber-photo img { display: block; width: 100%; height: 100%; object-fit: cover; transform: scale(calc(1.18 - var(--r) * 0.18)); transform-origin: 50% 100%; }
.ueber-portrait { aspect-ratio: 3 / 4; max-height: 82vh; width: min(100%, 30rem); }
.ueber-desk { aspect-ratio: 4 / 3; }
.ueber-balkon { aspect-ratio: 3 / 4; max-height: 76vh; width: min(100%, 26rem); justify-self: end; }
/* the heading rises out of its own line, the lead and the texts follow (--r as well) */
.ueber-head h2 { overflow: hidden; padding-top: 0.14em; /* room for the dots of the Ü */ font-size: clamp(2.8rem, 5.6vw, 5.8rem); line-height: 1; font-weight: 560; letter-spacing: -0.035em; }
.ueber-head h2 span { --r: 0; display: block; transform: translateY(calc((1 - var(--r)) * 105%)); }
.ueber-lead { --r: 0; margin-top: clamp(1rem, 3vh, 1.8rem); max-width: 22rem; font-size: clamp(1.3rem, 2vw, 1.9rem); line-height: 1.2; font-weight: 500; letter-spacing: -0.012em; opacity: var(--r); transform: translateY(calc((1 - var(--r)) * 18px)); }
.ueber-text { --r: 0; max-width: 32rem; font-size: clamp(1.05rem, 1.35vw, 1.25rem); line-height: 1.6; color: var(--ink-soft); opacity: var(--r); transform: translateY(calc((1 - var(--r)) * 22px)); }
.ueber-t1 { justify-self: end; }
.ueber-sign { margin-top: 1.4rem; font-family: var(--mono); font-size: 0.74rem; color: var(--ocher); }
@media (max-width: 760px) {
  .ueber-grid { grid-template-columns: minmax(0, 1fr); row-gap: 36px; }
  .ueber-portrait, .ueber-balkon { width: 100%; max-height: 70vh; justify-self: stretch; }
  .ueber-t1 { justify-self: start; }
}

/* ---------- Services: a dark room, the camera flies forward ---------- */

/* starts one screen early, underneath the projects (they sit above it), see leistungen.js */
/* in the services the accent is night blue instead of the card gold */
#leistungen, #pakete { --card-gold: #3d5f9e; --accent: #3d5f9e; }
.svc-rays { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
#leistungen { position: relative; z-index: 1; margin-top: -100svh; height: 800vh; background: var(--card); color: var(--card-cream); }
.space {
  position: sticky;
  top: 0;
  height: 100svh;
  overflow: hidden;
  perspective: 1000px;
  /* a few far away specks so the room has depth */
  background:
    radial-gradient(1px 1px at 12% 22%, rgba(245, 241, 234, 0.5), transparent),
    radial-gradient(1px 1px at 78% 14%, rgba(245, 241, 234, 0.4), transparent),
    radial-gradient(1px 1px at 64% 72%, rgba(245, 241, 234, 0.45), transparent),
    radial-gradient(1px 1px at 28% 84%, rgba(245, 241, 234, 0.35), transparent),
    radial-gradient(1.5px 1.5px at 90% 56%, rgba(61, 95, 158, 0.8), transparent),
    radial-gradient(1px 1px at 40% 40%, rgba(245, 241, 234, 0.3), transparent),
    var(--card);
}
.world { position: absolute; inset: 0; transform-style: preserve-3d; }
.service {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(30rem, 40vw); /* with the 12vw offset it always stays on screen */
  opacity: 0;
  visibility: hidden;
  will-change: transform, opacity, filter;
}
.service.intro { width: min(46rem, 90vw); text-align: center; }
/* every service the same way: the heading and one sentence on top, the picture large and centred
   below; the picture is sized by the height too, so both always fit on the screen */
.service:not(.intro) {
  --o: 0;
  width: min(76rem, 92vw);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1rem, 3.5vh, 2.5rem);
  text-align: center;
}
.svc-text { order: -1; max-width: 40rem; }
.service h2 {
  font-size: clamp(2.2rem, 5vw, 5.2rem);
  line-height: 1.04;
  font-weight: 560;
  letter-spacing: -0.022em;
}
.service h3 {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  font-size: clamp(1.8rem, 3.4vw, 3.4rem);
  line-height: 1.05;
  font-weight: 560;
  letter-spacing: -0.02em;
}
.service h3 i { flex: none; width: 12px; height: 12px; border-radius: 50%; background: var(--card-gold); }
.service p { margin-top: 1rem; color: rgba(245, 241, 234, 0.68); font-size: clamp(1rem, 1.25vw, 1.2rem); line-height: 1.5; }

/* Webdesign: three devices showing the same example site */
.devices { position: relative; width: min(60rem, 88vw, calc((100svh - 17rem) * 16 / 11)); aspect-ratio: 16 / 11; }
.dev { position: absolute; z-index: 1; } /* above the light pools */
/* spread out from one stack in the middle while coming closer (--o from 0 to 1) */
.dev.dev-laptop { left: 0; top: 0; width: 80%; transform: translate(calc((1 - var(--o)) * 10%), calc((1 - var(--o)) * 8%)); }
.dev.dev-tablet { right: 0; bottom: 4%; width: 30%; transform: translate(calc((1 - var(--o)) * -70%), calc((1 - var(--o)) * -20%)); }
.dev.dev-phone { left: 6%; bottom: 0; width: 14%; transform: translate(calc((1 - var(--o)) * 180%), calc((1 - var(--o)) * -30%)); }
/* devices: black glass bezel, a thin metal edge, a soft shadow below and a sheen on the glass */
.dev-screen {
  --bz: 6px;
  position: relative;
  overflow: hidden;
  container-type: inline-size;
  background: #f3ece0;
  border: var(--bz) solid #07080a;
  border-radius: 12px;
  box-shadow:
    0 0 0 1.5px #3d4147,                     /* metal edge */
    0 0 0 2.5px rgba(255, 255, 255, 0.07),   /* highlight on the edge */
    inset 0 0 0 1px rgba(255, 255, 255, 0.04),
    0 40px 70px -24px rgba(0, 0, 0, 0.9),    /* shadow below */
    0 0 60px -10px rgba(214, 226, 245, 0.10); /* faint glow of the screen into the room */
}
.dev-screen::after {
  /* light falling on the glass from the top left */
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(118deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0.05) 28%, rgba(255, 255, 255, 0) 42%);
}
.dev-screen::before {
  /* camera in the bezel */
  content: "";
  position: absolute;
  z-index: 3;
  left: 50%;
  top: calc(var(--bz) * -0.62);
  width: 4px;
  height: 4px;
  margin-left: -2px;
  border-radius: 50%;
  background: #1d2733;
  box-shadow: 0 0 0 1px #000;
}
.dev-laptop .dev-screen { --bz: 9px; aspect-ratio: 16 / 10; border-radius: 12px 12px 2px 2px; border-bottom-width: 14px; }
.laptop-base {
  /* the lower half: brushed aluminium with a finger groove in the middle */
  position: relative;
  height: 11px;
  margin: 0 -7%;
  border-radius: 1px 1px 12px 12px / 1px 1px 9px 9px;
  background: linear-gradient(#6c7077, #3a3d42 45%, #1c1e21);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.18) inset, 0 26px 40px -14px rgba(0, 0, 0, 0.9);
}
.laptop-base::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  width: 14%;
  height: 4px;
  transform: translateX(-50%);
  border-radius: 0 0 6px 6px;
  background: #24272b;
}
.dev-tablet .dev-screen { --bz: 9px; aspect-ratio: 3 / 4; border-radius: 18px; }
.dev-phone .dev-screen { --bz: 4px; aspect-ratio: 9 / 19; border-radius: 16px; }
.dev-phone .dev-screen::before {
  /* the pill at the top of the phone */
  top: 6px;
  width: 30%;
  height: 7px;
  margin-left: -15%;
  border-radius: 6px;
  background: #050506;
  box-shadow: none;
}

/* light around the devices: a cool glow behind, a warm pool of light below */
.devices::before, .devices::after {
  content: "";
  position: absolute;
  pointer-events: none;
}
.devices::before {
  inset: -18% -12%;
  background: radial-gradient(50% 50% at 50% 45%, rgba(214, 226, 245, 0.09), transparent 70%);
}
.devices::after {
  left: 5%;
  right: 5%;
  bottom: -14%;
  height: 26%;
  background: radial-gradient(50% 50% at 50% 50%, rgba(61, 95, 158, 0.2), transparent 72%);
}

/* Monatliche Betreuung: a server module in 3D */
.care3d { display: block; width: min(60rem, 88vw, calc((100svh - 19rem) * 4 / 3)); aspect-ratio: 4 / 3; } /* 19rem: heading, sentence and button above */

/* Packaging Design: the own brand as packaging in 3D */
/* the item is as large as the screen: heading at the top, the 3D picture fills everything behind
   it, so the products are never cut at its edges and the dive needs no scaling */
.service.svc-pack { width: 100vw; height: 100svh; justify-content: flex-start; padding: clamp(1.5rem, 6vh, 4rem) 4vw 0; }
.svc-pack .svc-text { position: relative; z-index: 1; }
.products3d { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }

/* the example site of an unnamed business in black, white and the blue of the services; sized by
   its screen (cqw) so it lays out like a real responsive page */
.mini { --b: #3d5f9e; --ink: #0c111c; text-align: left; position: absolute; inset: 0; display: grid; grid-template-rows: auto 1fr auto; background: #f6f7fa; color: var(--ink); font-family: var(--sans); }
.mini-bar { display: flex; align-items: center; gap: 3cqw; padding: 2.2cqw 4cqw; background: #0b0f19; color: #f6f7fa; }
.mini-bar b { display: flex; align-items: center; gap: 1.2cqw; font-size: 2.6cqw; font-weight: 600; letter-spacing: -0.01em; }
.mini-bar b i { width: 2.6cqw; height: 2.6cqw; border-radius: 0.7cqw; background: var(--b); }
.mini-bar nav { display: flex; gap: 2.6cqw; margin-left: auto; font-size: 1.7cqw; color: rgba(246, 247, 250, 0.7); }
.mini-bar em { padding: 1cqw 2cqw; border-radius: 0.8cqw; background: var(--b); font-style: normal; font-size: 1.7cqw; font-weight: 600; }
.mini-bar s { display: none; }
.mini-hero { display: grid; grid-template-columns: 1.05fr 1fr; align-items: center; gap: 4cqw; padding: 5cqw 4cqw 3cqw; }
.mini-copy p { margin: 0; color: var(--ink); font-size: 5.2cqw; line-height: 1.05; font-weight: 600; letter-spacing: -0.03em; }
.mini-sub { display: block; margin-top: 1.8cqw; font-size: 1.9cqw; line-height: 1.4; color: #5a6275; }
.mini-cta { display: flex; gap: 1.6cqw; margin-top: 3cqw; }
.mini-cta i, .mini-cta u { padding: 1.3cqw 2.4cqw; border-radius: 0.9cqw; font-style: normal; text-decoration: none; font-size: 1.8cqw; font-weight: 600; }
.mini-cta i { background: var(--b); color: #fff; }
.mini-cta u { border: 1px solid rgba(12, 17, 28, 0.25); }
/* an abstract picture in the blues instead of a photo */
.mini-visual {
  aspect-ratio: 4 / 3;
  border-radius: 1.6cqw;
  background:
    radial-gradient(60% 50% at 75% 25%, rgba(143, 176, 232, 0.9), transparent 70%),
    radial-gradient(45% 40% at 20% 85%, rgba(12, 17, 28, 0.55), transparent 70%),
    linear-gradient(140deg, #1f3a6b, #3d5f9e 55%, #6f8fc4);
}
.mini-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.4cqw; padding: 0 4cqw 4cqw; }
.mini-row div { display: grid; gap: 1cqw; padding: 2.2cqw; border-radius: 1.2cqw; background: #fff; box-shadow: 0 0 0 1px rgba(12, 17, 28, 0.07); }
.mini-row i { width: 3cqw; height: 3cqw; border-radius: 0.8cqw; background: rgba(61, 95, 158, 0.15); box-shadow: inset 0 0 0 0.5cqw rgba(61, 95, 158, 0.55); }
.mini-row b { font-size: 2cqw; font-weight: 600; }
.mini-row span { height: 0.9cqw; border-radius: 1cqw; background: #e3e6ee; }
.mini-row span + span { width: 70%; }
/* narrow screens (tablet, phone): stacked like a real mobile page, a menu icon instead of the links */
@container (max-width: 400px) {
  .mini-bar { padding: 4cqw 5cqw; }
  .mini-bar b { font-size: 5.6cqw; gap: 2.4cqw; }
  .mini-bar b i { width: 5.4cqw; height: 5.4cqw; border-radius: 1.4cqw; }
  .mini-bar nav, .mini-bar em { display: none; }
  .mini-bar s { display: block; margin-left: auto; width: 6cqw; height: 4cqw; background: linear-gradient(#f6f7fa, #f6f7fa) 0 0 / 100% 0.7cqw no-repeat, linear-gradient(#f6f7fa, #f6f7fa) 0 50% / 100% 0.7cqw no-repeat, linear-gradient(#f6f7fa, #f6f7fa) 0 100% / 100% 0.7cqw no-repeat; }
  .mini-hero { grid-template-columns: 1fr; gap: 5cqw; padding: 6cqw 5cqw 4cqw; }
  .mini-visual { order: -1; aspect-ratio: 16 / 10; border-radius: 3cqw; }
  .mini-copy p { font-size: 10cqw; }
  .mini-sub { font-size: 4cqw; margin-top: 3cqw; }
  .mini-cta { flex-direction: column; gap: 2.4cqw; margin-top: 5cqw; }
  .mini-cta i, .mini-cta u { padding: 3cqw 4cqw; border-radius: 2cqw; font-size: 4.2cqw; text-align: center; }
  .mini-row { grid-template-columns: 1fr; gap: 3cqw; padding: 0 5cqw 5cqw; }
  .mini-row div { padding: 4cqw; border-radius: 2.4cqw; gap: 2cqw; }
  .mini-row i { width: 6cqw; height: 6cqw; border-radius: 1.6cqw; }
  .mini-row b { font-size: 4.4cqw; }
  .mini-row span { height: 1.8cqw; }
}

@media (max-width: 760px) {
  .service:not(.intro) { --x: -50% !important; }
  .service { width: 84vw; }
}

/* ---------- Tablets and phones ---------- */

@media (max-width: 760px) {
  #anfragen .pin {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: 54svh auto; /* phone and text together fit one screen, also with the browser bars */
    align-items: start;
  }
  .phone { height: min(54svh, 125vw); align-self: end; } /* 125vw = full width at the photo ratio */
  /* the arm ends in the text area, so it fades out at the bottom here */
  .phone img {
    -webkit-mask-image: linear-gradient(#000 70%, transparent 98%);
    mask-image: linear-gradient(#000 70%, transparent 98%);
  }
  .anfragen-text { max-width: none; padding: 1rem var(--gutter) 1.5rem; }
  .anfragen-text p { max-width: none; }
  /* the sentence sits inside the upright phone frame here */
  .scan-text { padding: 0 44px; }
  .scan-s { font-size: 1.85rem; }
  .anfragen-text h2 { font-size: 1.6rem; }
  .anfragen-text p { font-size: 0.95rem; margin-top: 0.6rem; }
}

@media (max-width: 760px) {
  :root { --bar-h: 58px; }
  body { font-size: 16px; }

  .hero-text { max-width: none; }
  #card-still {
    width: 74vw;
    right: 13vw;
    top: 24%;
    transform: translateY(-50%) perspective(900px) rotateX(16deg) rotateY(-14deg) rotateZ(3deg);
  }


}

@media (prefers-reduced-motion: reduce) {
  .btn, .btn::before, #scene, #card-still { transition: none; }
  #dot i { animation: none; opacity: 0; }
}
