/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: #f8f9fa;
  color: #1a1a2e;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a { color: #0d6efd; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Layout ── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 1.5rem; }

/* Sticky footer: main grows to fill remaining space */
main.container { flex: 1; }

/* ── Header ── */
.site-header {
  background: #0d1b2a;
  color: #fff;
  padding: 0.75rem 0;
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,.3);
}
.header-inner {
  max-width: 1280px; margin: 0 auto; padding: 0 1.5rem;
  display: flex; align-items: center; justify-content: space-between;
}
.logo { color: #fff; font-size: 1.2rem; font-weight: 700; letter-spacing: .5px; }
.logo:hover { text-decoration: none; }
.logo-img { display: block; height: 48px; width: auto; }
.header-nav { display: flex; align-items: center; gap: 1rem; }
.main-menu { display: flex; align-items: center; gap: .9rem; }
.main-menu a {
  color: #d9e7ff;
  font-weight: 600;
  font-size: .92rem;
}
.menu-sep { color: #7ea3d9; font-weight: 600; }
.main-menu a:hover { color: #ffffff; text-decoration: none; }
.user-info { display: flex; align-items: center; gap: .5rem; color: #fff; }
.avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; border: 2px solid #fff; }
.user-name { font-size: .9rem; }

/* Mobile hamburger */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.6rem;
  cursor: pointer;
  padding: .25rem;
  line-height: 1;
}
.nav-drawer {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* ── Footer ── */
.site-footer {
  background: #0d1b2a;
  color: #adb5bd;
  text-align: center;
  padding: 1.5rem 0;
  font-size: .85rem;
  margin-top: auto;
}
.footer-grid { display: grid; gap: .35rem; }
.site-footer a { color: #9dd2ff; }
.footer-links { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; flex-wrap: wrap; }
.footer-admin-link {
  margin-top: .25rem;
  font-size: .73rem;
  opacity: .8;
}
.footer-admin-link a { color: #7ea3d9; }

.link-button {
  border: 0;
  background: transparent;
  color: #9dd2ff;
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
  padding: 0;
}

.legal-page {
  max-width: 860px;
  margin: 2rem auto;
  background: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,.07);
}

.legal-page h1 { margin-bottom: 1rem; color: #0d1b2a; }
.legal-page h2 { margin-top: 1.2rem; margin-bottom: .4rem; color: #0d1b2a; }
.legal-page p, .legal-page li { color: #334155; }
.legal-page ul { margin: .4rem 0 .6rem 1.2rem; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .55rem 1.1rem; border-radius: 6px; border: none;
  font-size: .9rem; font-weight: 500; cursor: pointer;
  transition: background .15s, transform .1s;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: #0d6efd; color: #fff; }
.btn-primary:hover { background: #0b5ed7; }
.btn-secondary { background: #e9ecef; color: #495057; }
.btn-secondary:hover { background: #dee2e6; }
.btn-danger { background: #dc3545; color: #fff; }
.btn-danger:hover { background: #bb2d3b; }
.btn-warning { background: #ffc107; color: #000; }
.btn-warning:hover { background: #e0a800; }
.btn-sm { padding: .35rem .75rem; font-size: .82rem; }
.btn-xs { padding: .2rem .5rem; font-size: .75rem; }
.btn-full { width: 100%; justify-content: center; }
.inline-form { display: inline; }

.cookie-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 300;
}

.cookie-banner__content {
  max-width: 880px;
  margin: 0 auto;
  background: #ffffff;
  border: 1px solid #dbe4ef;
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(9,30,66,.2);
  padding: .9rem 1rem;
  display: flex;
  gap: .8rem;
  justify-content: space-between;
  align-items: center;
}

.cookie-banner__content p { color: #334155; font-size: .88rem; }
.cookie-banner__actions { display: flex; gap: .5rem; white-space: nowrap; }

/* ── Flash ── */
.flash {
  background: #d1ecf1; border: 1px solid #bee5eb; color: #0c5460;
  padding: .75rem 1rem; border-radius: 6px; margin: 1rem 0;
}
.flash--error { background: #f8d7da; border-color: #f5c2c7; color: #842029; }

/* ── Badges ── */
.badge {
  display: inline-block; padding: .2em .55em;
  background: #e9ecef; color: #495057;
  font-size: .75rem; font-weight: 600; border-radius: 20px;
}
.badge--full { background: #f8d7da; color: #842029; }
.badge--private { background: #fff3cd; color: #664d03; }
.badge--external { background: #cff4fc; color: #055160; }
.badge--cancelled { background: #f8d7da; color: #842029; }
.badge--draft { background: #e2e3e5; color: #41464b; }
.badge--archived { background: #d3d3d3; color: #495057; }
.badge--category { background: #dbeafe; color: #1e40af; font-size: .78rem; }
.badge--free { background: #d1e7dd; color: #0a3622; }

/* ── Filter bar ── */
.filter-bar {
  display: flex; flex-wrap: wrap; gap: .75rem; align-items: flex-end;
  background: #fff; padding: 1rem 1.25rem; border-radius: 10px;
  box-shadow: 0 1px 4px rgba(0,0,0,.08); margin: 1.5rem 0;
}
.filter-group { display: flex; flex-direction: column; gap: .25rem; }
.filter-group label { font-size: .8rem; font-weight: 600; color: #6c757d; }
.filter-group input, .filter-group select {
  padding: .4rem .65rem; border: 1px solid #ced4da; border-radius: 6px;
  font-size: .9rem; background: #fff;
}
.filter-group--search { flex: 1; min-width: 200px; }

/* ── Event Grid ── */
.page-hero { padding: 2rem 0 .5rem; }
.page-hero h1 { font-size: 2rem; color: #0d1b2a; }
.page-hero__lead {
  margin-top: .55rem;
  max-width: 780px;
  color: #334155;
  font-size: 1rem;
}
.event-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem; padding: 1.5rem 0;
}

.info-page {
  max-width: 1100px;
  margin: 2rem auto;
}

.info-page h1 {
  color: #0d1b2a;
  margin-bottom: .45rem;
}

.info-page__lead {
  color: #334155;
  max-width: 880px;
  margin-bottom: 1.2rem;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.info-card {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  padding: 1.25rem;
  box-shadow: 0 2px 8px rgba(0,0,0,.05);
}

.info-card__image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: .75rem;
  display: block;
}

.info-card h2 { color: #0d1b2a; margin-bottom: .35rem; }
.info-card p { color: #334155; margin-bottom: .6rem; }
.info-card ul { margin: .2rem 0 .75rem 1.2rem; color: #334155; }
.info-card--wide { max-width: 860px; }

/* ── Event Card ── */
.event-card {
  background: #fff; border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,.07);
  overflow: hidden; display: flex; flex-direction: column;
  transition: box-shadow .2s, transform .2s;
}
.event-card:hover { box-shadow: 0 6px 18px rgba(0,0,0,.12); transform: translateY(-2px); }
.event-card--full { opacity: .75; }
.event-card--cancelled { opacity: .65; }
.event-card__image { width: 100%; height: 180px; object-fit: cover; display: block; }
.event-card__image--placeholder {
  width: 100%; height: 180px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #0d1b2a 0%, #1e3a5f 100%);
  font-size: 4rem;
}
.event-card__body { padding: 1rem 1.25rem; flex: 1; display: flex; flex-direction: column; gap: .4rem; }
.event-card__badges { display: flex; flex-wrap: wrap; gap: .3rem; margin-bottom: .25rem; }
.event-card__title { font-size: 1.1rem; font-weight: 700; margin: .1rem 0; }
.event-card__title a { color: #0d1b2a; }
.event-card__meta { font-size: .82rem; color: #6c757d; }
.event-card__desc { font-size: .9rem; color: #495057; flex: 1; }
.event-card__footer {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: .5rem; margin-top: .75rem;
  padding-top: .75rem; border-top: 1px solid #f1f3f5;
}
.event-card__price { font-weight: 700; font-size: .95rem; color: #0d1b2a; }
.event-card__slots { font-size: .8rem; color: #198754; }
/* All CTA buttons in event cards identical size */
.event-card__actions { display: flex; gap: .4rem; margin-left: auto; }
.event-card__actions .btn { min-width: 90px; justify-content: center; }

.no-events { grid-column: 1/-1; text-align: center; color: #6c757d; padding: 3rem 0; }

/* ── Event Detail ── */
.event-detail { max-width: 860px; margin: 2rem auto; }

/* Blue event header with icon + category bubble */
.event-detail__header-hero {
  background: linear-gradient(135deg, #0d6efd 0%, #0d1b2a 100%);
  border-radius: 12px;
  padding: 2.5rem 2rem;
  margin-bottom: 1.5rem;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.event-detail__header-hero::before {
  content: '';
  position: absolute;
  top: -40px; right: -40px;
  width: 200px; height: 200px;
  background: rgba(255,255,255,.04);
  border-radius: 50%;
}
.event-detail__icon { font-size: 3rem; margin-bottom: .5rem; display: block; }
.event-detail__title { font-size: 2rem; font-weight: 700; margin: .5rem 0; }
.event-detail__category {
  display: inline-block;
  background: rgba(255,255,255,.18);
  color: #fff;
  font-size: .8rem;
  font-weight: 600;
  padding: .25em .75em;
  border-radius: 20px;
  backdrop-filter: blur(4px);
}

.event-detail__image { width: 100%; max-height: 420px; object-fit: cover; border-radius: 12px; margin-bottom: 1.5rem; }
.event-detail__content { background: #fff; border-radius: 12px; padding: 2rem; margin-top: 1.5rem; box-shadow: 0 2px 8px rgba(0,0,0,.07); }
.event-detail__meta { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: .75rem; padding: 1rem 0; border-top: 1px solid #e9ecef; border-bottom: 1px solid #e9ecef; margin-bottom: 1.5rem; }
.meta-item { display: flex; flex-direction: column; gap: .1rem; }
.meta-item strong { font-size: .8rem; text-transform: uppercase; color: #6c757d; }
.event-detail__description { line-height: 1.8; color: #333; white-space: pre-wrap; margin-bottom: 1.5rem; }
.event-detail__actions { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.registration-status { padding: .5rem .85rem; border-radius: 6px; font-size: .9rem; font-weight: 500; }
.registration-status--active { background: #d1e7dd; color: #0a3622; }
.registration-status--full { background: #f8d7da; color: #842029; }

/* Cancelled banner */
.event-cancelled-banner {
  background: #f8d7da;
  border: 1px solid #f5c2c7;
  color: #842029;
  padding: 1rem 1.25rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  font-weight: 600;
}

/* ── Overlay ── */
.overlay { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; z-index: 200; }
.overlay__backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.55); }
.overlay__dialog {
  position: relative; background: #fff; border-radius: 12px;
  padding: 2rem; width: min(520px, 95vw); max-height: 90vh; overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0,0,0,.25);
}
.overlay__close { position: absolute; top: .75rem; right: .75rem; background: none; border: none; font-size: 1.4rem; cursor: pointer; color: #6c757d; }
.overlay__dialog h2 { margin-bottom: 1rem; font-size: 1.2rem; }

/* ── Forms ── */
.form-stack { display: flex; flex-direction: column; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: .35rem; }
.form-group label { font-size: .88rem; font-weight: 600; }
.form-group input, .form-group select, .form-group textarea {
  padding: .5rem .75rem; border: 1px solid #ced4da; border-radius: 6px;
  font-size: .95rem; font-family: inherit; background: #fff;
  transition: border-color .15s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none; border-color: #0d6efd; box-shadow: 0 0 0 3px rgba(13,110,253,.15);
}
.form-wide { max-width: 860px; }
.form-row { display: flex; flex-wrap: wrap; gap: 1rem; }
.form-row .form-group { flex: 1; min-width: 200px; }
.form-row .form-group--wide { flex: 100%; }
.form-row--checkboxes { flex-wrap: wrap; align-items: center; }
.checkbox-label { display: flex; align-items: center; gap: .5rem; cursor: pointer; font-weight: 500; }
.checkbox-label input { width: auto; }
.form-actions { display: flex; gap: 1rem; padding-top: .5rem; }
.admin-preview-img { max-width: 200px; max-height: 120px; object-fit: cover; border-radius: 6px; margin-bottom: .5rem; display: block; }

/* ── Centered box ── */
.centered-box { max-width: 480px; margin: 4rem auto; background: #fff; border-radius: 12px; padding: 2.5rem; text-align: center; box-shadow: 0 2px 12px rgba(0,0,0,.09); }
.centered-box h1 { margin-bottom: 1rem; }
.centered-box p { color: #495057; margin-bottom: .75rem; }

/* ── Admin ── */
.admin-body { background: #f1f3f5; }
.admin-header { background: #0d1b2a; color: #fff; padding: .75rem 0; }
.admin-page-header { display: flex; align-items: center; justify-content: space-between; margin: 1.5rem 0 1rem; flex-wrap: wrap; gap: .5rem; }
.admin-page-header h1 { font-size: 1.5rem; }
.admin-section { background: #fff; padding: 1rem 1.25rem; border-radius: 10px; margin-bottom: 1.25rem; box-shadow: 0 1px 4px rgba(0,0,0,.06); }
.admin-section h2 { font-size: 1rem; margin-bottom: .75rem; }
.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: .75rem;
  margin: 0 0 1.1rem;
}
.admin-stat-card {
  background: #ffffff;
  border: 1px solid #dbe4ef;
  border-radius: 10px;
  padding: .8rem .9rem;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
}
.admin-stat-card__label {
  font-size: .76rem;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.admin-stat-card__value {
  font-size: 1.55rem;
  line-height: 1.1;
  font-weight: 700;
  color: #0f172a;
  margin-top: .2rem;
}
.admin-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 10px; overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,.06); font-size: .9rem; }
.admin-table th { background: #e9ecef; padding: .65rem 1rem; text-align: left; font-size: .8rem; text-transform: uppercase; color: #6c757d; }
.admin-table td { padding: .6rem 1rem; border-top: 1px solid #f1f3f5; vertical-align: middle; }
.admin-table tr:hover td { background: #f8f9fa; }
.table-actions { display: flex; gap: .4rem; flex-wrap: wrap; }
.admin-actions { display: flex; gap: .5rem; flex-wrap: wrap; }

/* ── Icon picker ── */
.icon-picker { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .5rem; }
.icon-option {
  font-size: 1.5rem; padding: .35rem .5rem;
  border: 2px solid transparent; border-radius: 8px;
  cursor: pointer; background: #f1f3f5; transition: border-color .15s;
  user-select: none;
}
.icon-option:hover, .icon-option.selected { border-color: #0d6efd; background: #dbeafe; }

/* ── Archive ── */
.archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
  padding: 1.5rem 0;
}
.archive-card {
  background: #fff; border-radius: 10px; padding: 1rem 1.25rem;
  box-shadow: 0 1px 4px rgba(0,0,0,.06);
  display: flex; flex-direction: column; gap: .35rem;
  opacity: .85;
}
.archive-card__title { font-size: 1rem; font-weight: 700; color: #0d1b2a; }
.archive-card__meta { font-size: .82rem; color: #6c757d; }

/* ── Login page ── */
.login-body { display: flex; align-items: center; justify-content: center; min-height: 100vh; }
.login-box { background: #fff; border-radius: 12px; padding: 2.5rem; width: min(420px, 95vw); box-shadow: 0 4px 24px rgba(0,0,0,.1); }
.login-box h1 { font-size: 1.4rem; margin-bottom: 1.5rem; text-align: center; }

/* ── Partner / Landing ── */
.partner-hero {
  background: linear-gradient(135deg, #0d1b2a 0%, #1e3a5f 100%);
  color: #fff;
  padding: 4rem 2rem;
  border-radius: 16px;
  text-align: center;
  margin: 2rem 0;
}
.partner-hero h1 { font-size: 2.2rem; margin-bottom: .75rem; }
.partner-hero p { font-size: 1.1rem; color: #d9e7ff; max-width: 680px; margin: 0 auto 2rem; }
.partner-hero__cta { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.partner-features { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.25rem; margin: 2rem 0; }
.partner-feature {
  background: #fff; border-radius: 12px; padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
  border-left: 4px solid #0d6efd;
}
.partner-feature h3 { font-size: 1rem; margin-bottom: .4rem; color: #0d1b2a; }
.partner-feature p { color: #495057; font-size: .9rem; }
.partner-contact {
  background: #fff; border-radius: 12px; padding: 2rem;
  box-shadow: 0 2px 8px rgba(0,0,0,.06); margin: 2rem 0;
}

/* ── Responsive ── */
@media (max-width: 900px) {
  .event-detail__title { font-size: 1.5rem; }
  .partner-hero h1 { font-size: 1.6rem; }
}

@media (max-width: 720px) {
  /* Mobile nav */
  .nav-toggle { display: block; }
  .nav-drawer {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: #0d1b2a;
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem 1.5rem;
    gap: .75rem;
    border-top: 1px solid #1e3a5f;
    box-shadow: 0 8px 16px rgba(0,0,0,.3);
  }
  .nav-drawer.open { display: flex; }
  .site-header { position: relative; }
  .header-inner { flex-wrap: wrap; gap: .5rem; }
  .main-menu { flex-direction: column; align-items: flex-start; gap: .5rem; }
  .menu-sep { display: none; }
  .user-info { width: 100%; }
  .logo-img { height: 40px; }
  .cookie-banner__content { flex-direction: column; align-items: stretch; }
  .cookie-banner__actions { justify-content: flex-end; }
  .event-detail__header-hero { padding: 1.5rem 1.25rem; }
  .event-detail__title { font-size: 1.3rem; }
  .event-detail__icon { font-size: 2rem; }
  .admin-page-header { flex-direction: column; align-items: flex-start; }
  .filter-bar { flex-direction: column; }
}
