/*
Theme Name: Bogentenne Starter
Theme URI: https://example.com/
Author: OpenAI
Author URI: https://openai.com/
Description: Individuelles WordPress-Theme für die Bogentenne Startseite und zwei Unterseiten mit Gutenberg-kompatiblem Inhaltsbereich.
Version: 0.1.26
Requires at least: 6.4
Tested up to: 6.8
Requires PHP: 8.0
Text Domain: bogentenne-starter
*/

:root {
  --bt-purple: #440077;
  --bt-purple-dark: #440077;
  --bt-text: #2f2435;
  --bt-white: #ffffff;
  --bt-panel: rgba(255, 255, 255, 0.78);
  --bt-panel-strong: rgba(255, 255, 255, 0.88);
  --bt-accent: #440077;
  --bt-front-bg-image: url("assets/images/startseite-bg.jpg");
  --bt-subpage-bg-image: url("assets/images/unterseite-bg.jpg");
  --bt-bogenschiessen-image: url("assets/images/startseite-bg.jpg");
  --bt-gaestehaeuschen-image: url("assets/images/unterseite-bg.jpg");
  --bt-shadow: 0 18px 40px rgba(49, 30, 56, 0.18);
  --bt-radius-xl: 24px;
  --bt-radius-lg: 16px;
  --bt-radius-md: 12px;
  --bt-frame-line: clamp(8px, 0.8vw, 14px);
  --bt-frame-line-double: clamp(16px, 1.6vw, 28px);
  --bt-frame-inner-radius: 14px;
  --bt-layout-gap: clamp(10px, 1vw, 14px);
  --bt-stage-padding: clamp(14px, 1.4vw, 18px);
  --bt-stage-width: 1920px;
  --bt-stage-min-height: min(100vh, 950px);
  --bt-gutter: clamp(20px, 2.2vw, 34px);
  --bt-rail-width: clamp(250px, 20vw, 380px);
  --bt-menu-card-height: clamp(116px, 18vh, 220px);
  --bt-menu-panel-padding-y: clamp(12px, 1vw, 18px);
  --bt-menu-panel-padding-x: clamp(14px, 1.1vw, 22px);
  --bt-menu-heading-size: clamp(1rem, 0.85vw, 1.2rem);
  --bt-menu-text-size: clamp(0.9rem, 0.72vw, 1rem);
  --bt-menu-label-size: clamp(1.1rem, 1.35vw, 2rem);
  --bt-font-body: "Canva Sans", "Aptos", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --bt-font-heading: "Josefin Sans", "Trebuchet MS", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html {
  margin: 0;
  background: var(--bt-purple);
}
body {
  margin: 0;
  padding: var(--bt-frame-line);
  color: var(--bt-text);
  background: var(--bt-purple);
  font-family: var(--bt-font-body);
  line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6,
.entry-title,
.bt-panel h2,
.bt-panel h3,
.bt-nav-card__label {
  font-family: var(--bt-font-heading);
}

img { max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }

.entry-content .wp-block-image img,
.entry-content .wp-block-gallery img,
.entry-content .gallery img {
  cursor: zoom-in;
}

body.admin-bar .bt-site-shell { min-height: calc(100vh - 32px - var(--bt-frame-line-double)); }

.bt-site-shell {
  min-height: calc(100vh - var(--bt-frame-line-double));
  width: 100%;
  padding: 0;
}

@media (min-width: 1280px) {
  .bt-site-shell {
    width: min(100%, var(--bt-stage-width));
    margin: 0 auto;
  }
}

.bt-stage {
  position: relative;
  min-height: calc(var(--bt-stage-min-height) - var(--bt-frame-line-double));
  overflow: hidden;
  background-color: #fff;
  background-position: center center;
  background-repeat: no-repeat;
  background-size: cover;
  border-radius: var(--bt-frame-inner-radius);
}

.bt-stage-image {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.bt-stage--subpage .bt-stage-image {
  object-position: center center;
}

.bt-stage::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.08));
  pointer-events: none;
}

.bt-stage--front {
  background-image: var(--bt-front-bg-image);
}

.bt-stage--subpage {
  background-image: var(--bt-subpage-bg-image);
}

.bt-inner {
  position: relative;
  z-index: 2;
  min-height: var(--bt-stage-min-height);
  padding: var(--bt-stage-padding);
  display: grid;
}

.bt-front-grid {
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(28px, 3vw, 42px);
  align-items: stretch;
}

