/* ============================================================
   KNOPPEN
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 22px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  border: none;
  transition: background 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s;
  text-decoration: none;
  white-space: nowrap;
  line-height: 1;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(196,113,74,0.28);
}
.btn-primary:hover  { background: var(--primary-dark); }
.btn-primary:active { transform: translateY(1px); }
.btn-primary:disabled { opacity: 0.55; cursor: not-allowed; box-shadow: none; }

.btn-secondary {
  background: var(--surface-raised);
  color: var(--text);
  border: 1.5px solid var(--border);
}
.btn-secondary:hover { border-color: var(--primary); color: var(--primary); }

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  padding: 8px 12px;
}
.btn-ghost:hover { color: var(--text); background: rgba(44,37,32,0.06); border-radius: var(--radius-sm); }

.btn-icon {
  background: transparent;
  border: none;
  padding: 8px;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  font-size: 1.1rem;
  transition: color 0.2s, background 0.2s;
}
.btn-icon:hover { color: var(--text); background: rgba(44,37,32,0.06); }

.btn-block { display: flex; width: 100%; }


/* ============================================================
   FORMULIEREN
   ============================================================ */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: var(--space-md);
}

.form-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.form-input,
.form-select,
.form-textarea {
  padding: 12px 14px;
  background: var(--surface-raised);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  color: var(--text);
  width: 100%;
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
  appearance: none;
}
.form-input::placeholder,
.form-textarea::placeholder { color: var(--text-light); }

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(196,113,74,0.12);
}

.form-textarea {
  resize: vertical;
  min-height: 90px;
  line-height: 1.5;
}

.form-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='7' viewBox='0 0 12 7'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%239A8E86' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
}
@media (max-width: 480px) {
  .form-row { grid-template-columns: 1fr; }
}

.form-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}


/* ============================================================
   MELDINGEN
   ============================================================ */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: var(--space-md);
  line-height: 1.5;
}
.alert-icon { flex-shrink: 0; font-size: 1rem; margin-top: 1px; }
.alert-error   { background: var(--red-bg);    border: 1px solid #E0B8B8; color: #7A2020; }
.alert-warning { background: var(--orange-bg); border: 1px solid #E0CCB0; color: #7A4820; }
.alert-success { background: var(--green-bg);  border: 1px solid #B8D4C4; color: #2A5C3A; }
.alert-info    { background: var(--primary-light); border: 1px solid #E0C8B8; color: #7A3820; }


/* ============================================================
   KAARTEN
   ============================================================ */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.card-padded  { padding: var(--space-lg); }

.card + .card { margin-top: var(--space-md); }

.card-header {
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.card-section {
  padding: var(--space-md) var(--space-lg);
  border-top: 1px solid var(--border);
}
.card-section:first-child { border-top: none; }

.card-link {
  display: block;
  transition: box-shadow 0.2s;
}
.card-link:hover {
  box-shadow: var(--shadow-sm);
}


/* ============================================================
   BADGES
   ============================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
}
.badge-green   { background: var(--green-bg);   color: var(--green); }
.badge-orange  { background: var(--orange-bg);  color: var(--orange); }
.badge-red     { background: var(--red-bg);     color: var(--red); }
.badge-muted   { background: var(--border);     color: var(--text-muted); }
.badge-primary { background: var(--primary-light); color: var(--primary-dark); }
.badge-accent  { background: var(--accent-light);  color: #3A5C39; }


/* ============================================================
   LAADINDICATOR
   ============================================================ */
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.65s linear infinite;
  display: inline-block;
  vertical-align: middle;
}
.spinner-dark {
  border-color: rgba(44,37,32,0.2);
  border-top-color: var(--primary);
}
@keyframes spin { to { transform: rotate(360deg); } }

.loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
  padding: 60px var(--space-md);
  color: var(--text-muted);
  font-size: 0.9rem;
}


/* ============================================================
   BOVENKANT NAVIGATIE
   ============================================================ */
.top-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-md);
  z-index: 200;
  box-shadow: var(--shadow-xs);
}

.top-nav-brand {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}
.top-nav-brand span { color: var(--primary); }

.top-nav-right {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Paginatitel in de nav (voor detailpagina's) */
.top-nav-title {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--text);
}


/* ============================================================
   ONDERKANT NAVIGATIE
   ============================================================ */
.bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: var(--bottom-nav-h);
  background: var(--surface);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: stretch;
  z-index: 200;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.bottom-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--text-light);
  text-decoration: none;
  font-size: 0.68rem;
  font-weight: 500;
  padding: 8px 4px 10px;
  transition: color 0.2s;
  border: none;
  background: none;
  letter-spacing: 0.02em;
}
.bottom-nav-item:hover  { color: var(--text-muted); }
.bottom-nav-item.active { color: var(--primary); }

