:root {
  /* Neutrals */
  --c-bg: #fefcf8;
  --c-text: #1f2937;
  --c-muted: #6b7280;
  --c-border: #e5e7eb;
  --c-card-bg: #ffffff;
  --c-sidebar-bg: #faf5ec;

  /* Brand */
  --c-navy: #0e2648;
  --c-navy-deep: #0a1c38;
  --c-navy-soft: #1b3a63;
  --c-accent: #e07a1f;
  --c-accent-hover: #c85f17;
  --c-accent-soft: #fdead2;
  --c-sky-1: #e9f1fa;
  --c-sky-2: #d4e4f4;

  /* Effects */
  --sh-card: 0 1px 2px rgba(14,38,72,.04), 0 2px 8px rgba(14,38,72,.05);
  --sh-card-lg: 0 4px 16px rgba(14,38,72,.08), 0 12px 32px rgba(14,38,72,.06);
  --sh-header: 0 2px 14px rgba(0,0,0,.15);

  /* Layout */
  --max-w: 1200px;
  --sidebar-w: 300px;
  --gap: 1.5rem;
  --bp-mobile: 860px;

  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Barlow", "Segoe UI", Roboto, sans-serif;

  font-size: 16px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--font-body);
  line-height: 1.6;
  word-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; }

a { color: var(--c-accent); text-decoration: none; }
a:hover { color: var(--c-accent-hover); text-decoration: underline; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.005em;
  color: #111;
}
h1 { font-size: 2.15rem; margin: 0 0 1rem; }
h2 {
  font-size: 1.55rem;
  margin: 2rem 0 .6rem;
  position: relative;
  padding-bottom: .3rem;
}
h2::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 2.2rem; height: 3px;
  background: var(--c-accent);
  border-radius: 2px;
}
h3 { font-size: 1.1rem; margin: 0 0 .6rem; }

p { margin: .4rem 0 .9rem; }

/* ---------- Header ---------- */
.site-header {
  background: linear-gradient(180deg, var(--c-navy-deep) 0%, var(--c-navy) 100%);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--sh-header);
}
.site-header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: .7rem 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: nowrap;
}
.site-header-inner .lang-switch { flex-shrink: 0; }
.site-header-inner .site-brand { flex-shrink: 0; }
.site-header-inner .site-nav { min-width: 0; }
.site-brand {
  display: flex;
  align-items: center;
  gap: .7rem;
  color: #fff;
  font-weight: 600;
  line-height: 1.2;
}
.site-brand:hover { text-decoration: none; color: #fff; }
.site-brand img {
  height: 48px;
  width: auto;
  filter: drop-shadow(0 1px 4px rgba(0,0,0,.25));
}
.site-brand span {
  display: inline-block;
  max-width: 14em;
  line-height: 1.15;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: .005em;
}

/* ---------- Hamburger (mobile only) ---------- */
.nav-toggle {
  display: none;
  margin-left: auto;
  width: 40px; height: 40px;
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 4px;
  background: rgba(255,255,255,.08);
  cursor: pointer;
  padding: 0;
  position: relative;
}
.nav-toggle span {
  position: absolute;
  left: 10px; right: 10px;
  height: 2px;
  background: #fff;
  transition: transform .2s ease, opacity .2s ease, top .2s ease;
}
.nav-toggle span:nth-child(1) { top: 12px; }
.nav-toggle span:nth-child(2) { top: 19px; }
.nav-toggle span:nth-child(3) { top: 26px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { top: 19px; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { top: 19px; transform: rotate(-45deg); }

/* ---------- Language switcher ---------- */
.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  font-size: .85rem;
  font-weight: 600;
  margin-left: .5rem;
}
.lang-switch a,
.lang-switch .lang-current {
  display: inline-block;
  padding: .3rem .55rem;
  border-radius: 4px;
  line-height: 1;
  color: rgba(255,255,255,.75);
  border: 1px solid transparent;
}
.lang-switch a:hover {
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.22);
  color: #fff;
  text-decoration: none;
}
.lang-switch .lang-current {
  background: var(--c-accent);
  color: #fff;
}

/* ---------- Navigation ---------- */
.site-nav { margin-left: auto; }
.site-nav > ul {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  gap: .15rem;
  flex-wrap: wrap;
}
.site-nav > ul > li { position: relative; }
.site-nav a {
  display: block;
  padding: .55rem .85rem;
  color: rgba(255,255,255,.9);
  border-radius: 4px;
  white-space: nowrap;
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: .01em;
  transition: background .15s ease, color .15s ease;
}
.site-nav a:hover,
.site-nav li:hover > a,
.site-nav li:focus-within > a {
  background: rgba(255,255,255,.08);
  color: var(--c-accent);
  text-decoration: none;
}

/* Desktop dropdown */
.site-nav .submenu-toggle { display: none; }
.site-nav .submenu {
  list-style: none;
  margin: 0; padding: .35rem 0;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 230px;
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: 6px;
  box-shadow: 0 10px 30px rgba(14,38,72,.18);
  display: none;
  z-index: 10;
  overflow: hidden;
}
.site-nav li.has-submenu:hover .submenu,
.site-nav li.has-submenu:focus-within .submenu { display: block; }
.site-nav .submenu li { width: 100%; }
.site-nav .submenu a {
  padding: .55rem 1rem;
  border-radius: 0;
  color: var(--c-text);
}
.site-nav .submenu a:hover {
  background: var(--c-accent-soft);
  color: var(--c-accent-hover);
}

/* ---------- Hero (home page) ---------- */
.hero {
  position: relative;
  min-height: 420px;
  height: 58vh;
  max-height: 620px;
  background-size: cover;
  background-position: center 35%;
  color: #fff;
  overflow: hidden;
}
.hero::before {
  /* Warm golden-hour tint on top of the photo */
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(
    135deg,
    rgba(224,122,31,.22) 0%,
    rgba(224,122,31,0) 45%,
    rgba(14,38,72,.0) 55%,
    rgba(14,38,72,.55) 100%
  );
  mix-blend-mode: multiply;
}
.hero::after {
  /* Dark gradient at bottom for legibility of overlaid text */
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(
    180deg,
    rgba(14,38,72,.10) 0%,
    rgba(14,38,72,.10) 40%,
    rgba(14,38,72,.70) 100%
  );
}
.hero-inner {
  position: relative;
  z-index: 1;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 2rem 1rem 2.2rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4.2vw, 3.2rem);
  color: #fff;
  text-shadow: 0 2px 24px rgba(0,0,0,.4);
  margin: 0 0 .4rem;
  line-height: 1.05;
  letter-spacing: -.01em;
}
.hero-title::after { display: none; }
.hero-tagline {
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  color: rgba(255,255,255,.95);
  max-width: 680px;
  text-shadow: 0 1px 10px rgba(0,0,0,.35);
  margin: 0;
}