.bt-brand-area {
  position: relative;
  min-height: 620px;
}

.bt-logo-wrap {
  max-width: 390px;
  padding: 18px 22px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  backdrop-filter: blur(4px);
}

.bt-logo-wrap img {
  display: block;
  width: 100%;
  height: auto;
}

.bt-brand-copy {
  margin-top: 18px;
  max-width: 360px;
  padding: 14px 18px;
  background: rgba(255,255,255,0.58);
  border-radius: 14px;
  backdrop-filter: blur(6px);
  box-shadow: var(--bt-shadow);
}

.bt-brand-copy h1,
.bt-brand-copy p {
  margin: 0;
}

.bt-brand-copy p + p { margin-top: 8px; }

.bt-front-right {
  display: grid;
  align-content: space-between;
  gap: 26px;
}

.bt-card-stack {
  display: grid;
  gap: 22px;
  justify-items: end;
  padding-top: 32px;
}

.bt-nav-card {
  width: min(100%, 330px);
  min-height: 205px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(139, 111, 150, 0.16);
  border-radius: var(--bt-radius-xl);
  box-shadow: var(--bt-shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease, background-color 0.22s ease;
}

.bt-nav-card:hover,
.bt-nav-card:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 24px 48px rgba(49, 30, 56, 0.24);
  background: #ffffff;
}

.bt-nav-card span {
  font-size: clamp(1.6rem, 2vw, 2rem);
  line-height: 1.1;
}

.bt-footer-panels {
  display: grid;
  grid-template-columns: minmax(270px, 360px) minmax(270px, 360px);
  justify-content: end;
  gap: 18px;
  align-items: end;
}

.bt-panel {
  padding: 18px 22px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: var(--bt-radius-lg);
  box-shadow: var(--bt-shadow);
  backdrop-filter: blur(6px);
}

.bt-panel h2,
.bt-panel h3 {
  margin: 0 0 12px;
  font-size: 1.2rem;
  line-height: 1.15;
}

.bt-panel p,
.bt-panel ul {
  margin: 0;
}

.bt-panel ul {
  padding: 0;
  list-style: none;
}

.bt-panel li + li {
  margin-top: 8px;
}

.bt-panel a:hover,
.bt-panel a:focus-visible {
  text-decoration: underline;
}

.bt-subpage-grid {
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
}

.bt-subpage-right {
  width: min(100%, 860px);
  min-height: auto;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 22px;
  padding-top: clamp(36px, 8vh, 96px);
}

.bt-content-panel {
  width: min(100%, 680px);
  padding: clamp(26px, 3vw, 40px);
  background: var(--bt-panel);
  border-radius: 18px;
  box-shadow: var(--bt-shadow);
  backdrop-filter: blur(10px);
}

.bt-content-panel .entry-title {
  margin: 0 0 18px;
  font-size: clamp(2rem, 2.7vw, 3rem);
  line-height: 1.05;
}

.bt-content-panel .entry-content > *:first-child { margin-top: 0; }
.bt-content-panel .entry-content > *:last-child { margin-bottom: 0; }

.bt-contact-button {
  position: static;
  display: inline-flex;
  margin-top: 0;
  padding: 14px 20px;
  border-radius: 16px;
  background: #440077;
  box-shadow: var(--bt-shadow);
  font-size: 1rem;
  color: var(--bt-white);
  border: 2px solid var(--bt-accent);
}

.bt-contact-button:hover,
.bt-contact-button:focus-visible {
  background: #440077;
  transform: translateY(-2px);
}

.entry-content {
  font-size: 1.08rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(68, 0, 119, 0.18) transparent;
}

.entry-content::-webkit-scrollbar {
  width: 6px;
}

.entry-content::-webkit-scrollbar-track {
  background: transparent;
}

.entry-content::-webkit-scrollbar-thumb {
  background: rgba(68, 0, 119, 0.16);
  border-radius: 999px;
  border: 2px solid transparent;
  background-clip: padding-box;
}

.entry-content::-webkit-scrollbar-thumb:hover {
  background: rgba(68, 0, 119, 0.28);
  background-clip: padding-box;
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
  line-height: 1.15;
  color: #38273f;
}

.entry-content .wp-block-button__link,
.wp-block-button__link {
  border-radius: 16px;
  padding: 0.8rem 1.2rem;
}

