/*
Theme Name: 3-d-works
Theme URI: https://3-d-works.com
Author: Philipp Schindler
Description: Dunkles Studio-Theme für 3D-Druck-Projekte, Downloads und Crowdfunding. Wechselnde, schwach beleuchtete Druckerteile als Hintergrund. Keine externen Schriften, keine Tracker.
Version: 1.5.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: tw
*/

/* ---------- Schriften (lokal, SIL Open Font License) ---------- */
@font-face { font-family: "Barlow Condensed"; font-weight: 500; font-style: normal; font-display: swap;
  src: url("assets/fonts/barlow-condensed-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("assets/fonts/barlow-condensed-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; font-style: normal; font-display: swap;
  src: url("assets/fonts/barlow-condensed-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("assets/fonts/barlow-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 500; font-style: normal; font-display: swap;
  src: url("assets/fonts/barlow-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("assets/fonts/barlow-latin-600-normal.woff2") format("woff2"); }

/* ---------- Design-Token ---------- */
:root {
  --ink: #050505;
  --panel: rgba(255, 255, 255, .04);
  --panel-strong: rgba(255, 255, 255, .07);
  --line: rgba(255, 255, 255, .12);
  --text: #ece8e1;
  --muted: #a7a298;
  --heat: #ff8a1f;
  --heat-hi: #ffb15c;
  --heat-ink: #1b0d02;
  --radius: 3px;
  --wrap: 1180px;
  --gutter: clamp(1.1rem, 4vw, 2.5rem);
  --font-head: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Barlow", "Helvetica Neue", Arial, sans-serif;
}

/* ---------- Basis ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.125rem;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: var(--heat-hi); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { color: #ffd08a; }
:focus-visible { outline: 2px solid var(--heat); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--heat); color: var(--heat-ink); }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: .005em;
  margin: 0 0 .5em;
  color: #fff;
  text-wrap: balance;
}
h1 { font-size: clamp(3rem, 8vw, 6.6rem); font-weight: 600; line-height: .95; letter-spacing: -.005em; }
h2 { font-size: clamp(2rem, 4.4vw, 3.1rem); }
h3 { font-size: clamp(1.45rem, 2.6vw, 1.8rem); }
h4 { font-size: 1.25rem; }
p { margin: 0 0 1.1em; }

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--heat); color: var(--heat-ink); padding: .6rem 1rem; font-weight: 600;
}
.skip-link:focus { left: 1rem; top: 1rem; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.screen-reader-text { position: absolute !important; clip: rect(1px,1px,1px,1px); width: 1px; height: 1px; overflow: hidden; }

/* ---------- Hintergrund-Bühne ---------- */
.stage {
  position: fixed; inset: 0; z-index: -1; overflow: hidden;
  background: var(--ink);
  animation: stage-in 1.6s ease-out both;
}
.stage-art {
  position: absolute; inset: -3%;
  background: var(--bg) right center / cover no-repeat;
  animation: stage-drift 52s ease-in-out infinite alternate;
  will-change: transform;
}
.stage-glow {
  position: absolute; inset: 0;
  background: var(--bg-glow) right center / cover no-repeat;
  mix-blend-mode: screen;
  animation: stage-pulse 6s ease-in-out infinite;
}
.stage-sparks { position: absolute; inset: 0; pointer-events: none; }
.stage-sparks i {
  position: absolute; left: var(--x); bottom: -2%;
  width: var(--s); height: var(--s); border-radius: 50%;
  background: var(--heat-hi); box-shadow: 0 0 6px 2px rgba(255,138,31,.55);
  opacity: 0; animation: spark var(--d) linear infinite; animation-delay: var(--w);
}
.stage::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(5,5,5,.97) 0%, rgba(5,5,5,.86) 36%, rgba(5,5,5,.38) 72%, rgba(5,5,5,.22) 100%),
    linear-gradient(0deg, rgba(5,5,5,.9) 0%, rgba(5,5,5,0) 28%);
}
body.is-inner .stage::after {
  background:
    linear-gradient(90deg, rgba(5,5,5,.97) 0%, rgba(5,5,5,.9) 45%, rgba(5,5,5,.62) 100%),
    linear-gradient(0deg, rgba(5,5,5,.95) 0%, rgba(5,5,5,0) 30%);
}
@keyframes stage-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes stage-drift { from { transform: scale(1) translate3d(0, 0, 0); } to { transform: scale(1.07) translate3d(-1.4%, -1%, 0); } }
@keyframes stage-pulse { 0%, 100% { opacity: .3; } 50% { opacity: .95; } }
@keyframes spark {
  0% { transform: translate3d(0, 0, 0); opacity: 0; }
  12% { opacity: .85; }
  80% { opacity: .35; }
  100% { transform: translate3d(var(--dx), -105vh, 0); opacity: 0; }
}
@media (max-width: 760px) {
  .stage-art, .stage-glow { background-position: 70% center; }
  .stage::after, body.is-inner .stage::after { background: rgba(5,5,5,.82); }
  .stage-sparks i:nth-child(n+7) { display: none; }
}

/* ---------- Kopfbereich ---------- */
.site-header { padding-block: 1.4rem; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.brand {
  font-family: var(--font-head); font-weight: 700; font-size: 1.9rem; letter-spacing: .01em;
  color: #fff; text-decoration: none; line-height: 1;
  display: inline-flex; align-items: baseline; gap: .05em;
}
.brand::after { content: ""; width: .32em; height: .32em; background: var(--heat); border-radius: 50%; margin-left: .12em; box-shadow: 0 0 14px 2px rgba(255,138,31,.7); }
.nav-toggle {
  display: none; background: none; border: 1px solid var(--line); color: var(--text);
  font: inherit; font-family: var(--font-head); font-weight: 500; font-size: 1.1rem;
  padding: .4rem .9rem; border-radius: var(--radius); cursor: pointer;
}
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: clamp(1rem, 2.4vw, 2.2rem); flex-wrap: wrap; }
.main-nav a {
  font-family: var(--font-head); font-weight: 500; font-size: 1.2rem; color: var(--text);
  text-decoration: none; padding-block: .3rem; border-bottom: 2px solid transparent;
}
.main-nav a:hover { color: #fff; border-bottom-color: var(--heat); }
.main-nav .current-menu-item > a, .main-nav .current_page_item > a, .main-nav a[aria-current="page"] { border-bottom-color: var(--heat); color: #fff; }

@media (max-width: 820px) {
  .nav-toggle { display: inline-block; }
  .main-nav { display: none; position: absolute; left: 0; right: 0; top: 4.6rem; z-index: 20;
    background: var(--ink); border-block: 1px solid var(--line); padding: 1rem var(--gutter) 1.4rem; }
  .main-nav.is-open { display: block; }
  .main-nav ul { flex-direction: column; gap: .4rem; }
  .main-nav a { font-size: 1.4rem; display: inline-block; }
  .site-header { position: relative; }
}

/* ---------- Inhaltsbereich ---------- */
main { flex: 1; padding-block: clamp(1.5rem, 5vw, 4rem) clamp(3rem, 8vw, 6rem); }
.page-head { margin-bottom: clamp(1.6rem, 4vw, 3rem); max-width: 52rem; }
.page-head h1 { font-size: clamp(2.8rem, 6.4vw, 5rem); margin-bottom: .25em; }
.page-head .lead { color: var(--muted); font-size: 1.25rem; max-width: 40rem; }

/* ---------- Startseite: Hero ---------- */
.hero { padding-block: clamp(2.5rem, 9vw, 7.5rem) clamp(2.5rem, 7vw, 5rem); }
.hero h1 { max-width: 11ch; margin-bottom: .3em; }
.hero h1 span { display: block; }
.hero h1 .repeat { color: var(--heat); text-shadow: 0 0 .6em rgba(255,138,31,.35); animation: repeat-glow 4s ease-in-out infinite; }
@keyframes repeat-glow { 0%, 100% { text-shadow: 0 0 .35em rgba(255,138,31,.2); } 50% { text-shadow: 0 0 .75em rgba(255,138,31,.55); } }
@media (prefers-reduced-motion: reduce) { .hero h1 .repeat { animation: none; } }
.hero p { max-width: 34rem; color: #cfcac1; font-size: 1.28rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 2rem; }

.btn {
  display: inline-block; font-family: var(--font-head); font-weight: 600; font-size: 1.25rem; line-height: 1;
  padding: .95rem 1.5rem; border-radius: var(--radius); text-decoration: none; cursor: pointer;
  border: 1px solid transparent; transition: background-color .15s, color .15s, border-color .15s;
}
.btn-primary { background: var(--heat); color: var(--heat-ink); }
.btn-primary:hover { background: var(--heat-hi); color: var(--heat-ink); }
.btn-ghost { border-color: rgba(255,255,255,.35); color: #fff; background: rgba(5,5,5,.35); }
.btn-ghost:hover { border-color: var(--heat); color: #fff; }

/* ---------- Abschnitte ---------- */
.section { padding-block: clamp(2rem, 5vw, 3.6rem); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.6rem; }
.section-head h2 { margin: 0; }
.more-link { font-family: var(--font-head); font-weight: 500; font-size: 1.2rem; }

/* ---------- Projekt-Karten ---------- */
.grid-projekte { display: grid; gap: 1.4rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
/* Startseite: erstes Projekt groß links, die übrigen gestapelt rechts */
@media (min-width: 900px) {
  .grid-projekte.is-featured { grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); }
  .grid-projekte.is-featured > .card:first-child { grid-row: span 2; }
  .grid-projekte.is-featured > .card:first-child .card-media { aspect-ratio: auto; flex: 1 1 auto; min-height: 260px; }
  .grid-projekte.is-featured > .card:first-child .card-body { flex: 0 0 auto; }
  .grid-projekte.is-featured > .card:first-child h3 { font-size: clamp(1.8rem, 3vw, 2.4rem); }
  .grid-projekte.is-featured > .card:not(:first-child) .card-media { aspect-ratio: 16 / 8; }
}
.card {
  display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; backdrop-filter: blur(6px);
  transition: border-color .15s, background-color .15s;
}
.card:hover { border-color: rgba(255,138,31,.75); background: var(--panel-strong); }
.card-media { aspect-ratio: 4 / 3; background: #0b0b0c; overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-media.is-empty {
  background:
    radial-gradient(60% 70% at 30% 20%, rgba(255,138,31,.22), transparent 70%),
    repeating-linear-gradient(0deg, rgba(255,138,31,.12) 0 1px, transparent 1px 8px),
    #0b0b0c;
}
.card-body { padding: 1.2rem 1.3rem 1.4rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.card-body h3 { margin: 0; }
.card-body h3 a { color: #fff; text-decoration: none; }
.card-body h3 a::after { content: ""; position: absolute; inset: 0; }
.card { position: relative; }
.card-body p { margin: 0; color: var(--muted); font-size: 1rem; line-height: 1.5; }
.card-meta { color: var(--heat-hi); font-family: var(--font-head); font-weight: 500; font-size: 1.1rem; }
.card-spec { margin-top: auto; padding-top: .8rem; color: var(--muted); font-size: .95rem; border-top: 1px solid var(--line); }

.empty-note { border: 1px dashed var(--line); border-radius: var(--radius); padding: 1.6rem; color: var(--muted); max-width: 40rem; }

/* ---------- Einzelnes Projekt ---------- */
.projekt-layout { display: grid; gap: clamp(1.6rem, 4vw, 3.5rem); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 960px) { .projekt-layout { grid-template-columns: minmax(0, 1fr) 20rem; align-items: start; } }
.datenblatt { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem 1.4rem 1.5rem; backdrop-filter: blur(6px); }
@media (min-width: 960px) { .datenblatt { position: sticky; top: 1.5rem; } }
.datenblatt h2 { font-size: 1.6rem; margin-bottom: .6rem; }
.datenblatt dl { margin: 0; display: grid; grid-template-columns: auto 1fr; }
.datenblatt dt, .datenblatt dd { margin: 0; padding: .55rem 0; border-top: 1px solid var(--line); }
.datenblatt dt { color: var(--muted); padding-right: 1.2rem; }
.datenblatt dd { text-align: right; color: #fff; font-weight: 500; }
.datenblatt .btn { width: 100%; text-align: center; margin-top: 1.2rem; }
.projekt-head { max-width: none; }
.projekt-head.has-thumb { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "titel bild" "lead lead"; column-gap: clamp(1.2rem, 4vw, 3rem); align-items: stretch; }
.projekt-head.has-thumb h1 { grid-area: titel; margin: 0; align-self: end; }
.projekt-head.has-thumb .lead { grid-area: lead; margin: 1rem 0 0; }
.projekt-hero { grid-area: bild; margin: 0; position: relative; aspect-ratio: 1 / 1; height: 100%; min-height: 4.5rem; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
@media (max-width: 599px) { .projekt-hero { height: auto; width: 5.5rem; align-self: start; margin-top: .4rem; } }
.projekt-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- Fließtext ---------- */
.prose { max-width: 44rem; }
.prose.is-wide { max-width: none; }
.prose > * { max-width: 44rem; }
.prose > .alignwide, .prose > .wp-block-gallery, .prose > .wp-block-image, .prose > figure, .prose > .wp-block-columns { max-width: none; }
.prose h2 { margin-top: 1.6em; font-size: clamp(1.8rem, 3.4vw, 2.4rem); }
.prose h3 { margin-top: 1.4em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.prose li { margin-bottom: .3em; }
.prose blockquote { margin: 1.6em 0; padding: .2em 0 .2em 1.2em; border-left: 3px solid var(--heat); color: #d8d3ca; font-size: 1.2rem; }
.prose img { border-radius: var(--radius); }
.prose figure { margin: 1.6em 0; }
.prose figcaption { color: var(--muted); font-size: .95rem; margin-top: .5em; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.2em 0; }
.prose table { border-collapse: collapse; width: 100%; margin: 1.4em 0; }
.prose th, .prose td { text-align: left; padding: .6em .8em; border-bottom: 1px solid var(--line); }
.prose code { background: var(--panel-strong); padding: .1em .35em; border-radius: 2px; font-size: .92em; }
.wp-block-gallery { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: .8rem !important; }
.wp-block-gallery .wp-block-image { margin: 0 !important; }
.wp-block-gallery.columns-1 { grid-template-columns: 1fr; }
.wp-block-gallery.columns-2 { grid-template-columns: repeat(2, 1fr); }
.wp-block-gallery.columns-3 { grid-template-columns: repeat(3, 1fr); }
.wp-block-gallery.columns-4 { grid-template-columns: repeat(4, 1fr); }
.wp-block-gallery.columns-5, .wp-block-gallery.columns-6 { grid-template-columns: repeat(4, 1fr); }
.wp-block-gallery .wp-block-image { width: auto !important; flex: none !important; }
.wp-block-gallery { align-items: start; }
.wp-block-gallery img { width: 100% !important; height: auto !important; border-radius: var(--radius); border: 1px solid var(--line); display: block; }
.wp-block-gallery.is-cropped img { height: 100% !important; aspect-ratio: 1 / 1; object-fit: cover; }
@media (max-width: 640px) {
	.wp-block-gallery.columns-3, .wp-block-gallery.columns-4, .wp-block-gallery.columns-5, .wp-block-gallery.columns-6 { grid-template-columns: repeat(2, 1fr); }
}
.wp-caption, .wp-block-image { max-width: 100%; }

/* ---------- Formulare ---------- */
.form { display: grid; gap: 1.1rem; max-width: 36rem; margin-top: 1.5rem; }
.form label { display: grid; gap: .4rem; font-weight: 500; }
.form input[type="text"], .form input[type="email"], .form textarea {
  width: 100%; font: inherit; color: var(--text); background: rgba(0,0,0,.55);
  border: 1px solid rgba(255,255,255,.28); border-radius: var(--radius); padding: .8rem .9rem;
}
.form textarea { min-height: 10rem; resize: vertical; }
.form input:focus, .form textarea:focus { outline: 2px solid var(--heat); outline-offset: 1px; border-color: var(--heat); }
.form .hint { color: var(--muted); font-size: .95rem; margin: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.notice { border-radius: var(--radius); padding: 1rem 1.2rem; margin: 0 0 1.4rem; max-width: 36rem; border: 1px solid var(--line); }
.notice.is-ok { border-color: rgba(120, 200, 140, .55); background: rgba(80, 160, 100, .12); }
.notice.is-err { border-color: rgba(255, 120, 90, .6); background: rgba(200, 70, 40, .14); }

/* ---------- Downloads ---------- */
.downloads { display: grid; gap: 1rem; max-width: 46rem; }
.download {
  display: grid; grid-template-columns: 1fr auto; gap: 1rem 1.5rem; align-items: center;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.3rem;
}
.download h3 { margin: 0 0 .2rem; }
.download p { margin: 0; color: var(--muted); font-size: 1rem; }
.download .facts { color: var(--muted); font-size: .95rem; margin-top: .4rem; }
@media (max-width: 560px) { .download { grid-template-columns: 1fr; } }

/* ---------- Updates / Beiträge ---------- */
.post-list { display: grid; gap: 0; max-width: 46rem; }
.post-item { padding-block: 1.5rem; border-top: 1px solid var(--line); }
.post-item:last-child { border-bottom: 1px solid var(--line); }
.post-item time { color: var(--heat-hi); font-family: var(--font-head); font-weight: 500; font-size: 1.1rem; }
.post-item h2, .post-item h3 { margin: .15em 0 .4em; font-size: clamp(1.7rem, 3vw, 2.2rem); }
.post-item h2 a, .post-item h3 a { color: #fff; text-decoration: none; }
.post-item h2 a:hover, .post-item h3 a:hover { color: var(--heat-hi); }
.post-item p { color: #c7c2b8; margin: 0; }
.pagination { margin-top: 2rem; display: flex; gap: 1rem; font-family: var(--font-head); font-size: 1.2rem; }

/* ---------- Crowdfunding-Band ---------- */
.band {
  display: grid; gap: 1.2rem 3rem; align-items: center; grid-template-columns: minmax(0, 1fr);
  background: linear-gradient(100deg, rgba(255,138,31,.16), rgba(255,138,31,.03) 60%), var(--panel);
  border: 1px solid rgba(255,138,31,.4); border-radius: var(--radius); padding: clamp(1.4rem, 4vw, 2.4rem);
}
@media (min-width: 820px) { .band { grid-template-columns: minmax(0, 1fr) auto; } }
.band h2 { margin-bottom: .2em; }
.band p { margin: 0; color: #d8d3ca; max-width: 36rem; }

/* ---------- Fußbereich ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: 1.8rem 2.4rem; color: var(--muted); font-size: 1rem; background: rgba(5,5,5,.8); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 2rem; }
.site-footer .credit { flex-basis: 100%; margin: 0; font-size: .85rem; order: 3; }
.site-footer .credit a { text-decoration: underline; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 1.4rem; flex-wrap: wrap; }
.site-footer a { color: var(--text); text-decoration: none; }
.site-footer a:hover { color: var(--heat-hi); text-decoration: underline; }

@media (prefers-reduced-motion: reduce) {
  .stage, .stage-art, .stage-glow { animation: none; }
  .stage-glow { opacity: .6; }
  .stage-sparks { display: none; }
  html { scroll-behavior: auto; }
  .btn, .card { transition: none; }
}
@media print {
  .stage, .site-header, .site-footer { display: none; }
  body { background: #fff; color: #000; }
}

/* ---------- 3D-Betrachter ---------- */
.tw3d { position: relative; margin: 0 0 2rem; aspect-ratio: 4 / 3; max-height: 70vh; width: 100%; background: radial-gradient(120% 90% at 50% 35%, #2a1d12 0%, #0d0a08 70%); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.prose .tw3d, .prose > .tw3d { max-width: none; }
.tw3d-start { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; margin: 0; border: 0; background: transparent; color: #fff; cursor: pointer; display: grid; place-items: center; font: inherit; }
.tw3d-start img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; transition: opacity .25s ease, transform .6s ease; }
.tw3d-start:hover img, .tw3d-start:focus-visible img { opacity: .8; transform: scale(1.02); }
.tw3d-start:focus-visible { outline: 2px solid var(--heat); outline-offset: -4px; }
.tw3d-cta { position: relative; display: inline-flex; align-items: center; gap: .6rem; padding: .8rem 1.3rem; background: var(--heat); color: var(--heat-ink); border-radius: var(--radius); font-family: 'Barlow Condensed', sans-serif; font-weight: 700; font-size: 1.25rem; letter-spacing: .01em; box-shadow: 0 8px 30px rgba(0,0,0,.45); }
.tw3d-start:hover .tw3d-cta { background: var(--heat-hi); }
.tw3d-size { position: absolute; left: .9rem; bottom: .7rem; font-size: .85rem; color: var(--muted); text-shadow: 0 1px 6px #000; }
.tw3d.is-loading .tw3d-cta span::after { content: " …"; }
.tw3d.is-loading .tw3d-start { cursor: progress; }
.tw3d model-viewer { width: 100%; height: 100%; --poster-color: transparent; background: transparent; display: block; }

/* Bildbetrachter */
.wp-block-gallery img[data-tw-full], .wp-block-image img[data-tw-full] { cursor: zoom-in; }
html.tw-lb-open { overflow: hidden; }
.tw-lb { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; background: rgba(8, 8, 9, .94); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); padding: 3.2rem 4rem 3.6rem; }
.tw-lb[hidden] { display: none; }
.tw-lb-fig { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; gap: .8rem; }
.tw-lb-img { max-width: 100%; max-height: calc(100vh - 9rem); width: auto; height: auto; object-fit: contain; border-radius: 4px; box-shadow: 0 10px 50px rgba(0,0,0,.6); opacity: 0; transition: opacity .2s ease; background: #151517; }
.tw-lb-img.is-in { opacity: 1; }
.tw-lb-cap { color: #cfcfd4; font-size: .95rem; text-align: center; max-width: 60ch; }
.tw-lb-close, .tw-lb-nav { position: absolute; display: flex; align-items: center; justify-content: center; width: 2.8rem; height: 2.8rem; padding: 0; border: 1px solid rgba(255,255,255,.18); border-radius: 50%; background: rgba(255,255,255,.07); color: #fff; font-size: 1.9rem; line-height: 1; cursor: pointer; transition: background .15s, border-color .15s; }
.tw-lb-close:hover, .tw-lb-nav:hover { background: rgba(255,255,255,.16); border-color: var(--heat, #ff8a1f); }
.tw-lb-close:focus-visible, .tw-lb-nav:focus-visible { outline: 2px solid var(--heat, #ff8a1f); outline-offset: 2px; }
.tw-lb-close { top: 1rem; right: 1rem; }
.tw-lb-nav { top: 50%; margin-top: -1.4rem; padding-bottom: .15rem; }
.tw-lb-prev { left: 1rem; }
.tw-lb-next { right: 1rem; }
.tw-lb-nav[hidden], .tw-lb-count[hidden], .tw-lb-cap[hidden] { display: none; }
.tw-lb-count { position: absolute; bottom: 1rem; left: 0; right: 0; text-align: center; color: #9a9aa2; font-size: .9rem; letter-spacing: .06em; }
@media (max-width: 640px) {
	.tw-lb { padding: 3.4rem .6rem 3.4rem; }
	.tw-lb-nav { top: auto; bottom: .7rem; margin: 0; }
	.tw-lb-prev { left: 1rem; }
	.tw-lb-next { right: 1rem; }
}
@media (prefers-reduced-motion: reduce) { .tw-lb-img { transition: none; } }

/* Sprachumschalter */
@media (min-width: 821px) { .main-nav { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.2rem); } }
.lang-switch { list-style: none; margin: 0; padding: 0 0 0 clamp(1rem, 2.4vw, 2.2rem); display: flex; gap: .7rem; border-left: 1px solid rgba(255,255,255,.18); }
.lang-switch a { font-weight: 600; letter-spacing: .08em; font-size: .9rem; color: #b9b9b9; text-decoration: none; border-bottom: 2px solid transparent; padding-bottom: .15rem; }
.lang-switch a:hover, .lang-switch a[aria-current="true"] { color: #fff; border-bottom-color: var(--heat); }
@media (max-width: 820px) { .main-nav .lang-switch { flex-direction: row; gap: 1.4rem; border-left: 0; padding: 1.1rem 0 0; } .lang-switch a { font-size: 1.1rem; } }
/* Schwebende TranslatePress-Auswahl ausblenden, der Umschalter sitzt im Header */
#trp-floater-ls, .trp-floating-switcher { display: none !important; }
