@import url('fonts-local.css');

:root {
  --font: "DM Sans", system-ui, sans-serif;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --bg: #eef4ef;
  --bg-pattern:
    radial-gradient(ellipse 120% 80% at 50% -20%, rgba(180, 210, 185, 0.45) 0%, transparent 55%),
    radial-gradient(ellipse 80% 50% at 100% 50%, rgba(200, 225, 200, 0.25) 0%, transparent 45%),
    linear-gradient(180deg, #f4faf6 0%, #eef4ef 35%, #e8f0ea 100%);
  --text: #152818;
  --muted: #4d5f4f;
  --accent: #1e5c32;
  --accent-hover: #164726;
  --accent-soft: #2f7d44;
  --link: #1a6b3a;
  --link-hover: #0f4d28;
  --border: #b8d4bf;
  --card: #fff;
  --card-shadow: 0 4px 6px -1px rgba(21, 40, 24, 0.06), 0 12px 24px -8px rgba(21, 40, 24, 0.12);
  --header-bg: linear-gradient(145deg, #9ec9a8 0%, #7fb88c 42%, #6aa578 100%);
  --header-border: rgba(45, 95, 62, 0.35);
  --header-nav-link: #0f2918;
  --header-nav-hover-bg: rgba(255, 255, 255, 0.55);
  --header-nav-active-bg: rgba(255, 255, 255, 0.72);
  --radius: 14px;
  --radius-lg: 20px;
  --maxw: 54rem;
}

* { box-sizing: border-box; }

body.public {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg-pattern);
  background-attachment: fixed;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-header {
  background: var(--header-bg);
  border-bottom: 1px solid var(--header-border);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.4) inset,
    0 4px 20px rgba(21, 60, 35, 0.12);
  position: sticky;
  top: 0;
  z-index: 50;
}

.site-header__inner {
  max-width: 76rem;
  margin: 0 auto;
  padding: 0.75rem 1.1rem;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem 1.25rem;
}

.site-nav {
  min-width: 0;
}

.site-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.35rem 0.4rem;
}

.site-nav__item {
  margin: 0;
  min-width: 0;
}

.site-nav__link {
  display: block;
  padding: 0.45rem 0.65rem;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--header-nav-link);
  text-decoration: none;
  border-radius: 999px;
  text-align: center;
  line-height: 1.25;
  transition:
    background 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.site-nav__link:hover {
  background: var(--header-nav-hover-bg);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(15, 41, 24, 0.12);
}

.site-nav__link.is-active {
  color: var(--accent);
  font-weight: 700;
  background: var(--header-nav-active-bg);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
}

.site-nav__link:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .site-nav__link {
    transition: none;
  }
  .site-nav__link:hover {
    transform: none;
  }
  .btn {
    transition: none;
  }
  .btn:active {
    transform: none;
  }
}

.site-logo {
  flex-shrink: 0;
  line-height: 0;
  align-self: center;
  filter: drop-shadow(0 2px 6px rgba(15, 41, 24, 0.15));
}

.site-logo img {
  display: block;
  height: 62px;
  width: auto;
  max-width: 92px;
  object-fit: contain;
  border-radius: 10px;
}

.site-main {
  flex: 1;
  width: 100%;
  margin: 0 auto;
  padding: 2.25rem 1rem 3.5rem;
}

.site-main__inner {
  max-width: var(--maxw);
  margin: 0 auto;
}

.site-main h1 {
  font-family: var(--font-display);
  font-size: clamp(1.65rem, 4vw, 2.15rem);
  font-weight: 700;
  color: var(--accent);
  margin-top: 0;
  margin-bottom: 1.25rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.site-main h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--accent-soft);
  margin-top: 2rem;
  margin-bottom: 0.65rem;
  line-height: 1.3;
}

.site-main h3 {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text);
  margin-top: 1.5rem;
}

.site-main .content {
  background: var(--card);
  border: 1px solid rgba(184, 212, 191, 0.65);
  border-radius: var(--radius-lg);
  box-shadow: var(--card-shadow);
  padding: 2rem 1.75rem 2.25rem;
}

@media (min-width: 640px) {
  .site-main .content {
    padding: 2.5rem 2.5rem 2.75rem;
  }
}

.site-main .content > *:first-child {
  margin-top: 0;
}

.site-main .content p {
  margin: 0 0 1.1em;
  max-width: 62ch;
}

.site-main .content ul,
.site-main .content ol {
  margin: 0 0 1.1em;
  padding-left: 1.35em;
  max-width: 58ch;
}

.site-main .content li {
  margin-bottom: 0.4em;
}