@media (max-width: 959px) {
  .bt-front-grid,
  .bt-subpage-grid,
  .bt-footer-panels {
    grid-template-columns: 1fr;
  }

  .bt-card-stack,
  .bt-footer-panels {
    justify-items: stretch;
    justify-content: stretch;
  }

  .bt-nav-card,
  .bt-panel,
  .bt-content-panel {
    width: 100%;
  }

  .bt-brand-area,
  .bt-subpage-left,
  .bt-subpage-right {
    min-height: auto;
  }

  .bt-contact-button {
    position: static;
    display: inline-flex;
    margin-top: 18px;
  }
}

@media (max-width: 640px) {
  body {
    padding: 6px;
  }

  .bt-inner {
    padding: var(--bt-stage-padding);
  }

  .bt-nav-card {
    min-height: 150px;
  }

  .bt-nav-card span {
    font-size: 1.35rem;
  }

  .bt-content-panel .entry-title {
    font-size: 2rem;
  }
}

.bt-front-grid {
  grid-template-columns: minmax(0, 1fr) minmax(360px, 460px);
}

.bt-brand-area {
  min-height: 720px;
}

.bt-brand-copy {
  margin-top: auto;
  margin-bottom: 24px;
  background: rgba(255, 255, 255, 0.72);
}

.bt-front-right {
  align-content: start;
  justify-items: end;
  gap: 22px;
}

.bt-content-panel {
  width: min(100%, 760px);
  padding: clamp(30px, 3.2vw, 46px);
  background: rgba(255, 255, 255, 0.72);
  border: 2px solid rgba(68, 0, 119, 0.18);
}

.bt-content-panel--front {
  width: min(100%, 420px);
  justify-self: end;
  background: rgba(255, 255, 255, 0.68);
}

.bt-content-panel--front .entry-title {
  font-size: clamp(1.8rem, 2.4vw, 2.5rem);
}

.bt-card-stack {
  width: min(100%, 420px);
  justify-items: stretch;
  padding-top: 0;
}

.bt-card-stack > * {
  width: 100%;
}

.bt-nav-card,
.bt-panel {
  border: 2px solid var(--bt-accent);
}

.bt-nav-card {
  position: relative;
  min-height: var(--bt-menu-card-height);
  overflow: hidden;
  justify-content: center;
  text-align: center;
  background-color: rgba(255, 255, 255, 0.25);
}

.bt-nav-card__image {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.bt-nav-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(35, 20, 41, 0.02) 0%, rgba(35, 20, 41, 0.12) 58%, rgba(35, 20, 41, 0.36) 100%);
  pointer-events: none;
}

.bt-nav-card__label {
  position: absolute;
  right: 18px;
  bottom: 18px;
  z-index: 2;
  color: #ffffff;
  font-size: var(--bt-menu-label-size);
  font-weight: 700;
  line-height: 1.05;
  text-align: right;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.42);
}

.bt-panel--accent {
  background: #440077;
  color: var(--bt-white);
}

.bt-panel--accent a {
  color: var(--bt-white);
}

.bt-panel--accent a:hover,
.bt-panel--accent a:focus-visible {
  text-decoration: underline;
}

.bt-stage--subpage .bt-content-panel {
  width: 100%;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(68, 0, 119, 0.16);
  backdrop-filter: none;
}

body.bt-lightbox-open {
  overflow: hidden;
}

.bt-lightbox {
  --bt-lightbox-edge-gap: clamp(10px, 1.2vw, 18px);
  --bt-lightbox-side-clearance: clamp(72px, 5vw, 96px);
  --bt-lightbox-top-clearance: clamp(74px, 6vw, 104px);
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--bt-lightbox-edge-gap);
  background: rgba(20, 10, 29, 0.82);
  backdrop-filter: blur(8px);
}

.bt-lightbox[hidden] {
  display: none;
}

.bt-lightbox__viewport {
  position: relative;
  width: min(100%, 1600px);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bt-lightbox__figure {
  margin: 0;
  width: 100%;
  max-width: 100%;
  max-height: 100%;
  display: grid;
  gap: 14px;
  justify-items: center;
  align-content: center;
}

.bt-lightbox__image {
  display: block;
  max-width: min(calc(100vw - (var(--bt-lightbox-edge-gap) * 2) - var(--bt-lightbox-side-clearance)), 1520px);
  max-height: calc(100vh - (var(--bt-lightbox-edge-gap) * 2) - var(--bt-lightbox-top-clearance));
  width: auto;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.35);
}

.bt-lightbox__caption {
  max-width: min(90vw, 900px);
  color: #ffffff;
  text-align: center;
  font-size: 0.98rem;
}

