/* ==========================================================================
   KASTRO Obsidian Kinetic Theme Stylesheet
   Pure, ultra-fast modern CSS driven by CSS custom properties. Zero bloat.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. RESET & BASE
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background-color: var(--color-bg, #edebe6);
  color: var(--color-body, #475569);
  font-family: var(--font-body, 'Plus Jakarta Sans', sans-serif);
  font-size: var(--size-body, 15px);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

::selection {
  background-color: rgba(0, 128, 255, 0.3);
  color: #ffffff;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: #08090d;
}
::-webkit-scrollbar-thumb {
  background: #1c2233;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary, #0080ff);
}

img, svg, video {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: all 0.2s ease;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
}

/* --------------------------------------------------------------------------
   2. TYPOGRAPHY
   -------------------------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading, 'Rubik', sans-serif);
  color: var(--color-heading, #ffffff);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h1 { font-size: var(--size-h1, 44px); }
h2 { font-size: var(--size-h2, 34px); }
h3 { font-size: var(--size-h3, 24px); }
h4 { font-size: var(--size-h4, 20px); }
h5 { font-size: var(--size-h5, 18px); }
h6 { font-size: var(--size-h6, 16px); }

.display-hero {
  font-size: clamp(34px, 5.5vw, var(--size-hero, 64px));
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.text-gradient {
  background: linear-gradient(90deg, #60a5fa 0%, #a5b4fc 50%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.lead-text {
  font-size: var(--size-body-lg, 18px);
  color: var(--color-body, #cbd5e1);
  line-height: 1.7;
}

.caption-text {
  font-size: var(--size-body-sm, 13px);
  color: var(--color-muted, #64748b);
}

.tabular-nums {
  font-variant-numeric: tabular-nums;
  font-family: var(--font-mono, monospace);
}

/* --------------------------------------------------------------------------
   3. LAYOUT & CONTAINERS
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

@media (max-width: 640px) {
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

.section-spacing {
  padding-top: 5rem;
  padding-bottom: 5rem;
}

@media (max-width: 768px) {
  .section-spacing {
    padding-top: 3.5rem;
    padding-bottom: 3.5rem;
  }
}

/* --------------------------------------------------------------------------
   4. UI COMPONENTS (Pills, Badges, Buttons, Cards)
   -------------------------------------------------------------------------- */
/* Badges */
.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 1rem;
  border-radius: var(--radius-full, 9999px);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #cbd5e1;
  transition: all 0.25s ease;
}

.badge-pill:hover {
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08);
}

.badge-blue,
.badge-rose,
.badge-amber {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
}

.pulse-dot {
  display: none;
}

@keyframes pulse-glow {
  0% { transform: scale(0.95); opacity: 0.7; }
  50% { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.7; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.75rem;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--radius-full, 9999px);
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary, #0080ff) 0%, #1d4ed8 100%);
  color: #ffffff;
  box-shadow: 0 0 24px rgba(0, 128, 255, 0.35);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 32px rgba(0, 128, 255, 0.55);
  color: #ffffff;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.22);
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-crimson {
  background: linear-gradient(135deg, var(--color-secondary, #dc2626) 0%, #991b1b 100%);
  color: #ffffff;
  box-shadow: 0 0 25px rgba(220, 38, 38, 0.4);
}

.btn-crimson:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 32px rgba(220, 38, 38, 0.6);
  color: #ffffff;
}

.btn-sm {
  padding: 0.55rem 1.25rem;
  font-size: 0.785rem;
}

/* Agency Cards */
.agency-card {
  background: linear-gradient(180deg, #121622 0%, #0d1018 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg, 16px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.agency-card:hover {
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-3px);
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.6), 0 0 30px -10px rgba(0, 128, 255, 0.15);
}

.agency-card-content {
  padding: 2rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Ambient Glow Orbs */
.glow-orb {
  position: absolute;
  pointer-events: none;
  border-radius: 50%;
  filter: blur(80px);
  z-index: 0;
}

.glow-orb-hero {
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 750px;
  height: 400px;
  background: radial-gradient(circle, rgba(0, 128, 255, 0.22) 0%, rgba(220, 38, 38, 0.1) 60%, transparent 80%);
  filter: blur(120px);
}

/* --------------------------------------------------------------------------
   5. HEADER / NAVIGATION
   -------------------------------------------------------------------------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 4.25rem;
  z-index: 990;
  background: rgba(8, 9, 13, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  transition: all 0.25s ease;
}

.site-main {
  margin: 0 !important;
  padding: 0 !important;
}

#hero-section,
#hero-section > section {
  margin-top: 0 !important;
}

body.admin-bar header.sticky,
body.admin-bar header.klimzaal-header,
body.admin-bar .site-header {
  top: 32px !important;
}

body.admin-bar .mobile-nav-drawer {
  top: calc(4.25rem + 32px);
}

body.admin-bar .site-main {
  padding-top: 0 !important;
  margin-top: 0 !important;
}

@media screen and (max-width: 782px) {
  body.admin-bar header.sticky,
  body.admin-bar header.klimzaal-header,
  body.admin-bar .site-header {
    top: 46px !important;
  }
  body.admin-bar .mobile-nav-drawer {
    top: calc(4.25rem + 46px);
  }
  body.admin-bar .site-main {
    padding-top: 0 !important;
    margin-top: 0 !important;
  }
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.logo-text {
  font-size: 1.25rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #ffffff;
}

.logo-tag {
  font-size: 0.685rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full, 9999px);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

@media (max-width: 992px) {
  .header-nav {
    display: none;
  }
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: #cbd5e1;
}

.nav-link:hover {
  color: #ffffff;
}

.mobile-menu-btn {
  display: none;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  color: #ffffff;
  padding: 0.5rem;
  cursor: pointer;
}

@media (max-width: 992px) {
  .mobile-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

.mobile-nav-drawer {
  display: none;
  position: fixed;
  top: 4.25rem;
  left: 0;
  width: 100%;
  background: #08090d;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1.5rem;
  z-index: 989;
  flex-direction: column;
  gap: 1rem;
}

.mobile-nav-drawer.is-open {
  display: flex;
}

/* --------------------------------------------------------------------------
   6. HERO SECTION
   -------------------------------------------------------------------------- */
.kastro-hero {
  position: relative;
  overflow: hidden;
  padding-top: 8rem;
  padding-bottom: 6rem;
  text-align: center;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 2.5rem;
}

/* --------------------------------------------------------------------------
   7. SOCIAL PROOF LOGO BAR
   -------------------------------------------------------------------------- */
.logo-bar-section {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding: 3rem 0;
  text-align: center;
}

.logo-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2.5rem 3.5rem;
  margin-top: 2rem;
}

.logo-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #94a3b8;
  transition: color 0.2s ease;
}

