/* =============================================
   Familiedag – Stylesheet
   ============================================= */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --groen:      #1D9E75;
  --groen-licht:#E1F5EE;
  --groen-mid:  #9FE1CB;
  --groen-donker:#085041;
  --groen-text: #0F6E56;
  --amber:      #BA7517;
  --amber-licht:#FAEEDA;
  --rood:       #A32D2D;
  --rood-licht: #FCEBEB;
  --blauw-licht:#E6F1FB;
  --blauw-text: #0C447C;
  --wit:        #ffffff;
  --bg:         #f8f8f6;
  --border:     rgba(0,0,0,0.12);
  --border-mid: rgba(0,0,0,0.22);
  --tekst:      #1a1a18;
  --muted:      #5f5e5a;
  --radius:     10px;
  --radius-lg:  14px;
}

body {
  font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 15px;
  line-height: 1.6;
  color: var(--tekst);
  background: var(--bg);
}

a { color: inherit; text-decoration: none; }

/* ── Nav ── */
.nav {
  background: var(--wit);
  border-bottom: 0.5px solid var(--border);
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 52px;
  position: sticky;
  top: 0;
  z-index: 50;
}
.nav-logo {
  font-size: 15px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-links { display: flex; gap: 2px; align-items: center; flex-wrap: wrap; }
.nav-btn {
  padding: 6px 11px;
  font-size: 13px;
  color: var(--muted);
  border-radius: 8px;
  transition: all 0.15s;
  white-space: nowrap;
}
.nav-btn:hover, .nav-btn.active { background: #f0f0ec; color: var(--tekst); }
.nav-btn.active { font-weight: 500; }
.nav-admin { color: var(--amber) !important; }
.nav-logout { color: var(--muted); }

/* ── Container ── */
.container { max-width: 780px; margin: 0 auto; padding: 2rem 1.25rem 3rem; }

/* ── Login ── */
.login-body { display: flex; align-items: center; justify-content: center; min-height: 100vh; }
.login-wrap { width: 100%; max-width: 380px; padding: 1rem; }
.login-card {
  background: var(--wit);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
}
.login-icon { font-size: 36px; text-align: center; margin-bottom: 1rem; }
.login-title { font-size: 20px; font-weight: 500; text-align: center; margin-bottom: 0.375rem; }
.login-sub { font-size: 14px; color: var(--muted); text-align: center; margin-bottom: 1.5rem; }

/* ── Hero ── */
.hero {
  background: linear-gradient(150deg, var(--groen-licht) 0%, #eaf3de 100%);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  text-align: center;
  margin-bottom: 1.25rem;
}
.hero-badge {
  display: inline-block;
  background: white;
  color: var(--groen-text);
  font-size: 13px;
  font-weight: 500;
  padding: 4px 14px;
  border-radius: 20px;
  margin-bottom: 1rem;
}
.hero-title { font-size: 24px; font-weight: 500; color: var(--groen-donker); margin-bottom: 0.625rem; }
.hero-sub { font-size: 15px; color: var(--groen-text); margin-bottom: 1.5rem; line-height: 1.65; }
.hero-btns { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.btn-hero-main {
  padding: 10px 22px;
  background: var(--groen);
  color: white;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  transition: opacity 0.15s;
}
.btn-hero-main:hover { opacity: 0.88; }
.btn-hero-sec {
  padding: 10px 22px;
  background: white;
  color: var(--groen-text);
  border: 0.5px solid var(--groen-mid);
  border-radius: var(--radius);
  font-size: 14px;
  transition: all 0.15s;
}
.btn-hero-sec:hover { background: var(--groen-licht); }

/* ── Info grid ── */
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 1.25rem;
}
.info-card {
  background: var(--wit);
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  padding: 0.875rem 1rem;
}
.info-label { font-size: 12px; color: var(--muted); margin-bottom: 3px; }
.info-value { font-size: 14px; font-weight: 500; }

/* ── Invite text ── */
.invite-text {
  background: var(--wit);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  color: var(--muted);
  line-height: 1.8;
}
.invite-text p { margin-bottom: 0.875rem; }
.invite-text p:last-child { margin-bottom: 0; }
.invite-text strong { color: var(--tekst); font-weight: 500; }

/* ── Forms ── */
.form-group { margin-bottom: 0; }
.form-group label, label {
  display: block;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 4px;
}
.req { color: var(--groen); }
input[type=text],
input[type=email],
input[type=tel],
input[type=number],
input[type=password],
select,
textarea {
  width: 100%;
  padding: 8px 11px;
  border: 0.5px solid var(--border-mid);
  border-radius: var(--radius);
  font-size: 14px;
  font-family: inherit;
  background: var(--wit);
  color: var(--tekst);
  outline: none;
  height: 38px;
  transition: border-color 0.15s;
}
input:focus, select:focus, textarea:focus { border-color: var(--groen); }
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 1rem;
}
@media (max-width: 520px) { .form-row { grid-template-columns: 1fr; } }
.form-card {
  background: var(--wit);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-bottom: 1rem;
}
.form-section-title {
  font-size: 15px;
  font-weight: 500;
  margin-bottom: 1rem;
  padding-bottom: 0.625rem;
  border-bottom: 0.5px solid var(--border);
}
.persons-ctrl { display: flex; align-items: center; gap: 8px; }
.persons-btn {
  width: 32px; height: 38px;
  border: 0.5px solid var(--border-mid);
  border-radius: var(--radius);
  background: none;
  cursor: pointer;
  font-size: 18px;
  color: var(--tekst);
  display: flex; align-items: center; justify-content: center;
}
.persons-btn:hover { background: #f0f0ec; }
.persons-info { font-size: 13px; color: var(--muted); white-space: nowrap; }
.check-list { display: flex; flex-wrap: wrap; gap: 8px; }
.check-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 14px;
  transition: all 0.15s;
  background: var(--wit);
}
.check-row:hover { border-color: var(--groen); background: var(--groen-licht); }
.check-row input[type=checkbox] { margin: 0; }
.submit-row { display: flex; align-items: center; gap: 12px; margin-top: 0.5rem; }
.submit-note { font-size: 12px; color: var(--muted); }

/* ── Buttons ── */
.btn-primary {
  padding: 9px 20px;
  background: var(--groen);
  border: none;
  border-radius: var(--radius);
  color: white;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: opacity 0.15s;
  display: inline-block;
}
.btn-primary:hover { opacity: 0.88; }
.btn-full { width: 100%; text-align: center; }
.btn-secondary {
  padding: 8px 16px;
  background: none;
  border: 0.5px solid var(--border-mid);
  border-radius: var(--radius);
  color: var(--tekst);
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  display: inline-block;
  transition: all 0.15s;
}
.btn-secondary:hover { background: #f0f0ec; }

/* ── Alerts ── */
.alert {
  border-radius: var(--radius);
  padding: 10px 14px;
  font-size: 14px;
  margin-bottom: 1rem;
}
.alert-error   { background: var(--rood-licht); color: var(--rood); }
.alert-succes  { background: var(--groen-licht); color: var(--groen-text); }

/* ── Succes pagina ── */
.succes-wrap { text-align: center; padding: 3rem 1rem; }
.succes-icon { font-size: 48px; margin-bottom: 1rem; }
.succes-wrap h2 { font-size: 20px; font-weight: 500; margin-bottom: 0.75rem; }
.succes-wrap p { font-size: 14px; color: var(--muted); margin-bottom: 0.625rem; max-width: 360px; margin-left: auto; margin-right: auto; }
.succes-wrap .btn-secondary { margin-top: 1.25rem; }

/* ── Foto's ── */
.page-header { margin-bottom: 1.25rem; }
.page-header h1 { font-size: 20px; font-weight: 500; margin-bottom: 3px; }
.page-header p { font-size: 14px; color: var(--muted); }
.upload-panel {
  background: var(--wit);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}
.upload-panel.hidden { display: none; }
.year-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 1.25rem; }
.year-tab {
  padding: 5px 14px;
  border: 0.5px solid var(--border-mid);
  border-radius: 20px;
  font-size: 13px;
  color: var(--muted);
  transition: all 0.15s;
  display: inline-block;
}
.year-tab:hover  { border-color: var(--groen); color: var(--groen-text); }
.year-tab.active { background: var(--groen); border-color: var(--groen); color: white; font-weight: 500; }
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
}
.photo-item {
  aspect-ratio: 1;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  position: relative;
}
.photo-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.2s; }
.photo-item:hover img { transform: scale(1.04); }
.leeg-melding { text-align: center; padding: 3rem; color: var(--muted); font-size: 15px; }
.lightbox {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.88);
  z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 1.5rem;
}
.lightbox.hidden { display: none; }
.lightbox img { max-width: 100%; max-height: 90vh; border-radius: var(--radius); }
.lightbox-close {
  position: absolute; top: 1rem; right: 1rem;
  background: rgba(255,255,255,0.15);
  border: none; color: white;
  width: 36px; height: 36px;
  border-radius: 50%; cursor: pointer; font-size: 16px;
}
.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.15);
  border: none;
  color: white;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
}
.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }

/* ── Admin ── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
  margin-bottom: 1.5rem;
}
.stat-card {
  background: #f0f0ec;
  border-radius: var(--radius);
  padding: 0.875rem 1rem;
}
.stat-label { font-size: 12px; color: var(--muted); margin-bottom: 3px; }
.stat-value { font-size: 22px; font-weight: 500; }
.stat-value.green { color: var(--groen-text); }
.stat-value.amber { color: var(--amber); }
.table-wrap {
  background: var(--wit);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  overflow-x: auto;
}
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th {
  padding: 9px 13px;
  text-align: left;
  font-weight: 500;
  font-size: 12px;
  color: var(--muted);
  background: #f8f8f6;
  border-bottom: 0.5px solid var(--border);
  white-space: nowrap;
}
td { padding: 9px 13px; border-bottom: 0.5px solid var(--border); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: #fafaf8; }
.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 500;
  white-space: nowrap;
}
.badge-nieuw    { background: var(--amber-licht); color: #633806; }
.badge-betaald  { background: var(--groen-licht); color: var(--groen-donker); }
.badge-gestuurd { background: var(--blauw-licht); color: var(--blauw-text); }
.action-btns { display: flex; gap: 5px; align-items: center; flex-wrap: wrap; }
.btn-icon {
  padding: 3px 9px;
  font-size: 12px;
  border: 0.5px solid var(--border-mid);
  border-radius: 7px;
  background: none;
  cursor: pointer;
  color: var(--tekst);
  font-family: inherit;
  white-space: nowrap;
  display: inline-block;
  transition: all 0.15s;
  text-decoration: none;
}
.btn-icon:hover      { background: #f0f0ec; }
.btn-icon-green      { border-color: var(--groen-mid); color: var(--groen-text); }
.btn-icon-green:hover{ background: var(--groen-licht); }
.btn-icon-red        { border-color: #f0b0b0; color: var(--rood); }
.btn-icon-red:hover  { background: var(--rood-licht); }
.btn-wa {
  padding: 3px 9px;
  font-size: 12px;
  border: none;
  border-radius: 7px;
  background: #25D366;
  color: white;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
  display: inline-block;
  transition: opacity 0.15s;
}
.btn-wa:hover { opacity: 0.88; }