.bt-lightbox__button {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 46px;
  min-height: 46px;
  padding: 0 14px;
  border: 0;
  border-radius: 14px;
  background: rgba(68, 0, 119, 0.92);
  color: #ffffff;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28);
  cursor: pointer;
  font: inherit;
  transition: transform 0.18s ease, background-color 0.18s ease;
}

.bt-lightbox__button:hover,
.bt-lightbox__button:focus-visible {
  background: rgba(87, 11, 145, 0.96);
  transform: translateY(-1px);
}

.bt-lightbox__button--close {
  top: clamp(12px, 2vw, 22px);
  right: clamp(12px, 2vw, 22px);
  font-size: 1.4rem;
  line-height: 1;
}

.bt-lightbox__button--prev,
.bt-lightbox__button--next {
  top: 50%;
  width: 52px;
  min-width: 52px;
  padding: 0;
  transform: translateY(-50%);
  font-size: 1.55rem;
  line-height: 1;
}

.bt-lightbox__button--prev {
  left: clamp(8px, 1.2vw, 16px);
}

.bt-lightbox__button--next {
  right: clamp(8px, 1.2vw, 16px);
}

.bt-lightbox__button--hidden {
  display: none;
}

.bt-stage--subpage .bt-contact-button {
  justify-self: center;
}

@media (max-width: 959px) {
  .bt-front-grid,
  .bt-subpage-grid {
    grid-template-columns: 1fr;
  }

  .bt-brand-area {
    min-height: 340px;
  }

  .bt-front-right,
  .bt-subpage-right {
    justify-items: stretch;
    padding-top: 0;
  }

  .bt-content-panel,
  .bt-content-panel--front,
  .bt-card-stack {
    width: 100%;
  }

  .bt-lightbox {
    --bt-lightbox-edge-gap: 10px;
    --bt-lightbox-side-clearance: 20px;
    --bt-lightbox-top-clearance: 110px;
    padding: var(--bt-lightbox-edge-gap);
  }

  .bt-lightbox__viewport {
    width: 100%;
    height: 100%;
  }

  .bt-lightbox__image {
    max-width: calc(100vw - (var(--bt-lightbox-edge-gap) * 2) - var(--bt-lightbox-side-clearance));
    max-height: calc(100vh - (var(--bt-lightbox-edge-gap) * 2) - var(--bt-lightbox-top-clearance));
    border-radius: 10px;
  }

  .bt-lightbox__button--prev,
  .bt-lightbox__button--next {
    bottom: 12px;
    top: auto;
    transform: none;
  }

  .bt-lightbox__button--prev {
    left: 12px;
  }

  .bt-lightbox__button--next {
    right: 12px;
  }
}

.bt-front-grid {
  grid-template-columns: minmax(0, 1fr);
}

.bt-front-right {
  width: 100%;
  margin-left: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--bt-rail-width);
  grid-template-areas:
    "content top"
    "content info";
  gap: var(--bt-layout-gap);
  align-content: start;
  align-items: start;
  justify-items: stretch;
}

.bt-front-right--menu-only {
  grid-template-areas:
    ". top"
    ". info";
}

.bt-top-cards {
  grid-area: top;
  display: grid;
  gap: var(--bt-layout-gap);
}

.bt-content-panel--front {
  grid-area: content;
  width: 100%;
  max-width: none;
  margin: 0;
  justify-self: start;
  background: rgba(255, 255, 255, 0.72);
}

.bt-info-stack {
  grid-area: info;
  display: grid;
  gap: var(--bt-layout-gap);
}

.bt-info-stack .bt-panel,
.bt-subpage-sidebar .bt-panel {
  padding: var(--bt-menu-panel-padding-y) var(--bt-menu-panel-padding-x);
}

.bt-info-stack .bt-panel h2,
.bt-info-stack .bt-panel h3,
.bt-subpage-sidebar .bt-panel h2,
.bt-subpage-sidebar .bt-panel h3 {
  margin-bottom: clamp(8px, 0.8vw, 12px);
  font-size: var(--bt-menu-heading-size);
}

.bt-info-stack .bt-panel p,
.bt-info-stack .bt-panel li,
.bt-info-stack .bt-panel a,
.bt-subpage-sidebar .bt-panel p,
.bt-subpage-sidebar .bt-panel li,
.bt-subpage-sidebar .bt-panel a {
  font-size: var(--bt-menu-text-size);
  line-height: 1.45;
}