.logo-item:hover {
  color: #ffffff;
}

.logo-item svg {
  color: var(--color-primary, #0080ff);
  width: 1.25rem;
  height: 1.25rem;
}

/* --------------------------------------------------------------------------
   8. SERVICES GRID
   -------------------------------------------------------------------------- */
.services-header {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 3rem;
}

@media (min-width: 768px) {
  .services-header {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}

.cards-grid-3 {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .cards-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.service-icon-box {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: var(--radius-lg, 16px);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.service-feature-list {
  list-style: none;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.service-feature-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.8125rem;
  color: #cbd5e1;
}

.bullet-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.card-footer-link {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* --------------------------------------------------------------------------
   9. PROCESS FLOW (ONZE AANPAK)
   -------------------------------------------------------------------------- */
.process-step-num {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.quote-banner {
  margin-top: 2.5rem;
  padding: 1.75rem 2rem;
  border-radius: var(--radius-lg, 16px);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 640px) {
  .quote-banner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

/* --------------------------------------------------------------------------
   10. MANIFESTO & ROI METRICS
   -------------------------------------------------------------------------- */
.manifesto-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 992px) {
  .manifesto-container {
    grid-template-columns: 1.3fr 1fr;
  }
}

.metrics-subgrid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 1rem;
}

@media (min-width: 640px) {
  .metrics-subgrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.metric-card {
  padding: 1.5rem;
  border-radius: var(--radius-lg, 16px);
  background: #08090d;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.metric-num {
  font-size: 2.5rem;
  font-weight: 900;
  line-height: 1;
}

/* --------------------------------------------------------------------------
   11. DYNAMIC BLOG / POSTS SECTION
   -------------------------------------------------------------------------- */
.post-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.post-thumb-wrap {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #0b0e17;
  overflow: hidden;
  position: relative;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.post-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.post-card:hover .post-thumb-img {
  transform: scale(1.04);
}

.post-body {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.75rem;
  color: var(--color-muted, #64748b);
  margin-bottom: 0.75rem;
}

.post-title {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 0.75rem;
  color: #ffffff;
}

.post-title a:hover {
  color: var(--color-primary, #0080ff);
}

.post-excerpt {
  font-size: 0.875rem;
  color: #94a3b8;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.post-readmore {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-primary, #0080ff);
}

.post-readmore:hover {
  color: #60a5fa;
  transform: translateX(2px);
}

/* --------------------------------------------------------------------------
   12. CONTACT & INTAKE FORM
   -------------------------------------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

@media (min-width: 992px) {
  .contact-grid {
    grid-template-columns: 5fr 7fr;
  }
}

.contact-channel-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-lg, 16px);
  background: #08090d;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.2s ease;
}

.contact-channel-card:hover {
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateX(3px);
}

.form-group {
  margin-bottom: 1rem;
}

.form-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #cbd5e1;
  margin-bottom: 0.5rem;
}

.form-control {
  width: 100%;
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius-full, 9999px);
  background: #0a0d15;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 0.875rem;
  outline: none;
  transition: all 0.2s ease;
}

textarea.form-control {
  border-radius: var(--radius-lg, 16px);
  resize: vertical;
  min-height: 110px;
}

.form-control:focus {
  border-color: var(--color-primary, #0080ff);
  box-shadow: 0 0 0 1px var(--color-primary, #0080ff), 0 0 15px rgba(0, 128, 255, 0.25);
}

.form-control::placeholder {
  color: #64748b;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 640px) {
  .form-grid-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.form-alert {
  padding: 1rem;
  border-radius: var(--radius-lg, 16px);
  background: rgba(6, 78, 59, 0.3);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #6ee7b7;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1rem;
}

/* --------------------------------------------------------------------------
   13. FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
  background: #08090d;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 4rem;
  padding-bottom: 3rem;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 2.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

@media (min-width: 768px) {
  .footer-top-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .footer-top-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}

.footer-heading {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #94a3b8;
  margin-bottom: 1rem;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.footer-links a {
  font-size: 0.8125rem;
  color: #cbd5e1;
}

.footer-links a:hover {
  color: #ffffff;
}

.footer-bottom-bar {
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  font-size: 0.75rem;
  color: #64748b;
}

@media (min-width: 640px) {
  .footer-bottom-bar {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

/* --------------------------------------------------------------------------
   14. FLOATING COOKIE BANNER
   -------------------------------------------------------------------------- */
.cookie-banner {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  max-width: 420px;
  width: calc(100% - 2.5rem);
  z-index: 950;
  background: rgba(15, 18, 26, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1.25rem;
  border-radius: var(--radius-lg, 16px);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

/* --------------------------------------------------------------------------
   15. FRONTEND QUICK EDITOR DOCK (FOR LOGGED IN ADMINS)
   -------------------------------------------------------------------------- */
.kastro-quick-dock {
  position: fixed;
  bottom: 1.25rem;
  left: 1.25rem;
  z-index: 999;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: #0e1224;
  border: 1px solid rgba(0, 128, 255, 0.35);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(0, 128, 255, 0.25);
  padding: 0.4rem 0.6rem;
  border-radius: var(--radius-full, 9999px);
  font-size: 0.75rem;
  font-weight: 600;
  color: #ffffff;
}

.kastro-quick-dock a {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #60a5fa;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-full, 9999px);
  transition: all 0.2s ease;
}

.kastro-quick-dock a:hover {
  background: rgba(0, 128, 255, 0.2);
  color: #ffffff;
}


/* --------------------------------------------------------------------------
   16. IN-PLACE FRONTEND SECTION EDITOR (DRAWER & BUTTONS)
   -------------------------------------------------------------------------- */
.section-editable {
  position: relative;
  transition: outline 0.25s ease, box-shadow 0.25s ease;
}

.kastro-section-edit-btn {
  position: absolute;
  top: 1.5rem;
  right: max(1.5rem, calc((100% - 80rem) / 2 + 2rem));
  z-index: 40;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.85rem;
  background: rgba(18, 22, 31, 0.9);
  border: 1px solid rgba(157, 34, 127, 0.5);
  border-radius: var(--radius-full, 9999px);
  color: #f3a6df;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  transition: all 0.2s ease;
  opacity: 0.7;
}

.section-editable:hover .kastro-section-edit-btn,
.kastro-section-edit-btn:hover {
  opacity: 1;
  background: var(--color-primary, #9d227f);
  border-color: var(--color-primary, #9d227f);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(157, 34, 127, 0.4);
}

/* Standalone Backdrop Overlay: blurs and dims the rest of the website */
.kastro-editor-backdrop {
  position: fixed;
  inset: 0;
  z-index: 9980;
  background: rgba(4, 6, 12, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.kastro-editor-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
}

/* Active Section Being Edited: sharp, focused above blur, illuminated with Manta magenta */
.section-editable.kastro-section-being-edited {
  position: relative !important;
  z-index: 9990 !important;
  outline: 3px solid var(--color-primary, #9d227f) !important;
  outline-offset: 4px;
  box-shadow: 0 0 0 5px rgba(157, 34, 127, 0.35), 0 25px 80px rgba(0, 0, 0, 0.6) !important;
  border-radius: 8px;
  background-color: var(--klimzaal-bg-body, #edebe6);
}

/* Floating pill label indicating the section currently in live focus */
.section-editable.kastro-section-being-edited::before {
  content: '⚡ Sectie in bewerking — live voorvertoning';
  position: absolute;
  top: -16px;
  left: 24px;
  z-index: 9995;
  background: var(--color-primary, #9d227f);
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.35rem 0.95rem;
  border-radius: 9999px;
  box-shadow: 0 4px 18px rgba(157, 34, 127, 0.55);
  pointer-events: none;
  animation: kastroPulseBadge 2.4s infinite ease-in-out;
}

@keyframes kastroPulseBadge {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.03); opacity: 0.92; }
}

.section-editable.kastro-section-being-edited .kastro-section-edit-btn {
  display: none !important;
}

/* Drawer Container */
.kastro-drawer {
  position: fixed;
  inset: 0;
  z-index: 10000;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.kastro-drawer.is-open {
  opacity: 1;
}

.kastro-drawer-panel {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 520px;
  max-width: 100%;
  background: #0e1224;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: -15px 0 50px rgba(0, 0, 0, 0.8);
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  pointer-events: auto;
}

.kastro-drawer.is-open .kastro-drawer-panel {
  transform: translateX(0);
}

.kastro-drawer-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(8, 9, 13, 0.5);
}

.kastro-drawer-close {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
  font-size: 1.5rem;
  line-height: 1;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.kastro-drawer-close:hover {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.05);
}

.kastro-drawer-body {
  padding: 2rem;
  overflow-y: auto;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.kastro-editor-field-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.kastro-editor-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #cbd5e1;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.kastro-editor-input,
.kastro-editor-textarea,
.kastro-editor-select {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md, 8px);
  background: #08090d;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 0.875rem;
  outline: none;
  transition: all 0.2s ease;
}

.kastro-editor-textarea {
  min-height: 85px;
  resize: vertical;
}

.kastro-editor-input:focus,
.kastro-editor-textarea:focus,
.kastro-editor-select:focus {
  border-color: var(--color-primary, #9d227f);
  box-shadow: 0 0 0 1px var(--color-primary, #9d227f);
}

.kastro-drawer-footer {
  padding: 1.5rem 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(8, 9, 13, 0.5);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.kastro-save-status {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md, 8px);
  font-size: 0.8125rem;
  text-align: center;
  font-weight: 600;
}

.kastro-save-status.is-success {
  background: rgba(6, 78, 59, 0.4);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #6ee7b7;
}

.kastro-save-status.is-loading {
  background: rgba(30, 58, 138, 0.4);
  border: 1px solid rgba(59, 130, 246, 0.4);
  color: #93c5fd;
}

.kastro-editor-drawer-tip {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  margin-bottom: 0.5rem;
  background: rgba(157, 34, 127, 0.08);
  border: 1px solid rgba(157, 34, 127, 0.25);
  border-radius: var(--radius-md, 8px);
  color: #cbd5e1;
  font-size: 0.8125rem;
  line-height: 1.4;
}

.kastro-editor-drawer-tip strong {
  color: #ffffff;
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   16B. INLINE FRONTEND LIVE TEXT EDITOR (.is-editable & save bar)
   -------------------------------------------------------------------------- */
body.logged-in .is-editable {
  outline: 1px dashed transparent;
  transition: outline 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
  border-radius: 4px;
}
body.logged-in .is-editable:hover {
  outline: 2px dashed rgba(157, 34, 127, 0.7) !important;
  background-color: rgba(157, 34, 127, 0.08) !important;
  cursor: text;
}
body.logged-in .is-editable:focus {
  outline: 2px solid var(--color-primary, #9d227f) !important;
  background-color: rgba(255, 255, 255, 0.96) !important;
  color: #12161f !important;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.25);
}

/* Floating formatting micro-toolbar for inline editing */
.kastro-inline-toolbar {
  position: absolute;
  z-index: 100000;
  display: flex;
  align-items: center;
  gap: 3px;
  background: rgba(18, 22, 31, 0.96);
  border: 1px solid rgba(157, 34, 127, 0.5);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 4px 6px;
  border-radius: 8px;
  pointer-events: auto;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.kastro-inline-toolbar.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.kastro-inline-toolbar button {
  background: transparent;
  border: none;
  color: #e2e8f0;
  padding: 5px 8px;
  font-size: 0.8125rem;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  line-height: 1.2;
  transition: background-color 0.12s ease, color 0.12s ease;
  user-select: none;
}
.kastro-inline-toolbar button:hover {
  background: rgba(157, 34, 127, 0.35);
  color: #ffffff;
}
.kastro-inline-toolbar button:active {
  background: var(--color-primary, #9d227f);
  color: #ffffff;
}
.kastro-inline-toolbar-divider {
  width: 1px;
  height: 16px;
  background: rgba(255, 255, 255, 0.15);
  margin: 0 2px;
}

.kastro-inline-save-bar {
  position: fixed;
  bottom: -80px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 99999;
  transition: bottom 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}
.kastro-inline-save-bar.is-active {
  bottom: 24px;
  pointer-events: auto;
}
.kastro-inline-save-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(18, 22, 31, 0.95);
  border: 1px solid rgba(157, 34, 127, 0.5);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.55), 0 0 24px rgba(157, 34, 127, 0.3);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 8px 18px;
  border-radius: 9999px;
  color: #ffffff;
  font-size: 0.8125rem;
}
.kastro-inline-save-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}
.kastro-inline-save-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.kastro-inline-btn-cancel {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #cbd5e1;
  border-radius: 9999px;
  padding: 6px 14px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.kastro-inline-btn-cancel:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}
.kastro-inline-btn-save {
  background: var(--color-primary, #9d227f);
  border: 1px solid var(--color-primary, #9d227f);
  color: #ffffff;
  border-radius: 9999px;
  padding: 6px 16px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 10px rgba(157, 34, 127, 0.4);
  transition: all 0.15s ease;
}
.kastro-inline-btn-save:hover {
  background: #b82d96;
  border-color: #b82d96;
  transform: translateY(-1px);
}


/* --------------------------------------------------------------------------
   17. LOGO IMAGES & DYNAMIC BLOG CATEGORY FILTER CHIPS
   -------------------------------------------------------------------------- */
.kastro-client-logo-img {
  max-height: 38px;
  max-width: 170px;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: brightness(0) invert(1) opacity(0.65);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-block;
}

.logo-item:hover .kastro-client-logo-img {
  filter: brightness(0) invert(1) opacity(1);
  transform: scale(1.06);
}

.kastro-cat-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
  margin-bottom: 2rem;
}

.kastro-cat-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-full, 9999px);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.kastro-cat-filter-btn:hover {
  color: #ffffff;
  border-color: rgba(0, 128, 255, 0.4);
  background: rgba(0, 128, 255, 0.1);
}

.kastro-cat-filter-btn.is-active {
  background: var(--color-primary, #0080ff);
  border-color: var(--color-primary, #0080ff);
  color: #ffffff;
  box-shadow: 0 0 15px rgba(0, 128, 255, 0.4);
}

/* --------------------------------------------------------------------------
   14. MODULAR EVENTS & AGENDA BLOCK
   -------------------------------------------------------------------------- */
.kastro-events-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.75rem;
  margin-top: 2.5rem;
}

@media (min-width: 768px) {
  .kastro-events-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .kastro-events-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.kastro-event-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
  background: var(--color-surface, #10121a);
  border: 1px solid var(--color-border, rgba(255, 255, 255, 0.08));
  border-radius: var(--radius-lg, 16px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease, box-shadow 0.25s ease;
}

.kastro-event-card:hover {
  transform: translateY(-4px);
  border-color: var(--color-border-glow, rgba(0, 128, 255, 0.35));
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4);
}

.kastro-event-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.25rem;
}

.kastro-event-date-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 56px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-border, rgba(255, 255, 255, 0.08));
  border-radius: var(--radius-md, 8px);
  font-family: var(--font-mono, monospace);
  line-height: 1.1;
}

.kastro-event-date-day {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-primary, #0080ff);
}

.kastro-event-date-month {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #94a3b8;
  margin-top: 2px;
}

.kastro-event-heading {
  font-family: var(--font-heading, sans-serif);
  font-size: 1.2rem;
  line-height: 1.35;
  color: #ffffff;
  margin: 0 0 0.75rem 0;
}

.kastro-event-heading a:hover {
  color: var(--color-primary, #0080ff);
}

.kastro-event-excerpt {
  font-family: var(--font-body, sans-serif);
  font-size: 0.925rem;
  line-height: 1.6;
  color: #94a3b8;
  margin: 0 0 1.25rem 0;
}

.kastro-event-meta-details {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: #cbd5e1;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 1.5rem;
}

.kastro-event-meta-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.kastro-event-footer {
  margin-top: auto;
}

/* ==========================================================================
   Dynamic Grid Column Layouts for Courses / Gallery (2, 3 or 4 columns)
   ========================================================================== */
@media (min-width: 768px) {
  .klimzaal-cards-grid.grid-cols-2-layout,
  .klimzaal-gallery-grid.grid-cols-2-layout {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  .klimzaal-cards-grid.grid-cols-3-layout,
  .klimzaal-gallery-grid.grid-cols-3-layout {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }
}

@media (min-width: 1024px) {
  .klimzaal-cards-grid.grid-cols-2-layout,
  .klimzaal-gallery-grid.grid-cols-2-layout {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  .klimzaal-cards-grid.grid-cols-3-layout,
  .klimzaal-gallery-grid.grid-cols-3-layout {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }
  .klimzaal-cards-grid.grid-cols-4-layout,
  .klimzaal-gallery-grid.grid-cols-4-layout {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }
}

.klimzaal-gallery-item {
  aspect-ratio: 4 / 3 !important;
  width: 100% !important;
  position: relative !important;
  overflow: hidden !important;
  border-radius: var(--radius-2xl, 1rem) !important;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.08) !important;
  border: 1px solid rgba(0, 0, 0, 0.08) !important;
  cursor: pointer !important;
}

.klimzaal-gallery-item img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.klimzaal-gallery-item:hover img {
  transform: scale(1.06) !important;
}

/* Gallery Item Hover Overlay & White Card */
.klimzaal-gallery-item .klimzaal-gallery-overlay {
  position: absolute !important;
  inset: 0 !important;
  background: rgba(15, 23, 42, 0.35) !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: flex-end !important;
  padding: 1rem !important;
  opacity: 0 !important;
  visibility: hidden !important;
  transition: opacity 0.3s ease, visibility 0.3s ease !important;
  pointer-events: none !important;
  z-index: 10 !important;
}

.klimzaal-gallery-item:hover .klimzaal-gallery-overlay,
.klimzaal-gallery-item:focus .klimzaal-gallery-overlay,
.klimzaal-gallery-item.is-hovered .klimzaal-gallery-overlay {
  opacity: 1 !important;
  visibility: visible !important;
}

.klimzaal-gallery-item .klimzaal-gallery-card {
  background: rgba(255, 255, 255, 0.96) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(255, 255, 255, 0.9) !important;
  box-shadow: 0 12px 28px -4px rgba(0, 0, 0, 0.28), 0 8px 12px -6px rgba(0, 0, 0, 0.2) !important;
  border-radius: var(--radius-xl, 12px) !important;
  padding: 0.875rem 1rem !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 0.75rem !important;
  transform: translateY(8px) !important;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.klimzaal-gallery-item:hover .klimzaal-gallery-card,
.klimzaal-gallery-item:focus .klimzaal-gallery-card,
.klimzaal-gallery-item.is-hovered .klimzaal-gallery-card {
  transform: translateY(0) !important;
}

.klimzaal-gallery-item .klimzaal-gallery-title {
  font-family: var(--font-headline, 'Epilogue', sans-serif) !important;
  font-weight: 700 !important;
  font-size: 0.925rem !important;
  line-height: 1.25 !important;
  color: #0f172a !important;
  margin: 0 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

.klimzaal-gallery-item .klimzaal-gallery-desc {
  font-family: var(--font-body, 'Plus Jakarta Sans', sans-serif) !important;
  font-size: 0.75rem !important;
  line-height: 1.35 !important;
  color: #475569 !important;
  margin: 0.25rem 0 0 0 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
}

.klimzaal-gallery-item .klimzaal-gallery-zoom {
  width: 2.25rem !important;
  height: 2.25rem !important;
  border-radius: var(--radius-md, 8px) !important;
  background: rgba(157, 34, 127, 0.1) !important;
  color: #9d227f !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  border: 1px solid rgba(157, 34, 127, 0.2) !important;
  transition: transform 0.2s ease, background 0.2s ease !important;
}

.klimzaal-gallery-item:hover .klimzaal-gallery-zoom {
  transform: scale(1.08) !important;
  background: rgba(157, 34, 127, 0.18) !important;
}

/* ==========================================================================
   Klimzaal Lightbox / Lightframe Modal
   ========================================================================== */
.klimzaal-lightbox {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.klimzaal-lightbox.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.klimzaal-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 14, 22, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  cursor: pointer;
}

.klimzaal-lightbox-container {
  position: relative;
  z-index: 2;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.klimzaal-lightbox-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 100%;
}

.klimzaal-lightbox-img-wrap {
  position: relative;
  max-width: 85vw;
  max-height: 78vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.klimzaal-lightbox-img {
  max-width: 100%;
  max-height: 78vh;
  object-fit: contain;
  border-radius: 1rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.klimzaal-lightbox-caption {
  margin-top: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  color: #ffffff;
  padding: 0 0.5rem;
  gap: 1rem;
}

.klimzaal-lightbox-title {
  font-family: var(--font-headline, sans-serif);
  font-weight: 700;
  font-size: 1.05rem;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.klimzaal-lightbox-counter {
  font-family: var(--font-mono, monospace);
  font-size: 0.8rem;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.1);
  padding: 0.25rem 0.65rem;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  white-space: nowrap;
}

.klimzaal-lightbox-btn-close {
  position: absolute;
  top: -3.5rem;
  right: 0;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}

.klimzaal-lightbox-btn-close:hover {
  background: var(--primary-color, #f3a6df);
  color: #13171f;
  transform: scale(1.08);
}

.klimzaal-lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.klimzaal-lightbox-prev {
  left: -4.5rem;
}

.klimzaal-lightbox-next {
  right: -4.5rem;
}

.klimzaal-lightbox-nav:hover {
  background: var(--primary-color, #f3a6df);
  color: #13171f;
  transform: translateY(-50%) scale(1.1);
}

@media (max-width: 1024px) {
  .klimzaal-lightbox-prev {
    left: 0.5rem;
  }
  .klimzaal-lightbox-next {
    right: 0.5rem;
  }
  .klimzaal-lightbox-btn-close {
    top: 1rem;
    right: 1rem;
  }
}

/* ==========================================================================
   Frontend Editor Drawer: Media Library Image Picker & Gallery Manager
   ========================================================================== */
.kastro-editor-image-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.kastro-editor-image-preview-box {
  width: 100%;
  height: 120px;
  border-radius: 0.75rem;
  border: 1px dashed rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.25);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.kastro-editor-image-preview-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kastro-editor-image-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.btn-kastro-media-select {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.85rem;
  background: rgba(243, 166, 223, 0.15);
  border: 1px solid rgba(243, 166, 223, 0.35);
  color: #f3a6df;
  border-radius: 0.6rem;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-kastro-media-select:hover {
  background: #f3a6df;
  color: #13171f;
}

.btn-kastro-media-clear {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.5rem 0.75rem;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
  border-radius: 0.6rem;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-kastro-media-clear:hover {
  background: #ef4444;
  color: #ffffff;
}

/* Gallery Multi-Image Manager in Drawer */
.kastro-editor-gallery-grid {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-top: 0.75rem;
}

.kastro-editor-gallery-item-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.5rem;
  padding: 0.5rem;
  position: relative;
}

.kastro-editor-gallery-thumb-box {
  width: 60px;
  height: 60px;
  border-radius: 0.375rem;
  overflow: hidden;
  flex-shrink: 0;
  position: relative;
  background: #000;
}

.kastro-editor-gallery-thumb-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kastro-editor-gallery-item-fields {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.kastro-editor-gallery-item-input {
  width: 100%;
  padding: 0.35rem 0.6rem;
  font-size: 0.78rem;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 0.375rem;
  color: #fff;
  transition: border-color 0.15s;
}

.kastro-editor-gallery-item-input:focus {
  outline: none;
  border-color: var(--color-primary, #9d227f);
}

.kastro-editor-gallery-thumb-remove {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 9999px;
  background: rgba(239, 68, 68, 0.85);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: bold;
  line-height: 1;
  flex-shrink: 0;
  transition: transform 0.15s, background 0.15s;
}

.kastro-editor-gallery-thumb-remove:hover {
  transform: scale(1.15);
  background: rgba(239, 68, 68, 1);
}

/* ==========================================================================
   Gallery and Groups Sections - Generous Section Spacing & Breathing Room
   ========================================================================== */
#gallery,
#groups {
  padding-top: 5.5rem !important;
  padding-bottom: 5.5rem !important;
}

@media (min-width: 1024px) {
  #gallery,
  #groups {
    padding-top: 7.5rem !important;
    padding-bottom: 7.5rem !important;
  }
}

/* ==========================================================================
   Groups & Schools Cards & Action Buttons Layout & Alignment
   ========================================================================== */
.klimzaal-group-card {
  display: flex !important;
  flex-direction: column !important;
  justify-content: space-between !important;
  height: 100% !important;
}

.klimzaal-group-card-content {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 1 auto !important;
  flex-grow: 1 !important;
}

.klimzaal-group-icon-box {
  width: 3.5rem !important;
  height: 3.5rem !important;
  border-radius: var(--radius-2xl, 1rem) !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background-color: var(--primary-light, #fbf0f8) !important;
  color: var(--color-primary, #9d227f) !important;
  margin-bottom: 1.5rem !important;
  flex-shrink: 0 !important;
  transition: transform 0.2s ease !important;
}

.group:hover .klimzaal-group-icon-box {
  transform: scale(1.08) !important;
}

.klimzaal-group-btn {
  margin-top: auto !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  width: 100% !important;
  padding: 0.85rem 1.25rem !important;
  border-radius: var(--radius-xl, 0.75rem) !important;
  background-color: var(--color-primary, #9d227f) !important;
  color: #ffffff !important;
  font-size: 0.8125rem !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  box-sizing: border-box !important;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
  transition: all 0.2s ease !important;
}

.klimzaal-group-btn:hover {
  background-color: var(--color-primary-hover, #7f1d66) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06) !important;
}

/* Flex grow and auto-margin helpers */
.flex-grow,
.grow {
  flex-grow: 1 !important;
}

.mt-auto {
  margin-top: auto !important;
}

/* --------------------------------------------------------------------------
 * Intelligent Tile / Card ("Tegel") Protection:
 * When section backgrounds are dark or have dark overlays, section-level
 * header text (h2, subtitle) adapts to white/light text. However, content
 * situated on white or light surface tiles (cards) MUST maintain their
 * high-contrast dark readability and not turn white!
 * -------------------------------------------------------------------------- */
section.klimzaal-bg-dark h2,
section.klimzaal-bg-dark .text-on-surface:not(.bg-white *):not(.klimzaal-group-card *):not(.klimzaal-card *):not([class*="bg-white"] *) {
  color: #ffffff !important;
}

section.klimzaal-bg-dark h2 ~ p.text-slate-600,
section.klimzaal-bg-dark h2 ~ div p.text-slate-600,
section.klimzaal-bg-dark .section-header p.text-slate-600 {
  color: #cbd5e1 !important;
}

section.klimzaal-bg-dark.border-t {
  border-color: rgba(255, 255, 255, 0.12) !important;
}

/* Card / Tile Surface Protection */
section.klimzaal-bg-dark .bg-white,
section.klimzaal-bg-dark [class*="bg-white"],
section.klimzaal-bg-dark .klimzaal-group-card,
section.klimzaal-bg-dark .klimzaal-card,
section.klimzaal-bg-dark .bg-amber-50,
section.klimzaal-bg-dark [class*="bg-amber-50"],
section.klimzaal-bg-dark .bg-stone-50,
section.klimzaal-bg-dark [class*="bg-stone-50"],
section.klimzaal-bg-dark .bg-stone-100 {
  color: #0f172a;
}

section.klimzaal-bg-dark .bg-white h3,
section.klimzaal-bg-dark [class*="bg-white"] h3,
section.klimzaal-bg-dark .klimzaal-group-card h3,
section.klimzaal-bg-dark .klimzaal-card h3,
section.klimzaal-bg-dark .bg-amber-50 h3,
section.klimzaal-bg-dark [class*="bg-amber-50"] h3 {
  color: #0f172a !important;
}

section.klimzaal-bg-dark .bg-white p.text-slate-600,
section.klimzaal-bg-dark .bg-white .text-slate-600,
section.klimzaal-bg-dark [class*="bg-white"] p.text-slate-600,
section.klimzaal-bg-dark [class*="bg-white"] .text-slate-600,
section.klimzaal-bg-dark .klimzaal-group-card p.text-slate-600,
section.klimzaal-bg-dark .klimzaal-group-card .text-slate-600 {
  color: #475569 !important;
}

section.klimzaal-bg-dark .bg-white .text-slate-700,
section.klimzaal-bg-dark [class*="bg-white"] .text-slate-700,
section.klimzaal-bg-dark .klimzaal-group-card .text-slate-700 {
  color: #334155 !important;
}

section.klimzaal-bg-dark .bg-white .text-slate-800,
section.klimzaal-bg-dark [class*="bg-white"] .text-slate-800,
section.klimzaal-bg-dark .klimzaal-group-card .text-slate-800 {
  color: #1e293b !important;
}

section.klimzaal-bg-dark .bg-white .text-slate-900,
section.klimzaal-bg-dark [class*="bg-white"] .text-slate-900,
section.klimzaal-bg-dark .klimzaal-group-card .text-slate-900 {
  color: #0f172a !important;
}

section.klimzaal-bg-dark .bg-white .text-slate-500,
section.klimzaal-bg-dark [class*="bg-white"] .text-slate-500,
section.klimzaal-bg-dark .klimzaal-group-card .text-slate-500 {
  color: #64748b !important;
}

section.klimzaal-bg-dark .bg-white .border-border-subtle,
section.klimzaal-bg-dark [class*="bg-white"].border-border-subtle,
section.klimzaal-bg-dark .klimzaal-group-card.border-border-subtle {
  border-color: #e2e8f0 !important;
}

section.klimzaal-bg-dark .bg-white a.bg-stone-100,
section.klimzaal-bg-dark [class*="bg-white"] a.bg-stone-100 {
  background-color: #f5f5f4 !important;
  color: #1e293b !important;
}

/* Header Action Buttons */
a.klimzaal-btn-scenery,
a.klimzaal-btn-first-time {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 2.5rem !important;
  padding: 0 1rem !important;
  font-size: 0.75rem !important;
  font-weight: 600 !important;
  line-height: 1 !important;
  border-radius: var(--radius-xl, 0.75rem) !important;
  white-space: nowrap !important;
  text-decoration: none !important;
  cursor: pointer !important;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

a.klimzaal-btn-scenery {
  background-color: #ffffff !important;
  color: #1e293b !important;
  border: 1px solid #e2e8f0 !important;
}

a.klimzaal-btn-scenery:hover {
  background-color: #f8fafc !important;
  color: var(--primary-color, #9d227f) !important;
  border-color: rgba(157, 34, 127, 0.4) !important;
  box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.08) !important;
}

a.klimzaal-btn-first-time {
  background-color: var(--primary-color, #9d227f) !important;
  color: #ffffff !important;
  border: 1px solid transparent !important;
}

a.klimzaal-btn-first-time:hover {
  background-color: var(--secondary-color, #781660) !important;
  box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.12) !important;
}

@media (max-width: 639px) {
  a.klimzaal-btn-scenery {
    display: none !important;
  }
}

/* ==========================================================================
   Partners & Collaborations Section (Dark Mode & Soft Rounded Cards)
   ========================================================================== */
.klimzaal-partners-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .klimzaal-partners-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .klimzaal-partners-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 1.75rem;
  }
}

.klimzaal-partner-card {
  display: flex;
  flex-direction: column;
  background-color: #141b26 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: var(--radius-xl, 0px) !important; /* Inherits theme corner radius setting (e.g. 0px for square corners) */
  overflow: hidden !important;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.45);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease, box-shadow 0.3s ease;
}

.klimzaal-partner-card:hover {
  transform: translateY(-5px);
  border-color: rgba(157, 34, 127, 0.5) !important;
  box-shadow: 0 20px 35px -8px rgba(0, 0, 0, 0.65), 0 0 20px rgba(157, 34, 127, 0.15);
}

.klimzaal-partner-img-wrap {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
  background-color: #0b0f17;
  border-top-left-radius: var(--radius-xl, 0px) !important;
  border-top-right-radius: var(--radius-xl, 0px) !important;
}

.klimzaal-partner-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.klimzaal-partner-card:hover .klimzaal-partner-img-wrap img {
  transform: scale(1.07);
}

.klimzaal-partner-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: rgba(12, 16, 23, 0.82) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  border-radius: var(--radius-full, 0px) !important; /* Inherits theme corner radius setting */
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #ffffff !important;
  z-index: 2;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.35);
}

.klimzaal-partner-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  justify-content: space-between;
  background-color: #141b26 !important;
}

.klimzaal-partner-sub {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--primary-color, #ec4899) !important;
  margin-bottom: 0.35rem;
  display: block;
}

.klimzaal-partner-title {
  font-family: var(--font-headline, sans-serif);
  font-size: 1.18rem;
  font-weight: 700;
  color: #ffffff !important;
  line-height: 1.3;
  margin-bottom: 0.5rem;
}

.klimzaal-partner-card:hover .klimzaal-partner-title {
  color: #ffffff !important;
}

.klimzaal-partner-desc {
  font-size: 0.85rem;
  line-height: 1.55;
  color: #94a3b8 !important;
  margin-bottom: 1.25rem;
  flex: 1;
}

.klimzaal-partner-footer {
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.klimzaal-partner-link {
  font-size: 0.775rem;
  font-weight: 600;
  color: #cbd5e1 !important;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: color 0.2s ease, transform 0.2s ease;
  text-decoration: none;
}

.klimzaal-partner-link:hover,
.klimzaal-partner-card:hover .klimzaal-partner-link {
  color: var(--primary-color, #ec4899) !important;
}


