/* Layout: eine Spalte wie ein Briefbogen. Das Aquarell trägt den Einstieg, jeder Abschnitt ist ein
   gerahmtes Blatt mit Edelweiß in den Ecken, wie auf der Einladungskarte. */
:root {
  --paper: #f4f5eb;
  --panel: #f9faf3;
  --ink: #4a3a2c;
  --ink-soft: #6a5846;
  --gold: #b59b6e;
  --gold-deep: #94784b;
  --gold-text: #755c35;
  --green: #4d6342;
  --line: rgba(181, 155, 110, .6);
  --line-soft: rgba(181, 155, 110, .3);
  --ribbon: #efe4cc;
  --font-script: 'Kaushan Script', 'Brush Script MT', 'Segoe Script', cursive;
  --font-body: 'Merienda', 'Segoe Script', 'Georgia', serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background-color: var(--paper);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .45 0 0 0 0 .38 0 0 0 0 .28 0 0 0 .09 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.8;
  -webkit-text-size-adjust: 100%;
}
img { max-width: 100%; height: auto; }
a { color: var(--green); }
p { margin: 0 0 1rem; }

.hero, main, .nav, .foot { max-width: 46rem; margin-inline: auto; padding-inline: 1rem; }

/* Einstieg */
.hero { text-align: center; padding-block: 2.2rem 1rem; }
.titel {
  font-family: var(--font-script); font-weight: 400;
  font-size: clamp(2.1rem, 8.6vw, 3.5rem); line-height: 1.15;
  color: var(--gold-deep); margin: 0 0 1rem; text-wrap: balance;
}
.ribbon-wrap { margin: 0 0 1.2rem; filter: drop-shadow(0 1px 0 rgba(148, 120, 75, .55)); }
.ribbon {
  display: inline-block; padding: .5rem 2.6rem; background: var(--ribbon); color: var(--ink-soft);
  font-size: clamp(.9rem, 3.6vw, 1.15rem); letter-spacing: .2em; text-transform: uppercase; line-height: 1.4;
  clip-path: polygon(0 0, 100% 0, calc(100% - 1.1rem) 50%, 100% 100%, 0 100%, 1.1rem 50%);
}
.hero-art {
  display: block; width: 100%; aspect-ratio: 816 / 580; object-fit: cover;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 78%, transparent 100%),
                      linear-gradient(to right, transparent 0, #000 9%, #000 91%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 78%, transparent 100%),
              linear-gradient(to right, transparent 0, #000 9%, #000 91%, transparent 100%);
  mask-composite: intersect;
}
.datum {
  margin: -1.6rem 0 .1rem; position: relative;
  font-weight: 700; font-size: clamp(1.8rem, 8vw, 2.6rem); letter-spacing: .06em; color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.ort { font-size: 1rem; color: var(--ink-soft); margin-bottom: 1.4rem; }

.count { display: flex; justify-content: center; gap: 0; margin: 0 auto .4rem; max-width: 24rem; }
.count .unit { flex: 1; padding: .2rem .4rem; border-left: 1px solid var(--line); }
.count .unit:first-child { border-left: 0; }
.count b { display: block; font-size: clamp(1.4rem, 7vw, 2rem); line-height: 1.3; font-variant-numeric: tabular-nums; color: var(--ink); }
.count span { font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); }
.count-note { font-size: .88rem; color: var(--ink-soft); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .7rem; justify-content: center; margin: 1.3rem 0 0; }

/* Navigation */
.nav { display: flex; gap: .5rem; overflow-x: auto; padding-block: .3rem 1rem; scrollbar-width: none; justify-content: safe center; }
.nav::-webkit-scrollbar { display: none; }
.nav a {
  flex: none; padding: .45rem .95rem; border: 1px solid var(--line); border-radius: 2px;
  text-decoration: none; color: var(--ink-soft); font-size: .88rem; background: rgba(249, 250, 243, .6);
}
.nav a:hover { border-color: var(--gold-deep); color: var(--ink); }

/* Blätter */
main { padding-bottom: 1rem; }
.panel {
  position: relative; margin-block: 1.8rem; padding: 2.6rem 1.3rem 1.8rem;
  background-color: var(--panel); border: 1px solid var(--line);
  background-image: url(img/edelweiss-ecke.webp), url(img/edelweiss-ecke-tr.webp),
                    url(img/edelweiss-ecke-bl.webp), url(img/edelweiss-ecke-br.webp);
  background-repeat: no-repeat;
  background-position: top 6px left 6px, top 6px right 6px, bottom 6px left 6px, bottom 6px right 6px;
  background-size: clamp(54px, 15vw, 92px) auto;
  scroll-margin-top: 1rem;
}
.panel::before { content: ""; position: absolute; inset: 6px; border: 1px solid var(--line-soft); pointer-events: none; }
.panel > * { position: relative; }
.panel h2, .note h2 {
  font-family: var(--font-script); font-weight: 400; font-size: clamp(1.7rem, 6.4vw, 2.2rem);
  line-height: 1.2; color: var(--ink-soft); text-align: center; margin: 0 0 1.3rem; text-wrap: balance;
}
.panel h2::after {
  content: ""; display: block; width: min(14rem, 68%); aspect-ratio: 550 / 115; margin: .3rem auto 0;
  background: url(img/berge-trenner.webp) center / contain no-repeat;
}
.lead { text-align: center; }
.small { font-size: .85rem; color: var(--ink-soft); }
.panel .small, .foot .small { text-align: center; }

.note { margin-block: 1.4rem; padding: 1rem 1.2rem; border-left: 3px solid var(--gold); background: rgba(249, 250, 243, .7); }
.note h2 { font-size: 1.5rem; text-align: left; margin: 0 0 .4rem; }
.note ul { list-style: none; margin: 0; padding: 0; }
.note li { margin: .3rem 0; }
.note time { font-size: .8rem; letter-spacing: .1em; color: var(--gold-text); margin-right: .6rem; }

/* Fakten */
.facts { display: grid; gap: 0; margin: 0; }
.fact { padding: .9rem 0; border-top: 1px solid var(--line-soft); }
.fact:first-child { border-top: 0; }
.fact dt { font-size: .74rem; letter-spacing: .16em; text-transform: uppercase; color: var(--gold-text); margin-bottom: .15rem; }
.fact dd { margin: 0; }
.fact.wichtig { background: rgba(181, 155, 110, .12); margin-inline: -.6rem; padding-inline: .6rem; border-top-color: transparent; }
.fact dd .btn { margin-top: .7rem; }
@media (min-width: 40rem) {
  .facts { grid-template-columns: 1fr 1fr; column-gap: 2rem; }
  .fact:nth-child(2) { border-top: 0; }
  .fact.wichtig { grid-column: 1 / -1; }
}

/* Zeitplan */
.zeit { list-style: none; margin: 0; padding: 0; }
.zeit li { display: grid; grid-template-columns: 4.6rem 1fr; gap: 0 1.1rem; padding: 0 0 1.2rem; position: relative; }
.zeit li::before { content: ""; position: absolute; left: 4.6rem; top: .5rem; bottom: -.3rem; width: 1px; background: var(--line); transform: translateX(.55rem); }
.zeit li:last-child::before { display: none; }
.zeit li::after { content: ""; position: absolute; left: 4.6rem; top: .55rem; width: .6rem; height: .6rem; border: 1px solid var(--gold-deep); background: var(--panel); transform: translateX(.25rem) rotate(45deg); }
.zeit .t { font-weight: 700; font-variant-numeric: tabular-nums; }
.zeit .b { padding-left: .9rem; min-width: 0; }
.zeit h3 { margin: 0; font-size: 1rem; }
.zeit p { margin: 0; color: var(--ink-soft); font-size: .95rem; }

/* Listen für Orte und Unterkünfte */
.item { padding: 1.1rem 0; border-top: 1px solid var(--line-soft); }
.item:first-child { border-top: 0; padding-top: 0; }
.item h3 { margin: 0 0 .15rem; font-size: 1.05rem; display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.item .meta { font-size: .85rem; color: var(--gold-text); margin-bottom: .3rem; }
.item p { margin: 0 0 .6rem; }
.item .addr { font-weight: 700; overflow-wrap: anywhere; }
.actions { display: flex; flex-wrap: wrap; gap: .6rem; margin: .4rem 0 0; }
.panel > .actions { justify-content: center; margin-block: .9rem; }
.tipps { margin: 1rem 0 .4rem; padding-left: 1.2rem; }
.badge { display: inline-block; font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; border: 1px dashed var(--gold-deep); color: var(--gold-text); padding: .05rem .5rem; line-height: 1.6; font-weight: 400; }

/* Knöpfe */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: .5rem 1.1rem;
  border: 1px solid var(--ink); border-radius: 2px; background: transparent; color: var(--ink);
  font: inherit; font-size: .9rem; line-height: 1.3; text-decoration: none; cursor: pointer;
}
.btn:hover { background: rgba(74, 58, 44, .08); }
.btn.primary { background: var(--ink); color: var(--paper); }
.btn.primary:hover { background: #352a20; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

/* Formular */
form label, form legend { display: block; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--gold-text); margin: 1rem 0 .3rem; padding: 0; }
form input[type="text"], form input[type="number"], form select, form textarea {
  width: 100%; min-height: 44px; padding: .55rem .7rem; border: 1px solid var(--line); border-radius: 2px;
  background: var(--paper); color: var(--ink); font: inherit; font-size: 1rem;
}
form textarea { resize: vertical; }
fieldset.radios { border: 0; padding: 0; margin: 0; min-width: 0; }
.radios label { display: flex; align-items: center; gap: .6rem; font-size: 1rem; letter-spacing: 0; text-transform: none; color: var(--ink); margin: .35rem 0; min-height: 36px; }
.radios input { width: 1.15rem; height: 1.15rem; accent-color: var(--ink); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.msg { white-space: pre-wrap; overflow-wrap: anywhere; margin: 1.2rem 0 0; padding: .9rem 1rem; background: var(--paper); border: 1px dashed var(--line); font: inherit; font-size: .9rem; line-height: 1.6; }

/* Galerie */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: .6rem; margin-top: 1rem; }
.tile { padding: 0; border: 1px solid var(--line); background: var(--paper); cursor: zoom-in; display: block; border-radius: 2px; overflow: hidden; }
.tile img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; transition: transform .25s ease; }
.tile:hover img { transform: scale(1.04); }
@media (prefers-reduced-motion: reduce) { .tile img { transition: none; } }