.bt-info-stack .bt-panel li + li,
.bt-subpage-sidebar .bt-panel li + li {
  margin-top: clamp(4px, 0.45vw, 8px);
}

.bt-top-cards > *,
.bt-info-stack > * {
  width: 100%;
}

.bt-brand-area,
.bt-brand-copy,
.bt-logo-wrap {
  display: none;
}

@media (max-width: 959px) {
  .bt-front-right {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: var(--bt-layout-gap);
  }

  .bt-top-cards,
  .bt-info-stack {
    width: 100%;
    gap: var(--bt-layout-gap);
  }

  .bt-top-cards,
  .bt-content-panel--front,
  .bt-info-stack {
    grid-area: auto;
    order: initial;
  }

  .bt-top-cards {
    order: 1;
  }

  .bt-content-panel--front {
    order: 2;
  }

  .bt-info-stack {
    order: 3;
  }

  .bt-content-panel--front,
  .bt-top-cards,
  .bt-info-stack,
  .bt-top-cards > *,
  .bt-info-stack > * {
    width: 100%;
    max-width: none;
  }

  .bt-nav-card {
    width: 100%;
    min-height: 170px;
  }
}

.bt-subpage-grid {
  grid-template-columns: minmax(0, 1fr) var(--bt-rail-width);
  gap: var(--bt-layout-gap);
  align-items: start;
  justify-items: stretch;
}

.bt-content-panel--subpage {
  width: 100%;
  max-width: none;
  justify-self: start;
}

.bt-subpage-sidebar {
  width: 100%;
  max-width: var(--bt-rail-width);
  justify-self: end;
  display: grid;
  gap: var(--bt-layout-gap);
}

.bt-subpage-sidebar .bt-top-cards,
.bt-subpage-sidebar .bt-info-stack {
  grid-area: auto;
}

.bt-stage--subpage .bt-top-cards,
.bt-stage--subpage .bt-info-stack {
  width: 100%;
}

.bt-stage--subpage .bt-top-cards > *,
.bt-stage--subpage .bt-info-stack > * {
  width: 100%;
}

.bt-nav-card--current {
  box-shadow: 0 0 0 3px rgba(68, 0, 119, 0.25);
}

@media (max-width: 959px) {
  .bt-subpage-grid {
    grid-template-columns: 1fr;
    gap: var(--bt-layout-gap);
  }

  .bt-content-panel--subpage,
  .bt-subpage-sidebar {
    width: 100%;
    max-width: none;
    justify-self: stretch;
  }

  .bt-subpage-sidebar {
    gap: var(--bt-layout-gap);
  }
}

@media (min-width: 960px) {
  body.is-bt-front-page,
  body.is-bt-subpage {
    overflow: hidden;
  }

  body.is-bt-front-page .bt-site-shell,
  body.is-bt-subpage .bt-site-shell {
    height: calc(100vh - var(--bt-frame-line-double));
    min-height: calc(100vh - var(--bt-frame-line-double));
  }

  body.admin-bar.is-bt-front-page .bt-site-shell,
  body.admin-bar.is-bt-subpage .bt-site-shell {
    height: calc(100vh - 32px - var(--bt-frame-line-double));
    min-height: calc(100vh - 32px - var(--bt-frame-line-double));
  }

  body.is-bt-front-page .bt-stage,
  body.is-bt-subpage .bt-stage,
  body.is-bt-front-page .bt-inner,
  body.is-bt-subpage .bt-inner,
  body.is-bt-front-page .bt-front-right,
  body.is-bt-subpage .bt-subpage-grid {
    height: 100%;
    min-height: 0;
  }

  body.is-bt-front-page .bt-front-right,
  body.is-bt-subpage .bt-subpage-grid {
    align-content: stretch;
  }

  body.is-bt-front-page .bt-content-panel--front,
  body.is-bt-subpage .bt-content-panel--subpage {
    height: 100%;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
  }

  body.is-bt-front-page .bt-content-panel--front .entry-content,
  body.is-bt-subpage .bt-content-panel--subpage .entry-content {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 8px;
    overscroll-behavior: contain;
  }

  body.is-bt-front-page .bt-subpage-sidebar,
  body.is-bt-front-page .bt-top-cards,
  body.is-bt-front-page .bt-info-stack,
  body.is-bt-subpage .bt-subpage-sidebar,
  body.is-bt-subpage .bt-top-cards,
  body.is-bt-subpage .bt-info-stack {
    align-self: start;
  }
}
