:root {
  --green: #426f59;
  --green-dark: #2f5745;
  --gold: #c4a45a;
  --gold-soft: #e8dcc0;
  --red: #9a5a62;
  --red-soft: #ead7d9;
  --bg: #f7f6f2;
  --surface: rgba(255, 255, 255, 0.94);
  --text: #1d1d1b;
  --muted: #5f5f5f;
  --border: rgba(66, 111, 89, 0.14);
  --shadow: 0 18px 40px rgba(47, 87, 69, 0.10);
  --radius: 22px;
  --max-width: 1180px;
  --header-height: 82px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
  background:
    linear-gradient(rgba(247, 246, 242, 0.92), rgba(247, 246, 242, 0.96)),
    url("../img/winfridenhaus.jpg") center / cover fixed;
  line-height: 1.65;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--green);
  text-decoration: none;
}

a:hover {
  color: var(--red);
}

.container {
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(66, 111, 89, 0.12);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
}

.topbar-inner {
  min-height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 12px 0;
  position: relative;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  color: inherit;
}

.brand:hover {
  color: inherit;
}

.brand img {
  width: 46px;
  height: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.brand-text {
  min-width: 0;
}

.brand-text strong,
.brand-text span {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-text strong {
  font-size: 1rem;
  color: var(--green-dark);
}

.brand-text span {
  font-size: 0.9rem;
  color: var(--muted);
}

.menu-toggle {
  display: none;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(66, 111, 89, 0.14);
  background: #fff;
  border-radius: 14px;
  padding: 0;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.05);
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  background: var(--green-dark);
  border-radius: 999px;
  transition: 0.2s ease;
}

.menu-toggle.is-active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle.is-active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.is-active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  align-items: center;
}

.nav a {
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 600;
  color: var(--green-dark);
  transition: 0.2s ease;
}

.nav a:hover {
  background: rgba(196, 164, 90, 0.12);
  color: var(--green-dark);
  transform: translateY(-1px);
}

.nav .social {
  padding: 8px;
  background: rgba(154, 90, 98, 0.08);
}

.nav .social svg {
  width: 18px;
  height: 18px;
  display: block;
  fill: var(--red);
}

.nav .social-instagram:hover svg {
  fill: var(--red);
}

.hero {
  padding: 56px 0 24px;
}

.hero-card {
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  background:
    linear-gradient(135deg, rgba(47, 87, 69, 0.88), rgba(66, 111, 89, 0.80) 42%, rgba(154, 90, 98, 0.62) 100%),
    url("../img/winfridenhaus.jpg") center / cover;
  box-shadow: var(--shadow);
  min-height: 470px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: stretch;
}

.hero-content {
  padding: 56px;
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  max-width: 100%;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.hero h1 {
  margin: 0;
  font-size: clamp(2.2rem, 5vw, 4.5rem);
  line-height: 1.05;
}

.hero h2 {
  margin: 0;
  font-size: clamp(1.05rem, 2vw, 1.45rem);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
}

.hero p {
  margin: 0;
  font-size: 1.04rem;
  max-width: 60ch;
  color: rgba(255, 255, 255, 0.92);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 8px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  padding: 14px 18px;
  font-weight: 700;
  transition: 0.2s ease;
  border: 1px solid transparent;
  text-align: center;
}

.button.primary {
  background: var(--gold);
  color: #1d1d1b;
}

.button.primary:hover {
  background: #cfb06b;
  color: #1d1d1b;
  transform: translateY(-1px);
}

.button.secondary {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.24);
}

.button.secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  transform: translateY(-1px);
}

.hero-side {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 36px;
}

.crest-card {
  background: rgba(255, 255, 255, 0.94);
  border-radius: 28px;
  padding: 28px;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.14);
  width: min(320px, 100%);
}

.crest-card img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

main {
  padding-bottom: 72px;
}

section {
  scroll-margin-top: calc(var(--header-height) + 18px);
  margin-top: 28px;
}

.section-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 26px 28px 14px;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(1.45rem, 2.5vw, 2.1rem);
  color: var(--green-dark);
  line-height: 1.15;
}

.section-head .badge {
  flex-shrink: 0;
  font-size: 0.85rem;
  font-weight: 800;
  color: #6f4d26;
  background: linear-gradient(90deg, rgba(66, 111, 89, 0.12), rgba(196, 164, 90, 0.18), rgba(154, 90, 98, 0.12));
  border: 1px solid rgba(196, 164, 90, 0.18);
  border-radius: 999px;
  padding: 9px 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.section-body {
  padding: 0 28px 28px;
}

.intro-text {
  font-size: 1.04rem;
  color: #2a2a2a;
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 26px 0;
}

.principle-card {
  background: linear-gradient(180deg, #fff, #faf8f0);
  border: 1px solid rgba(196, 164, 90, 0.20);
  border-radius: 20px;
  padding: 22px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.04);
}

.principle-card img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  margin-bottom: 14px;
}

.principle-card h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
  color: var(--green-dark);
}

.subtopic {
  margin: 26px 0 10px;
  padding: 18px 20px;
  border-left: 5px solid rgba(66, 111, 89, 0.55);
  background: linear-gradient(90deg, rgba(232, 220, 192, 0.24), rgba(255, 255, 255, 0.84));
  border-radius: 0 18px 18px 0;
}