.bottom-nav-item.nav-add { color: var(--text-muted); }
.bottom-nav-item.nav-add.active { color: var(--primary); }


/* ============================================================
   ICONEN (Lucide SVG)
   ============================================================ */

/* Lucide vervangt <i data-lucide="..."> met <svg> */
[data-lucide], .lucide {
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

.top-nav-brand svg          { width: 18px; height: 18px; color: var(--primary); }
.btn-icon svg               { width: 18px; height: 18px; }
.bottom-nav-item > svg      { width: 22px; height: 22px; }
.timeline-icon svg          { width: 20px; height: 20px; }
.alert-icon svg             { width: 16px; height: 16px; }
.doc-warning-header svg     { width: 14px; height: 14px; vertical-align: -2px; }

.nav-add-circle {
  width: 36px;
  height: 36px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(196,113,74,0.35);
}
.nav-add-circle svg { width: 18px; height: 18px; color: #fff; }

.login-plane-icon {
  display: block;
  margin: 0 auto 16px;
  color: var(--primary);
}
.login-plane-icon svg { width: 48px; height: 48px; }


/* ============================================================
   LOGIN PAGINA
   ============================================================ */
.login-body {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: var(--space-lg) var(--space-md);
  background: var(--bg);
}

.login-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 52px 44px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-lg);
}

@media (max-width: 480px) {
  .login-card { padding: 40px 24px; border-radius: var(--radius-lg); }
}

.login-brand {
  text-align: center;
  margin-bottom: 44px;
}


.login-brand h1 {
  font-size: 3rem;
  color: var(--text);
  letter-spacing: 0.1em;
}

.login-tagline {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 8px;
  letter-spacing: 0.02em;
}

.login-divider {
  height: 1px;
  background: var(--border);
  margin: var(--space-lg) 0;
}

.reiziger-chip {
  display: inline-flex;
  align-items: center;
  padding: 5px 14px;
  background: var(--surface-raised);
  border: 1.5px solid var(--border);
  border-radius: 100px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  font-family: var(--font-sans);
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.reiziger-chip:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
  background: var(--primary-light);
}


/* ============================================================
   DESKTOP SIDEBAR
   ============================================================ */
.side-nav {
  display: none;
}

@media (min-width: 900px) {
  .side-nav {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: var(--sidebar-w);
    background: var(--surface);
    border-right: 1px solid var(--border);
    padding: var(--space-xl) var(--space-lg);
    z-index: 300;
    gap: var(--space-lg);
  }

  .side-nav-brand {
    font-family: var(--font-serif);
    font-size: 1.65rem;
    font-weight: 500;
    color: var(--text);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: var(--space-lg);
    border-bottom: 1px solid var(--border);
    letter-spacing: 0.03em;
  }
  .side-nav-brand svg { width: 20px; height: 20px; color: var(--primary); }
  .side-nav-brand span { color: var(--text); }

  .side-nav-items {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
  }

  .side-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 500;
    transition: background 0.15s, color 0.15s;
    border: none;
    background: none;
    cursor: pointer;
    width: 100%;
    font-family: var(--font-sans);
    text-align: left;
  }
  .side-nav-item svg { width: 17px; height: 17px; flex-shrink: 0; }
  .side-nav-item:hover  { background: var(--primary-light); color: var(--primary-dark); }
  .side-nav-item.active { background: var(--primary-light); color: var(--primary-dark); font-weight: 600; }

  .side-nav-footer {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--border);
  }

  .side-nav-logout:hover { background: var(--red-bg); color: var(--red); }

  .bottom-nav { display: none; }
}
