/* dustingotte.de – hellgraues Papier, fette Montserrat-Überschriften, Senfgelb als Akzent.
   Zwei eigene Layouts: Handy (wie eine App, Tab-Leiste, Wischkarten) und Computer (Bento-Raster, Hover). */
@font-face { font-family: "Montserrat"; font-weight: 500; font-display: swap; src: url("fonts/montserrat-500.woff2") format("woff2"); }
@font-face { font-family: "Montserrat"; font-weight: 700; font-display: swap; src: url("fonts/montserrat-700.woff2") format("woff2"); }
@font-face { font-family: "Montserrat"; font-weight: 800; font-display: swap; src: url("fonts/montserrat-800.woff2") format("woff2"); }

:root {
  --paper: #EEEEEC; --card: #F9F9F7; --border: #DCDCD8; --chip: #E4E4E0; --sunk: #E7E7E3;
  --ink: #1C1C1C; --muted: #66665F; --accent: #8A6410; --sun: #E3B94B; --on-sun: #1C1C1C;
  --night: #1C1C1C; --on-night: #F2F2EE; --night-muted: #A9A9A1;
  --display: "Montserrat", system-ui, -apple-system, "Helvetica Neue", sans-serif;
  --sans: system-ui, -apple-system, "Helvetica Neue", "Segoe UI", sans-serif;
  --shadow-lift: 0 2px 4px rgb(0 0 0 / .05), 0 24px 48px rgb(0 0 0 / .12);
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --paper: #141413; --card: #1E1E1C; --border: #33332F; --chip: #2A2A27; --sunk: #191917;
  --ink: #EDEDEA; --muted: #A5A59C; --accent: #E9C46A; --sun: #D9AE3F; --on-sun: #141413;
  --night: #262623; --on-night: #F2F2EE; --night-muted: #A9A9A1;
  --shadow-lift: 0 2px 4px rgb(0 0 0 / .3), 0 24px 48px rgb(0 0 0 / .45); color-scheme: dark } }
:root[data-theme="dark"] {
  --paper: #141413; --card: #1E1E1C; --border: #33332F; --chip: #2A2A27; --sunk: #191917;
  --ink: #EDEDEA; --muted: #A5A59C; --accent: #E9C46A; --sun: #D9AE3F; --on-sun: #141413;
  --night: #262623; --on-night: #F2F2EE; --night-muted: #A9A9A1;
  --shadow-lift: 0 2px 4px rgb(0 0 0 / .3), 0 24px 48px rgb(0 0 0 / .45); color-scheme: dark }

/* ---------- Grundlagen ---------- */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 72px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.6 var(--sans); overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); font-weight: 600; text-underline-offset: 3px; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
mark { background: linear-gradient(transparent 58%, var(--sun) 58%); color: inherit; padding: 0 .08em; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 24px; border-radius: 999px;
  font: 700 .82rem/1 var(--display); text-transform: uppercase; letter-spacing: .07em; text-decoration: none;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s; }
.btn.primary { background: var(--ink); color: var(--paper); }
.btn.secondary { color: var(--ink); border: 2px solid var(--ink); }
.btn.sun-btn { background: var(--sun); color: var(--on-sun); }
.btn:active { transform: scale(.97); }

.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { background: var(--chip); color: var(--muted); font-size: .76rem; font-weight: 600; padding: 4px 10px; border-radius: 999px; }

/* Nichts darf seitlich überstehen (schräges Laufband), sonst lässt Safari auf dem iPhone rauszoomen und die Seite wackelt.
   clip statt hidden, damit die Kopfzeile weiter mitläuft. Doppeltippen zoomt nicht. */
html, body { overflow-x: clip; }
main { overflow-x: clip; }
html { touch-action: manipulation; }

/* Einblenden (nur mit JavaScript, sonst sofort sichtbar) */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }

/* ---------- Kopfzeile ---------- */
.topbar { position: sticky; top: 0; z-index: 30; background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.monogram { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%;
  background: var(--ink); color: var(--paper); font: 800 .82rem/1 var(--display); letter-spacing: .02em; text-decoration: none; }
.brand-name { font: 800 .95rem/1 var(--display); text-transform: uppercase; letter-spacing: .04em; }
.topnav { display: none; }
@media (max-width: 899px) { .top-cta.btn { min-height: 38px; padding: 0 16px; font-size: .72rem; } }

/* ---------- Einstieg ---------- */
.hero { position: relative; display: flex; flex-direction: column; }
.hero-visual { order: -1; position: relative; display: grid; place-items: end center; height: min(112vw, 490px); margin: 0 -16px; overflow: hidden; }
.sun { position: absolute; left: 50%; top: 56%; width: min(86vw, 390px); aspect-ratio: 1; border-radius: 50%; background: var(--sun); transform: translate(-50%, -50%); }
.me { position: relative; width: min(72vw, 320px);
  -webkit-mask-image: linear-gradient(to bottom, #000 58%, transparent 94%); mask-image: linear-gradient(to bottom, #000 58%, transparent 94%); }
.hero-text { position: relative; z-index: 2; margin-top: -8px; padding: 0 0 8px 16px; border-left: 2px solid var(--ink); }
.greeting { font: 700 1rem/1.3 var(--display); margin: 0 0 10px; }
.hero h1 { font: 800 clamp(2.3rem, 11.5vw, 3.4rem)/.98 var(--display); text-transform: uppercase; letter-spacing: -.015em; margin: 0; }
.location { display: flex; align-items: center; gap: 6px; margin: 16px 0 0; font: 700 .9rem/1 var(--display); }
.location svg { width: 16px; height: 16px; color: var(--accent); }
.hero .lead { color: var(--muted); margin: 16px 0 0; text-wrap: pretty; }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 24px; }
.social, .next { display: none; }

/* ---------- Laufband ---------- */
.ticker { margin: 48px -4vw 8px; padding: 14px 0; background: var(--sun); color: var(--on-sun); transform: rotate(-2deg); overflow: hidden; }
.ticker-track { display: flex; width: max-content; gap: 22px; align-items: center; animation: ticker 32s linear infinite; }
.ticker span { font: 800 1.15rem/1 var(--display); text-transform: uppercase; letter-spacing: .02em; white-space: nowrap; }
.ticker i { font-style: normal; font-size: .9rem; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ---------- Abschnitte ---------- */
section { padding: 48px 0 24px; }
.section-head { display: flex; align-items: baseline; gap: 16px; margin-bottom: 22px; border-top: 2px solid var(--ink); padding-top: 16px; }
.section-head h2 { font: 800 clamp(1.9rem, 9vw, 3.4rem)/1 var(--display); text-transform: uppercase; letter-spacing: -.01em; margin: 0 auto 0 0; }
.section-head .count { font: 700 .85rem/1 var(--display); color: var(--muted); font-variant-numeric: tabular-nums; }
.section-head .hint { font: 700 .72rem/1 var(--display); text-transform: uppercase; letter-spacing: .14em; color: var(--accent); }

/* ---------- Projekte: Handy = Wischkarten ---------- */
.projects { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0 16px;
  margin: 0 -16px; padding: 4px 16px 16px; scrollbar-width: none; align-items: stretch; }
.projects::-webkit-scrollbar { display: none; }
.tile { position: relative; flex: 0 0 86%; scroll-snap-align: start; display: flex; flex-direction: column;
  background: var(--card); border: 1px solid var(--border); border-radius: 24px; padding: 22px; }
.tile h3 { font: 800 1.35rem/1.15 var(--display); text-transform: uppercase; margin: 0 0 8px; }
.tile p { color: var(--muted); font-size: .95rem; margin: 0 0 14px; }
.tile .sub { margin: -4px 0 12px; font: 700 .74rem/1.3 var(--display); text-transform: uppercase; letter-spacing: .12em; color: var(--accent); }
.tile ul { margin: 0 0 16px; padding-left: 1.1em; color: var(--muted); font-size: .92rem; }
.tile li { margin: 4px 0; }
.tile .tags { margin-top: auto; }
.num { position: absolute; top: 18px; right: 20px; font: 800 .8rem/1 var(--display); letter-spacing: .1em; color: var(--muted); }
.icon { width: 46px; height: 46px; border-radius: 50%; background: var(--sun); color: var(--on-sun); display: grid; place-items: center; margin-bottom: 16px; }
.icon svg { width: 22px; height: 22px; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 0 0 16px; }
.stat { background: var(--sunk); border-radius: 12px; padding: 10px 4px; text-align: center; }
.stat b { display: block; font: 800 1.1rem/1.15 var(--display); font-variant-numeric: tabular-nums; }
.stat span { font-size: .7rem; color: var(--muted); }

/* bookery-Kachel: dunkel, mit Handy im gelben Kreis */
.tile-book { background: var(--night); color: var(--on-night); border-color: var(--night); padding: 0; overflow: hidden; }
.tile-book .tile-body { position: relative; padding: 22px; display: flex; flex-direction: column; flex: 1; }
.tile-book p, .tile-book .facts li, .tile-book .num { color: var(--night-muted); }
.tile-book h3 { font-size: 1.7rem; text-transform: none; margin: 0; }
.feature-title { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.feature-title img { width: 48px; height: 48px; border-radius: 22.5%; }
.tile .kicker { font-size: .82rem; margin: 2px 0 0; }
.tile .facts { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 6px; }
.tile .facts li { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 8px; margin: 0; }
.facts svg { width: 16px; height: 16px; margin-top: 4px; color: var(--sun); }
.tile-book .btn { margin-top: auto; align-self: flex-start; }
/* Die ganze Kachel führt zu bookery: Der Knopf spannt sich über den Textteil, das Handy ist selbst ein Link. */
.tile-book .tile-link::after { content: ""; position: absolute; inset: 0; }
.tile-book { cursor: pointer; }
.tile-phone { order: -1; position: relative; height: 210px; overflow: hidden; display: grid; place-items: start center; padding-top: 26px; }
.tile-phone::before { content: ""; position: absolute; width: 230px; aspect-ratio: 1; border-radius: 50%; background: var(--sun); top: 30px; left: 50%; transform: translateX(-50%); }
.tile-phone .frame { position: relative; width: 150px; border-radius: 26px; padding: 5px; background: #0d0d0d; box-shadow: 0 20px 40px rgb(0 0 0 / .4); transform: rotate(-4deg); }
.tile-phone img { border-radius: 21px; }

.tile-soon { background: transparent; border: 2px dashed var(--border); justify-content: center; }
.tile-soon .icon { background: transparent; border: 2px dashed var(--muted); color: var(--muted); }

.dots { display: flex; justify-content: center; gap: 8px; margin-top: 4px; }
.dots button { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 999px; background: var(--border); cursor: pointer; transition: width .25s var(--ease), background .25s; }
.dots button.on { width: 24px; background: var(--ink); }

/* ---------- Über mich ---------- */
.about { display: grid; gap: 28px; }
.statement { font: 800 clamp(1.5rem, 7vw, 2.6rem)/1.15 var(--display); letter-spacing: -.015em; margin: 0 0 18px; }
.about .text p:not(.statement) { margin: 0 0 14px; color: var(--muted); }
.tool-group { margin-bottom: 22px; }
.toolbox h3 { font: 700 .72rem/1 var(--display); text-transform: uppercase; letter-spacing: .2em; color: var(--muted); margin: 0 0 10px; }
.toolbox .tags { gap: 8px; }
.toolbox .tag { font-size: .84rem; padding: 6px 12px; background: var(--card); border: 1px solid var(--border); color: var(--ink); }

/* ---------- Kontakt ---------- */
.contact { position: relative; overflow: hidden; display: grid; gap: 24px; background: var(--night); color: var(--on-night); border-radius: 28px; padding: 40px 22px 24px; }
.contact::before { content: ""; position: absolute; width: 260px; aspect-ratio: 1; border-radius: 50%; background: var(--sun); right: -110px; top: -120px; }
.contact > * { position: relative; }
.contact h2 { font: 800 clamp(2.2rem, 11vw, 4.6rem)/.95 var(--display); text-transform: uppercase; margin: 0 0 14px; }
.contact p { color: var(--night-muted); margin: 0; max-width: 28em; }
.contact .btn { width: 100%; min-height: 56px; }

/* ---------- Rechtstexte ---------- */
.legal { max-width: 680px; padding: 40px 0 0; }
.legal h1 { font: 800 clamp(2rem, 9vw, 3rem)/1.05 var(--display); text-transform: uppercase; margin: 0 0 8px; }
.legal h2 { font: 700 1.05rem/1.35 var(--display); margin: 2em 0 .4em; }
.meta { color: var(--muted); font-size: .9rem; margin-top: 0; }

/* ---------- Fußzeile ---------- */
.site-footer { margin-top: 40px; border-top: 1px solid var(--border); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 18px; padding-top: 20px;
  padding-bottom: calc(32px + env(safe-area-inset-bottom)); color: var(--muted); font-size: .85rem; }
.site-footer nav { display: flex; gap: 18px; }
.site-footer a { font-weight: 500; }
.site-footer a[aria-current="page"] { color: var(--ink); text-decoration: none; }

/* ---------- Nach oben (erscheint nach dem Scrollen, Knopf kommt aus main.js) ---------- */
.to-top { position: fixed; z-index: 40; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); width: 48px; height: 48px;
  border: 0; border-radius: 50%; background: var(--ink); color: var(--paper); display: grid; place-items: center; cursor: pointer;
  box-shadow: 0 10px 26px rgb(0 0 0 / .22); opacity: 0; transform: translateY(12px) scale(.9); pointer-events: none;
  transition: opacity .3s var(--ease), transform .3s var(--ease); }
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:active { transform: scale(.94); }
.to-top svg { width: 22px; height: 22px; }

/* =====================================================================
   Computer: eigenes Layout ab 900 px
   ===================================================================== */
@media (min-width: 900px) {
  body { font-size: 17px; line-height: 1.65; }
  .wrap { padding: 0 40px; }
  html { scroll-padding-top: 88px; }
  .to-top { right: 28px; bottom: 28px; width: 52px; height: 52px; }
  .site-footer .wrap { padding-bottom: 40px; }

  /* Kopfzeile: Name links, Menü in der Mitte, Kontakt rechts */
  .topbar .wrap { display: grid; grid-template-columns: 1fr auto 1fr; height: 80px; }
  .monogram { width: 42px; height: 42px; font-size: .86rem; }
  .brand-name { font-size: 1rem; }
  .topnav { display: flex; gap: 4px; }
  .topnav a { position: relative; color: var(--ink); font: 500 .8rem/1 var(--display); text-transform: uppercase; letter-spacing: .1em; text-decoration: none; padding: 12px 14px; }
  .topnav a::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: 6px; height: 2px; background: var(--sun); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
  .topnav a:hover::after { transform: scaleX(1); }
  .top-cta { display: inline-flex; justify-self: end; min-height: 42px; padding: 0 20px; font-size: .74rem; }
  .top-cta:hover { transform: translateY(-1px); }

  /* Einstieg: Text links, großes Foto rechts, Linie unten */
  .hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); align-items: center;
    min-height: min(calc(100svh - 80px), 860px); padding-right: 64px; border-bottom: 2px solid var(--ink); }
  .hero-visual { order: 0; align-self: stretch; height: auto; min-height: 560px; margin: 0; overflow: visible; }
  .sun { top: 52%; width: min(100%, 560px); }
  .me { width: min(84%, 470px); -webkit-mask-image: linear-gradient(to bottom, #000 74%, transparent 99%); mask-image: linear-gradient(to bottom, #000 74%, transparent 99%); }
  .hero-text { margin: 0 0 56px; padding: 0 0 0 clamp(20px, 2.5vw, 32px); }
  .greeting { font-size: 1.25rem; margin-bottom: 14px; }
  .hero h1 { font-size: clamp(3.4rem, 6vw, 5.2rem); }
  .location { margin-top: 24px; font-size: 1rem; }
  .hero .lead { font-size: 1.1rem; max-width: 30em; margin-top: 18px; }
  .actions { display: flex; margin-top: 30px; }
  .btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgb(0 0 0 / .14); }
  .social { display: flex; flex-direction: column; gap: 12px; position: absolute; right: 0; top: 50%; transform: translateY(-50%); }
  .social a { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--ink); color: var(--paper); transition: transform .2s var(--ease), background .2s; }
  .social a:hover { transform: scale(1.1); background: var(--accent); }
  .social svg { width: 18px; height: 18px; }
  .next { display: grid; place-items: center; position: absolute; right: 0; bottom: 40px; width: 46px; height: 46px; border-radius: 50%;
    border: 2px solid var(--ink); color: var(--ink); transition: background .2s, color .2s; animation: bob 2.4s var(--ease) infinite; }
  .next:hover { background: var(--ink); color: var(--paper); }
  .next svg { width: 18px; height: 18px; }
  @keyframes bob { 50% { transform: translateY(6px); } }

  .ticker { margin: 72px -2vw 16px; padding: 20px 0; }
  .ticker span { font-size: 1.7rem; }
  .ticker-track { gap: 34px; }

  section { padding: 88px 0 24px; }
  .section-head { margin-bottom: 36px; padding-top: 20px; }
  .section-head .hint { display: none; }

  /* Projekte: Bento-Raster */
  .projects { display: grid; overflow: visible; margin: 0; padding: 0; gap: 18px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-areas: "book book home" "book book home" "ki ki soon"; }
  .dots { display: none; }
  .tile { padding: 28px; border-radius: 28px; transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
  .tile:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
  .tile-book { grid-area: book; flex-direction: row; align-items: stretch; padding: 0; }
  .tile-home { grid-area: home; }
  .tile-ki { grid-area: ki; }
  .tile-soon { grid-area: soon; }
  .tile-soon:hover { transform: none; box-shadow: none; border-color: var(--muted); }
  .tile h3 { font-size: 1.45rem; }
  .num { top: 26px; right: 28px; }
  .tile-book .tile-body { flex: 1.15; padding: 40px; }
  .tile-book h3 { font-size: 2.2rem; }
  .feature-title img { width: 60px; height: 60px; }
  .tile-book p { font-size: 1rem; }
  .tile-phone { order: 0; flex: 1; height: auto; padding-top: 0; place-items: center; }
  .tile-phone::before { width: 340px; top: 50%; transform: translate(-50%, -50%); transition: transform .5s var(--ease); }
  .tile-phone .frame { width: 220px; border-radius: 34px; padding: 7px; transform: rotate(5deg) translateY(30px); transition: transform .5s var(--ease); }
  .tile-phone img { border-radius: 28px; }
  .tile-book:hover .tile-phone .frame { transform: rotate(0deg) translateY(10px); }
  .tile-book:hover .tile-phone::before { transform: translate(-50%, -50%) scale(1.06); }
  .tile-book .num { top: 26px; left: 40px; right: auto; }
  .tile-book .feature-title { margin-top: 20px; }
  .tile-home .stats { margin: 6px 0 20px; }
  .stat { padding: 14px 6px; }
  .stat b { font-size: 1.35rem; }

  /* Über mich: großes Statement links, Werkzeuge rechts */
  .about { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 72px; align-items: start; }
  .statement { font-size: clamp(2.2rem, 3.6vw, 3rem); margin-bottom: 28px; }
  .about .text p:not(.statement) { font-size: 1.08rem; max-width: 34em; }
  .toolbox { position: sticky; top: 110px; padding: 28px; background: var(--card); border: 1px solid var(--border); border-radius: 28px; }
  .tool-group:last-child { margin-bottom: 0; }

  /* Kontakt: zweispaltig */
  .contact { grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 48px; padding: 72px 64px; border-radius: 36px; }
  .contact::before { width: 420px; right: -150px; top: -190px; transition: transform .6s var(--ease); }
  .contact:hover::before { transform: scale(1.08); }
  .contact .btn { width: auto; min-height: 60px; padding: 0 32px; font-size: .9rem; }
  .contact p { font-size: 1.1rem; }

  .legal { padding-top: 64px; }
}

@media (min-width: 900px) and (max-width: 1099px) {
  .projects { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-areas: "book book" "home ki" "home soon"; }
  .topnav a { padding: 12px 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before { transition: none !important; animation: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- Code-Seite ---------- */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.gate-page { min-height: 100svh; overflow: hidden; }
.gate { position: relative; min-height: 100svh; display: grid; place-items: center; padding: 24px 16px calc(64px + env(safe-area-inset-bottom)); }
.gate-sun { position: absolute; width: min(120vw, 640px); aspect-ratio: 1; border-radius: 50%; background: var(--sun); right: -30vw; top: -18vw; }
.gate-card { position: relative; width: min(100%, 440px); padding: 32px 24px; border-radius: 28px; background: var(--card); border: 1px solid var(--border);
  box-shadow: var(--shadow-lift); border-left: 4px solid var(--ink); }
.gate-card .monogram { margin-bottom: 20px; }
.gate-card .greeting { margin-bottom: 6px; color: var(--muted); font-size: .9rem; }
.gate-card h1 { font: 800 clamp(2.6rem, 13vw, 4rem)/.95 var(--display); text-transform: uppercase; letter-spacing: -.02em; margin: 0 0 14px; }
.gate-text { color: var(--muted); margin: 0 0 24px; }
#gate-form { display: grid; gap: 10px; }
#gate-code { width: 100%; min-height: 56px; padding: 0 18px; border-radius: 16px; border: 2px solid var(--border); background: var(--paper); color: var(--ink);
  font: 700 1.3rem/1 var(--display); letter-spacing: .12em; text-align: center; text-transform: lowercase; transition: border-color .2s; }
#gate-code::placeholder { color: var(--border); }
#gate-code:focus { outline: none; border-color: var(--ink); }
#gate-code[aria-invalid="true"] { border-color: #C2410C; animation: shake .35s; }
#gate-form .btn { min-height: 56px; width: 100%; }
#gate-form .btn:disabled { opacity: .6; }
.gate-error { min-height: 1.4em; margin: 12px 0 0; color: #C2410C; font-weight: 600; font-size: .92rem; text-align: center; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .gate-error, :root:not([data-theme="light"]) #gate-code[aria-invalid="true"] { color: #FB923C; border-color: #FB923C; } }
.gate-legal { position: absolute; left: 0; right: 0; bottom: calc(20px + env(safe-area-inset-bottom)); display: flex; justify-content: center; gap: 18px; font-size: .85rem; }
.gate-legal a { font-weight: 500; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
@media (min-width: 900px) {
  .gate-sun { width: 720px; right: 8vw; top: 50%; transform: translateY(-50%); }
  .gate { justify-items: start; padding-left: max(40px, calc((100vw - 1120px) / 2)); }
  .gate-card { padding: 48px 44px; width: 460px; }
  .gate-legal { justify-content: flex-start; padding-left: max(40px, calc((100vw - 1120px) / 2)); }
}

/* ---------- Handy: kleineres Porträt, Projekte als ruhige Liste statt Wischkarten ---------- */
@media (max-width: 899px) {
  /* Einstieg: Text links, Foto rechts daneben */
  .hero { display: grid; grid-template-columns: minmax(0, 1fr) min(36vw, 200px); column-gap: 10px; padding-top: 20px;
    grid-template-areas: "greet photo" "title photo" "loc loc" "lead lead" "actions actions"; }
  .hero-text { display: contents; }
  .greeting { grid-area: greet; align-self: end; margin: 0 0 8px; }
  .hero h1 { grid-area: title; align-self: start; font-size: clamp(1.5rem, 6.9vw, 2.4rem); }
  .location { grid-area: loc; margin-top: 20px; }
  .hero .lead { grid-area: lead; }
  .actions { grid-area: actions; }
  .hero-visual { grid-area: photo; order: 0; height: auto; margin: 0; align-self: center; aspect-ratio: 4 / 5; overflow: hidden; place-items: end center; }
  .sun { width: 100%; top: 58%; }
  .me { width: 92%; }

  .projects { flex-direction: column; overflow: visible; margin: 0; padding: 0; gap: 12px; }
  .tile { flex: none; }
  .section-head .hint, .dots { display: none; }
  .tile ul, .tile .tags { display: none; }

  .tile:not(.tile-book) { display: grid; grid-template-columns: 44px minmax(0, 1fr); column-gap: 14px; padding: 18px; border-radius: 20px; }
  .tile:not(.tile-book) .icon { width: 44px; height: 44px; margin: 0; }
  .tile:not(.tile-book) .icon svg { width: 20px; height: 20px; }
  .tile:not(.tile-book) h3 { grid-column: 2; align-self: center; margin: 0; font-size: 1.15rem; }
  .tile:not(.tile-book) .sub { grid-column: 1 / -1; margin: 12px 0 0; }
  .tile:not(.tile-book) p, .tile .stats { grid-column: 1 / -1; margin: 10px 0 0; font-size: .92rem; }
  .tile .num { top: 16px; right: 18px; }
  .tile-soon { padding: 14px 18px; }
  .tile-soon p { display: none; }

  .tile-book .tile-phone { height: 150px; padding-top: 20px; }
  .tile-book .tile-phone::before { width: 180px; top: 24px; }
  .tile-book .tile-phone .frame { width: 112px; border-radius: 20px; padding: 4px; }
  .tile-book .tile-phone img { border-radius: 16px; }
  .tile-book .tile-body { padding: 18px; }
  .tile-book .feature-title { margin-bottom: 10px; }
  .tile-book .feature-title img { width: 44px; height: 44px; }
  .tile-book h3 { font-size: 1.5rem; }
  .tile-book p { font-size: .92rem; margin-bottom: 16px; }
}