/* On the home page, pull up content below hero slightly */
.home-content { margin-top: -.5rem; }

/* ---------- Layout ---------- */
.site-layout {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 1.8rem 1rem;
  display: grid;
  grid-template-columns: 1fr var(--sidebar-w);
  gap: var(--gap);
}
.site-main { min-width: 0; }
.site-main > article > h1 { margin-top: 0; }
.site-main > article > h1::after {
  content: "";
  display: block;
  width: 3rem; height: 3px;
  background: var(--c-accent);
  border-radius: 2px;
  margin-top: .5rem;
}

/* Lists inside Vereinsordnung etc. */
.site-main ol li { margin-bottom: .7em; }
.site-main ol li > ul { margin-top: .4em; }

.club-address {
  background: linear-gradient(135deg, #fff8ec 0%, #fdead2 100%);
  border-left: 4px solid var(--c-accent);
  padding: 1rem 1.1rem;
  font-size: .95rem;
  border-radius: 0 6px 6px 0;
}
.signature {
  margin-top: 2rem;
  text-align: right;
  font-style: italic;
  color: var(--c-muted);
}

blockquote {
  margin: 1rem 0;
  padding: .8rem 1.1rem;
  border-left: 4px solid var(--c-accent);
  background: var(--c-accent-soft);
  border-radius: 0 6px 6px 0;
  color: #5c4423;
}
blockquote p { margin: 0; }

/* ---------- Sidebar ---------- */
.site-sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  min-width: 0;
}
.widget {
  background: var(--c-card-bg);
  border: 1px solid var(--c-border);
  border-radius: 10px;
  padding: 1rem;
  box-shadow: var(--sh-card);
}
.widget h3 {
  font-family: var(--font-display);
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--c-navy);
  padding-bottom: .5rem;
  margin-bottom: .8rem;
  position: relative;
}
.widget h3::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 1.8rem; height: 2px;
  background: var(--c-accent);
  border-radius: 2px;
}
.widget .windrose { display: block; margin: 0 auto; max-width: 100%; }
.widget .calendar {
  width: 100%;
  height: 360px;
  border: 0;
  border-radius: 6px;
}
.widget .thumbs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.widget .thumbs a { line-height: 0; }
.widget .thumbs img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 6px;
  transition: transform .2s ease;
}
.widget .thumbs a:hover img { transform: scale(1.04); }

