:root {
  --bg:        #1a0e09;
  --bg2:       #2a1610;
  --ink:       #f8ecdd;
  --muted:     #d9c2ab;
  --soft:      #b3917a;
  --gold:      #ecb766;
  --ember:     #d76a4f;
  --line:      rgba(248,236,221,0.16);
  --line-soft: rgba(248,236,221,0.09);
  --panel:     rgba(255,243,228,0.045);
  --panel2:    rgba(255,243,228,0.085);
  --aurore:    #f0c879;
  --mars:      #df6c4a;
  --shadow:    0 34px 90px rgba(0,0,0,.5);
  --radius:    26px;
  --display:   'Fraunces', Georgia, serif;
  --body:      'Spectral', Georgia, serif;
  --hand:      'Caveat', 'Segoe Script', cursive;
  --facet-hue: var(--gold);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; font-family: var(--body); color: var(--ink);
  background:
    radial-gradient(120% 90% at 20% -5%, rgba(236,183,102,.20), transparent 55%),
    radial-gradient(110% 90% at 92% 4%, rgba(215,106,79,.24), transparent 52%),
    radial-gradient(120% 100% at 50% 108%, rgba(236,183,102,.10), transparent 60%),
    linear-gradient(160deg, var(--bg), var(--bg2) 60%, #0f0805);
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.soft-narrow { max-width: 46ch; }
.map-intro { max-width: none; line-height: 1.6; }

.grain { position: fixed; inset: 0; pointer-events: none; z-index: 0; opacity: .16; mix-blend-mode: soft-light;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.4'/%3E%3C/svg%3E"); }
.emberfield { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.emberfield span { position: absolute; width: 6px; height: 6px; border-radius: 50%;
  background: rgba(236,183,102,.8); box-shadow: 0 0 22px rgba(236,183,102,.6);
  animation: drift 16s ease-in-out infinite alternate; }
.emberfield span:nth-child(1){left:11%;top:24%;animation-delay:-1s}
.emberfield span:nth-child(2){left:78%;top:16%;animation-delay:-5s;background:rgba(215,106,79,.8);box-shadow:0 0 22px rgba(215,106,79,.6)}
.emberfield span:nth-child(3){left:86%;top:58%;animation-delay:-8s}
.emberfield span:nth-child(4){left:17%;top:80%;animation-delay:-11s;background:rgba(215,106,79,.7)}
.emberfield span:nth-child(5){left:46%;top:35%;animation-delay:-13s}
.emberfield span:nth-child(6){left:64%;top:78%;animation-delay:-3s}
@keyframes drift { to { transform: translate3d(16px,-26px,0) scale(1.35); opacity:.45; } }

/* buttons */
.primary-button, .secondary-button, .ghost-button {
  border-radius: 999px; padding: 12px 20px; font-family: var(--body); font-weight: 400; letter-spacing: .01em;
  transition: transform .18s ease, filter .18s ease, background .2s ease, border-color .2s ease;
}
.primary-button { color: #2a1206; background: linear-gradient(135deg, var(--gold), #f6d79e);
  box-shadow: 0 14px 30px rgba(236,183,102,.22); font-weight: 500; }
.primary-button:hover { transform: translateY(-2px); filter: brightness(1.05); }
.primary-button.wide { width: 100%; }
.secondary-button { border: 1px solid var(--line); background: var(--panel2); color: var(--ink); }
.secondary-button:hover { transform: translateY(-2px); border-color: var(--gold); }
.ghost-button { color: var(--soft); border: 1px solid var(--line-soft); }
.ghost-button:hover { color: var(--ink); border-color: var(--line); }
.text-link { color: var(--gold); font-style: italic; opacity: .9; align-self: flex-start; }
.text-link:hover { opacity: 1; }
.eyebrow { color: var(--gold); text-transform: uppercase; letter-spacing: .22em; font-size: .7rem; font-family: var(--body); }

/* onboarding */
.onboarding { position: relative; z-index: 2; min-height: 100vh; display: grid; place-items: center; padding: 28px; }
.onboarding-inner { text-align: center; max-width: 520px; animation: rise .9s ease both; }
.first-breath { font-family: var(--hand); color: var(--gold); font-size: 1.9rem; line-height: 1.15; opacity: .9; margin: 0 0 26px; }
.ob-title { font-family: var(--display); font-weight: 400; font-size: clamp(2.6rem, 9vw, 4.2rem); letter-spacing: -.03em; margin: 0; }
.ob-sub { font-family: var(--hand); color: var(--gold); margin: 18px 0 6px; font-size: 1.7rem; line-height: 1.2; }
.ob-sub-small { color: var(--muted); margin: 0 0 26px; font-size: 1.05rem; }
.claim-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.claim-card { border: 1px solid var(--line); border-radius: 24px; padding: 30px 18px; background: var(--panel);
  display: flex; flex-direction: column; align-items: center; gap: 8px; backdrop-filter: blur(14px);
  transition: transform .2s ease, border-color .2s ease, box-shadow .25s ease; }
.claim-card .claim-sigil { font-family: var(--display); font-size: 2.6rem; line-height: 1; }
.claim-card .claim-sigil-svg { display: grid; place-items: center; height: 50px; color: var(--mars); }
.claim-card .claim-sigil-svg svg { display: block; }
.claim-card .claim-name { font-family: var(--display); font-size: 1.7rem; }
.claim-card .claim-hint { font-family: var(--hand); color: var(--muted); font-size: 1.2rem; }
.claim-card[data-role="aurore"] .claim-sigil { color: var(--aurore); }
.claim-card[data-role="mars"]   .claim-sigil { color: var(--mars); }
.claim-card[data-role="aurore"]:hover { border-color: var(--aurore); box-shadow: 0 0 0 1px var(--aurore), 0 24px 60px rgba(240,200,121,.16); transform: translateY(-4px); }
.claim-card[data-role="mars"]:hover { border-color: var(--mars); box-shadow: 0 0 0 1px var(--mars), 0 24px 60px rgba(223,108,74,.16); transform: translateY(-4px); }
.claim-card.preselect[data-role="aurore"] { border-color: var(--aurore); box-shadow: 0 0 0 1px var(--aurore), 0 24px 60px rgba(240,200,121,.16); }
.claim-card.preselect[data-role="mars"] { border-color: var(--mars); box-shadow: 0 0 0 1px var(--mars), 0 24px 60px rgba(223,108,74,.16); }
.claim-card.dimmed { opacity: .42; }
.claim-card.dimmed:hover { opacity: 1; }
.claim-foot { color: var(--soft); font-family: var(--hand); font-size: 1.2rem; margin-top: 22px; }

/* form fields */
input, textarea { width: 100%; background: rgba(0,0,0,.24); border: 1px solid var(--line); border-radius: 16px;
  padding: 14px 16px; outline: none; transition: border-color .2s ease; }
textarea { min-height: 92px; resize: vertical; line-height: 1.6; }
input::placeholder, textarea::placeholder { color: var(--soft); opacity: .8; font-style: italic; }
input:focus, textarea:focus { border-color: var(--gold); }

/* app shell */
.app { position: relative; z-index: 1; max-width: 920px; margin: 0 auto; padding: 0 20px 40px; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; gap: 14px; padding: 20px 0 8px; }
.brand { display: flex; align-items: center; gap: 12px; margin-right: auto; }
.brand-glyph { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); color: var(--gold); font-family: var(--display); transition: transform .25s ease, border-color .25s ease; }
.brand:hover .brand-glyph { transform: rotate(-10deg); border-color: var(--gold); }
.brand-block { display: flex; flex-direction: column; line-height: 1.1; }
.brand-mark { font-family: var(--display); font-size: 1.05rem; letter-spacing: .04em; color: var(--ink); opacity: .92; white-space: nowrap; }
.brand-mundart { font-family: var(--hand); font-size: .92rem; color: var(--gold); opacity: .8; white-space: nowrap; }
.brand:hover .brand-mark { color: var(--gold); opacity: 1; }
.nav-right { display: flex; align-items: center; gap: 14px; order: 2; }
.nav-link { color: var(--muted); font-size: .96rem; opacity: .85; white-space: nowrap; }
.nav-link:hover { opacity: 1; color: var(--ink); }
.whoami { font-family: var(--hand); font-size: 1.25rem; padding: 4px 14px; border-radius: 999px; border: 1px solid var(--line); order: 3; }
.whoami.aurore { color: var(--aurore); border-color: rgba(240,200,121,.4); }
.whoami.mars   { color: var(--mars);   border-color: rgba(223,108,74,.4); }

/* Aktivität-Hinweise */
.activity-dot { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px;
  background: var(--gold); color: #2a1206; font-size: .72rem; font-weight: 700; line-height: 1; border: 0; cursor: pointer;
  box-shadow: 0 0 14px rgba(236,183,102,.55); animation: pulseDot 2.4s ease-in-out infinite; }
.activity-dot:hover { filter: brightness(1.08); transform: scale(1.06); }
@keyframes pulseDot { 0%,100% { transform: scale(1); } 50% { transform: scale(1.12); } }
.peek-new { display: inline-flex; align-items: center; gap: 9px; color: var(--gold); font-style: italic; font-size: .96rem; letter-spacing: .01em; }
.peek-ember { position: relative; width: 9px; height: 9px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #fff0d0, var(--gold) 55%, var(--ember) 100%);
  box-shadow: 0 0 10px rgba(236,183,102,.7); animation: emberBreath 2.6s ease-in-out infinite; }
.peek-ember::after { content: ""; position: absolute; inset: -6px; border-radius: 50%; border: 1px solid rgba(236,183,102,.4); animation: emberRing 2.6s ease-out infinite; }
@keyframes emberBreath { 0%,100% { transform: scale(1); opacity: .9; } 50% { transform: scale(1.25); opacity: 1; } }
@keyframes emberRing { 0% { transform: scale(.6); opacity: .7; } 100% { transform: scale(1.6); opacity: 0; } }
.door.has-new { box-shadow: 0 0 0 1px rgba(236,183,102,.5), 0 26px 70px rgba(236,183,102,.16), var(--shadow); }
.door.has-new::before { opacity: .8; }

.view { animation: rise .5s ease both; }
.view-head { padding: 18px 4px 8px; }
.view-head h2 { font-family: var(--display); font-weight: 400; font-size: clamp(2rem, 6vw, 3.2rem); margin: 6px 0 8px; letter-spacing: -.02em; }

/* deck */
.deck-stage { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; gap: 8px; margin-top: 10px; }
.deck-arrow { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); color: var(--muted); font-size: 1.5rem; line-height: 1; transition: all .2s ease; }
.deck-arrow:hover { color: var(--ink); border-color: var(--gold); transform: scale(1.05); }
.deck-arrow:disabled { opacity: .25; cursor: default; transform: none; }
.deck-card-wrap { perspective: 1400px; }
.deck-progress { display: flex; gap: 7px; justify-content: center; margin: 22px 0 6px; flex-wrap: wrap; }
.deck-progress i { width: 7px; height: 7px; border-radius: 50%; background: var(--line); transition: background .3s ease, transform .3s ease; }
.deck-progress i.on { background: var(--gold); transform: scale(1.25); }
.deck-foot-row { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 16px; margin-top: 8px; }
.deck-foot { text-align: center; color: var(--soft); font-family: var(--hand); font-size: 1.25rem; margin: 0; }
.ghost-button.small { padding: 8px 16px; font-size: .9rem; }
.deck-draws { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: center; }
.facet-pills { display: flex; gap: 6px; }
.facet-pill { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: var(--panel);
  font-family: var(--display); font-size: 1.15rem; line-height: 1; display: grid; place-items: center;
  transition: transform .18s ease, border-color .18s ease, background .18s ease; cursor: pointer; }
.facet-pill[data-facet="welt"]  { color: #e9ba63; }
.facet-pill[data-facet="kopf"]  { color: #e8d8b2; }
.facet-pill[data-facet="spiel"] { color: #f0a553; }
.facet-pill[data-facet="naehe"] { color: #e3a39a; }
.facet-pill[data-facet="feuer"] { color: #d4574a; }
.facet-pill:hover { border-color: currentColor; transform: translateY(-2px); background: rgba(0,0,0,.18); }

.door {
  position: relative; overflow: hidden; border-radius: var(--radius); padding: clamp(26px, 5vw, 40px);
  border: 1px solid var(--line); background: linear-gradient(150deg, var(--panel2), rgba(255,243,228,.03));
  backdrop-filter: blur(16px); box-shadow: var(--shadow); min-height: 430px;
  display: flex; flex-direction: column; gap: 14px; outline: none;
  transition: border-color .24s ease;
}
.door::before { content:""; position:absolute; inset:-1px; pointer-events:none; opacity:.55;
  background: radial-gradient(circle at 18% 0%, color-mix(in srgb, var(--facet-hue) 30%, transparent), transparent 38%),
              radial-gradient(circle at 100% 100%, color-mix(in srgb, var(--facet-hue) 24%, transparent), transparent 42%); }
.door > * { position: relative; z-index: 1; }
.door:hover { border-color: color-mix(in srgb, var(--facet-hue) 55%, transparent); }
.door.intro { border-color: rgba(236,183,102,.4); }
.door-image { width: 100%; max-height: 180px; object-fit: cover; border-radius: 18px; margin-bottom: 4px; border: 1px solid var(--line-soft); }
.door-top { display: flex; justify-content: space-between; align-items: flex-start; }
.door-cat { color: var(--facet-hue); text-transform: uppercase; letter-spacing: .18em; font-size: .82rem; font-weight: 600; }
.door-sigil { font-family: var(--display); font-size: 2.4rem; color: color-mix(in srgb, var(--facet-hue) 80%, transparent); line-height: 1; }
.door-name { font-family: var(--hand); font-weight: 600; font-size: clamp(2.1rem, 6vw, 2.9rem); letter-spacing: 0; line-height: 1.05; color: var(--gold); }
.door-impulse { font-family: var(--hand); color: var(--gold); font-size: 1.45rem; line-height: 1.3; opacity: .92; }
.intro .door-impulse { font-size: 1.65rem; opacity: 1; }
.door-trail-peek { display: flex; align-items: center; gap: 8px; color: var(--soft); font-size: .9rem; margin-top: auto; flex-wrap: wrap; }
.door-trail-peek .dot { width: 7px; height: 7px; border-radius: 50%; }
.door-trail-peek .dot.aurore { background: var(--aurore); }
.door-trail-peek .dot.mars { background: var(--mars); }

/* Wahl-Marker auf der Karte */
.door .choice-tag { padding: 4px 12px; border-radius: 999px; font-size: .82rem; font-family: var(--hand); font-size: 1rem; }
.door .choice-tag.other { background: rgba(236,183,102,.16); color: var(--gold); border: 1px solid rgba(236,183,102,.5); }
.door .choice-tag.mine  { background: rgba(248,236,221,.06); color: var(--muted); border: 1px solid var(--line); }
.door .choice-tag.both  { background: linear-gradient(135deg, rgba(240,200,121,.2), rgba(223,108,74,.2)); color: var(--ink); border: 1px solid var(--gold); }
.door.chosen-by-other { box-shadow: 0 0 0 1px rgba(236,183,102,.5), 0 26px 70px rgba(236,183,102,.15), var(--shadow); }
.door.chosen-both { box-shadow: 0 0 0 1px var(--gold), 0 30px 80px rgba(236,183,102,.22), var(--shadow); border-color: var(--gold); }

/* Wahl-Block im Raum */
.choose-block { border: 1px solid var(--line); border-radius: 22px; padding: 22px 22px 20px; margin: 8px 0 22px;
  background: linear-gradient(150deg, rgba(255,243,228,.06), rgba(0,0,0,.16)); position: relative; }
.choose-block.other { border-color: rgba(236,183,102,.55); background: linear-gradient(150deg, rgba(236,183,102,.12), rgba(0,0,0,.16)); }
.choose-block.mine { border-color: rgba(248,236,221,.25); }
.choose-block.both { border-color: var(--gold); background: linear-gradient(150deg, rgba(236,183,102,.16), rgba(223,108,74,.10)); }
.choose-title { font-family: var(--hand); font-size: 1.55rem; color: var(--gold); margin: 0 0 10px; line-height: 1.2; }
.choose-block.both .choose-title { color: var(--ink); }
.choose-help { color: var(--muted); font-size: .95rem; margin: 0 0 12px; }
.choose-line { color: var(--ink); margin: 4px 0; font-size: 1.02rem; line-height: 1.55; }
.choose-who { font-family: var(--hand); font-size: 1.15rem; margin-right: 6px; }
.choose-who.aurore { color: var(--aurore); }
.choose-who.mars { color: var(--mars); }
.choose-when { color: var(--soft); font-size: .8rem; margin: 8px 0 10px; }
.choose-block input { margin-bottom: 10px; }
.choose-btn { margin-top: 4px; }
.door-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.door.swipe-left { animation: swipeLeft .32s ease both; }
.door.swipe-right { animation: swipeRight .32s ease both; }
@keyframes swipeLeft { to { transform: translateX(-30px) rotate(-2deg); opacity: 0; } }
@keyframes swipeRight { to { transform: translateX(30px) rotate(2deg); opacity: 0; } }

/* Kinetisches Ziehen — Karte wird weggeworfen, neue schnappt rein */
.door.draw-toss-left  { animation: drawTossLeft .2s cubic-bezier(.55,0,.85,.3) both; }
.door.draw-toss-right { animation: drawTossRight .2s cubic-bezier(.55,0,.85,.3) both; }
@keyframes drawTossLeft  { to { transform: translateX(-120px) translateY(8px) rotate(-9deg) scale(.92); opacity: 0; } }
@keyframes drawTossRight { to { transform: translateX(120px) translateY(8px) rotate(9deg) scale(.92); opacity: 0; } }
.door.draw-snap { animation: drawSnap .42s cubic-bezier(.16,1.1,.3,1) both; }
@keyframes drawSnap {
  0%   { transform: translateY(-14px) scale(.96); opacity: 0; }
  60%  { transform: translateY(2px) scale(1.015); opacity: 1; }
  100% { transform: translateY(0) scale(1); opacity: 1; } }

/* room */
.room-back { color: var(--muted); font-size: .95rem; display: inline-flex; gap: 6px; align-items: center; margin: 8px 0 14px; }
.room-back:hover { color: var(--ink); }
.room-head { border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(24px,5vw,38px);
  background: linear-gradient(150deg, var(--panel2), rgba(255,243,228,.03)); position: relative; overflow: hidden; }
.room-head::before { content:""; position:absolute; inset:-1px; pointer-events:none; opacity:.45;
  background: radial-gradient(circle at 15% 0%, color-mix(in srgb, var(--facet-hue) 32%, transparent), transparent 42%); }
.room-head > * { position: relative; }

/* ===== Per-Facet-Temperatur =====
   Jede Facette fühlt sich anders an, bleibt aber in der Amber-Familie.
   Feuer: heiss, intensiv. Universum: weit, golden. Mind: klar, kühl-blass.
   Nähe: weich, rosa. Spiel: warm, lebendig. */

/* FEUER — heisser, intensiver Glow, engerer/stärkerer Brennpunkt */
.door[data-facet="feuer"]::before { opacity:.78;
  background: radial-gradient(circle at 30% 110%, color-mix(in srgb, var(--facet-hue) 55%, transparent), transparent 50%),
              radial-gradient(circle at 80% -10%, color-mix(in srgb, var(--facet-hue) 32%, transparent), transparent 40%); }
.room-head[data-facet="feuer"]::before,
[data-facet="feuer"] .room-head::before { opacity:.7;
  background: radial-gradient(circle at 50% 120%, color-mix(in srgb, var(--facet-hue) 48%, transparent), transparent 55%); }
[data-facet="feuer"] .room-head { border-color: color-mix(in srgb, var(--facet-hue) 28%, var(--line)); }

/* UNIVERSUM — weiter, expansiver Glow, golden, grosse Streuung */
.door[data-facet="welt"]::before { opacity:.5;
  background: radial-gradient(circle at 15% -5%, color-mix(in srgb, var(--facet-hue) 34%, transparent), transparent 55%),
              radial-gradient(circle at 95% 105%, color-mix(in srgb, var(--facet-hue) 26%, transparent), transparent 60%); }
[data-facet="welt"] .room-head::before { opacity:.46;
  background: radial-gradient(circle at 12% -5%, color-mix(in srgb, var(--facet-hue) 30%, transparent), transparent 60%); }

/* MIND — klarer, kühler, präziser; blasser und schmaler Lichtkegel */
.door[data-facet="kopf"]::before { opacity:.4;
  background: radial-gradient(circle at 50% -10%, color-mix(in srgb, var(--facet-hue) 26%, transparent), transparent 42%); }
[data-facet="kopf"] .room-head::before { opacity:.36;
  background: radial-gradient(circle at 50% -8%, color-mix(in srgb, var(--facet-hue) 24%, transparent), transparent 44%); }

/* NÄHE — weich, diffus, rosa; sanfter breiter Schimmer ohne harten Brennpunkt */
.door[data-facet="naehe"]::before { opacity:.5;
  background: radial-gradient(circle at 50% 50%, color-mix(in srgb, var(--facet-hue) 24%, transparent), transparent 70%); }
[data-facet="naehe"] .room-head::before { opacity:.42;
  background: radial-gradient(circle at 40% 30%, color-mix(in srgb, var(--facet-hue) 22%, transparent), transparent 65%); }

/* SPIEL — warm, lebendig, zwei verspielte Lichtquellen */
.door[data-facet="spiel"]::before { opacity:.58;
  background: radial-gradient(circle at 20% 10%, color-mix(in srgb, var(--facet-hue) 32%, transparent), transparent 44%),
              radial-gradient(circle at 85% 90%, color-mix(in srgb, var(--facet-hue) 28%, transparent), transparent 46%); }
[data-facet="spiel"] .room-head::before { opacity:.48;
  background: radial-gradient(circle at 18% 5%, color-mix(in srgb, var(--facet-hue) 30%, transparent), transparent 48%); }
.room-top { display: flex; justify-content: space-between; align-items: flex-start; }
.room-sigil { font-family: var(--display); font-size: 2.6rem; color: var(--facet-hue); line-height: 1; }
.room-cat { color: var(--facet-hue); text-transform: uppercase; letter-spacing: .18em; font-size: .82rem; font-weight: 600; }
.room-name { font-family: var(--hand); font-weight: 600; font-size: clamp(2.4rem, 7vw, 3.4rem); letter-spacing: 0; line-height: 1.05; color: var(--gold); margin: 4px 0 14px; }
.room-image { width: 100%; max-height: 320px; object-fit: cover; border-radius: 18px; margin: 6px 0 14px; border: 1px solid var(--line-soft); }
.room-impulse { color: var(--muted); font-size: 1.12rem; line-height: 1.7; }
.room-meta { display: grid; gap: 12px; margin-top: 22px; }
.room-meta .mb { border: 1px solid var(--line-soft); border-radius: 16px; padding: 14px 16px; background: rgba(0,0,0,.16); }
.room-meta .mb span { display: block; color: var(--facet-hue); font-size: .68rem; text-transform: uppercase; letter-spacing: .16em; margin-bottom: 5px; }
.room-meta .mb p { margin: 0; color: var(--muted); line-height: 1.6; }
.changed-note { margin-top: 14px; color: var(--soft); font-family: var(--hand); font-size: 1.15rem; }

.trail-head { display: flex; align-items: baseline; justify-content: space-between; margin: 30px 4px 14px; }
.trail-head h3 { font-family: var(--display); font-weight: 400; font-size: 1.5rem; margin: 0; }
.trail { display: flex; flex-direction: column; gap: 14px; }
.trail-empty { color: var(--soft); font-family: var(--hand); font-size: 1.35rem; padding: 10px 2px; }
.trace { border: 1px solid var(--line-soft); border-radius: 20px; padding: 16px 18px; background: rgba(0,0,0,.18); position: relative; max-width: 86%; }
.trace.aurore { align-self: flex-start; border-left: 3px solid var(--aurore); }
.trace.mars   { align-self: flex-end;  border-right: 3px solid var(--mars); }
.trace .who { font-family: var(--hand); font-size: 1.25rem; margin: 0 0 6px; }
.trace.aurore .who { color: var(--aurore); }
.trace.mars   .who { color: var(--mars); text-align: right; }
.trace .line { margin: 0; color: var(--ink); line-height: 1.6; }
.trace .when { color: var(--soft); font-size: .76rem; margin-top: 8px; }
.trace.mars .when, .trace.mars .line { text-align: right; }
.trace img.photo { width: 100%; border-radius: 14px; margin-top: 10px; display: block; border: 1px solid var(--line-soft); }
.trace.heart { background: radial-gradient(circle at 50% 0%, rgba(223,108,74,.18), rgba(0,0,0,.2)); border: 1px solid rgba(223,108,74,.4); text-align: center; max-width: 100%; align-self: center; }
.trace.heart .big-heart { font-size: 2.4rem; color: var(--mars); animation: pulse 2.4s ease-in-out infinite; }
.trace.heart .line { text-align: center; font-family: var(--hand); font-size: 1.4rem; color: var(--ink); }
.trace.heart.taken .big-heart { color: var(--gold); animation: none; }
.trace.heart .taken-note { font-family: var(--hand); color: var(--gold); font-size: 1.2rem; margin-top: 8px; }
@keyframes pulse { 0%,100%{ transform: scale(1);} 50%{ transform: scale(1.12);} }

.add-trail { margin-top: 26px; border: 1px dashed var(--line); border-radius: 22px; padding: 20px; background: var(--panel); }
.add-trail h4 { font-family: var(--display); font-weight: 400; font-size: 1.25rem; margin: 0 0 12px; }
.photo-row { display: flex; align-items: center; gap: 12px; margin: 12px 0; flex-wrap: wrap; position: relative; }
.photo-btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); cursor: pointer; user-select: none; }
.photo-btn:hover { border-color: var(--gold); color: var(--ink); }
.file-info { font-family: var(--hand); color: var(--gold); font-size: 1.1rem; opacity: .9; }
.photo-preview { max-height: 120px; border-radius: 12px; border: 1px solid var(--line-soft); }
.add-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
.heart-give { color: var(--mars); border: 1px solid rgba(223,108,74,.45); border-radius: 999px; padding: 12px 18px; display: inline-flex; gap: 8px; align-items: center; transition: all .2s ease; }
.heart-give:hover { background: rgba(223,108,74,.12); transform: translateY(-2px); }

/* die Karte (Konstellation) */
.map-wrap { position: relative; margin-top: 12px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  background: radial-gradient(circle at 50% 50%, #160a06 0%, #0a0503 100%); aspect-ratio: 4/3; }
.map-svg { display: block; width: 100%; height: 100%; }
.map-svg .star { cursor: pointer; opacity: 0; animation: starIn .8s ease both; transition: r .25s ease, opacity .25s ease; transform-origin: center; transform-box: fill-box; --age-op: 0.9; }
.map-svg .star:hover { r: 5.5; opacity: 1; }
.map-svg .star.heart { animation: starIn .8s ease both, heartPulse 3s ease-in-out infinite 1s; }
@keyframes starIn { from { opacity: 0; transform: scale(0.2); } to { opacity: var(--age-op); transform: scale(1); } }
@keyframes heartPulse { 0%,100% { opacity: var(--age-op); } 50% { opacity: 1; } }
.map-label { font-family: var(--body); font-size: 13px; letter-spacing: .22em; text-transform: uppercase; opacity: .7; pointer-events: none; font-weight: 500; }
.map-empty { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; pointer-events: none; }
.map-empty .map-line { font-family: var(--hand); color: var(--gold); font-size: 1.6rem; margin: 0; opacity: .8; }
.map-empty .map-line.strong { font-size: 2.2rem; opacity: 1; }
.map-legend { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 18px; padding: 0 4px; color: var(--muted); font-size: .9rem; }
.legend-item { display: inline-flex; align-items: center; gap: 8px; }
.legend-dot { width: 10px; height: 10px; border-radius: 50%; box-shadow: 0 0 12px currentColor; }
.legend-item strong { color: var(--ink); font-weight: 500; }
.legend-item em { font-style: italic; opacity: .85; }

/* Star-Info Popover über der Karte */
.star-info { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%);
  width: min(380px, calc(100% - 28px)); background: rgba(20,11,7,.94);
  border: 1px solid color-mix(in srgb, var(--facet-hue) 60%, var(--line)); border-radius: 18px;
  padding: 18px 20px 16px; backdrop-filter: blur(14px); z-index: 5;
  box-shadow: 0 24px 60px rgba(0,0,0,.5); animation: rise .25s ease both; }
.star-info-close { position: absolute; top: 8px; right: 10px; color: var(--soft); font-size: 1.3rem; line-height: 1;
  width: 28px; height: 28px; border-radius: 50%; transition: color .2s; }
.star-info-close:hover { color: var(--ink); }
.star-info-meta { display: flex; gap: 10px; align-items: baseline; margin-bottom: 8px; flex-wrap: wrap; }
.star-info-who { font-family: var(--hand); font-size: 1.25rem; }
.star-info-who.aurore { color: var(--aurore); }
.star-info-who.mars   { color: var(--mars); }
.star-info-cat { color: var(--muted); font-size: .82rem; font-style: italic; }
.star-info-heart { color: var(--mars); font-size: 1.6rem; text-align: center; margin: 4px 0; }
.star-info-heart em { color: var(--gold); font-size: .85rem; font-style: italic; margin-left: 6px; }
.star-info-photo { width: 100%; max-height: 200px; object-fit: cover; border-radius: 12px; margin-bottom: 10px; border: 1px solid var(--line-soft); }
.star-info-line { color: var(--ink); line-height: 1.55; margin: 6px 0; font-size: 1rem; }
.star-info-when { color: var(--soft); font-size: .76rem; margin: 8px 0 12px; }
.star-info-open { color: var(--gold); font-family: var(--body); font-size: .92rem; display: inline-block; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; transition: all .2s ease; }
.star-info-open:hover { border-color: var(--gold); background: rgba(236,183,102,.08); }

/* Highlight einer Spur beim Ankommen aus der Karte */
.trace.highlight { animation: traceHi 2.2s ease both; }
@keyframes traceHi {
  0% { box-shadow: 0 0 0 0 rgba(236,183,102,.0); }
  20% { box-shadow: 0 0 0 3px rgba(236,183,102,.5), 0 12px 30px rgba(236,183,102,.15); }
  100% { box-shadow: 0 0 0 0 rgba(236,183,102,0); }
}

/* Facet-Picker im Erfinden */
.facet-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin: 6px 0 4px; }
.facet-pick { border: 1px solid var(--line); border-radius: 18px; padding: 14px 12px; text-align: left; background: var(--panel);
  display: flex; flex-direction: column; gap: 4px; cursor: pointer; transition: all .2s ease; color: var(--ink); }
.facet-pick:hover { transform: translateY(-2px); border-color: var(--facet-hue); }
.facet-pick.sel { border-color: var(--facet-hue); box-shadow: 0 0 0 1px var(--facet-hue), 0 14px 30px color-mix(in srgb, var(--facet-hue) 18%, transparent); background: linear-gradient(145deg, color-mix(in srgb, var(--facet-hue) 12%, transparent), rgba(0,0,0,.1)); }
.facet-sigil { font-family: var(--display); font-size: 1.6rem; color: var(--facet-hue); line-height: 1; }
.facet-label { font-family: var(--display); font-size: 1.15rem; }
.facet-kicker { font-family: var(--body); font-style: italic; color: var(--muted); font-size: .82rem; line-height: 1.35; }

/* invent form */
.invent-form { display: grid; gap: 14px; max-width: 620px; margin-top: 8px; }
.invent-form input:first-of-type { font-family: var(--display); font-size: 1.3rem; padding: 18px; }
#extraFields { display: grid; gap: 14px; }

.foot { text-align: center; padding: 34px 0 26px; font-family: var(--hand); color: var(--gold); font-size: 1.25rem; opacity: .75; }
.foot span { font-family: inherit; font-size: inherit; color: inherit; }

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.toast { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%) translateY(20px); z-index: 60;
  background: rgba(20,11,7,.92); border: 1px solid var(--line); color: var(--ink); padding: 12px 20px; border-radius: 22px;
  font-family: var(--hand); font-size: 1.2rem; opacity: 0; transition: all .3s ease; backdrop-filter: blur(10px);
  max-width: min(92vw, 520px); text-align: center; line-height: 1.35; }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (max-width: 560px) {
  .claim-grid { grid-template-columns: 1fr; }
  .deck-stage { grid-template-columns: 36px 1fr 36px; }
  .deck-arrow { width: 36px; height: 36px; }
  .trace { max-width: 94%; }
  .facet-grid { grid-template-columns: 1fr 1fr; }
  .map-wrap { aspect-ratio: 1/1; }

  /* Topbar aufgeräumt: zwei saubere Reihen statt gequetschtem Umbruch */
  .topbar { flex-wrap: wrap; row-gap: 10px; padding: 16px 0 8px; }
  .brand { flex: 1 1 auto; min-width: 0; }
  .brand-mundart { display: none; }          /* steht schon im Onboarding + Intro */
  .brand-mark { font-size: 1rem; }
  .whoami { order: 2; flex: 0 0 auto; }
  .nav-right { order: 3; flex-basis: 100%; justify-content: flex-start;
    gap: 18px; padding-top: 4px; border-top: 1px solid var(--line-soft); }
  .nav-link { font-size: .9rem; }
}

/* ===== Admin / Kuratoren-Sicht (nur Mars) ===== */
.nav-admin { color: var(--ember); }
.adm-list { display: flex; flex-direction: column; gap: 26px; }
.adm-group { border: 1px solid var(--line); border-radius: 20px; padding: 18px 18px 8px;
  background: linear-gradient(150deg, color-mix(in srgb, var(--facet-hue) 7%, transparent), rgba(0,0,0,.12)); }
.adm-group-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.adm-group-head h3 { font-family: var(--display); font-weight: 400; font-size: 1.5rem; margin: 0; color: var(--ink); }
.adm-sigil { font-family: var(--display); font-size: 1.6rem; color: var(--facet-hue); line-height: 1; }
.adm-count { margin-left: auto; color: var(--soft); font-size: .82rem; }
.adm-row { display: flex; align-items: center; gap: 12px; padding: 12px 6px; border-top: 1px solid var(--line-soft); }
.adm-row.is-archived { opacity: .55; }
.adm-main { flex: 1; min-width: 0; }
.adm-name { font-family: var(--hand); font-size: 1.5rem; color: var(--gold); display: block; line-height: 1.1; }
.adm-name:hover { color: var(--ink); }
.adm-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 5px; }
.adm-tag { font-size: .72rem; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.adm-tag.fresh { color: var(--soft); }
.adm-tag.touched { color: var(--gold); border-color: rgba(236,183,102,.4); }
.adm-tag.chosen { color: var(--ink); border-color: var(--gold); }
.adm-tag.arch { color: var(--ember); border-color: rgba(215,106,79,.5); }
.adm-tag.own { color: var(--aurore); border-color: rgba(240,200,121,.4); }
.adm-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.adm-dot.aurore { background: var(--aurore); }
.adm-dot.mars { background: var(--mars); }
.adm-actions { flex-shrink: 0; }
.adm-btn { font-size: .85rem; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line);
  color: var(--muted); background: rgba(255,243,228,.04); transition: all .18s ease; }
.adm-btn:hover { border-color: var(--gold); color: var(--ink); }
.adm-btn:disabled { opacity: .5; }

/* ===== Welcome — einmalige Orientierung ===== */
.welcome-inner { max-width: 540px; }
.welcome-lines { display: flex; flex-direction: column; gap: 18px; margin: 28px 0 22px; text-align: left; }
.welcome-lines p { font-family: var(--body); font-size: 1.12rem; line-height: 1.5; color: var(--ink);
  display: flex; align-items: baseline; gap: 14px; margin: 0; }
.welcome-sigil { font-family: var(--display); font-size: 1.5rem; color: var(--gold); flex-shrink: 0; width: 1.4rem; text-align: center; }
.welcome-tone { font-family: var(--hand); font-size: 1.5rem; color: var(--gold); opacity: .85; margin: 6px 0 26px; }
.welcome-go { font-size: 1.05rem; padding: 14px 48px; }
@media (max-width: 560px) {
  .welcome-lines p { font-size: 1.04rem; }
}

/* welcome — Einladungs-Rahmung */
.welcome-intro { font-family: var(--body); font-size: 1.06rem; line-height: 1.55; color: var(--ink);
  opacity: .92; margin: 18px auto 24px; max-width: 460px; }
.welcome-intro .intro-beat { margin: 0 0 .85em; }
.welcome-intro .intro-beat:last-child { margin-bottom: 0; }
.welcome-cocreate { font-family: var(--body); font-size: .98rem; line-height: 1.5; color: var(--muted);
  margin: 20px auto 4px; max-width: 460px; }

/* Map motto — e pluribus unum, quiet at the foot */
.map-motto {
  text-align: center;
  font-family: 'Fraunces', Georgia, serif;
  font-style: italic;
  font-size: .82rem;
  letter-spacing: .06em;
  color: rgba(236,183,102,.45);
  margin: 1.4rem 0 .4rem;
}

