/* Gästehaus Drachennest – style.css */

@font-face {
  font-family: "Drachennest Hand";
  src: url("../fonts/drachennest-hand.woff2") format("woff2");
  font-display: swap;
}
@font-face {
  font-family: "Nunito Sans";
  src: url("../fonts/nunito-sans.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --primary: #24353f;
  --primary-dark: #17232a;
  --bg: #f7f7f7;
  --surface: #fff;
  --text: #24353f;
  --muted: #4b5b65;
  --line: #dde2e5;
  --focus: #0a58ca;
  --radius: .5rem;
  --shadow: 0 .5rem 2rem rgba(36, 53, 63, .12);
  --max: 68rem;
  --header-h: 4rem;
  --font: "Nunito Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Drachennest Hand", "Segoe Print", "Bradley Hand", cursive;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font: 400 1.125rem/1.65 var(--font);
  color: var(--text);
  background: var(--bg);
}
img, picture, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--primary); text-underline-offset: .15em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.on-dark :focus-visible, .hero :focus-visible, .site-header :focus-visible, .menu :focus-visible, .lightbox :focus-visible {
  outline-color: #fff;
}
h1, h2, h3 { line-height: 1.2; margin: 0 0 1rem; font-weight: 300; }
h2 { font-size: clamp(1.75rem, 4.5vw, 2.5rem); }
h2 strong, h3 strong { font-weight: 700; }
h3 { font-size: 1.5rem; font-weight: 700; }
p { margin: 0 0 1rem; }
ul { margin: 0 0 1rem; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}
.skip-link {
  position: fixed; left: 1rem; top: -4rem; z-index: 100; padding: .6rem 1rem;
  background: #fff; color: var(--primary); border-radius: var(--radius); font-weight: 700;
}
.skip-link:focus { top: 1rem; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.i { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50; height: var(--header-h);
  background: rgba(23, 35, 42, .92); color: #fff;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.site-header .bar { display: flex; align-items: center; gap: 1rem; height: 100%; padding: 0 1rem; max-width: 90rem; margin: 0 auto; }
.brand { display: flex; align-items: center; gap: .6rem; color: #fff; text-decoration: none; font-size: 1.25rem; margin-right: auto; }
.brand img { width: 2.5rem; height: 2.5rem; }
.brand span { font-family: var(--font-display); font-size: 1.5rem; line-height: 1; }
.brand strong { font-weight: 400; }
@media (max-width: 30rem) { .brand span { font-size: 1.2rem; } }
.top-links { display: none; gap: 1.5rem; }
.top-links a { color: #fff; text-decoration: none; font-weight: 600; padding: .5rem 0; border-bottom: 2px solid transparent; }
.top-links a:hover, .top-links a[aria-current] { border-color: #fff; }
@media (min-width: 56rem) { .top-links { display: flex; } }
.menu-btn {
  display: none; align-items: center; gap: .5rem; font: inherit; font-weight: 600; color: #fff;
  background: transparent; border: 2px solid rgba(255, 255, 255, .6); border-radius: 99px; padding: .4rem 1rem; cursor: pointer;
}
.menu-btn:hover { background: rgba(255, 255, 255, .12); }
.js .menu-btn { display: inline-flex; }

/* ---------- Menü ---------- */
.menu { background: var(--primary); color: #fff; padding: 2rem 1.5rem; }
.menu ul { list-style: none; margin: 0; padding: 0; }
.menu a { color: #fff; display: block; padding: .5rem 0; text-decoration: none; }
.menu a:hover { text-decoration: underline; }
.menu .primary-links { font-size: 1.25rem; margin-bottom: 1rem; padding-bottom: 1rem; border-bottom: 1px solid rgba(255, 255, 255, .25); }
.menu .primary-links a { font-weight: 700; }
.menu a[aria-current="page"] { text-decoration: underline; text-underline-offset: .25em; }
.menu .social { display: flex; gap: 1rem; margin-top: 1.5rem; }
.menu-close { display: none; }
.backdrop { display: none; }
.js .menu {
  position: fixed; inset: 0 0 0 auto; z-index: 70; width: min(22rem, 100%); overflow-y: auto;
  transform: translateX(100%); visibility: hidden; transition: transform .3s ease, visibility 0s .3s;
}
.js .menu.open { transform: none; visibility: visible; transition: transform .3s ease; }
.js .menu-close {
  display: flex; width: fit-content; align-items: center; gap: .5rem; margin: 0 0 1.5rem auto; font: inherit; font-weight: 600;
  color: #fff; background: transparent; border: 2px solid rgba(255, 255, 255, .6); border-radius: 99px; padding: .4rem 1rem; cursor: pointer;
}
.js .backdrop { display: block; position: fixed; inset: 0; z-index: 65; background: rgba(10, 18, 22, .6); opacity: 0; visibility: hidden; transition: opacity .3s ease, visibility 0s .3s; }
.js .backdrop.open { opacity: 1; visibility: visible; transition: opacity .3s ease; }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate; display: grid; place-items: center; text-align: center;
  min-height: 100vh; min-height: 100svh; padding: calc(var(--header-h) + 2rem) 1.25rem 5.5rem; color: #fff;
}
.hero.is-short { min-height: 75vh; min-height: 75svh; }
.hero > picture, .hero > picture img { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2; }
.hero > picture img { object-fit: cover; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(rgba(16, 27, 33, .6), rgba(16, 27, 33, .5) 45%, rgba(16, 27, 33, .75));
}
.hero .content { max-width: 44rem; }
.hero h1, .brand span { text-rendering: optimizeLegibility; }
.hero h1 { font-family: var(--font-display); font-weight: 400; font-size: clamp(2.75rem, 9vw, 5.5rem); line-height: 1.05; margin-bottom: .75rem; }
.hero h1 strong { font-weight: 400; display: block; }
.hero .tagline { font-size: clamp(1.4rem, 3.5vw, 2rem); font-weight: 300; line-height: 1.3; margin: 0 0 1rem; }
.hero p { font-size: 1.2rem; }
.hero { padding-top: calc(var(--header-h) + 5.5rem); }
.hero .hero-logo { position: absolute; top: calc(var(--header-h) + .75rem); right: 1rem; width: 4.5rem; height: 4.5rem; transform: rotate(15deg); }
@media (min-width: 50rem) {
  .hero { padding-top: calc(var(--header-h) + 7rem); }
  .hero .hero-logo { top: calc(var(--header-h) + 1.25rem); right: 2rem; width: 6rem; height: 6rem; }
}
@media (min-width: 70rem) {
  .hero { padding-top: calc(var(--header-h) + 2rem); }
  .hero .hero-logo { top: calc(var(--header-h) + 1.75rem); right: clamp(2rem, 6vw, 6rem); width: 9rem; height: 9rem; }
}
.hero .scroll-btn { position: absolute; left: 50%; bottom: 1.5rem; translate: -50% 0; }

/* ---------- Abschnitte & Boxen ---------- */
.section { padding: 0 1rem; margin: 2.5rem 0; scroll-margin-top: calc(var(--header-h) + .5rem); }
.box { max-width: var(--max); margin: 0 auto; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.center { text-align: center; }
.content { padding: clamp(1.5rem, 5vw, 3.5rem); }
.content > :last-child { margin-bottom: 0; }
.content.has-scroll { padding-bottom: 5.5rem; position: relative; }
.content.has-scroll .scroll-btn { position: absolute; left: 50%; bottom: 1.5rem; translate: -50% 0; }
.columns { display: grid; }
.media { display: block; position: relative; }
.media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.media.wide img { aspect-ratio: 4 / 3; }
@media (min-width: 40rem) { .media.wide img { aspect-ratio: 16 / 9; } }
.columns .content { display: flex; flex-direction: column; justify-content: center; }
@media (min-width: 50rem) {
  .columns { grid-template-columns: 1fr 1fr; }
  .columns .media img { position: absolute; inset: 0; height: 100%; aspect-ratio: auto; }
  .columns .content.has-scroll { padding-bottom: 5.5rem; }
}
.lead { font-size: 1.25rem; }
.actions { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 1rem; margin-top: 1.75rem; }
.actions .scroll-btn { position: static; translate: none; }
.two-col .actions { justify-content: flex-start; }

/* Scroll-Button */
.scroll-btn {
  display: inline-grid; place-items: center; width: 3rem; height: 3rem; border-radius: 50%;
  background: var(--primary); color: #fff; text-decoration: none; border: 2px solid transparent;
  transition: background .2s, transform .2s;
}
.hero .scroll-btn { background: rgba(255, 255, 255, .15); border-color: #fff; }
.scroll-btn:hover { background: var(--primary-dark); transform: translateY(2px); }
.hero .scroll-btn:hover { background: rgba(255, 255, 255, .3); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem; padding: .75rem 1.6rem;
  font: inherit; font-weight: 700; line-height: 1.2; text-align: center; text-decoration: none;
  color: var(--primary); background: transparent; border: 2px solid var(--primary); border-radius: 99px; cursor: pointer;
  transition: background .2s, color .2s;
}
.btn:hover { background: var(--primary); color: #fff; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-stack { display: grid; gap: 1rem; max-width: 24rem; margin: 1.5rem auto 0; }

/* ---------- Galerie & Lightbox ---------- */
.gallery { display: grid; gap: .5rem; padding: 0 .5rem .5rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); margin: 0; list-style: none; }
.gallery-4 { grid-template-columns: repeat(2, 1fr); gap: 1rem; padding: 0 clamp(1.5rem, 5vw, 3.5rem); }
@media (min-width: 50rem) { .gallery-4 { grid-template-columns: repeat(4, 1fr); } }
.gallery a { display: block; overflow: hidden; border-radius: .25rem; }
.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform .4s ease; }
.gallery a:hover img { transform: scale(1.04); }
.lightbox { border: 0; padding: 0; background: transparent; width: 100%; height: 100%; max-width: 100vw; max-height: 100vh; color: #fff; }
.lightbox::backdrop { background: rgba(10, 18, 22, .94); }
.lightbox figure { margin: 0; height: 100%; display: grid; grid-template-rows: 1fr auto; place-items: center; padding: 3.5rem 1rem 1rem; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 8rem); max-height: calc(100svh - 8rem); object-fit: contain; }
.lightbox figcaption { padding-top: .75rem; text-align: center; }
.lb-btn {
  position: absolute; display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: 50%;
  color: #fff; background: rgba(255, 255, 255, .15); border: 2px solid rgba(255, 255, 255, .7); cursor: pointer;
}
.lb-btn:hover { background: rgba(255, 255, 255, .3); }
.lb-close { top: .75rem; right: .75rem; }
.lb-prev, .lb-next { top: 50%; translate: 0 -50%; }
.lb-prev { left: .75rem; }
.lb-next { right: .75rem; }

/* ---------- Zimmer-Karten & Slider ---------- */
.section-title { font-size: clamp(2.25rem, 6vw, 3.5rem); text-align: center; max-width: var(--max); margin: 0 auto 2.5rem; }
#zimmer { margin-top: 4.5rem; }
.rooms { display: grid; gap: 2rem; max-width: var(--max); margin: 0 auto; }
.room { display: grid; margin: 0; width: 100%; }
.room-info { padding: clamp(1.5rem, 4vw, 2.5rem); display: flex; flex-direction: column; justify-content: center; }
.room-info h3 { font-size: 1.75rem; margin-bottom: .5rem; }
.room-size { display: inline-block; align-self: flex-start; margin: 0 0 1rem; padding: .15rem .9rem; border-radius: 99px; background: var(--bg); border: 1px solid var(--line); font-weight: 600; }
.room-info ul { padding-left: 1.2rem; }
.room-info li { margin-bottom: .4rem; }
.room-info .btn { align-self: flex-start; margin-top: auto; }
@media (min-width: 50rem) {
  .room { grid-template-columns: 1.1fr 1fr; }
  .room:nth-child(even) .slider { order: 2; }
  .slider { min-height: 22rem; }
  .slides, .slides li { height: 100%; }
  .slides li { position: relative; }
  .slides a, .slides picture, .slides img { position: absolute; inset: 0; width: 100%; height: 100%; aspect-ratio: auto; }
}
.slider { position: relative; background: var(--line); min-width: 0; }
.slides { display: flex; margin: 0; padding: 0; list-style: none; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.slides::-webkit-scrollbar { display: none; }
.slides li { flex: 0 0 100%; scroll-snap-align: start; }
.slides a { display: block; }
.slides img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.slider-btn {
  display: none; position: absolute; top: 50%; translate: 0 -50%; place-items: center; width: 2.75rem; height: 2.75rem;
  border-radius: 50%; border: 0; cursor: pointer; background: rgba(255, 255, 255, .92); color: var(--primary); box-shadow: 0 2px 8px rgba(0, 0, 0, .25);
}
.slider-btn:hover { background: #fff; }
.slider-btn.prev { left: .75rem; }
.slider-btn.next { right: .75rem; }
.js .slider-btn { display: grid; }
.slider-count { display: none; position: absolute; right: .75rem; bottom: .75rem; padding: .15rem .8rem; border-radius: 99px; background: rgba(16, 27, 33, .8); color: #fff; font-size: .9rem; }
.js .slider-count { display: block; }

/* ---------- Tabelle, Listen, Text ---------- */
.table-wrap { overflow-x: auto; margin-bottom: 1.5rem; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th, td { padding: .75rem 1rem; border-bottom: 1px solid var(--line); }
th { font-weight: 700; border-bottom: 2px solid var(--primary); }
.two-col { display: grid; gap: 1rem 3rem; text-align: left; }
@media (min-width: 40rem) { .two-col { grid-template-columns: 1fr 1fr; } }
.small { font-size: .9375rem; color: var(--muted); }
.check-list { text-align: left; max-width: 46rem; margin-inline: auto; padding-left: 1.25rem; }
.check-list li { margin-bottom: .6rem; }
.prose { max-width: 48rem; margin-inline: auto; }
.prose h1 { font-size: clamp(2rem, 5vw, 3rem); }
.prose h2 { font-size: 1.6rem; margin-top: 2rem; }
.page-plain main { padding-top: calc(var(--header-h) + 2rem); min-height: 70vh; }
.widget-note { margin-top: 2rem; }

/* ---------- Footer ---------- */
.site-footer { text-align: center; padding: 3rem 1rem 3.5rem; color: var(--muted); font-size: 1rem; }
.site-footer a { color: var(--primary); }
.social { display: flex; justify-content: center; gap: 1rem; list-style: none; margin: 0 0 1.25rem; padding: 0; }
.social-row { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: .5rem 1.25rem; margin-bottom: 1.25rem; }
.social-row .social { margin: 0; }
.social-label { font-family: var(--font-display); font-size: 2rem; line-height: 1; color: var(--primary); }
.social a { display: grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: 50%; border: 2px solid currentColor; text-decoration: none; }
.social a:hover { background: var(--primary); color: #fff; }
.menu .social a { color: #fff; }
.menu .social a:hover { background: #fff; color: var(--primary); }

/* ---------- Einblend-Animationen ---------- */
@keyframes reveal { from { opacity: 0; transform: translateY(2rem); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: no-preference) {
  /* Hero: nur Opazität, Überschrift ohne Animation (Safari rendert animierten Text sonst teils unscharf) */
  .hero .content > :not(h1), .hero .scroll-btn { animation: fade .9s ease backwards; }
  .hero .content > :nth-child(2) { animation-delay: .1s; }
  .hero .content > :nth-child(3) { animation-delay: .25s; }
  .hero .hero-logo { animation: fade .9s ease .4s backwards; }
  .hero .scroll-btn { animation-delay: .6s; }
  @supports (animation-timeline: view()) {
    .reveal { animation: reveal linear backwards; animation-timeline: view(); animation-range: entry 0% entry 35%; }
  }
  @supports not (animation-timeline: view()) {
    .js .reveal { opacity: 0; transform: translateY(2rem); transition: opacity .8s ease, transform .8s ease; }
    .js .reveal.in { opacity: 1; transform: none; }
  }
}