/* ---------- Gallery shortcode ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  margin: 1rem 0;
}
.gallery a { line-height: 0; }
.gallery img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 6px;
  transition: transform .2s ease, box-shadow .2s ease;
  box-shadow: var(--sh-card);
}
.gallery a:hover img {
  transform: scale(1.03);
  box-shadow: var(--sh-card-lg);
}

/* ---------- Gallery index (fotogallerie section) ---------- */
.gallery-index {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
  margin: 1.5rem 0;
}
.gallery-index-item {
  display: block;
  text-decoration: none;
  color: inherit;
  line-height: 0;
  border-radius: 10px;
  overflow: hidden;
  background: var(--c-card-bg);
  border: 1px solid var(--c-border);
  box-shadow: var(--sh-card);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.gallery-index-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--sh-card-lg);
  border-color: var(--c-accent);
}
.gallery-index-item img,
.gallery-index-placeholder {
  display: block;
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform .3s ease;
}
.gallery-index-placeholder {
  background: linear-gradient(135deg, var(--c-sky-1), var(--c-sky-2));
}
.gallery-index-item:hover img { transform: scale(1.04); }
.gallery-index-title {
  display: block;
  line-height: 1.3;
  padding: .7rem .85rem .85rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .98rem;
  color: var(--c-navy);
  background: #fff;
}

/* ---------- Webcam password gate ---------- */
.webcam-gate {
  max-width: 420px;
  margin: 2rem auto;
  padding: 1.4rem 1.3rem;
  background: linear-gradient(180deg, #fff 0%, var(--c-sidebar-bg) 100%);
  border: 1px solid var(--c-border);
  border-radius: 10px;
  box-shadow: var(--sh-card);
}
.webcam-gate p { margin: 0 0 .9rem; }
.webcam-gate-form {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  align-items: center;
}
.webcam-gate-form label {
  flex-basis: 100%;
  font-size: .85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--c-muted);
}
.webcam-gate-form input {
  flex: 1 1 160px;
  padding: .6rem .75rem;
  border: 1px solid var(--c-border);
  border-radius: 6px;
  font: inherit;
  background: #fff;
}
.webcam-gate-form input:focus {
  outline: none;
  border-color: var(--c-accent);
  box-shadow: 0 0 0 3px rgba(224,122,31,.2);
}
.webcam-gate-form button {
  padding: .6rem 1.1rem;
  border: 0;
  border-radius: 6px;
  background: var(--c-accent);
  color: #fff;
  font: inherit;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: .02em;
  cursor: pointer;
  transition: background .15s ease, transform .1s ease;
}
.webcam-gate-form button:hover {
  background: var(--c-accent-hover);
  transform: translateY(-1px);
}
.webcam-gate-error {
  flex-basis: 100%;
  margin: .2rem 0 0 !important;
  color: #b00020;
  font-size: .9rem;
}

/* ---------- WP-migrated content ---------- */
figure.wp-block-image { margin: 1rem 0; }
figure.wp-block-image img {
  border-radius: 8px;
  box-shadow: var(--sh-card);
}
figure.wp-block-image figcaption { color: var(--c-muted); font-size: .9rem; }
figure.alignleft { float: left; margin: 0 1rem 1rem 0; max-width: 50%; }
main iframe { max-width: 100%; border-radius: 6px; }