.site-main .content a {
  color: var(--link);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  text-decoration-color: rgba(26, 107, 58, 0.45);
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

.site-main .content a:hover {
  color: var(--link-hover);
  text-decoration-color: var(--link-hover);
}

.site-main .content strong {
  font-weight: 700;
  color: var(--text);
}

.site-main .content .gbv-form-embed {
  margin: 1.75rem 0;
}

.site-main .content .gbv-form-embed > h2 {
  margin-top: 0;
}

.gbv-embed-frame {
  margin: 1rem 0 0;
  border-radius: var(--radius);
  border: 1px solid rgba(184, 212, 191, 0.75);
  background: rgba(255, 255, 255, 0.75);
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(21, 40, 24, 0.08);
}

.gbv-embed-frame__iframe {
  display: block;
  width: 100%;
  height: min(80vh, 980px);
  border: 0;
  background: #fff;
}

.ff-hero {
  max-width: none;
  width: 100%;
  padding: 1.1rem 1.15rem;
  border-radius: var(--radius);
  border: 1px solid rgba(184, 212, 191, 0.75);
  background: linear-gradient(145deg, rgba(232, 240, 234, 0.55) 0%, rgba(255, 255, 255, 0.95) 100%);
  box-shadow: 0 6px 18px rgba(21, 40, 24, 0.08);
  margin: 0 0 1.25rem;
}

.ff-hero__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.2;
}

.ff-hero__subtitle,
.ff-hero__date {
  margin: 0.35rem 0 0;
  color: var(--muted);
}

.ff-form {
  max-width: none;
  width: 100%;
}

.ff-bring {
  margin-top: 1.75rem;
  max-width: none;
  width: 100%;
  border: 1px solid rgba(184, 212, 191, 0.65);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.85);
  padding: 1.1rem 1.15rem;
  box-shadow: 0 4px 14px rgba(21, 40, 24, 0.06);
}

@media (min-width: 820px) {
  /* Festefeiern: Formular auf Desktop als 2-Spalten-Layout */
  .gbv-form-embed--festefeiern .ff-form {
    grid-template-columns: 1fr 1fr;
    max-width: none;
  }

  /* "Ich bringe mit" + Button über volle Breite */
  .gbv-form-embed--festefeiern .ff-form label:nth-of-type(5) {
    grid-column: 1 / -1;
  }

  .gbv-form-embed--festefeiern .ff-form button {
    grid-column: 1 / -1;
    justify-self: start;
  }
}

.ff-bring__title {
  margin-top: 0;
}

.ff-bring__empty {
  margin: 0;
  color: var(--muted);
}

.ff-bring__list {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
  display: grid;
  gap: 0.5rem;
}

.ff-bring__item {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: baseline;
  padding: 0.55rem 0.7rem;
  border-radius: 12px;
  background: #fafcf9;
  border: 1px solid rgba(184, 212, 191, 0.75);
}

.ff-bring__name {
  font-weight: 600;
  color: var(--text);
}

.ff-bring__count {
  font-variant-numeric: tabular-nums;
  color: var(--accent);
  font-weight: 700;
}

.site-main .content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: 0 4px 16px rgba(21, 40, 24, 0.08);
}

.site-footer {
  margin-top: auto;
  background: linear-gradient(180deg, rgba(232, 240, 234, 0.6) 0%, rgba(220, 232, 224, 0.95) 100%);
  border-top: 1px solid var(--border);
}

.site-footer__inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 1.35rem 1rem 1.75rem;
}

.site-footer__links {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
}

.site-footer__dot {
  opacity: 0.55;
}

.site-footer a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.site-footer a:hover {
  color: var(--accent-hover);
  border-bottom-color: rgba(30, 92, 50, 0.45);
}

html.cookie-banner--dismissed .cookie-banner {
  display: none;
}

.cookie-banner {
  position: fixed;
  z-index: 100;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0.75rem 1rem calc(0.75rem + env(safe-area-inset-bottom, 0));
  background: rgba(248, 252, 249, 0.97);
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 24px rgba(21, 40, 24, 0.1);
}

.cookie-banner__inner {
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
}

.cookie-banner__text {
  margin: 0;
  flex: 1 1 16rem;
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--muted);
}

.cookie-banner__text strong {
  color: var(--text);
  font-weight: 600;
}

.cookie-banner__text a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.cookie-banner__text a:hover {
  color: var(--accent-hover);
  border-bottom-color: rgba(30, 92, 50, 0.45);
}

.cookie-banner__btn {
  flex-shrink: 0;
  padding: 0.5rem 1.1rem;
  font-size: 0.9rem;
}

.msg {
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  margin-bottom: 1rem;
}

.msg--ok {
  background: #e8f5e9;
  border: 1px solid #a5d6a7;
}

.msg--err {
  background: #ffebee;
  border: 1px solid #ef9a9a;
}