.lb { position: fixed; inset: 0; z-index: 50; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .8rem; padding: 3.2rem .5rem 1rem; background: rgba(36, 28, 21, .94); }
.lb[hidden] { display: none; }
.lb-fig { margin: 0; text-align: center; max-width: 100%; min-width: 0; }
.lb-fig img { max-width: 100%; max-height: calc(100dvh - 11rem); object-fit: contain; }
.lb-fig figcaption { color: #e9e2d2; font-size: .85rem; margin-top: .4rem; }
.lb-x, .lb-nav { position: absolute; width: 44px; height: 44px; border: 1px solid rgba(233, 226, 210, .5); background: rgba(36, 28, 21, .6); color: #f4efe2; font-size: 1.5rem; line-height: 1; cursor: pointer; border-radius: 2px; }
.lb-x { top: .7rem; right: .7rem; font-size: 1.1rem; }
.lb-nav { top: 50%; transform: translateY(-50%); }
.lb-nav.prev { left: .4rem; } .lb-nav.next { right: .4rem; }
.lb .btn { border-color: #e9e2d2; color: #f4efe2; }
.lb .btn:hover { background: rgba(244, 239, 226, .12); }
.lb :focus-visible { outline-color: #f4efe2; }

/* Fuß */
.foot { text-align: center; padding-block: 1.5rem 3rem; }
.gruss { font-family: var(--font-script); font-size: clamp(1.7rem, 7vw, 2.3rem); color: var(--gold-deep); margin-bottom: .6rem; }

/* Datenschutz */
.datenschutz { margin: 1rem auto 1.4rem; max-width: 36rem; text-align: left; border-top: 1px solid var(--line-soft); padding-top: .8rem; }
.datenschutz summary { cursor: pointer; font-size: .88rem; color: var(--ink-soft); text-align: center; list-style: none; min-height: 44px; display: flex; align-items: center; justify-content: center; text-decoration: underline; }
.datenschutz summary::-webkit-details-marker { display: none; }
.ds-body { font-size: .88rem; line-height: 1.7; color: var(--ink-soft); }
.ds-body p { margin: 0 0 .7rem; }

/* Anfahrts-Skizze */
.karte { margin: 0 0 1.4rem; }
.karte-box { position: relative; border: 1px solid var(--line); background: var(--paper); line-height: 1.2; overflow: hidden; }
.karte-box img { display: block; width: 100%; }
.karte .tag { position: absolute; transform: translate(0, -50%); padding: .1rem .45rem; background: rgba(249, 250, 243, .94); border: 1px solid var(--line); border-radius: 2px; font-size: .72rem; color: var(--ink); white-space: nowrap; }
.karte .tag-r { transform: translate(-100%, -50%); }
.karte .tag-soft { background: rgba(249, 250, 243, .78); color: var(--ink-soft); font-style: italic; }
.karte .pin { position: absolute; transform: translate(-50%, -50%); display: grid; place-items: center; }
.karte .pin-p { width: 1.9rem; height: 1.9rem; border-radius: 50%; background: var(--ink); color: var(--paper); font-weight: 700; font-size: .95rem; box-shadow: 0 0 0 3px rgba(244, 245, 235, .9); }
.karte .ring { position: absolute; transform: translate(-50%, -50%); width: 2.6rem; height: 2.6rem; border-radius: 50%; border: 2px dashed var(--gold-deep); }
.karte .kn { position: absolute; left: .6rem; top: .5rem; width: 1.6rem; height: 1.6rem; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; font-size: .72rem; color: var(--ink-soft); background: rgba(249, 250, 243, .8); }
.karte figcaption { margin-top: .8rem; font-size: .92rem; }
.karte ol { margin: .4rem 0 .6rem; padding-left: 1.3rem; }
.karte li { margin-bottom: .35rem; }

.hint { text-align: left !important; margin: .3rem 0 0; }

.karte .fluss { position: absolute; font-size: .8rem; letter-spacing: .22em; text-transform: uppercase; color: #46727e; font-style: italic; white-space: nowrap; pointer-events: none; }
.note-box { margin: 0 0 1.2rem; padding: .8rem 1rem; border: 1px solid var(--gold-deep); background: rgba(181, 155, 110, .14); font-size: .95rem; line-height: 1.6; }
.fact.wichtig dd > div { display: flex; justify-content: center; }
/* Alle Knöpfe mittig */
.actions, .item .actions { justify-content: center; }
.lb .btn.lb-dl { align-self: center; }

/* Sonder-Banner */
.gag { padding: 1.1rem 1rem 1.2rem; text-align: center; background: var(--gold-deep); color: #fff; border-bottom: 3px double rgba(255,255,255,.55); }
.gag p { margin: 0; }
.gag-an { font-size: clamp(1.5rem, 6.5vw, 2.2rem); line-height: 1.2; font-weight: 700; }
.gag-text { margin-top: .35rem; font-size: clamp(1rem, 4.2vw, 1.25rem); line-height: 1.4; }
.gag-ps { margin-top: .7rem !important; font-size: .85rem; line-height: 1.4; font-style: italic; opacity: .92; }