/* ---------- Image viewer (zoom / pan overlay) ---------- */
body.viewer-open { overflow: hidden; }
.viewer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 17, 28, .94);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  touch-action: none;
}
.viewer[hidden] { display: none; }
.viewer-stage {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.viewer-image {
  max-width: 95vw;
  max-height: 95vh;
  width: auto;
  height: auto;
  object-fit: contain;
  transform-origin: center center;
  cursor: grab;
  user-select: none;
  -webkit-user-drag: none;
  touch-action: none;
  will-change: transform;
}
.viewer-image:active { cursor: grabbing; }
.viewer-btn {
  position: absolute;
  background: rgba(255, 255, 255, .08);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .18);
  width: 44px;
  height: 44px;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  border-radius: 50%;
  z-index: 2;
  transition: background .15s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.viewer-btn:hover,
.viewer-btn:focus {
  background: var(--c-accent);
  border-color: var(--c-accent);
  outline: none;
}
.viewer-close { top: 1rem; right: 1rem; font-size: 1.5rem; }
.viewer-prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.viewer-next { right: 1rem; top: 50%; transform: translateY(-50%); }
.viewer-caption {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  max-width: 80vw;
  padding: .4rem .9rem;
  background: rgba(0, 0, 0, .4);
  color: rgba(255, 255, 255, .9);
  border-radius: 20px;
  font-size: .9rem;
  pointer-events: none;
  z-index: 2;
}
.viewer-caption[hidden] { display: none; }

@media (max-width: 600px) {
  .viewer-btn { width: 40px; height: 40px; }
  .viewer-close { top: .5rem; right: .5rem; }
  .viewer-prev { left: .5rem; }
  .viewer-next { right: .5rem; }
  .viewer-caption { bottom: .5rem; font-size: .85rem; }
}

/* ---------- Random gallery (page footer band) ---------- */
.random-gallery {
  max-width: var(--max-w);
  margin: 2rem auto 0;
  padding: 1.5rem 1rem 1rem;
  border-top: 1px solid var(--c-border);
}
.random-gallery h2 {
  margin: 0 0 1rem;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--c-navy);
}
.random-gallery h2::after {
  width: 2rem;
  height: 2px;
}
.random-gallery-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
  min-height: 90px;
}
.random-gallery-grid a { line-height: 0; display: block; }
.random-gallery-grid img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 6px;
  box-shadow: var(--sh-card);
  transition: transform .2s ease, box-shadow .2s ease;
}
.random-gallery-grid a:hover img {
  transform: translateY(-2px) scale(1.02);
  box-shadow: var(--sh-card-lg);
}

@media (max-width: 860px) {
  .random-gallery-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 480px) {
  .random-gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Footer ---------- */
.site-footer {
  background: linear-gradient(180deg, var(--c-navy) 0%, var(--c-navy-deep) 100%);
  color: rgba(255,255,255,.7);
  margin-top: 3rem;
  padding: 2rem 1rem;
  text-align: center;
  font-size: .9rem;
  border-top: 3px solid var(--c-accent);
}
.site-footer p { max-width: var(--max-w); margin: 0 auto; }

/* ---------- Responsive: tablet/mobile ---------- */
@media (max-width: 1000px) {
  .site-layout { grid-template-columns: 1fr 260px; }
}

@media (max-width: 860px) {
  .site-header-inner { flex-wrap: nowrap; }
  .site-brand span { display: none; }

  .lang-switch { order: 1; margin-left: auto; font-size: .8rem; }
  .nav-toggle { order: 2; margin-left: .3rem; display: block; }
  .site-nav { order: 3; }

  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: #fff;
    color: var(--c-text);
    border-bottom: 1px solid var(--c-border);
    box-shadow: 0 10px 24px rgba(14,38,72,.18);
    margin-left: 0;
  }
  .site-nav.is-open { display: block; }
  .site-nav > ul {
    flex-direction: column;
    gap: 0;
    padding: .4rem 0;
  }
  .site-nav > ul > li { width: 100%; }
  .site-nav a {
    padding: .8rem 1rem;
    color: var(--c-text);
  }
  .site-nav a:hover {
    background: var(--c-sidebar-bg);
    color: var(--c-accent);
  }

  .site-nav .submenu-toggle {
    display: inline-block;
    position: absolute;
    top: .3rem;
    right: .3rem;
    width: 40px; height: 40px;
    background: transparent;
    border: 0;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--c-muted);
  }
  .site-nav .submenu {
    position: static;
    display: none;
    box-shadow: none;
    border: 0;
    background: var(--c-sidebar-bg);
    padding: 0;
    border-radius: 0;
  }
  .site-nav li.has-submenu.is-open .submenu { display: block; }
  .site-nav .submenu a { padding-left: 2rem; }

  .site-layout {
    grid-template-columns: 1fr;
    padding: 1rem;
  }
  .site-sidebar { order: 2; }
  .site-main { order: 1; }

  .hero {
    min-height: 320px;
    height: 46vh;
  }

  h1 { font-size: 1.7rem; }
  h2 { font-size: 1.25rem; }
  figure.alignleft { float: none; margin: 1rem 0; max-width: 100%; }
}

@media (max-width: 480px) {
  :root { font-size: 15px; }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .gallery img { height: 140px; }
  .gallery-index { grid-template-columns: repeat(2, 1fr); }
  .gallery-index-item img,
  .gallery-index-placeholder { height: 140px; }
  .site-brand img { height: 40px; }
  .hero { min-height: 280px; height: 42vh; }
}
