:root {
  --bg: #f4ead8;
  --paper: #fffaf1;
  --text: #21180f;
  --muted: #6f6659;
  --accent: #111111;
  --accent-dark: #000000;
  --border: #e3d4bd;
  --shadow: 0 16px 40px rgba(70, 45, 20, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

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

a:hover {
  text-decoration: underline;
}

/* Algemene layout met vaste sidebar */
.site-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 36px 22px 52px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 34px;
  align-items: start;
}

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

.site-sidebar {
  position: sticky;
  top: 24px;
  display: grid;
  gap: 0;
  background: rgba(255, 250, 241, 0.94);
  border: 1px solid var(--border);
  border-radius: 28px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.side-hero {
  display: block;
  min-height: 230px;
  background:
    linear-gradient(
      to bottom,
      rgba(244, 234, 216, 0.00) 0%,
      rgba(244, 234, 216, 0.00) 68%,
      rgba(244, 234, 216, 0.45) 100%
    ),
    image-set(
      url('/assets/img/fata-hero.webp') type('image/webp'),
      url('/assets/img/fata-hero.jpg') type('image/jpeg')
    ) center / cover no-repeat;
}

.side-hero:hover {
  text-decoration: none;
  filter: brightness(0.98);
}

.side-nav {
  display: grid;
  gap: 8px;
  padding: 18px 20px;
  border-top: 1px solid var(--border);
}

.side-nav a {
  color: #111;
  font-weight: 850;
  padding: 10px 14px;
  border-radius: 999px;
}

.side-nav a:hover {
  background: #111;
  color: #fff;
  text-decoration: none;
}

.side-panel {
  border-top: 1px solid var(--border);
  padding: 22px 20px;
}

.side-panel h2 {
  margin-top: 0;
}

.side-panel p {
  color: var(--muted);
}

/* Header boven content */
.page-head {
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: 28px 30px 20px;
  margin: 0;
  border-bottom: 1px solid var(--border);
}

.page-head h1,
.page-head h2 {
  margin: 0;
  font-size: clamp(2.2rem, 4vw, 3.8rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.page-head p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.home-head h1 {
  white-space: nowrap;
}

/* Eén geheel: header + inhoud */
.content-block {
  background: rgba(255, 250, 241, 0.94);
  border: 1px solid var(--border);
  border-radius: 28px;
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-bottom: 28px;
}

.content-body {
  padding: 26px;
}

.text-content {
  max-width: 100%;
}

.text-content h2:first-child,
.text-content h3:first-child {
  margin-top: 0;
}

.text-content img {
  max-width: 100%;
  height: auto;
  border-radius: 16px;
}

.empty-state {
  padding: 26px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 18px;
}

/* Flyers */
.event-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
}

.event-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.event-card a {
  display: block;
}

.event-card img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
  background: #fff;
  transition: transform 0.2s ease, filter 0.2s ease;
}

.event-card:hover img {
  transform: scale(1.01);
  filter: brightness(0.98);
}

.flyer-detail {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 0;
  box-shadow: none;
  overflow: hidden;
}

.flyer-detail img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 0;
}

.content-block .flyer-detail {
  margin: 0;
}

/* Panels en tekstpagina's */
.panel {
  background: white;
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 26px;
  box-shadow: var(--shadow);
}

.intro-panel {
  margin-top: 28px;
}

.content-panel {
  margin-bottom: 24px;
}

.content-panel h2:first-child {
  margin-top: 0;
}

.content-panel img {
  max-width: 100%;
  height: auto;
  border-radius: 16px;
}

.group-list {
  display: grid;
  gap: 14px;
}

.group-link {
  display: block;
  padding: 16px 18px;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 16px;
  font-weight: 750;
}

.contact-list {
  padding-left: 0;
  list-style: none;
}

.contact-list li {
  margin-bottom: 12px;
}

/* Buttons */
.button,
.share-button {
  display: inline-block;
  background: var(--accent);
  color: white;
  padding: 10px 15px;
  border-radius: 999px;
  font-weight: 750;
}

.button:hover,
.share-button:hover {
  background: var(--accent-dark);
  color: white;
  text-decoration: none;
}

.share-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 22px 0 0;
}

.share-button.secondary {
  background: #6f6659;
}

.share-button.secondary:hover {
  background: #4f463c;
}

/* Video */
.video-embed {
  position: relative;
  padding-top: 56.25%;
  border-radius: 16px;
  overflow: hidden;
  background: #000;
  margin: 18px 0 30px;
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Footer */
.footer {
  background: #21180f;
  color: #f4ead8;
  padding: 26px 22px;
  text-align: center;
}

.footer p {
  margin: 0;
}

/* Responsive */
@media (max-width: 900px) {
  .site-shell {
    grid-template-columns: 1fr;
    padding: 22px 16px 42px;
  }

  .site-sidebar {
    position: static;
    order: -1;
    border-radius: 22px;
  }

  .side-hero {
    min-height: 240px;
  }

  .side-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
  }

  .side-nav a {
    font-size: 0.92rem;
    padding: 8px 10px;
  }

  .home-head h1 {
    white-space: normal;
  }
}