.booking-flash--success {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1.35rem 1.5rem;
  margin-bottom: 1.75rem;
  background: linear-gradient(145deg, #e8f5e9 0%, #c8e6c9 55%, #a5d6a7 100%);
  border: 2px solid #2e7d32;
  border-radius: var(--radius);
  box-shadow: 0 6px 20px rgba(45, 90, 39, 0.18);
}

.booking-flash__check {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  background: #1b5e20;
  color: #fff;
  border-radius: 50%;
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.booking-flash__inner {
  min-width: 0;
}

.booking-flash__title {
  display: block;
  font-size: 1.35rem;
  font-weight: 700;
  color: #1b5e20;
  margin-bottom: 0.4rem;
  letter-spacing: 0.01em;
}

.booking-flash__text {
  margin: 0;
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--text);
  line-height: 1.55;
}

.bewerbung-flash-success {
  max-width: 42rem;
  margin-bottom: 2rem;
}

.bewerbung-flash-success .booking-flash__title {
  font-size: 1.55rem;
}

.bewerbung-flash-success .booking-flash__text {
  font-size: 1.125rem;
  font-weight: 600;
}

@media (max-width: 480px) {
  .booking-flash--success {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

.form-grid {
  display: grid;
  gap: 1rem;
  max-width: 28rem;
}

.form-grid label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-weight: 500;
}

.form-grid input,
.form-grid textarea,
.form-grid select {
  font: inherit;
  padding: 0.55rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fafcf9;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-grid input:focus,
.form-grid textarea:focus,
.form-grid select:focus {
  outline: none;
  border-color: var(--accent-soft);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(47, 125, 68, 0.18);
}

.btn {
  display: inline-block;
  font: inherit;
  font-weight: 600;
  padding: 0.65rem 1.35rem;
  border: none;
  border-radius: 10px;
  background: linear-gradient(180deg, var(--accent-soft) 0%, var(--accent) 100%);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(30, 92, 50, 0.25);
  transition: filter 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.btn:hover {
  filter: brightness(1.05);
  box-shadow: 0 4px 14px rgba(30, 92, 50, 0.3);
}

.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.btn:active {
  transform: translateY(1px);
}

.booking-cal-wrap {
  margin: 1.5rem 0;
}

.booking-cal {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  max-width: 22rem;
}

.booking-cal__title {
  font-weight: 600;
  margin-bottom: 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.booking-cal__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  text-align: center;
  font-size: 0.8125rem;
}

.booking-cal__dow {
  font-weight: 600;
  color: var(--muted);
  padding: 0.25rem;
}

.booking-cal__day {
  padding: 0.4rem;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid transparent;
}

.booking-cal__day:hover:not(.is-disabled):not(.is-empty) {
  background: #e8f5e9;
}

.booking-cal__legend {
  font-size: 0.75rem;
  color: var(--muted);
  margin: 0 0 0.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.booking-cal__legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.booking-cal__legend-item::before {
  content: '';
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 3px;
}

.booking-cal__legend--rented::before {
  background: #c62828;
  border: 1px solid #b71c1c;
}

.booking-cal__legend--pending::before {
  background: #f9a825;
  border: 1px solid #f57f17;
}

.booking-cal__day.is-disabled {
  cursor: not-allowed;
}

.booking-cal__day.is-disabled.is-pending-busy,
.booking-cal__day.is-disabled.is-rented {
  opacity: 1;
  text-decoration: none;
}

.booking-cal__day.is-disabled:not(.is-pending-busy):not(.is-rented) {
  opacity: 0.35;
  text-decoration: line-through;
}

.booking-cal__day.is-rented {
  background: #ffcdd2;
  color: #b71c1c;
  font-weight: 700;
  border-color: #e57373;
}

.booking-cal__day.is-pending-busy {
  background: #fff3e0;
  color: #e65100;
  font-weight: 600;
  border-color: #ffb74d;
}

.booking-cal__day.is-selected {
  background: var(--accent);
  color: #fff;
}

.booking-cal__day.is-in-range {
  background: #c8e6c9;
}

.booking-cal__day.is-empty {
  visibility: hidden;
  pointer-events: none;
}

.booking-range-hint {
  font-size: 0.875rem;
  color: var(--muted);
  margin-top: 0.5rem;
}

@media (max-width: 720px) {
  .site-header__inner {
    grid-template-columns: auto 1fr auto;
    grid-template-rows: auto auto;
  }

  .site-logo--left {
    grid-column: 1;
    grid-row: 1;
  }

  .site-logo--right {
    grid-column: 3;
    grid-row: 1;
  }

  .site-nav {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .site-nav__list {
    justify-content: center;
    row-gap: 0.3rem;
  }

  .site-nav__link {
    font-size: 0.8125rem;
    padding: 0.38rem 0.5rem;
  }

  .site-main {
    padding: 1.5rem 0.85rem 2.5rem;
  }

  .site-main .content {
    padding: 1.35rem 1.15rem 1.6rem;
    border-radius: var(--radius);
  }
}

@media (max-width: 380px) {
  .site-logo img {
    height: 50px;
    max-width: 76px;
  }

  .site-nav__link {
    font-size: 0.78rem;
    padding: 0.32rem 0.4rem;
  }
}