.subtopic h3 {
  margin: 0 0 10px;
  color: #7f5b31;
  font-size: 1.05rem;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.gallery figure {
  margin: 0;
  border-radius: 20px;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--border);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.06);
}

.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4 / 3;
}

.gallery-tall img {
  aspect-ratio: 215 / 250;
}

.zimmer-highlight {
  border: 1px solid rgba(196, 164, 90, 0.24);
  background: linear-gradient(135deg, rgba(66, 111, 89, 0.06), rgba(196, 164, 90, 0.10), rgba(154, 90, 98, 0.05));
  border-radius: 22px;
  padding: 22px;
  margin-bottom: 22px;
  text-align: center;
  font-size: 1.06rem;
}

.zimmer-highlight strong {
  color: var(--green-dark);
}

.program-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.legend-item {
  padding: 10px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
  font-size: 0.95rem;
}

.program-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.month-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 20px;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.04);
}

.month-card h3 {
  margin: 0 0 14px;
  color: var(--green-dark);
  font-size: 1.2rem;
  padding-bottom: 10px;
  border-bottom: 2px solid rgba(196, 164, 90, 0.28);
}

.event-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.event-item {
  background: linear-gradient(180deg, #fff, #fcfbf7);
  border: 1px solid rgba(66, 111, 89, 0.10);
  border-radius: 16px;
  padding: 14px 14px 12px;
}

.event-date {
  display: inline-block;
  margin-bottom: 8px;
  font-weight: 800;
  color: #7f5b31;
}

.event-text {
  color: #2b2b2b;
}

.stiftungsfest,
.fuchsenstunden {
  margin-top: 22px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 22px;
}

.stiftungsfest {
  border-left: 6px solid rgba(196, 164, 90, 0.55);
}

.fuchsenstunden {
  border-left: 6px solid rgba(66, 111, 89, 0.55);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 18px;
}

.contact-card,
.impressum-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 22px;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.04);
}

.contact-card h3,
.impressum-card h3 {
  margin-top: 0;
  color: var(--green-dark);
}

.contact-card strong {
  color: #7f5b31;
}

.board-list {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.board-list div {
  padding: 10px 12px;
  border-radius: 14px;
  background: #faf9f5;
  border: 1px solid rgba(196, 164, 90, 0.20);
  overflow-wrap: anywhere;
}

.verband-logos {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.verband-item {
  text-align: center;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 18px 12px;
  transition: 0.2s ease;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.04);
}

.verband-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 28px rgba(0, 0, 0, 0.08);
}

.verband-item img {
  width: 100px;
  height: 100px;
  object-fit: contain;
  margin: 0 auto 12px;
}

footer {
  padding: 28px 0 56px;
  color: var(--muted);
  text-align: center;
  font-size: 0.95rem;
}

@media (max-width: 1080px) {
  .hero-card,
  .contact-grid,
  .program-grid,
  .principles {
    grid-template-columns: 1fr;
  }

  .verband-logos {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-side {
    padding-top: 0;
  }

  .crest-card {
    max-width: 260px;
  }
}

@media (max-width: 760px) {
  :root {
    --header-height: 72px;
  }

  body {
    background:
      linear-gradient(rgba(247, 246, 242, 0.96), rgba(247, 246, 242, 0.98)),
      url("../img/winfridenhaus.jpg") center top / cover no-repeat fixed;
  }

  .container {
    width: min(var(--max-width), calc(100% - 20px));
  }

  .topbar-inner {
    min-height: 72px;
    padding: 10px 0;
  }

  .brand img {
    width: 40px;
  }

  .brand-text strong {
    font-size: 0.95rem;
  }

  .brand-text span {
    font-size: 0.82rem;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .nav {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    left: 0;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(66, 111, 89, 0.12);
    border-radius: 18px;
    box-shadow: 0 18px 34px rgba(0, 0, 0, 0.1);
    padding: 14px;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .nav.nav-open {
    display: flex;
  }

  .nav a {
    width: 100%;
    padding: 12px 14px;
    border-radius: 14px;
    background: #faf9f5;
  }

  .nav .social {
    display: inline-flex;
    justify-content: center;
    align-items: center;
  }

  .hero {
    padding-top: 24px;
  }

  .hero-card {
    border-radius: 24px;
    min-height: auto;
  }

  .hero-content,
  .hero-side,
  .section-head,
  .section-body {
    padding-left: 18px;
    padding-right: 18px;
  }

  .hero-content {
    padding-top: 28px;
    padding-bottom: 22px;
  }

  .hero-kicker {
    font-size: 0.82rem;
    line-height: 1.2;
  }

  .hero-actions {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
    padding-top: 22px;
  }

  .section-head .badge {
    font-size: 0.78rem;
  }

  .gallery,
  .verband-logos {
    grid-template-columns: 1fr;
  }

  .subtopic {
    padding: 16px;
  }

  .month-card,
  .event-item,
  .contact-card,
  .impressum-card,
  .stiftungsfest,
  .fuchsenstunden,
  .principle-card {
    padding: 16px;
  }

  .event-text,
  .board-list div,
  .impressum-card p,
  .contact-card p,
  .section-body p {
    overflow-wrap: anywhere;
  }
}

@media (max-width: 420px) {
  .hero h1 {
    font-size: 1.95rem;
  }

  .hero h2 {
    font-size: 1rem;
  }

  .section-head h2 {
    font-size: 1.3rem;
  }

  .legend-item {
    width: 100%;
    text-align: center;
  }
}