@media (max-width: 520px) {
  .site-shell {
    padding: 16px 14px 36px;
  }

  .site-sidebar {
    border-radius: 18px;
  }

  .side-hero {
    min-height: 220px;
  }

.page-head {
  padding: 22px 20px 18px;
}

.content-block {
  border-radius: 18px;
}

.content-body {
  padding: 18px;
}

  .page-head h1 {
    font-size: clamp(2rem, 12vw, 3rem);
  }

  .event-card,
  .panel,
  .flyer-detail {
    border-radius: 16px;
  }

  .panel,
  .flyer-detail {
    padding: 18px;
  }

  .share-row {
    flex-direction: column;
  }

  .share-button {
    text-align: center;
  }
}

.share-button {
  border: 0;
  cursor: pointer;
  font: inherit;
}

.share-button.is-success {
  background: #2f6f3e;
}

.share-note {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Mobiele sidebar/menu netter */
@media (max-width: 900px) {
  .side-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    padding: 18px;
  }

  .side-nav a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 10px 12px;
    text-align: center;
    line-height: 1.2;
    background: rgba(255, 250, 241, 0.75);
    border: 1px solid var(--border);
    border-radius: 16px;
    font-size: 0.95rem;
  }

  .side-nav a:hover {
    background: #111;
    color: #fff;
  }
}

@media (max-width: 420px) {
  .side-nav {
    grid-template-columns: 1fr;
  }

  .side-nav a {
    justify-content: flex-start;
    text-align: left;
    padding-left: 16px;
  }
}

.footer-credit {
  margin-top: 8px !important;
  font-size: 0.9rem;
  opacity: 0.78;
}

.footer-credit a {
  color: #f4ead8;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-credit a:hover {
  opacity: 1;
}

/* ============================================================
   MOBIEL — algemene stack zonder rare tussenruimte
   ============================================================ */
@media (max-width: 900px) {
  .site-shell {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 0 !important;
  }

  .site-sidebar {
    display: contents !important;
  }

  .side-hero {
    order: 1 !important;
    display: block !important;
    min-height: 220px !important;
    margin: 0 !important;
    border: 1px solid var(--border) !important;
    border-bottom: 0 !important;
    border-radius: 22px 22px 0 0 !important;
    box-shadow: none !important;
    overflow: hidden !important;
  }

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

  .side-nav {
    order: 3 !important;
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    margin: 0 !important;
    padding: 18px !important;
    background: rgba(255, 250, 241, 0.96) !important;
    border-left: 1px solid var(--border) !important;
    border-right: 1px solid var(--border) !important;
    border-top: 0 !important;
    border-bottom: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  .side-nav a {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 48px !important;
    padding: 10px 12px !important;
    text-align: center !important;
    line-height: 1.2 !important;
    background: rgba(255, 250, 241, 0.75) !important;
    border: 1px solid var(--border) !important;
    border-radius: 16px !important;
    font-size: 0.95rem !important;
  }

  .side-panel {
    order: 4 !important;
    margin: 0 !important;
    padding: 22px 20px !important;
    background: rgba(255, 250, 241, 0.96) !important;
    border: 1px solid var(--border) !important;
    border-top: 0 !important;
    border-radius: 0 0 22px 22px !important;
    box-shadow: none !important;
  }

  /* Algemene contentpagina's houden normale padding */
  .content-block {
    margin: 0 !important;
    border-top: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  .content-block .page-head {
    margin: 0 !important;
    padding: 24px 20px !important;
    border-bottom: 1px solid var(--border) !important;
    border-radius: 0 !important;
  }

  .content-block .content-body {
    padding: 22px 20px !important;
  }

  /* Alleen event detail: flyer zonder witte kaart/padding */
  .event-detail-page .content-body {
    margin: 0 !important;
    padding: 0 !important;
  }

  .event-detail-page .flyer-detail {
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  .event-detail-page .flyer-detail img {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  .event-detail-page .share-row {
    margin: 0 !important;
    padding: 18px !important;
    border-top: 1px solid var(--border) !important;
  }

  .event-detail-page .share-note {
    margin: 0 !important;
    padding: 0 18px 18px !important;
  }
}

@media (max-width: 420px) {
  .side-nav {
    grid-template-columns: 1fr !important;
  }

  .side-nav a {
    justify-content: flex-start !important;
    text-align: left !important;
    padding-left: 16px !important;
  }
}
