* { margin: 0; padding: 0; box-sizing: border-box; }
.app-hidden { display: none !important; }
.app-ready { animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.loading-screen {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg, #f6f7f9);
}
.loading-screen .logo { font-size: 1.8rem; animation: loadPulse 1.2s ease-in-out infinite; }
@keyframes loadPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
.loading-screen.fade-out { opacity: 0; transition: opacity 0.3s ease; pointer-events: none; }

:root {
  --bg: #f6f7f9;
  --white: #ffffff;
  --surface: #ffffff;
  --surface-2: #f0f2f5;
  --surface-3: #e8ebf0;
  --border: #e2e5ea;
  --border-light: #eceef2;
  --text: #1a1d26;
  --text-secondary: #4a5066;
  --text-muted: #8b90a0;
  --primary: #3b5bdb;
  --primary-light: #5c7cfa;
  --primary-lighter: #dbe4ff;
  --primary-dark: #2b4acb;
  --green: #0ca678;
  --green-bg: #e6fcf5;
  --green-border: #96f2d7;
  --red: #e03131;
  --red-bg: #fff5f5;
  --red-border: #ffc9c9;
  --orange: #e8590c;
  --orange-bg: #fff4e6;
  --orange-border: #ffd8a8;
  --blue-bg: #e7f5ff;
  --blue-border: #a5d8ff;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08), 0 1px 3px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 30px rgba(0,0,0,0.1), 0 1px 4px rgba(0,0,0,0.04);
  --radius: 10px;
  --radius-lg: 16px;
  --radius-sm: 8px;
  --radius-xs: 6px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  font-size: 15px;
  line-height: 1.5;
}

.hidden { display: none !important; }

/* ── Logo ── */
.logo {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.03em;
}
.logo-dot { color: var(--primary); }
.logo-sm {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.03em;
}

/* ── Onboarding ── */
.screen { min-height: 100vh; }
#authScreen, #profileSetup {
  display: flex; align-items: center; justify-content: center; padding: 2rem;
  background: linear-gradient(160deg, #f6f7f9 0%, #e8ebf4 100%);
}
.onboard-card {
  max-width: 460px; width: 100%; text-align: center;
  background: var(--white); padding: 3rem 2.5rem; border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); border: 1px solid var(--border-light);
}
.subtitle { color: var(--text-muted); margin: 0.4rem 0 2.5rem; font-size: 1rem; }

.form-group { margin-bottom: 1.5rem; text-align: left; }
.form-group label {
  display: block; font-size: 0.8rem; color: var(--text-secondary); margin-bottom: 0.5rem;
  text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600;
}
.label-hint { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--text-muted); }

.form-group input[type="text"], .form-group input[type="email"],
.form-group input[type="password"], .form-group input[type="number"],
.form-group input[type="date"], .form-group textarea {
  width: 100%; padding: 0.75rem 1rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text); font-size: 0.95rem; outline: none;
  transition: all 0.2s; font-family: inherit;
}
.form-group textarea { min-height: 70px; resize: vertical; font-size: 0.9rem; }
.form-group input[type="text"]:focus, .form-group input[type="email"]:focus,
.form-group input[type="password"]:focus, .form-group input[type="number"]:focus,
.form-group input[type="date"]:focus, .form-group textarea:focus {
  border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter);
}

/* ── Header ── */
header {
  background: var(--white); border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 10;
}
.header-inner {
  display: flex; justify-content: space-between; align-items: center;
  padding: 1rem 2rem; max-width: 960px; margin: 0 auto;
}
.header-left { display: flex; align-items: center; gap: 1rem; }
.header-right { display: flex; align-items: center; gap: 0.75rem; }
.hamburger-btn {
  display: none; align-items: center; justify-content: center;
  width: 36px; height: 36px; border: none; background: none;
  cursor: pointer; color: var(--text-muted); border-radius: var(--radius-sm);
  transition: all 0.15s;
}
.hamburger-btn:hover, .hamburger-btn.active { background: var(--surface-2); color: var(--text); }
.mobile-menu {
  display: flex; flex-direction: column; gap: 0.25rem;
  padding: 0.5rem 0.75rem 0.6rem;
  border-top: 1px solid var(--border-light);
  animation: fadeIn 0.15s;
}
.mobile-menu.hidden { display: none; }
.mobile-menu-item {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.6rem 0.75rem; border: none; background: var(--surface-2);
  border-radius: var(--radius-sm); cursor: pointer; font-size: 0.85rem;
  font-weight: 500; color: var(--text); font-family: inherit; transition: all 0.15s;
}
.mobile-menu-item:hover { background: var(--surface-3, #e8e8ec); }
.mobile-menu-item svg { flex-shrink: 0; color: var(--primary); }
.mobile-menu-claim svg { color: var(--red); }
.header-todo {
  position: relative; cursor: pointer; width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); transition: all 0.15s; color: var(--text-muted);
}
.header-todo:hover { background: var(--surface-2); color: var(--primary); }
.header-todo-badge {
  position: absolute; top: 2px; right: 2px; min-width: 16px; height: 16px;
  background: var(--red); color: #fff; font-size: 0.6rem; font-weight: 700;
  border-radius: 100px; display: flex; align-items: center; justify-content: center;
  padding: 0 4px;
}
.todo-dropdown {
  position: absolute; top: 100%; right: 0; width: 320px; background: var(--white);
  border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg);
  z-index: 100; padding: 0.75rem; margin-top: 0.5rem;
}
.todo-dropdown-title { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-muted); margin-bottom: 0.5rem; }
.todo-item {
  display: flex; align-items: flex-start; gap: 0.5rem; padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-light); cursor: pointer; font-size: 0.8rem;
  color: var(--text); line-height: 1.4;
}
.todo-item:last-child { border-bottom: none; }
.todo-item:hover { color: var(--primary); }
.todo-item svg { flex-shrink: 0; margin-top: 0.1rem; color: var(--orange); }
.todo-item.todo-payment svg { color: var(--primary); }
.todo-item.todo-info svg { color: var(--text-muted); }
.todo-item.todo-empty { color: var(--text-muted); cursor: default; }
.todo-item.todo-empty:hover { color: var(--text-muted); }
.icon-btn {
  background: none; border: 1.5px solid var(--border); color: var(--text-muted);
  width: 36px; height: 36px; border-radius: var(--radius-sm); cursor: pointer;
  display: flex; align-items: center; justify-content: center; transition: all 0.2s;
}
.icon-btn:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-lighter); }

/* ── Sections ── */
.section { padding: 2rem; max-width: 960px; margin: 0 auto; }
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.section-header-buttons { display: flex; gap: 0.5rem; align-items: center; }
.section-header-buttons .btn-outline {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.55rem 1.15rem; font-size: 0.85rem; font-weight: 600;
}
.manual-cost-section { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
textarea { width: 100%; padding: 0.75rem 1rem; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-family: inherit; font-size: 0.9rem; resize: vertical; outline: none; transition: border-color 0.2s; }
textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter); }
.section h2 { font-size: 1.15rem; font-weight: 700; color: var(--text); }

/* ── Buttons ── */
.btn-accent {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.55rem 1.15rem; background: var(--primary); border: none; border-radius: var(--radius-sm);
  color: #fff; font-size: 0.85rem; font-weight: 600; cursor: pointer; transition: all 0.15s;
  box-shadow: var(--shadow-sm);
}
.btn-accent:hover { background: var(--primary-dark); box-shadow: var(--shadow); }
.btn-outline {
  padding: 0.55rem 1.15rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text-secondary); font-size: 0.85rem; font-weight: 500;
  cursor: pointer; transition: all 0.15s;
}
.btn-outline:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-lighter); }
.btn-ghost {
  padding: 0.4rem 0.85rem; background: none; border: none;
  color: var(--text-muted); font-size: 0.82rem; font-weight: 500; cursor: pointer; transition: color 0.15s;
}
.btn-ghost:hover { color: var(--red); }
.btn-primary {
  padding: 0.8rem 1.5rem; background: var(--primary); border: none; border-radius: var(--radius);
  color: #fff; font-size: 0.95rem; font-weight: 600; cursor: pointer; transition: all 0.15s;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { background: var(--primary-dark); box-shadow: var(--shadow); }
.btn-full { width: 100%; }
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.78rem; }
.section-actions { display: flex; gap: 0.5rem; align-items: center; }

/* ── File Queue ── */
.file-queue { display: flex; flex-direction: column; gap: 0.5rem; margin-top: 1rem; }
.file-queue-item {
  display: flex; align-items: center; gap: 0.75rem; padding: 0.6rem 0.85rem;
  background: var(--surface-2); border: 1px solid var(--border-light); border-radius: var(--radius-sm); font-size: 0.85rem;
}
.file-queue-icon { font-size: 1.1rem; flex-shrink: 0; }
.file-queue-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-secondary); }
.file-queue-status { font-size: 0.75rem; color: var(--text-muted); font-weight: 500; }
.file-queue-status.done { color: var(--green); }
.file-queue-status.error { color: var(--red); }
.file-queue-status.processing { color: var(--primary); }
.file-queue-remove {
  background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 1rem; padding: 0 0.25rem;
}
.file-queue-remove:hover { color: var(--red); }
.upload-hint { display: block; font-size: 0.78rem; color: var(--text-muted); margin-top: 0.6rem; }

/* ── Policy Cards ── */
/* ── View Toggle ── */
.view-toggle {
  display: flex; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden;
}
.view-toggle-btn {
  padding: 0.4rem 0.55rem; background: var(--white); border: none; cursor: pointer;
  color: var(--text-muted); display: flex; align-items: center; transition: all 0.15s;
}
.view-toggle-btn:not(:last-child) { border-right: 1px solid var(--border); }
.view-toggle-btn:hover { color: var(--text); background: var(--surface-2); }
.view-toggle-btn.active { background: var(--primary); color: #fff; }

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

/* ── List View ── */
.policies-list { display: flex; flex-direction: column; gap: 0.35rem; }
.policy-list-row {
  display: flex; align-items: center; gap: 0.75rem; padding: 0.65rem 0.85rem;
  background: var(--white); border: 1px solid var(--border-light); border-radius: var(--radius-sm);
  cursor: pointer; transition: all 0.15s; box-shadow: var(--shadow-sm); position: relative;
}
.policy-list-row:hover { border-color: var(--primary); box-shadow: var(--shadow-md); }
.policy-list-logo {
  display: flex; align-items: center; flex-shrink: 0;
}
.policy-list-insurer {
  font-weight: 700; font-size: 0.85rem; color: var(--text); display: flex; align-items: center;
  gap: 0.5rem; min-width: 140px; max-width: 220px; flex-shrink: 0;
  overflow: hidden;
}
.policy-list-insurer-text {
  overflow: hidden; white-space: nowrap; min-width: 0;
  text-overflow: ellipsis;
}
.policy-list-name {
  flex: 1; font-size: 0.82rem; color: var(--text-secondary); min-width: 0;
  overflow: hidden; white-space: nowrap;
  text-overflow: ellipsis;
}
.policy-list-badges { display: flex; gap: 0.3rem; flex-shrink: 0; }
.policy-list-cost {
  font-size: 0.82rem; font-weight: 600; color: var(--text); min-width: 80px;
  text-align: right; font-variant-numeric: tabular-nums;
}
.policy-list-delete {
  position: static; opacity: 0; flex-shrink: 0;
}
.policy-list-row:hover .policy-list-delete { opacity: 1; }
.policy-card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.25rem; position: relative; cursor: pointer; transition: all 0.2s;
  box-shadow: var(--shadow-sm);
}
.policy-card:hover { border-color: var(--primary); box-shadow: var(--shadow-md); transform: translateY(-1px); }
.policy-card-top { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; }
.policy-insurer { font-weight: 700; font-size: 1.05rem; color: var(--text); display: flex; align-items: center; gap: 0.65rem; line-height: 1.3; overflow: hidden; }
.policy-insurer-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.insurer-logo { border-radius: 6px; object-fit: contain; flex-shrink: 0; background: var(--white); }
.insurer-logo-fallback {
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
  border-radius: 6px; background: var(--primary); color: #fff;
  font-weight: 800; font-family: inherit; line-height: 1;
}
.policy-type-badge {
  display: inline-flex; align-items: center; padding: 0.2rem 0.55rem; border-radius: 100px;
  font-size: 0.58rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  white-space: nowrap; flex-shrink: 0;
}
.policy-type-badge.zakelijk, .policy-type-badge.business { background: var(--blue-bg); color: #1971c2; border: 1px solid var(--blue-border); }
.policy-type-badge.particulier, .policy-type-badge.personal, .policy-type-badge.prive { background: #f3e8ff; color: #ae3ec9; border: 1px solid #d0bfff; }
.detail-scope-select {
  appearance: none; -webkit-appearance: none;
  padding: 0.2rem 1.1rem 0.2rem 0.55rem; border-radius: 100px;
  font-size: 0.58rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  cursor: pointer; outline: none;
}
.detail-scope-select.personal {
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5' viewBox='0 0 8 5'%3E%3Cpath d='M1 1l3 3 3-3' stroke='%238b3aad' stroke-width='1.2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 0.35rem center / 8px #f3e8ff;
  color: #ae3ec9; border: 1px solid #d0bfff;
}
.detail-scope-select.business {
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5' viewBox='0 0 8 5'%3E%3Cpath d='M1 1l3 3 3-3' stroke='%23145da0' stroke-width='1.2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 0.35rem center / 8px var(--blue-bg);
  color: #1971c2; border: 1px solid var(--blue-border);
}
.policy-name { font-size: 0.86rem; color: var(--text-muted); margin-bottom: 0.6rem; }
.policy-categories { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-bottom: 0.6rem; }
.policy-tag {
  display: inline-flex; align-items: center; gap: 0.3rem; padding: 0.2rem 0.6rem;
  background: var(--surface-2); color: var(--text-secondary); border: 1px solid var(--border-light);
  border-radius: 100px; font-size: 0.7rem; font-weight: 500;
}
.policy-summary {
  font-size: 0.83rem; color: var(--text-secondary); line-height: 1.55;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.policy-delete {
  position: absolute; top: 0.75rem; right: 0.75rem; background: var(--white); border: 1px solid var(--border);
  color: var(--text-muted); cursor: pointer; font-size: 0.85rem; opacity: 0; transition: all 0.2s;
  width: 26px; height: 26px; border-radius: 6px; display: flex; align-items: center; justify-content: center; z-index: 2;
}
.policy-card:hover .policy-delete { opacity: 1; }
.policy-delete:hover { color: var(--red); border-color: var(--red); background: var(--red-bg); }

/* ── Welcome banner ── */
.welcome-modal {
  background: var(--white); border-radius: 16px; padding: 0; position: relative;
  width: 720px; max-width: 95vw; max-height: 90vh; overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
  animation: welcomeSlideIn 0.3s ease;
}
@keyframes welcomeSlideIn {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.welcome-header {
  text-align: center; padding: 2rem 2rem 0;
}
.welcome-logo {
  width: 52px; height: 52px; border-radius: 14px; background: var(--primary);
  color: #fff; font-size: 1.8rem; font-weight: 800; display: inline-flex;
  align-items: center; justify-content: center; margin-bottom: 0.75rem;
  font-family: 'Inter', system-ui, sans-serif;
}
.welcome-logo span { color: var(--primary-light); }
.welcome-modal h3 { font-size: 1.25rem; font-weight: 800; color: var(--text); margin-bottom: 0.35rem; }
.welcome-header > p { font-size: 0.9rem; color: var(--text-secondary); margin-bottom: 0; }
.welcome-close {
  position: absolute; top: 1rem; right: 1rem; background: var(--surface-2); border: none;
  width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center;
  justify-content: center; font-size: 1.2rem; color: var(--text-muted); cursor: pointer;
  transition: background 0.15s;
}
.welcome-close:hover { background: var(--surface-3); color: var(--text); }
.welcome-section-label {
  font-size: 0.65rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-muted); margin: 1.25rem 2rem 0.5rem;
}
.welcome-section-label:first-of-type { margin-top: 1.25rem; }
.welcome-steps { display: flex; gap: 0.75rem; padding: 0 2rem; }
.welcome-step {
  flex: 1; display: flex; gap: 0.6rem; align-items: flex-start;
  background: var(--surface-2); border-radius: 10px;
  padding: 0.75rem; font-size: 0.82rem; line-height: 1.4;
}
.welcome-step strong { color: var(--text); }
.welcome-step span { color: var(--text-muted); font-size: 0.78rem; }
.welcome-step-icon {
  width: 26px; height: 26px; border-radius: 50%; background: var(--primary);
  color: #fff; font-size: 0.75rem; font-weight: 700; display: flex;
  align-items: center; justify-content: center; flex-shrink: 0;
}
.welcome-features {
  display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; padding: 0 2rem;
}
.welcome-feature {
  display: flex; gap: 0.6rem; align-items: flex-start;
  background: var(--surface-2); border-radius: 10px;
  padding: 0.65rem 0.75rem; font-size: 0.82rem; line-height: 1.4;
}
.welcome-feature strong { color: var(--text); font-size: 0.8rem; }
.welcome-feature span { color: var(--text-muted); font-size: 0.75rem; }
.welcome-feature svg { flex-shrink: 0; color: var(--primary); margin-top: 0.1rem; }
.welcome-cta {
  display: flex; gap: 0.75rem; padding: 1.5rem 2rem; align-items: center;
  justify-content: center; border-top: 1px solid var(--border-light); margin-top: 1.25rem;
}
@media (max-width: 600px) {
  #welcomeBanner { align-items: flex-start; padding-top: 0.5rem; padding-left: 0.5rem; padding-right: 0.5rem; }
  .welcome-modal { width: 100%; max-width: calc(100vw - 1rem); border-radius: 14px; margin: 0; max-height: none; flex-shrink: 0; overflow-x: hidden; }
  .welcome-header { padding: 1.5rem 1.25rem 0; }
  .welcome-section-label { margin-left: 1.25rem; margin-right: 1.25rem; }
  .welcome-steps { flex-direction: column; gap: 0.5rem; padding: 0 1.25rem; }
  .welcome-features { grid-template-columns: 1fr; padding: 0 1.25rem; }
  .welcome-cta { padding: 1.25rem; }
}

.empty-state {
  text-align: center; padding: 3.5rem 1rem; color: var(--text-muted); grid-column: 1 / -1;
  background: var(--white); border: 2px dashed var(--border); border-radius: var(--radius);
}
.empty-state .empty-icon { font-size: 2.5rem; margin-bottom: 0.75rem; opacity: 0.6; }
.empty-state p { font-size: 0.92rem; line-height: 1.6; margin: 0; }
.empty-state .empty-hint { font-size: 0.82rem; color: var(--text-muted); margin-top: 0.3rem; }
.empty-state-sm {
  text-align: center; padding: 1.5rem; color: var(--text-muted); font-size: 0.88rem;
  background: var(--white); border: 1px solid var(--border-light); border-radius: var(--radius-sm);
}

/* ── Overlap Section ── */
.overlap-section { padding-top: 0 !important; padding-bottom: 0 !important; background: none !important; border: none !important; box-shadow: none !important; }
.overlap-banner {
  display: flex; align-items: center; gap: 0.75rem; padding: 1rem 1.25rem;
  background: linear-gradient(135deg, #f0f4ff 0%, #e8eeff 100%);
  border: 1px solid #c5d0f0; border-radius: var(--radius) var(--radius) 0 0;
}
.overlap-banner-icon {
  width: 40px; height: 40px; border-radius: 50%; background: var(--primary);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.overlap-banner-icon svg { color: #fff; }
.overlap-banner-text { flex: 1; }
.overlap-banner-text h2 { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0; }
.overlap-banner-text p { font-size: 0.78rem; color: var(--text-muted); margin: 0.1rem 0 0; }
.overlap-content {
  display: flex; flex-direction: column; gap: 0; background: var(--white);
  border: 1px solid #c5d0f0; border-top: none;
}
.overlap-card {
  border-bottom: 1px solid var(--border-light); cursor: pointer; transition: background 0.15s;
}
.overlap-card:last-child { border-bottom: none; }
.overlap-card:hover { background: var(--surface-2); }
.overlap-card-header {
  display: flex; gap: 0.6rem; align-items: center; padding: 0.75rem 1.15rem;
}
.overlap-type-badge {
  display: inline-flex; align-items: center; gap: 0.3rem; font-size: 0.62rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.04em; padding: 0.2rem 0.5rem;
  border-radius: 100px; flex-shrink: 0;
}
.overlap-type-badge.full { background: var(--orange-bg); color: #e67700; border: 1px solid var(--orange-border); }
.overlap-type-badge.full svg { color: #e67700; }
.overlap-type-badge.partial { background: var(--blue-bg); color: #1971c2; border: 1px solid var(--blue-border); }
.overlap-type-badge.partial svg { color: #1971c2; }
.overlap-header-text { flex: 1; min-width: 0; }
.overlap-headline { font-size: 0.88rem; font-weight: 600; color: var(--text); }
.overlap-chevron {
  color: var(--text-muted); font-size: 0.65rem; transition: transform 0.25s; flex-shrink: 0;
}
.overlap-card.expanded .overlap-chevron { transform: rotate(180deg); }
.overlap-details { max-height: 0; overflow: hidden; transition: max-height 0.3s ease; }
.overlap-card.expanded .overlap-details { max-height: 500px; }
.overlap-details-inner {
  padding: 0 1.15rem 1rem 1.15rem; border-top: 1px solid var(--border-light); padding-top: 0.75rem;
}
.overlap-desc { font-size: 0.85rem; line-height: 1.55; color: var(--text-secondary); margin-bottom: 0.6rem; }
.overlap-advice-box {
  display: flex; align-items: flex-start; gap: 0.5rem; font-size: 0.82rem; color: #087f5b;
  background: var(--green-bg); padding: 0.6rem 0.85rem; border-radius: var(--radius-sm);
  line-height: 1.5; border: 1px solid var(--green-border);
}
.overlap-advice-box svg { flex-shrink: 0; margin-top: 0.1rem; color: #087f5b; }
.overlap-saving {
  display: flex; align-items: center; gap: 0.35rem; font-size: 0.8rem; color: var(--orange);
  margin-top: 0.5rem; font-weight: 600;
}
.overlap-saving svg { color: var(--orange); }
.overlap-summary-box {
  padding: 0.85rem 1.15rem; font-size: 0.85rem; color: var(--text-secondary);
  line-height: 1.55; border-top: 1px solid var(--border-light);
}
.overlap-allclear {
  display: flex; align-items: center; gap: 0.6rem; padding: 1rem 1.15rem;
  font-size: 0.88rem; color: #087f5b; font-weight: 500;
}
.overlap-allclear svg { color: #087f5b; flex-shrink: 0; }
.overlap-disclaimer {
  font-size: 0.7rem; color: var(--text-muted); padding: 0.6rem 1.15rem;
  background: var(--white); border: 1px solid #c5d0f0; border-top: none;
  border-radius: 0 0 var(--radius) var(--radius); line-height: 1.5;
}
.overlap-loading { text-align: center; padding: 2rem; color: var(--text-muted); font-size: 0.9rem; }
.overlap-loading .spinner {
  display: inline-block; width: 18px; height: 18px; border: 2px solid var(--border);
  border-top-color: var(--primary); border-radius: 50%; animation: spin 0.8s linear infinite;
  margin-right: 0.5rem; vertical-align: middle;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Gap / Coverage Analysis ── */
.gap-intro { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 1rem; }
.coverage-heading {
  font-size: 0.85rem; font-weight: 700; color: var(--text); text-transform: uppercase;
  letter-spacing: 0.04em; margin-bottom: 0.5rem;
}
.suggestions-heading {
  font-size: 0.85rem; font-weight: 700; color: var(--text); text-transform: uppercase;
  letter-spacing: 0.04em; margin-bottom: 0.25rem; margin-top: 1.5rem;
}
.suggestions-intro { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.gaps-grid { display: flex; flex-direction: column; gap: 0.45rem; }
.gap-item {
  display: flex; align-items: center; gap: 0.6rem; padding: 0.65rem 0.85rem;
  background: var(--white); border-radius: var(--radius-sm); border: 1px solid var(--border-light);
  font-size: 0.9rem; box-shadow: var(--shadow-sm);
}
.gap-item[data-scope="privé"] { border-left: 3px solid #ae3ec9; background: #faf5ff; }
.gap-item[data-scope="zakelijk"] { border-left: 3px solid #1971c2; background: #f0f7ff; }
.suggestion-item { border-left: 3px solid var(--border); background: var(--white); }
.gap-dot { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.gap-dot.covered { background: var(--green); }
.gap-dot.check-overlap { background: var(--orange); }
.gap-dot.missing-required { background: var(--red); }
.gap-dot.missing-recommended { background: var(--orange); }
.gap-name { flex: 1; min-width: 0; color: var(--text-secondary); overflow-wrap: break-word; word-break: break-word; }
.gap-label {
  font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.05em; font-weight: 600;
  padding: 0.15rem 0.35rem; border-radius: 100px;
}
.gap-label.covered { color: #087f5b; background: var(--green-bg); border: 1px solid var(--green-border); }
.gap-label.check-overlap { color: #e67700; background: var(--orange-bg); border: 1px solid var(--orange-border); }
.gap-label.missing-required { color: var(--red); background: var(--red-bg); border: 1px solid var(--red-border); }
.gap-label.missing-recommended { color: var(--orange); background: var(--orange-bg); border: 1px solid var(--orange-border); }
.gap-note { display: block; font-size: 0.72rem; color: var(--text-muted); margin-top: 0.15rem; }
.gap-scope {
  display: inline-flex; font-size: 0.6rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.04em; padding: 0.12rem 0.35rem; border-radius: 100px;
  margin-right: 0.2rem; flex-shrink: 0;
}
.gap-scope.zakelijk { background: var(--blue-bg); color: #1971c2; border: 1px solid var(--blue-border); }
.gap-scope.privé { background: #f3e8ff; color: #ae3ec9; border: 1px solid #d0bfff; }
.gap-hide-btn, .gap-unhide-btn {
  background: none; border: none; cursor: pointer; font-size: 0.75rem; color: var(--text-muted);
  padding: 0.2rem 0.4rem; border-radius: 4px; flex-shrink: 0; opacity: 0; transition: opacity 0.15s;
}
.gap-item:hover .gap-hide-btn, .gap-item:hover .gap-unhide-btn,
.suggestion-card:hover .gap-hide-btn, .suggestion-card:hover .gap-unhide-btn { opacity: 1; }
.gap-hide-btn:hover { color: var(--red); }
.gap-unhide-btn:hover { color: var(--primary); }
.gap-hidden-section { margin-top: 0.75rem; }
.gap-hidden-toggle {
  background: none; border: none; cursor: pointer; font-size: 0.8rem; font-weight: 600;
  color: var(--text-muted); padding: 0.5rem 0; display: flex; align-items: center; gap: 0.3rem;
}
.gap-hidden-toggle:hover { color: var(--text-secondary); }
.gap-hidden-arrow { font-size: 0.7rem; transition: transform 0.2s; }
.gap-hidden-section.open .gap-hidden-arrow { transform: rotate(180deg); }
.gap-hidden-list { display: none; flex-direction: column; gap: 0.35rem; margin-top: 0.5rem; }
.gap-hidden-section.open .gap-hidden-list { display: flex; }
.gap-item-hidden { opacity: 0.55; }

/* ── Expandable Suggestion Cards ── */
.suggestion-card {
  border: 1px solid var(--border-light); border-radius: var(--radius-sm);
  background: var(--white); box-shadow: var(--shadow-sm); cursor: pointer;
  transition: all 0.15s; border-left: 3px solid var(--border);
}
.suggestion-card:hover { border-color: var(--primary); border-left-color: var(--primary); }
.suggestion-header {
  display: flex; align-items: center; gap: 0.6rem; padding: 0.65rem 0.85rem;
  font-size: 0.9rem;
}
.suggestion-chevron {
  font-size: 0.7rem; color: var(--text-muted); transition: transform 0.2s; flex-shrink: 0;
}
.suggestion-card.open .suggestion-chevron { transform: rotate(180deg); }
.suggestion-detail {
  display: none; padding: 0 0.85rem 0.75rem 2.2rem;
}
.suggestion-card.open .suggestion-detail { display: block; }
.suggestion-desc {
  font-size: 0.82rem; color: var(--text-secondary); line-height: 1.55; margin-bottom: 0.5rem;
}
.suggestion-independer {
  display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.78rem;
  font-weight: 600; color: #4263eb; text-decoration: none; transition: color 0.15s;
}
.suggestion-independer:hover { color: #3b5bdb; }
.suggestion-independer svg { flex-shrink: 0; }

.suggestion-actions {
  display: flex; gap: 0.6rem; align-items: center; flex-wrap: wrap;
}
.suggestion-link-btn {
  background: var(--surface-2, #f4f5f8);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.75rem; font-weight: 600;
  padding: 0.3rem 0.65rem;
  border-radius: 100px; cursor: pointer;
  transition: all 0.15s; font-family: inherit;
}
.suggestion-link-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* Link suggestion -> polis modal */
.link-pol-list {
  display: flex; flex-direction: column; gap: 0.4rem;
  max-height: 320px; overflow-y: auto;
  margin-top: 0.5rem;
}
.link-pol-row {
  display: flex; align-items: center; gap: 0.7rem;
  padding: 0.65rem 0.85rem;
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer; text-align: left; font-family: inherit;
  transition: border-color 0.15s, background 0.15s;
}
.link-pol-row:hover {
  border-color: var(--primary);
  background: var(--primary-lighter, #dbe4ff);
}
.link-pol-logo { flex-shrink: 0; }
.link-pol-info { flex: 1; min-width: 0; }
.link-pol-name { font-size: 0.9rem; font-weight: 700; color: var(--text); }
.link-pol-sub { font-size: 0.75rem; color: var(--text-muted); margin-top: 0.1rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── Independer CTA ── */
.independer-cta { margin-top: 1.25rem; }
.independer-card {
  padding: 1rem 1.25rem; background: linear-gradient(135deg, #f8f9ff 0%, #eef2ff 100%);
  border: 1px solid #d0d5e8; border-radius: var(--radius); text-align: center;
}
.independer-logo {
  display: flex; align-items: center; justify-content: center; gap: 0.4rem;
  font-size: 0.9rem; font-weight: 700; color: #4263eb; margin-bottom: 0.4rem;
}
.independer-logo svg { color: #4263eb; }
.independer-text { font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 0.75rem; }
.independer-btn {
  display: inline-block; padding: 0.55rem 1.5rem; background: #4263eb; color: #fff;
  border-radius: 100px; font-size: 0.82rem; font-weight: 600; text-decoration: none;
  transition: background 0.15s;
}
.independer-btn:hover { background: #3b5bdb; }

/* ── Modal ── */
.modal {
  position: fixed; inset: 0; background: rgba(0,0,0,0.3); display: flex; align-items: center;
  justify-content: center; z-index: 100; padding: 1rem; backdrop-filter: blur(6px);
  overflow-y: auto; -webkit-overflow-scrolling: touch;
}
.modal-content {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 2rem; max-width: 520px; width: 100%; position: relative; max-height: 90vh;
  overflow-y: auto; overflow-x: hidden; box-shadow: var(--shadow-lg);
}
.modal-lg { max-width: 580px; }
.modal-content h2 { margin-bottom: 0.4rem; font-size: 1.2rem; font-weight: 700; }
.modal-desc { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 1.5rem; line-height: 1.55; }
.modal-close {
  position: absolute; top: 1rem; right: 1rem; background: none; border: none;
  color: var(--text-muted); cursor: pointer; z-index: 2; display: flex; align-items: center;
  justify-content: center; width: 32px; height: 32px; border-radius: var(--radius-xs);
  transition: all 0.15s;
}
.modal-close:hover { color: var(--text); background: var(--surface-2); }

/* Upload */
.back-btn {
  display: inline-flex; align-items: center; gap: 0.3rem;
  background: none; border: none; color: var(--text-muted); font-size: 0.85rem;
  cursor: pointer; margin-bottom: 1rem; padding: 0; font-weight: 500;
}
.back-btn:hover { color: var(--primary); }

.chip-grid { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.25rem; }
.chip {
  padding: 0.4rem 0.8rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: 100px; color: var(--text-secondary); font-size: 0.82rem; cursor: pointer;
  transition: all 0.15s; font-weight: 500;
}
.chip:hover { border-color: var(--primary); color: var(--primary); }
.chip.selected { border-color: var(--primary); background: var(--primary-lighter); color: var(--primary-dark); font-weight: 600; }
.chip-custom { border-style: dashed; color: var(--text-muted); }
.chip-custom:hover { border-style: solid; }
.chip-custom.selected { border-style: solid; }
.custom-category-row {
  display: flex; gap: 0.5rem; align-items: center; margin-top: 0.5rem;
}
.custom-category-row .form-input { flex: 1; margin: 0; }
.custom-category-row .btn-sm { white-space: nowrap; flex-shrink: 0; }

.toggle-row { display: flex; gap: 0.5rem; }
.toggle-btn {
  flex: 1; padding: 0.6rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text-secondary); font-size: 0.9rem;
  cursor: pointer; transition: all 0.15s; text-align: center; font-weight: 500;
}
.toggle-btn:hover { border-color: var(--primary); }
.toggle-btn.selected {
  border-color: var(--primary); background: var(--primary-lighter);
  color: var(--primary-dark); font-weight: 600;
}

.upload-zone {
  border: 2px dashed var(--border); border-radius: var(--radius); padding: 2.5rem;
  text-align: center; cursor: pointer; transition: all 0.2s; background: var(--surface-2);
}
.upload-zone:hover, .upload-zone.dragover {
  border-color: var(--primary); background: var(--primary-lighter);
}
.upload-icon { margin-bottom: 0.75rem; color: var(--text-muted); display: flex; justify-content: center; }
.upload-zone:hover .upload-icon, .upload-zone.dragover .upload-icon { color: var(--primary); }
.upload-zone p { color: var(--text-secondary); font-size: 0.9rem; line-height: 1.5; font-weight: 500; }
.upload-hint { font-size: 0.7rem; color: var(--text-muted); margin-top: 0.25rem; }

.upload-status {
  margin-top: 1rem; padding: 0.8rem 1rem; border-radius: var(--radius-sm); font-size: 0.85rem; line-height: 1.5;
}
.upload-status.success { background: var(--green-bg); color: #087f5b; border: 1px solid var(--green-border); }
.upload-status.error { background: var(--red-bg); color: var(--red); border: 1px solid var(--red-border); }
.upload-status.loading { background: var(--surface-2); color: var(--text-muted); border: 1px solid var(--border); }
.btn-retry {
  display: inline-block; margin-left: 0.5rem; padding: 0.3rem 0.75rem;
  background: var(--white); border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  font-size: 0.78rem; font-weight: 600; color: var(--primary); cursor: pointer;
  font-family: inherit; transition: all 0.15s;
}
.btn-retry:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.empty-state-sm .btn-retry { margin-left: 0; margin-top: 0.5rem; display: inline-block; }

.checkbox-row {
  display: flex; align-items: center; gap: 0.5rem; font-size: 0.85rem; color: var(--text-secondary); cursor: pointer;
}
.checkbox-row input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--primary); cursor: pointer; }
.upload-options { margin-top: 1rem; }

.divider {
  display: flex; align-items: center; gap: 1rem; margin: 1.5rem 0; color: var(--text-muted); font-size: 0.8rem;
}
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }

.manual-form { display: flex; flex-direction: column; gap: 0.75rem; }
.manual-form input {
  padding: 0.7rem 1rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text); font-size: 0.9rem; outline: none;
  font-family: inherit;
}
.manual-form input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter); }

/* ── Detail Modal ── */
.detail-header { margin-bottom: 1.5rem; }
.detail-insurer { font-size: 1.35rem; font-weight: 800; margin-bottom: 0.2rem; display: flex; align-items: center; gap: 0.65rem; }
.detail-name { font-size: 0.92rem; color: var(--text-muted); margin-bottom: 0.75rem; }
.detail-badges { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.65rem; margin-bottom: 1.5rem; }
.detail-stat {
  background: var(--surface-2); border-radius: var(--radius-sm); padding: 0.85rem;
  border: 1px solid var(--border-light);
}
.detail-stat-label {
  font-size: 0.7rem; color: var(--text-muted); text-transform: uppercase;
  letter-spacing: 0.05em; margin-bottom: 0.25rem; font-weight: 600;
}
.detail-stat-value { font-size: 0.95rem; font-weight: 600; color: var(--text); }

.detail-section { margin-bottom: 1.25rem; }
.detail-section h3 {
  font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-muted); margin-bottom: 0.6rem; font-weight: 600;
}
.detail-summary { font-size: 0.92rem; line-height: 1.65; color: var(--text-secondary); }

.detail-list { list-style: none; display: flex; flex-direction: column; gap: 0.35rem; }
.detail-list li {
  font-size: 0.86rem; padding: 0.5rem 0.75rem; background: var(--surface-2);
  border-radius: var(--radius-xs); display: flex; align-items: center; gap: 0.5rem;
  color: var(--text-secondary); border: 1px solid var(--border-light);
}
.detail-list li::before { content: ''; width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.detail-list.covered li { background: var(--green-bg); border-color: var(--green-border); }
.detail-list.covered li::before { background: var(--green); }
.detail-list.excluded li { background: var(--red-bg); border-color: var(--red-border); }
.detail-list.excluded li::before { background: var(--red); }
.detail-list.conditions li { background: var(--orange-bg); border-color: var(--orange-border); }
.detail-list.conditions li::before { background: var(--orange); }

.detail-cost-edit { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.detail-cost-edit label { font-size: 0.78rem; color: var(--text-muted); margin-bottom: 0.2rem; display: block; }
.detail-cost-edit .form-input { width: 100%; box-sizing: border-box; max-width: 100%; min-width: 0; }
.detail-cost-edit .full-width { grid-column: 1 / -1; }
.detail-cost-period-toggles { display: flex; gap: 0.35rem; }
.detail-cost-period-toggles button {
  flex: 1; padding: 0.45rem; border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--white); font-size: 0.8rem; cursor: pointer; transition: all 0.15s; color: var(--text-secondary);
}
.detail-cost-period-toggles button.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.detail-cost-save { margin-top: 0.5rem; padding: 0.5rem 1rem; background: var(--primary); color: #fff; border: none; border-radius: var(--radius-sm); font-size: 0.82rem; cursor: pointer; font-weight: 500; width: 100%; }
.detail-cost-save:hover { background: var(--primary-dark); }
.detail-cost-save.saved { background: var(--green); }
.detail-summary {
  width: 100%; resize: vertical; font-family: inherit; font-size: 0.88rem;
  line-height: 1.55; color: var(--text-secondary);
}

.cost-pm, .cost-py { font-size: 0.82rem; color: var(--text-secondary); }
.cost-period-label { font-size: 0.7rem; color: var(--text-muted); margin-left: 0.15rem; }

.detail-rescan {
  display: flex; align-items: center; justify-content: center; gap: 0.4rem;
  margin-top: 0.75rem; padding: 0.7rem; width: 100%; background: var(--white);
  border: 1.5px solid var(--primary-lighter); border-radius: var(--radius-sm);
  color: var(--primary); font-size: 0.85rem; font-weight: 500; cursor: pointer;
  transition: all 0.15s; font-family: inherit;
}
.detail-rescan:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.detail-rescan:hover svg { stroke: #fff; }
.detail-rescan:disabled { opacity: 0.5; cursor: not-allowed; }
.detail-rescan.rescan-success { background: var(--green); color: #fff; border-color: var(--green); }

/* ── Renew policy ── */
.detail-renew-section { margin-top: 1rem; }
.renew-dropzone {
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  padding: 1.3rem 1rem; cursor: pointer;
  border: 2px dashed var(--border); border-radius: var(--radius-sm);
  background: var(--surface-2, #f7f8fa); color: var(--text-muted);
  text-align: center; transition: all 0.15s;
}
.renew-dropzone:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-lighter, #dbe4ff); }
.renew-dropzone.dragover { border-color: var(--primary); background: var(--primary-lighter, #dbe4ff); color: var(--primary); }
.renew-dropzone-label { font-size: 0.85rem; font-weight: 500; line-height: 1.4; }
.renew-hint { font-size: 0.76rem; color: var(--text-muted); line-height: 1.5; margin-top: 0.55rem; }
.renew-status {
  margin-top: 0.6rem; padding: 0.6rem 0.8rem; border-radius: var(--radius-sm);
  font-size: 0.83rem; display: flex; align-items: center; gap: 0.4rem;
}
.renew-status.loading { background: var(--primary-lighter, #dbe4ff); color: var(--primary); }
.renew-status.error { background: var(--red-bg, #fff5f5); color: var(--red, #e03131); }
.renew-status.success { background: var(--green-bg, #e6fcf5); color: var(--green, #0ca678); }

/* Insurer name edit */
.detail-insurer-name {
  cursor: pointer; position: relative;
}
.detail-insurer-name:hover { opacity: 0.7; }
.detail-insurer-name .edit-hint {
  display: inline-block; margin-left: 0.4rem; opacity: 0; transition: opacity 0.15s;
  font-size: 1rem; color: var(--text-muted); vertical-align: middle;
}
.detail-insurer-name:hover .edit-hint { opacity: 1; }
.upload-insurer-edit {
  display: flex; align-items: center; gap: 0.4rem; margin-top: 0.4rem;
}
.upload-insurer-edit input {
  flex: 1; padding: 0.4rem 0.6rem; border: 1.5px solid var(--primary);
  border-radius: var(--radius-sm); font-size: 0.85rem; outline: none;
  font-family: inherit;
}
.upload-insurer-edit button {
  padding: 0.35rem 0.7rem; border: none; border-radius: var(--radius-sm);
  font-size: 0.8rem; font-weight: 600; cursor: pointer; font-family: inherit;
}
.upload-insurer-edit .insurer-save-btn {
  background: var(--primary); color: #fff;
}
.upload-insurer-edit .insurer-cancel-btn {
  background: var(--bg-secondary); color: var(--text-secondary);
}
/* Inline insurer name edit modal */
.insurer-edit-modal {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: 1100;
  background: rgba(0,0,0,0.35); display: flex; align-items: center; justify-content: center;
  animation: fadeIn 0.15s;
}
.insurer-edit-box {
  background: var(--white); border-radius: var(--radius-lg); padding: 1.5rem;
  width: 90%; max-width: 380px; box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}
.insurer-edit-box h3 {
  font-size: 1rem; font-weight: 700; margin-bottom: 0.75rem; color: var(--text);
}
.insurer-edit-box input {
  width: 100%; padding: 0.6rem 0.75rem; border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); font-size: 0.9rem; outline: none;
  font-family: inherit; transition: border-color 0.15s;
}
.insurer-edit-box input:focus { border-color: var(--primary); }
.insurer-edit-box .insurer-edit-actions {
  display: flex; gap: 0.5rem; margin-top: 1rem; justify-content: flex-end;
}
.insurer-edit-box .insurer-edit-actions button {
  padding: 0.5rem 1rem; border: none; border-radius: var(--radius-sm);
  font-size: 0.85rem; font-weight: 600; cursor: pointer; font-family: inherit;
}
.insurer-edit-box .insurer-edit-actions .btn-cancel {
  background: var(--bg-secondary); color: var(--text-secondary);
}
.insurer-edit-box .insurer-edit-actions .btn-save {
  background: var(--primary); color: #fff;
}

.detail-delete {
  margin-top: 0.5rem; padding: 0.7rem; width: 100%; background: var(--white);
  border: 1.5px solid var(--red-border); border-radius: var(--radius-sm);
  color: var(--red); font-size: 0.85rem; font-weight: 500; cursor: pointer; transition: all 0.15s;
}
.detail-delete:hover { background: var(--red); color: #fff; border-color: var(--red); }

.detail-download {
  display: block; margin-top: 1.5rem; padding: 0.7rem; width: 100%; text-align: center;
  text-decoration: none; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text-secondary); font-size: 0.85rem;
  font-weight: 500; cursor: pointer; transition: all 0.15s;
}
.detail-download:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-lighter); }
.detail-download svg { vertical-align: middle; margin-right: 0.4rem; }

/* ── Clickable detail items ── */
.detail-list li {
  cursor: pointer; transition: all 0.15s; position: relative;
}
.detail-list li:hover { filter: brightness(0.96); }
.detail-list li .item-text { flex: 1; }
.detail-list li .item-info {
  flex-shrink: 0; color: var(--text-muted); font-size: 0.72rem; opacity: 0.6; transition: opacity 0.15s;
}
.detail-list li:hover .item-info { opacity: 1; }

.explain-box {
  margin-top: 0.5rem; padding: 0.65rem 0.85rem; background: var(--white);
  border: 1px solid var(--border); border-radius: var(--radius-xs);
  font-size: 0.82rem; line-height: 1.6; color: var(--text-secondary);
  animation: fadeIn 0.2s ease; cursor: default;
}
.explain-box.loading { color: var(--text-muted); }
.explain-box.hidden { display: none; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

/* ── Documents list in detail modal ── */
.documents-list { display: flex; flex-direction: column; gap: 0.4rem; }
.document-row {
  display: flex; align-items: center; gap: 0.65rem; padding: 0.6rem 0.85rem;
  background: var(--surface-2); border: 1px solid var(--border-light); border-radius: var(--radius-sm);
}
.document-icon { font-size: 1.1rem; flex-shrink: 0; }
.document-name {
  flex: 1; font-size: 0.84rem; color: var(--text-secondary);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.document-dl {
  display: inline-flex; align-items: center; color: var(--text-muted); transition: color 0.15s;
  flex-shrink: 0;
}
.document-dl:hover { color: var(--primary); }

/* ── Premium box in upload modal ── */
.premium-box {
  margin-top: 1.5rem; padding: 1.25rem; background: var(--surface-2);
  border: 1px solid var(--border-light); border-radius: var(--radius);
}
.premium-box-title {
  font-size: 0.92rem; font-weight: 600; color: var(--text); margin-bottom: 0.75rem;
}
.premium-box-desc {
  font-size: 0.82rem; color: var(--text-muted); margin-bottom: 1rem; line-height: 1.5;
}
.toggle-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0.4rem; }
.toggle-row-3 .toggle-btn { font-size: 0.8rem; padding: 0.55rem 0.5rem; }
.premium-dates { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-top: 0.75rem; }

/* ── Danger zone ── */
.danger-zone {
  margin-top: 1.5rem; padding: 1.25rem; background: var(--red-bg);
  border: 1px solid var(--red-border); border-radius: var(--radius);
}
.danger-zone-header {
  display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem;
  font-size: 0.85rem; font-weight: 700; color: var(--red); text-transform: uppercase;
  letter-spacing: 0.05em;
}
.danger-zone-header svg { color: var(--red); }
.danger-desc {
  font-size: 0.82rem; color: var(--text-secondary); line-height: 1.55; margin-bottom: 0.75rem;
}
.btn-danger-outline {
  padding: 0.7rem; background: var(--white); border: 1.5px solid var(--red-border);
  border-radius: var(--radius-sm); color: var(--red); font-size: 0.85rem; font-weight: 500;
  cursor: pointer; transition: all 0.15s; font-family: inherit;
}
.btn-danger-outline:hover { background: var(--red); color: #fff; border-color: var(--red); }
.btn-danger {
  padding: 0.7rem; background: var(--red); border: none;
  border-radius: var(--radius-sm); color: #fff; font-size: 0.85rem; font-weight: 600;
  cursor: pointer; transition: all 0.15s; font-family: inherit;
}
.btn-danger:hover { background: #c92a2a; }
.btn-danger:disabled { opacity: 0.4; cursor: not-allowed; }
.delete-confirm {
  margin-top: 0.75rem; padding-top: 0.75rem; border-top: 1px solid var(--red-border);
}
.delete-confirm-text {
  font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 0.5rem;
}
.delete-confirm input {
  width: 100%; padding: 0.65rem 0.85rem; border: 1.5px solid var(--red-border);
  border-radius: var(--radius-sm); font-size: 0.9rem; outline: none; margin-bottom: 0.5rem;
  font-family: inherit; background: var(--white);
}
.delete-confirm input:focus { border-color: var(--red); box-shadow: 0 0 0 3px rgba(224,49,49,0.15); }

/* ── Upload save button ── */
.btn-save-upload { margin-top: 1rem; }
.btn-success { background: var(--green) !important; }
.btn-success:hover { background: #099268 !important; }

.security-notice {
  display: flex; align-items: center; gap: 0.5rem; padding: 0.6rem 0.85rem;
  background: #e8f5e9; border: 1px solid #c8e6c9; border-radius: var(--radius-sm);
  font-size: 0.75rem; color: #2e7d32; margin-bottom: 1.5rem; line-height: 1.4;
}
.security-notice svg { flex-shrink: 0; color: #2e7d32; }
.onboard-hint {
  font-size: 0.82rem; color: var(--text-muted); line-height: 1.5;
  text-align: center; margin: 0.5rem 0 1rem; padding: 0 0.5rem;
}
.onboard-questions { display: flex; flex-direction: column; gap: 0; margin-bottom: 1rem; }
.onboard-q {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.55rem 0; border-bottom: 1px solid var(--border-light); gap: 1rem;
}
.onboard-q:last-child { border-bottom: none; }
.onboard-q-left { flex: 1; min-width: 0; }
.onboard-q-label { display: block; font-size: 0.8rem; font-weight: 600; color: var(--text); margin: 0; }
.onboard-q-hint { font-size: 0.68rem; color: var(--text-muted); margin: 0.1rem 0 0; }
.onboard-toggle { display: flex; gap: 0.25rem; flex-shrink: 0; }
.onboard-opt {
  padding: 0.3rem 0.6rem; border: 1.5px solid var(--border);
  background: var(--white); border-radius: 100px; font-size: 0.7rem;
  font-weight: 500; color: var(--text-secondary); cursor: pointer; transition: all 0.15s;
  text-align: center; font-family: inherit; white-space: nowrap;
}
.onboard-opt:hover { border-color: var(--primary); color: var(--primary); }
.onboard-opt.selected { border-color: var(--primary); background: var(--primary-lighter); color: var(--primary); font-weight: 600; }
.onboard-q .form-select {
  width: auto; min-width: 140px; padding: 0.3rem 0.6rem; font-size: 0.75rem;
  border-radius: 100px; border-width: 1.5px;
}
.account-questions .onboard-q { padding: 0.5rem 0; }
.account-situation-desc { font-size: 0.78rem; color: var(--text-muted); margin: 0 0 0.25rem; line-height: 1.4; }
.field-error {
  margin-top: 0.5rem; font-size: 0.82rem; color: var(--red);
  animation: fadeIn 0.2s ease;
}
.field-success {
  margin-top: 0.5rem; padding: 0.75rem 1rem; font-size: 0.85rem; color: var(--green);
  background: var(--green-bg); border: 1px solid var(--green-border); border-radius: var(--radius-sm);
  animation: fadeIn 0.2s ease; text-align: center; line-height: 1.5;
}

/* ── Password Strength ── */
.password-strength {
  margin-top: 0.5rem; display: flex; align-items: center; gap: 0.65rem;
}
.strength-bars {
  display: flex; gap: 3px; flex: 1;
}
.strength-bar {
  height: 4px; flex: 1; border-radius: 2px; background: var(--border);
  transition: background 0.3s;
}
.strength-bar.active.weak { background: var(--red); }
.strength-bar.active.fair { background: var(--orange); }
.strength-bar.active.good { background: #f59f00; }
.strength-bar.active.strong { background: var(--green); }
.strength-label {
  font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em;
  min-width: 50px; text-align: right;
}
.strength-label.weak { color: var(--red); }
.strength-label.fair { color: var(--orange); }
.strength-label.good { color: #f59f00; }
.strength-label.strong { color: var(--green); }

/* ── Auth Divider ── */
.auth-divider {
  display: flex; align-items: center; gap: 1rem; margin: 1.25rem 0;
}
.auth-divider::before, .auth-divider::after {
  content: ''; flex: 1; height: 1px; background: var(--border);
}
.auth-divider span {
  font-size: 0.78rem; color: var(--text-muted); font-weight: 500; text-transform: uppercase; letter-spacing: 0.05em;
}

/* ── Google Button ── */
.btn-google {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.65rem;
  padding: 0.75rem 1.5rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius); color: var(--text); font-size: 0.92rem; font-weight: 600;
  cursor: pointer; transition: all 0.15s; font-family: inherit;
}
.btn-google:hover { border-color: var(--text-muted); box-shadow: var(--shadow); background: var(--surface-2); }
.btn-google svg { flex-shrink: 0; }

/* ── Auth Screen ── */
.auth-card { max-width: 420px; }
.auth-tabs {
  display: flex; gap: 0; margin-bottom: 1.5rem; border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); overflow: hidden;
}
.auth-tab {
  flex: 1; padding: 0.65rem; background: var(--white); border: none;
  font-size: 0.88rem; font-weight: 600; cursor: pointer; transition: all 0.15s;
  color: var(--text-muted);
}
.auth-tab.active {
  background: var(--primary); color: #fff;
}
.auth-card .btn-primary { margin-top: 0.5rem; }

/* ── Profile Setup ── */
.setup-card { max-width: 480px; }

/* ── Avatar ── */
.avatar-upload {
  width: 120px; height: 120px; border-radius: 50%; border: 2px dashed var(--border);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  cursor: pointer; transition: all 0.2s; margin: 0 auto 1.5rem; overflow: hidden;
  background: var(--surface-2); position: relative;
}
.avatar-upload:hover { border-color: var(--primary); background: var(--primary-lighter); }
.avatar-placeholder {
  display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--text-muted);
  width: 100%; height: 100%; gap: 0.25rem;
}
.avatar-hint {
  font-size: 0.6rem; color: var(--text-muted);
  font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em;
}
.avatar-img {
  width: 100%; height: 100%; object-fit: cover; border-radius: 50%;
}
/* ── Admin Header Button ── */
.admin-header-btn {
  width: 30px; height: 30px; border-radius: 8px; display: flex; align-items: center;
  justify-content: center; color: var(--text-muted); background: var(--bg);
  border: 1px solid var(--border); transition: all 0.2s; text-decoration: none;
}
.admin-header-btn:hover { color: var(--primary); border-color: var(--primary); background: var(--primary-lighter); }

/* ── Header Avatar ── */
.header-avatar {
  width: 36px; height: 36px; border-radius: 50%; overflow: hidden;
  background: var(--primary-lighter); display: flex; align-items: center; justify-content: center;
  cursor: pointer; border: 1.5px solid var(--border); transition: all 0.2s;
}
.header-avatar:hover { border-color: var(--primary); box-shadow: var(--shadow); }
.header-avatar img { width: 100%; height: 100%; object-fit: cover; }
.header-avatar-initials {
  font-size: 0.85rem; font-weight: 700; color: var(--primary);
}

/* ── Account avatar row ── */
/* ── Account Modal Layout ── */
.account-modal-content { max-width: 480px; }

.account-header {
  display: flex; align-items: center; gap: 1rem; margin-bottom: 1.5rem; padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-light);
}
.avatar-account {
  width: 80px; height: 80px; margin: 0; flex-shrink: 0; position: relative;
}
.avatar-account { cursor: pointer; }
.avatar-edit-badge {
  position: absolute; inset: 0; border-radius: 50%;
  background: rgba(0,0,0,0.45); display: flex; align-items: center; justify-content: center;
  color: #fff; opacity: 0; transition: opacity 0.15s; cursor: pointer;
}
.avatar-account:hover .avatar-edit-badge { opacity: 1; }
.account-header-info { flex: 1; }
.account-header-info h2 { margin: 0; font-size: 1.35rem; font-weight: 700; }
.account-header-sub { margin: 0.15rem 0 0; font-size: 0.8rem; color: var(--text-muted); }

.account-section-label {
  font-size: 0.65rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--text-muted); margin: 1.5rem 0 0.6rem; padding: 0;
}
.account-card {
  background: var(--surface-2); border: 1px solid var(--border-light);
  border-radius: var(--radius); padding: 1rem 1.2rem; margin-bottom: 0.25rem;
}
.account-card .form-group { margin-bottom: 0.75rem; }
.account-card .form-group:last-of-type { margin-bottom: 0.75rem; }
.account-card .btn-primary, .account-card .btn-outline { margin-top: 0.5rem; }

.account-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0.7rem 0; border-bottom: 1px solid var(--border-light);
}
.account-row:last-child { border-bottom: none; }
.account-row-label { font-size: 0.85rem; color: var(--text-muted); }
.account-row-value { font-size: 0.85rem; font-weight: 600; color: var(--text); text-align: right; }
.account-row-input {
  border: none; background: none; font-size: 0.85rem; font-weight: 600; color: var(--text);
  text-align: right; font-family: inherit; outline: none; width: 100%; padding: 0;
}
.account-row-input:focus { color: var(--primary); }

.account-plan-badge {
  background: var(--primary-lighter); color: var(--primary); padding: 0.2rem 0.65rem;
  border-radius: 100px; font-size: 0.75rem; font-weight: 700;
}
.account-billing-desc {
  font-size: 0.78rem; color: var(--text-muted); line-height: 1.5; margin: 0.75rem 0 0;
}

.account-notice {
  display: flex; align-items: flex-start; gap: 0.5rem; padding: 0.75rem 0;
  font-size: 0.8rem; color: var(--text-muted); line-height: 1.4;
}
.account-notice svg { flex-shrink: 0; margin-top: 0.1rem; color: var(--text-muted); }

/* ── Account Stats Grid ── */


/* ── Crop Modal ── */
.crop-container { max-height: 55vh; overflow: hidden; margin-bottom: 1rem; }
.crop-container img { max-width: 100%; display: block; }
.crop-actions { display: flex; gap: 0.5rem; justify-content: flex-end; }

input[type="number"], input[type="date"] {
  width: 100%; padding: 0.75rem 1rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text); font-size: 0.95rem; outline: none;
  transition: all 0.2s; font-family: inherit;
}
input[type="number"]:focus, input[type="date"]:focus {
  border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter);
}

/* ── Cost Tracking ── */
.cost-filters { display: flex; gap: 0.4rem; margin-bottom: 1rem; flex-wrap: wrap; }
.cost-filter {
  padding: 0.35rem 0.85rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: 100px; font-size: 0.78rem; font-weight: 600; cursor: pointer; transition: all 0.15s;
  color: var(--text-secondary);
}
.cost-filter:hover { border-color: var(--primary); color: var(--primary); }
.cost-filter.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.cost-table-wrapper { overflow-x: auto; }
.cost-table {
  width: 100%; min-width: 620px; border-collapse: collapse; font-size: 0.85rem;
  background: var(--white); border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--border); table-layout: fixed;
}
.cost-table th {
  text-align: left; font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.05em;
  font-weight: 600; color: var(--text-muted); padding: 0.7rem 0.85rem;
  background: var(--surface-2); border-bottom: 1px solid var(--border);
}
.cost-table th:nth-child(1) { width: 30%; }
.cost-table th:nth-child(2) { width: 25%; }
.cost-table th:nth-child(3) { width: 18%; }
.cost-table th:nth-child(4) { width: 13%; }
.cost-table th:nth-child(5) { width: 14%; }
.cost-group-header.zakelijk + .cost-table-wrapper .cost-table th { background: #e7f5ff; color: #1971c2; border-color: var(--blue-border); }
.cost-group-header.privé + .cost-table-wrapper .cost-table th { background: #f3e8ff; color: #7b2d8e; border-color: #d0bfff;
}
.cost-table td {
  padding: 0.65rem 0.85rem; border-bottom: 1px solid var(--border-light); color: var(--text-secondary);
  vertical-align: middle;
}
.cost-table td:first-child {
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cost-table td:first-child img,
.cost-table td:first-child .insurer-logo-fallback { vertical-align: middle; margin-right: 0.5rem; }
.cost-table tr:hover td { background: var(--surface-2); }
.cost-table tr:last-child td { border-bottom: none; }
.cost-policy-name { font-weight: 600; color: var(--text); max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cost-table td:nth-child(2) { white-space: nowrap; }
.cost-premium { white-space: nowrap; }
.cost-period { white-space: nowrap; color: var(--text-muted); font-size: 0.8rem; }
.cost-tag { font-size: 0.65rem; padding: 0.15rem 0.45rem; }
.cost-share-badge {
  display: inline-block; font-size: 0.7rem; font-weight: 700;
  padding: 0.15rem 0.5rem; border-radius: 100px; white-space: nowrap;
}
.cost-share-badge.full { background: var(--green-bg, #e6fcf5); color: var(--green, #0ca678); border: 1px solid var(--green-border, #b2f2bb); }
.cost-share-badge.partial { background: var(--primary-lighter, #dbe4ff); color: var(--primary, #3b5bdb); border: 1px solid var(--primary, #3b5bdb); }
.cost-share-sub {
  display: block; font-size: 0.7rem; color: var(--text-muted);
  font-weight: 500; margin-top: 0.15rem;
}
.cost-totals {
  margin-top: 0.75rem; display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem;
}
.cost-total-item {
  padding: 0.7rem 1rem; background: var(--white); border: 1px solid var(--border-light);
  border-radius: var(--radius-sm); display: flex; justify-content: space-between; align-items: center;
}
.cost-total-label { font-size: 0.82rem; color: var(--text-muted); }
.cost-total-value { font-size: 0.9rem; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; }
.cost-total-main {
  background: var(--primary-lighter); border-color: #bac8ff;
}
.cost-total-main .cost-total-label { color: var(--primary-dark); font-weight: 600; }
.cost-total-main .cost-total-value { color: var(--primary-dark); }

/* ── Payments Timeline ── */
.payments-timeline { display: flex; flex-direction: column; gap: 1.25rem; }
.payment-month { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border-light); }
.payment-month.current { border-color: var(--primary); border-width: 1.5px; }
.payment-month-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0.65rem 1rem; background: var(--surface-2); font-weight: 700; font-size: 0.88rem;
  text-transform: capitalize; color: var(--text-secondary);
}
.payment-month.current .payment-month-header { background: var(--primary-lighter); color: var(--primary-dark); }
.payment-month-total { font-variant-numeric: tabular-nums; font-size: 0.85rem; }
.payment-items { display: flex; flex-direction: column; }
.payment-item {
  display: flex; align-items: center; gap: 0.75rem; padding: 0.7rem 1rem;
  border-top: 1px solid var(--border-light); background: var(--white); cursor: pointer;
  transition: background 0.12s;
}
.payment-item:hover { background: var(--surface-2); }
.payment-item.past { opacity: 0.5; }
.payment-item.today { background: #fffbe6; }
.payment-item.today:hover { background: #fff7cc; }
.payment-date-col {
  width: 36px; height: 36px; border-radius: 50%; background: var(--surface-2);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.payment-item.today .payment-date-col { background: var(--primary); }
.payment-item.today .payment-day { color: #fff; }
.payment-day { font-weight: 700; font-size: 0.85rem; color: var(--text-secondary); }
.payment-info { flex: 1; display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
.payment-insurer { font-size: 0.85rem; font-weight: 600; color: var(--text); display: flex; align-items: center; gap: 0.4rem; }
.payment-policy { font-size: 0.75rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.payment-amount-col { text-align: right; flex-shrink: 0; display: flex; flex-direction: column; align-items: flex-end; gap: 0.15rem; }
.payment-amount { font-weight: 700; font-size: 0.9rem; color: var(--text); font-variant-numeric: tabular-nums; }
.payment-time-label { font-size: 0.65rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.03em; color: var(--text-muted); }
.payment-time-label.today { color: var(--primary); }
.payment-time-label.past { color: var(--green); }

.cost-group { margin-bottom: 1.25rem; border: 1px solid var(--border-light); border-radius: var(--radius); overflow: hidden; }
.cost-group-header {
  padding: 0.55rem 0.85rem; font-weight: 700; font-size: 0.85rem;
  border-bottom: 1px solid var(--border-light);
}
.cost-group-header.privé { background: #f3e8ff; color: #7b2d8e; border-color: #d0bfff; }
.cost-group-header.zakelijk { background: var(--blue-bg); color: #1971c2; border-color: var(--blue-border); }
.cost-group-header:not(.privé):not(.zakelijk) { background: var(--surface-2); color: var(--text-secondary); }
.cost-group .cost-table { border: none; border-radius: 0; }
.cost-totals-sm { margin-top: 0.4rem; margin-bottom: 0; }
.cost-totals-sm .cost-total-item { padding: 0.45rem 0.85rem; }
.cost-totals-sm .cost-total-label { font-size: 0.75rem; }
.cost-totals-sm .cost-total-value { font-size: 0.82rem; }

/* ── Person Management ── */
.persons-list { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: 1rem; }
.person-item {
  display: flex; align-items: center; gap: 0.5rem; padding: 0.5rem 0.75rem;
  background: var(--surface-2); border-radius: var(--radius-sm); font-size: 0.85rem;
}
.person-name { flex: 1; font-weight: 600; }
.person-remove { background: none; border: none; font-size: 1rem; cursor: pointer; color: var(--text-muted); padding: 0 0.3rem; }
.person-remove:hover { color: var(--red); }
.person-add-row { padding-top: 0.5rem; border-top: 1px solid var(--border-light); }
.form-select {
  width: 100%; padding: 0.7rem 1rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text); font-size: 0.9rem; font-family: inherit;
  outline: none; cursor: pointer; appearance: auto;
}
.form-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter); }

/* Person multi-select checkbox list */
.person-check-list { display: flex; flex-direction: column; gap: 0.4rem; }
.person-check {
  display: flex; align-items: center; gap: 0.6rem; padding: 0.6rem 0.8rem;
  background: var(--white); border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  cursor: pointer; transition: border-color 0.15s, background 0.15s;
  font-size: 0.9rem; color: var(--text);
}
.person-check:hover { border-color: var(--primary); }
.person-check input[type="checkbox"] {
  width: 18px; height: 18px; accent-color: var(--primary); cursor: pointer; flex-shrink: 0;
}
.person-check:has(input:checked) {
  border-color: var(--primary); background: var(--primary-lighter, #dbe4ff);
}

/* ── Global progress bar (top) ── */
.q-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px;
  z-index: 10000; pointer-events: none;
  background: transparent;
  opacity: 0; transition: opacity 0.15s;
}
.q-progress.active { opacity: 1; }
.q-progress-bar {
  position: absolute; top: 0; left: 0; height: 100%;
  width: 30%;
  background: linear-gradient(90deg, transparent 0%, var(--primary) 50%, transparent 100%);
  animation: q-progress-slide 1.1s ease-in-out infinite;
}
@keyframes q-progress-slide {
  0% { left: -30%; }
  100% { left: 100%; }
}

/* Subtle wait cursor on whole body during in-flight requests */
body.q-busy { cursor: progress; }
body.q-busy button:not(:disabled),
body.q-busy a { cursor: progress; }

/* ── Toast ── */
.q-toast {
  position: fixed; top: 16px; left: 50%; transform: translateX(-50%) translateY(-20px);
  z-index: 9999; max-width: 92%; min-width: 280px;
  padding: 0.85rem 1.1rem;
  background: var(--text); color: #fff;
  font-size: 0.9rem; font-weight: 500;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  opacity: 0; pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  text-align: center;
}
.q-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.q-toast.success { background: var(--green, #0ca678); }
.q-toast.error { background: var(--red, #e03131); }
@media (max-width: 600px) {
  .q-toast { top: 12px; font-size: 0.85rem; padding: 0.75rem 1rem; min-width: 0; width: calc(100% - 24px); }
}

/* ── What's new modal ── */
/* ── Announcement popup ── */
.announcement-badge {
  display: inline-block; font-size: 0.72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.06em;
  padding: 0.25rem 0.6rem; border-radius: 100px;
  background: var(--primary-lighter, #dbe4ff); color: var(--primary, #3b5bdb);
}
.announcement-body {
  font-size: 0.92rem; color: var(--text-secondary); line-height: 1.6;
  max-height: 50vh; overflow-y: auto;
}

.whats-new-list {
  display: flex; flex-direction: column; gap: 0.6rem;
  max-height: 60vh; overflow-y: auto;
}
.whats-new-item {
  display: flex; gap: 0.85rem; align-items: flex-start;
  padding: 0.8rem 0.9rem;
  background: var(--surface-2, #f4f5f8);
  border-radius: var(--radius-sm);
}
.whats-new-icon { font-size: 1.5rem; line-height: 1.2; flex-shrink: 0; }
.whats-new-text { display: flex; flex-direction: column; gap: 0.2rem; min-width: 0; }
.whats-new-text strong { font-size: 0.95rem; color: var(--text); }
.whats-new-text span { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.5; }

/* ── Beta program ── */
.beta-status {
  padding: 0.7rem 0.85rem; border-radius: var(--radius-sm);
  display: flex; flex-direction: column; gap: 0.2rem;
  font-size: 0.85rem;
}
.beta-status strong { font-size: 0.92rem; }
.beta-status span { color: var(--text-secondary); font-size: 0.82rem; line-height: 1.45; }
.beta-status.pending { background: var(--orange-bg, #fff4e6); border: 1px solid var(--orange-border, #ffd8a8); }
.beta-status.pending strong { color: #b66d00; }
.beta-status.approved { background: var(--green-bg, #e6fcf5); border: 1px solid var(--green-border, #b2f2bb); }
.beta-status.approved strong { color: var(--green, #0ca678); }
.beta-status.rejected { background: var(--red-bg, #fff5f5); border: 1px solid var(--red-border, #ffc9c9); }
.beta-status.rejected strong { color: var(--red, #e03131); }

.beta-fb-list { display: flex; flex-direction: column; gap: 0.4rem; }
.beta-fb-row {
  display: flex; gap: 0.7rem; align-items: flex-start; justify-content: space-between;
  padding: 0.65rem 0.85rem; background: var(--white);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.beta-fb-info { flex: 1; min-width: 0; }
.beta-fb-title { font-weight: 600; font-size: 0.88rem; color: var(--text); display: flex; align-items: center; gap: 0.4rem; flex-wrap: wrap; }
.beta-fb-type { font-size: 0.65rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--primary); background: var(--primary-lighter, #dbe4ff); padding: 0.1rem 0.4rem; border-radius: 100px; }
.beta-fb-details { font-size: 0.78rem; color: var(--text-muted); margin-top: 0.2rem; line-height: 1.5; }
.beta-fb-status {
  font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  padding: 0.2rem 0.55rem; border-radius: 100px; flex-shrink: 0; white-space: nowrap;
  background: var(--surface-2, #f4f5f8); color: var(--text-muted);
}
.beta-fb-status.status-in_behandeling, .beta-fb-status.status-gepland {
  background: var(--primary-lighter, #dbe4ff); color: var(--primary);
}
.beta-fb-status.status-afgerond {
  background: var(--green-bg, #e6fcf5); color: var(--green, #0ca678);
}
.beta-fb-status.status-afgewezen {
  background: var(--red-bg, #fff5f5); color: var(--red, #e03131);
}

/* ── Onboarding group prompts (nudges during profile setup) ── */
.onboard-group-prompt { margin: 0.25rem 0 0.75rem; }
.onboard-group-card {
  display: flex; align-items: center; gap: 0.8rem;
  padding: 0.8rem 1rem;
  background: var(--primary-lighter, #dbe4ff);
  border: 1px solid var(--primary, #3b5bdb);
  border-radius: var(--radius-sm);
}
.onboard-group-icon { font-size: 1.6rem; line-height: 1; flex-shrink: 0; }
.onboard-group-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0.15rem; }
.onboard-group-text strong { font-size: 0.9rem; color: var(--text); }
.onboard-group-text span { font-size: 0.8rem; color: var(--text-secondary); line-height: 1.45; }
.onboard-group-card button { flex-shrink: 0; }

/* ── Group cards (multiple groups per user) ── */
.group-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 0.85rem 1rem;
  margin-bottom: 0.75rem;
}
.group-card-head {
  display: flex; align-items: center; gap: 0.65rem; margin-bottom: 0.7rem;
  padding-bottom: 0.6rem; border-bottom: 1px solid var(--border-light);
}
.group-card-icon { font-size: 1.5rem; line-height: 1; }
.group-card-titles { flex: 1; min-width: 0; }
.group-card-name { font-weight: 700; font-size: 0.95rem; color: var(--text); }
.group-card-type { font-size: 0.72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; font-weight: 600; }

/* ── Household ── */
.hh-incoming { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 0.75rem; }
.hh-invite-card {
  display: flex; gap: 0.75rem; align-items: center;
  padding: 0.75rem; border-radius: var(--radius-sm);
  background: var(--primary-lighter, #dbe4ff); border: 1px solid var(--primary, #3b5bdb);
}
.hh-invite-icon { font-size: 1.3rem; flex-shrink: 0; }
.hh-invite-text { flex: 1; min-width: 0; }
.hh-invite-title { font-weight: 700; font-size: 0.9rem; color: var(--text); }
.hh-invite-sub { font-size: 0.78rem; color: var(--text-secondary); }
.hh-invite-actions { display: flex; gap: 0.4rem; flex-shrink: 0; }

.hh-members, .hh-pending-list { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 0.5rem; }
.hh-member-row, .hh-pending-row {
  display: flex; gap: 0.65rem; align-items: center;
  padding: 0.5rem 0.65rem; border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--white);
}
.hh-pending-row { background: var(--surface-2, #f8f9fb); border-style: dashed; }
.hh-member-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.85rem; flex-shrink: 0;
}
.hh-member-avatar.pending { background: var(--text-muted); font-size: 0.6rem; letter-spacing: 1px; }
.hh-member-info { flex: 1; min-width: 0; }
.hh-member-name {
  font-size: 0.88rem; color: var(--text); font-weight: 600;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.hh-self-badge {
  display: inline-block; margin-left: 0.4rem; padding: 0.05rem 0.4rem;
  background: var(--green-bg, #e6fcf5); color: var(--green, #0ca678);
  font-size: 0.65rem; font-weight: 700; border-radius: 100px;
  text-transform: uppercase; letter-spacing: 0.04em;
}
.hh-member-sub { font-size: 0.72rem; color: var(--text-muted); }
.hh-action-btn {
  background: var(--surface-2, #f1f3f5);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  cursor: pointer; font-size: 0.7rem; font-weight: 600;
  padding: 0.25rem 0.55rem;
  border-radius: 100px; flex-shrink: 0;
  letter-spacing: 0.02em;
  transition: all 0.15s;
}
.hh-action-btn:hover {
  color: var(--red, #e03131);
  border-color: var(--red, #e03131);
  background: var(--red-bg, #fff5f5);
}

/* Compact × close button used in member rows */
.hh-x-btn {
  background: transparent; border: none; color: var(--text-muted);
  width: 24px; height: 24px; padding: 0; line-height: 1;
  border-radius: 50%; cursor: pointer; flex-shrink: 0;
  font-size: 1.1rem; font-weight: 400;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all 0.15s; opacity: 0.7;
}
.hh-x-btn:hover { background: var(--red-bg, #fff5f5); color: var(--red, #e03131); opacity: 1; }
.hh-member-actions { display: flex; align-items: center; gap: 0.3rem; flex-shrink: 0; }
.hh-expand-arrow {
  font-size: 0.85rem; color: var(--text-muted);
  transition: transform 0.2s; opacity: 0.6;
}
.hh-member-row { cursor: pointer; transition: background 0.12s; }
.hh-member-row:hover { background: var(--surface-2, #f7f8fa); }
.hh-member-row[data-expanded="true"] .hh-expand-arrow { transform: rotate(180deg); }
.hh-member-extra {
  max-height: 0; overflow: hidden;
  transition: max-height 0.25s ease, margin-top 0.25s ease;
  margin-top: 0;
}
.hh-member-row[data-expanded="true"] .hh-member-extra {
  max-height: 80px; margin-top: 0.5rem;
}
.hh-member-row[data-expanded="true"] .hh-member-sub { padding-top: 0.4rem; border-top: 1px dashed var(--border-light); }

/* Member row: relationship + percentage controls — compact, single line */
.hh-member-row { align-items: flex-start; padding: 0.7rem 0.85rem; }
.hh-member-controls {
  display: inline-flex; gap: 0.35rem; margin-top: 0.45rem;
  align-items: center; flex-wrap: nowrap;
}
.hh-relationship-select {
  font-size: 0.78rem; font-weight: 500;
  padding: 0.3rem 1.4rem 0.3rem 0.55rem;
  height: 28px;
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5' viewBox='0 0 8 5'%3E%3Cpath d='M1 1l3 3 3-3' stroke='%238b90a0' stroke-width='1.4' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 0.5rem center / 8px;
  border: 1px solid var(--border); border-radius: 6px;
  color: var(--text); appearance: none; cursor: pointer; outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  min-width: 0;
}
.hh-relationship-select:hover { border-color: var(--text-muted); }
.hh-relationship-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter, #dbe4ff); }

.hh-pct-wrap {
  position: relative; display: inline-flex; align-items: center;
  width: 78px;
}
.hh-pct-input {
  width: 100%; height: 28px;
  padding: 0.3rem 1.5rem 0.3rem 0.55rem; font-size: 0.82rem; font-weight: 600;
  border: 1px solid var(--border); border-radius: 6px;
  background: var(--white); color: var(--text); outline: none;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
  text-align: left;
  -moz-appearance: textfield;
}
.hh-pct-input::-webkit-outer-spin-button,
.hh-pct-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.hh-pct-input:hover { border-color: var(--text-muted); }
.hh-pct-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter, #dbe4ff); }
.hh-pct-suffix {
  position: absolute; right: 0.55rem; pointer-events: none;
  font-size: 0.75rem; color: var(--text-muted); font-weight: 500;
}

.hh-total-warning {
  margin-top: 0.5rem; padding: 0.5rem 0.7rem;
  font-size: 0.78rem; font-weight: 500;
  border-radius: var(--radius-sm);
  background: var(--orange-bg, #fff4e6); color: #b66d00;
  border: 1px solid var(--orange-border, #ffd8a8);
}
.hh-total-warning.over {
  background: var(--red-bg, #fff5f5); color: var(--red, #e03131);
  border-color: var(--red-border, #ffc9c9);
}

.hh-name-edit {
  font-size: 0.92rem; font-weight: 700; padding: 0.2rem 0.5rem;
  background: transparent; border: 1px solid transparent;
  border-radius: 6px; color: var(--text); font-family: inherit;
  outline: none; min-width: 0; max-width: 200px;
  transition: background 0.15s, border-color 0.15s;
}
.hh-name-edit:hover { background: var(--surface-2, #f4f5f8); }
.hh-name-edit:focus { background: var(--white); border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter, #dbe4ff); }

.hh-member-avatar.nonaccount { background: var(--text-muted); }
.hh-add-row {
  display: flex; gap: 0.5rem; margin-top: 0.75rem; flex-wrap: wrap;
}

/* Share toggle in policy detail */
.hh-share-toggle {
  display: flex; gap: 0.7rem; align-items: flex-start;
  padding: 0.7rem; border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  cursor: pointer; background: var(--white);
}
.hh-share-toggle:has(input:checked) {
  border-color: var(--primary); background: var(--primary-lighter, #dbe4ff);
}
.hh-share-toggle input[type="checkbox"] {
  width: 18px; height: 18px; accent-color: var(--primary); cursor: pointer; flex-shrink: 0; margin-top: 0.15rem;
}
.hh-share-text { flex: 1; min-width: 0; font-size: 0.9rem; color: var(--text); }
.modal-sm { max-width: 420px; }
#personModal { z-index: 200; }
.form-input {
  width: 100%; padding: 0.7rem 1rem; background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text); font-size: 0.9rem; font-family: inherit;
  outline: none; transition: all 0.2s;
}
.form-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-lighter); }
.form-hint { font-size: 0.75rem; color: var(--text-muted); margin: 0.3rem 0 0; }
.toggle-row-2 { display: flex; gap: 0.35rem; }

/* ── Feedback FAB ── */
.feedback-fab {
  position: fixed; bottom: 1.25rem; right: 1.25rem; z-index: 50;
  display: flex; align-items: center; gap: 0.4rem;
  padding: 0.6rem 1rem; background: var(--text); color: #fff;
  border: none; border-radius: 100px; box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  font-size: 0.8rem; font-weight: 600; font-family: inherit; cursor: pointer;
  transition: all 0.2s;
}
.feedback-fab:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.25); }
.feedback-fab svg { flex-shrink: 0; }
.feedback-fab-icon { display: inline-flex; align-items: center; line-height: 1; flex-shrink: 0; }
#betaFabLabel, #betaFabIcon { transition: opacity 0.3s ease; }
@media (max-width: 600px) {
  .feedback-fab {
    bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
    right: calc(1.25rem + env(safe-area-inset-right, 0px));
    padding: 0.55rem 0.95rem; font-size: 0.78rem;
  }
}

/* ── Footer ── */
.app-footer {
  display: flex; justify-content: center; align-items: center; gap: 0.75rem;
  padding: 2rem 1rem 1.5rem; font-size: 0.75rem; color: var(--text-muted);
}
.app-footer a { color: var(--text-muted); text-decoration: none; }
.app-footer a:hover { color: var(--primary); }
.footer-dot { width: 3px; height: 3px; border-radius: 50%; background: var(--text-muted); }

/* ── Cookie notice ── */
.cookie-notice {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 1000;
  background: var(--white); border-top: 1px solid var(--border);
  padding: 0.85rem 1.25rem; display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; box-shadow: 0 -2px 8px rgba(0,0,0,0.06);
}
.cookie-notice p { font-size: 0.82rem; color: var(--text-secondary); margin: 0; }
.cookie-notice a { color: var(--primary); text-decoration: none; font-weight: 500; }
.cookie-notice a:hover { text-decoration: underline; }
.cookie-buttons { display: flex; gap: 0.5rem; flex-shrink: 0; }
.cookie-accept {
  background: var(--primary); color: #fff; border: none; border-radius: var(--radius-sm);
  padding: 0.4rem 1rem; font-size: 0.8rem; font-weight: 600; cursor: pointer; white-space: nowrap;
}
.cookie-accept:hover { background: var(--primary-dark); }
.cookie-reject {
  background: none; color: var(--text-muted); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 0.4rem 1rem; font-size: 0.8rem; font-weight: 500; cursor: pointer; white-space: nowrap;
}
.cookie-reject:hover { color: var(--text-secondary); border-color: var(--text-muted); }

/* ── Responsive ── */
@media (max-width: 600px) {
  .policies-grid { grid-template-columns: 1fr; }
  .policy-list-row {
    display: grid;
    grid-template-columns: 24px 1fr auto;
    grid-template-rows: auto auto;
    gap: 0.05rem 0.5rem;
    padding: 0.6rem 0.7rem;
    align-items: center;
  }
  .policy-list-logo {
    grid-column: 1; grid-row: 1 / 3;
    align-self: center;
  }
  .policy-list-insurer {
    grid-column: 2; grid-row: 1;
    min-width: 0; font-size: 0.85rem; max-width: none;
    overflow: hidden;
  }
  .policy-list-badges { display: none; }
  .policy-list-cost {
    grid-column: 3; grid-row: 1 / 3;
    min-width: auto; font-size: 0.82rem; font-weight: 700;
    text-align: right; align-self: center;
  }
  .policy-list-name {
    grid-column: 2; grid-row: 2;
    display: block; font-size: 0.73rem; color: var(--text-muted);
    overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
  }
  .view-toggle-btn { padding: 0.35rem 0.45rem; }
  .section { padding: 1.25rem 0.75rem; }
  .section h2 { font-size: 1.05rem; }
  header { padding: 0.5rem 0.75rem; }
  .header-inner { padding: 0; }
  .header-right .zorgpas-btn,
  .header-right .claim-btn { display: none; }
  .hamburger-btn { display: flex; }
  .section-header { flex-direction: column; align-items: flex-start; gap: 0.6rem; }
  .onboard-card { padding: 1.5rem 1.25rem; }

  /* Detail modal */
  .modal { padding: 0.5rem; align-items: flex-start; padding-top: 2rem; padding-bottom: 2rem; }
  .modal-content { padding: 1.25rem; border-radius: var(--radius); flex-shrink: 0; max-height: none; }

  /* Notification dropdown centered on mobile */
  .todo-dropdown {
    position: fixed; top: 60px; left: 0.75rem; right: 0.75rem;
    width: auto; max-height: 70vh; overflow-y: auto;
  }
  .detail-grid { grid-template-columns: 1fr; }
  .detail-stat { padding: 0.6rem 0.75rem; }
  .detail-cost-edit { grid-template-columns: 1fr; }

  /* Gap items */
  .gap-item { padding: 0.5rem 0.5rem; gap: 0.4rem; flex-wrap: nowrap; }
  .gap-name { font-size: 0.82rem; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .gap-name .gap-note { display: block; overflow: hidden; text-overflow: ellipsis; }
  .gap-label { font-size: 0.6rem; padding: 0.1rem 0.3rem; flex-shrink: 0; white-space: nowrap; }
  .gap-scope { font-size: 0.55rem; }
  .gap-hide-btn, .gap-unhide-btn { opacity: 1; font-size: 0.9rem; padding: 0.3rem 0.5rem; }
  .suggestion-header { padding: 0.5rem 0.5rem; gap: 0.4rem; flex-wrap: nowrap; }
  .suggestion-detail { padding: 0 0.5rem 0.6rem 1.5rem; }
  .gap-note { font-size: 0.68rem; }
  .independer-card { padding: 0.85rem 1rem; }
  .independer-btn { padding: 0.5rem 1.2rem; font-size: 0.78rem; }

  /* Cost table */
  .cost-table th, .cost-table td { padding: 0.5rem 0.5rem; font-size: 0.75rem; }
  .cost-table td:first-child { white-space: normal; }
  .cost-tag { font-size: 0.58rem; padding: 0.1rem 0.35rem; }
  .cost-group-header { padding: 0.45rem 0.65rem; font-size: 0.8rem; }
  .cost-filters { gap: 0.3rem; }
  .cost-filter { font-size: 0.72rem; padding: 0.3rem 0.6rem; }
  .cost-totals { gap: 0.4rem; }
  .cost-total-item { padding: 0.5rem 0.75rem; }

  /* Payments */
  .payment-item { padding: 0.55rem 0.75rem; gap: 0.5rem; }
  .payment-month-header { padding: 0.5rem 0.75rem; font-size: 0.82rem; }
  .payment-insurer { font-size: 0.8rem; }
  .payment-policy { font-size: 0.7rem; }
  .payment-amount { font-size: 0.82rem; }
  .payment-date-col { width: 32px; height: 32px; }
  .payment-day { font-size: 0.78rem; }

  /* Account modal */
  .account-modal-content { padding: 1.25rem; }
  .account-header { gap: 0.75rem; margin-bottom: 1rem; padding-bottom: 1rem; }
  .avatar-account { width: 60px; height: 60px; }
  .account-header-info h2 { font-size: 1.1rem; }
  .account-card { padding: 0.85rem; }
  .account-section-label { font-size: 0.65rem; margin: 1rem 0 0.4rem; }
  .account-row { padding: 0.5rem 0; }
  .onboard-q { padding: 0.4rem 0; }
  .onboard-q-label { font-size: 0.78rem; }
  .onboard-q .form-select { min-width: 120px; font-size: 0.7rem; padding: 0.25rem 0.5rem; }

  /* Policy cards */
  .policy-card { padding: 1.1rem; }
  .policy-insurer { font-size: 0.95rem; gap: 0.5rem; }
  .policy-name { font-size: 0.8rem; }
  .policy-categories { gap: 0.25rem; }
  .policy-tag { font-size: 0.62rem; padding: 0.15rem 0.45rem; }
  .policy-type-badge { font-size: 0.52rem; padding: 0.15rem 0.45rem; }
  .policy-summary { font-size: 0.78rem; }

  .claim-btn, .zorgpas-btn { font-size: 0.75rem; padding: 0.4rem 0.8rem; gap: 0.35rem; }
  .claim-btn svg, .zorgpas-btn svg { width: 12px; height: 12px; }
  .claim-match-header { flex-direction: column; gap: 0.3rem; align-items: flex-start; }
  .numpad-btn { padding: 0.7rem; font-size: 1rem; }
}

/* ── Claim / Schade melden ── */
.claim-btn {
  display: inline-flex; align-items: center; gap: 0.45rem;
  padding: 0.5rem 1rem; background: var(--orange-bg); color: var(--orange);
  border: 1.5px solid var(--orange-border); border-radius: 100px;
  font-size: 0.82rem; font-weight: 600; cursor: pointer;
  transition: all 0.15s; font-family: inherit; white-space: nowrap;
}
.claim-btn:hover { background: var(--orange); color: #fff; border-color: var(--orange); }
.claim-btn:hover svg { stroke: #fff; }
.claim-btn svg { flex-shrink: 0; }

.claim-modal-header { text-align: center; margin-bottom: 1.25rem; }
.claim-modal-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--orange-bg); color: var(--orange); margin-bottom: 0.75rem;
}
.claim-modal-desc {
  font-size: 0.88rem; color: var(--text-muted); line-height: 1.55; margin-top: 0.3rem;
}

.claim-submit-btn {
  display: flex; align-items: center; justify-content: center; gap: 0.45rem;
  width: 100%; margin-top: 0.75rem;
}

.claim-result { margin-top: 1rem; }

.claim-urgent {
  display: flex; align-items: flex-start; gap: 0.6rem;
  padding: 0.85rem 1rem; background: var(--red-bg); border: 1px solid var(--red-border);
  border-radius: var(--radius-sm); color: var(--red); font-size: 0.88rem;
  font-weight: 600; line-height: 1.5; margin-bottom: 0.75rem;
}
.claim-urgent svg { flex-shrink: 0; margin-top: 0.1rem; }

.claim-matches { display: flex; flex-direction: column; gap: 0.6rem; }

.claim-match {
  border: 1px solid var(--border-light); border-radius: var(--radius-sm);
  padding: 1rem; background: var(--white); box-shadow: var(--shadow-sm);
}
.claim-match.high { border-left: 3px solid var(--green); }
.claim-match.medium { border-left: 3px solid var(--orange); }
.claim-match.low { border-left: 3px solid var(--border); }

.claim-match-header {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 0.5rem;
  margin-bottom: 0.5rem;
}
.claim-match-insurer { font-size: 0.95rem; font-weight: 700; color: var(--text); }
.claim-match-policy { font-size: 0.82rem; color: var(--text-muted); margin-top: 0.1rem; }
.claim-match-cat {
  font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--primary); background: var(--primary-lighter); padding: 0.12rem 0.4rem;
  border-radius: 100px; margin-left: 0.3rem;
}

.claim-relevance-badge {
  font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  padding: 0.2rem 0.5rem; border-radius: 100px; flex-shrink: 0; white-space: nowrap;
}
.claim-relevance-badge.high { color: #087f5b; background: var(--green-bg); border: 1px solid var(--green-border); }
.claim-relevance-badge.medium { color: #e67700; background: var(--orange-bg); border: 1px solid var(--orange-border); }
.claim-relevance-badge.low { color: var(--text-muted); background: var(--surface-2); border: 1px solid var(--border); }

.claim-match-reason {
  font-size: 0.85rem; color: var(--text-secondary); line-height: 1.55; margin-bottom: 0.5rem;
}

.claim-match-status {
  display: inline-flex; align-items: center; gap: 0.35rem;
  font-size: 0.8rem; font-weight: 600; padding: 0.35rem 0.65rem;
  border-radius: var(--radius-xs); margin-bottom: 0.5rem;
}
.claim-match-status.covered { color: #087f5b; background: var(--green-bg); border: 1px solid var(--green-border); }
.claim-match-status.not-covered { color: var(--red); background: var(--red-bg); border: 1px solid var(--red-border); }
.claim-match-status.unclear { color: var(--orange); background: var(--orange-bg); border: 1px solid var(--orange-border); }

.claim-match-steps {
  font-size: 0.82rem; color: var(--text-secondary); line-height: 1.55;
  padding: 0.5rem 0.65rem; background: var(--surface-2); border-radius: var(--radius-xs);
  margin-bottom: 0.4rem;
}

.claim-match-detail {
  font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 0.4rem;
}

.claim-phone-btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.45rem 0.85rem; background: var(--green-bg); color: #087f5b;
  border: 1px solid var(--green-border); border-radius: 100px;
  font-size: 0.8rem; font-weight: 600; text-decoration: none;
  transition: all 0.15s; margin-top: 0.25rem;
}
.claim-phone-btn:hover { background: var(--green); color: #fff; border-color: var(--green); }
.claim-phone-btn:hover svg { stroke: #fff; }
.claim-phone-btn svg { flex-shrink: 0; }

.claim-general-advice {
  margin-top: 0.75rem; padding: 0.85rem 1rem; background: var(--blue-bg);
  border: 1px solid var(--blue-border); border-radius: var(--radius-sm);
  font-size: 0.85rem; color: var(--text-secondary); line-height: 1.55;
}

.claim-disclaimer {
  margin-top: 0.75rem; font-size: 0.72rem; color: var(--text-muted); line-height: 1.5;
  text-align: center;
}

.claim-error {
  color: var(--red); font-size: 0.88rem; text-align: center; padding: 1rem;
}

.claim-general {
  font-size: 0.88rem; color: var(--text-secondary); line-height: 1.55;
  text-align: center; padding: 1rem;
}

.claim-contact-block {
  margin-top: 0.5rem; padding: 0.65rem 0.85rem; background: var(--surface-2);
  border: 1px solid var(--border-light); border-radius: var(--radius-sm);
}
.claim-contact-title {
  display: flex; align-items: center; gap: 0.4rem;
  font-size: 0.78rem; font-weight: 700; color: var(--text);
  text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 0.4rem;
}
.claim-contact-title svg { color: var(--text-muted); }
.claim-contact-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; }

.claim-email-btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.45rem 0.85rem; background: var(--blue-bg); color: #1971c2;
  border: 1px solid var(--blue-border); border-radius: 100px;
  font-size: 0.8rem; font-weight: 600; text-decoration: none;
  transition: all 0.15s;
}
.claim-email-btn:hover { background: #1971c2; color: #fff; border-color: #1971c2; }
.claim-email-btn:hover svg { stroke: #fff; }
.claim-email-btn svg { flex-shrink: 0; }

.claim-no-contact {
  font-size: 0.78rem; color: var(--text-muted); font-style: italic;
}

/* ── Dismiss button in notifications ── */
.todo-dismiss {
  background: none; border: none; cursor: pointer; font-size: 1.1rem;
  color: var(--text-muted); padding: 0 0.3rem; line-height: 1;
  flex-shrink: 0; margin-left: auto; transition: color 0.15s; font-weight: 400;
}
.todo-dismiss:hover { color: var(--red); }
.todo-item.todo-contact svg { color: var(--primary); }

/* ── Zorgpas ── */
.zorgpas-btn {
  display: inline-flex; align-items: center; gap: 0.45rem;
  padding: 0.5rem 1rem; background: var(--green-bg); color: var(--green);
  border: 1.5px solid var(--green-border); border-radius: 100px;
  font-size: 0.82rem; font-weight: 600; cursor: pointer;
  transition: all 0.15s; font-family: inherit; white-space: nowrap;
}
.zorgpas-btn:hover { background: var(--green); color: #fff; border-color: var(--green); }
.zorgpas-btn:hover svg { stroke: #fff; }
.zorgpas-btn svg { flex-shrink: 0; }

.zorgpas-lock-header { text-align: center; margin-bottom: 1.5rem; }
.zorgpas-lock-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--primary-lighter); color: var(--primary); margin-bottom: 0.75rem;
}
.zorgpas-lock-desc { font-size: 0.88rem; color: var(--text-muted); line-height: 1.55; margin-top: 0.3rem; }

.zorgpas-pin-label {
  text-align: center; font-size: 0.85rem; font-weight: 600; color: var(--text-secondary);
  margin-bottom: 1rem;
}
.zorgpas-pin-dots {
  display: flex; justify-content: center; gap: 0.75rem; margin-bottom: 1.25rem;
}
.pin-dot {
  width: 14px; height: 14px; border-radius: 50%;
  border: 2px solid var(--border); background: var(--white);
  transition: all 0.15s;
}
.pin-dot.filled { background: var(--primary); border-color: var(--primary); }

.zorgpas-numpad {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem;
  max-width: 260px; margin: 0 auto;
}
.numpad-btn {
  padding: 0.85rem; background: var(--surface-2); border: 1px solid var(--border-light);
  border-radius: var(--radius-sm); font-size: 1.15rem; font-weight: 600;
  color: var(--text); cursor: pointer; transition: all 0.12s; font-family: inherit;
}
.numpad-btn:hover { background: var(--primary-lighter); border-color: var(--primary); color: var(--primary); }
.numpad-btn:active { transform: scale(0.95); }
.numpad-del { font-size: 1rem; color: var(--text-muted); }
.numpad-spacer { visibility: hidden; }

.zorgpas-pin-error {
  text-align: center; font-size: 0.82rem; color: var(--red); margin-top: 0.75rem;
  animation: fadeIn 0.2s ease;
}

.zorgpas-header {
  display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1.25rem;
}
.zorgpas-header-icon {
  display: flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: var(--radius-sm);
  background: var(--green-bg); color: var(--green); flex-shrink: 0;
}
.zorgpas-encrypted-badge {
  display: inline-flex; align-items: center; gap: 0.3rem;
  font-size: 0.68rem; font-weight: 600; color: var(--green);
  text-transform: uppercase; letter-spacing: 0.04em;
}

.zorgpas-cards { display: flex; flex-direction: column; gap: 1rem; }

.zorgpas-card-label {
  font-size: 0.72rem; font-weight: 700; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.4rem;
}

.zorgpas-card-preview {
  position: relative; border: 2px dashed var(--border); border-radius: var(--radius);
  overflow: hidden; min-height: 120px; background: var(--surface-2);
  transition: all 0.15s;
}
.zorgpas-card-preview:has(.zorgpas-card-img:not(.hidden)) {
  border-style: solid; border-color: var(--border-light);
}

.zorgpas-card-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 0.5rem; padding: 2rem; cursor: pointer; color: var(--text-muted);
  transition: all 0.15s;
}
.zorgpas-card-empty:hover { color: var(--primary); border-color: var(--primary); }
.zorgpas-card-empty span { font-size: 0.82rem; font-weight: 500; }

.zorgpas-card-img {
  width: 100%; display: block; border-radius: calc(var(--radius) - 2px);
}

.zorgpas-card-actions {
  position: absolute; top: 0.5rem; right: 0.5rem; display: flex; gap: 0.35rem;
}
.zorgpas-action-btn {
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: var(--radius-xs);
  background: rgba(255,255,255,0.92); border: 1px solid var(--border);
  cursor: pointer; color: var(--text-secondary); transition: all 0.15s;
  backdrop-filter: blur(4px);
}
.zorgpas-action-btn:hover { background: var(--primary-lighter); color: var(--primary); border-color: var(--primary); }
.zorgpas-action-btn.danger:hover { background: var(--red-bg); color: var(--red); border-color: var(--red-border); }

.zorgpas-uploading {
  opacity: 0.5; pointer-events: none;
}
.zorgpas-uploading::after {
  content: 'Uploaden...'; position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.8); font-size: 0.85rem; font-weight: 600;
  color: var(--primary);
}

.zorgpas-security-notice {
  display: flex; align-items: flex-start; gap: 0.5rem; margin-top: 1rem;
  padding: 0.65rem 0.85rem; background: var(--green-bg); border: 1px solid var(--green-border);
  border-radius: var(--radius-sm); font-size: 0.72rem; color: #087f5b; line-height: 1.5;
}
.zorgpas-security-notice svg { flex-shrink: 0; margin-top: 0.1rem; }

.zorgpas-upload-hint {
  font-size: 0.7rem; color: var(--text-muted); margin-top: -0.15rem;
}

.zorgpas-card-security {
  display: flex; align-items: center; gap: 0.3rem;
  font-size: 0.68rem; font-weight: 600; color: var(--green);
  margin-top: 0.35rem; padding-left: 0.15rem;
}

.zorgpas-card-pdf {
  width: 100%; height: 280px; display: block;
  border: none; border-radius: calc(var(--radius) - 2px);
}

/* ── Zorgpas crop/rotate modal ── */
.zp-crop-container {
  width: 100%; max-height: 360px; overflow: hidden;
  background: #1a1d26; border-radius: var(--radius-sm); margin-bottom: 0.75rem;
}
.zp-crop-container img { display: block; max-width: 100%; }
.zp-crop-toolbar {
  display: flex; justify-content: center; gap: 0.5rem; margin-bottom: 1rem;
}
.zp-crop-tool {
  display: inline-flex; align-items: center; gap: 0.35rem;
  padding: 0.5rem 0.85rem; background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-sm); font-size: 0.8rem; font-weight: 500;
  color: var(--text-secondary); cursor: pointer; transition: all 0.15s; font-family: inherit;
}
.zp-crop-tool:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-lighter); }
.zp-crop-tool svg { flex-shrink: 0; }

.zp-zoom-row {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0 0.5rem; margin-bottom: 1rem; color: var(--text-muted);
}
.zp-zoom-slider {
  flex: 1; height: 4px; -webkit-appearance: none; appearance: none;
  background: var(--border); border-radius: 2px; outline: none;
  cursor: pointer;
}
.zp-zoom-slider::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--primary); border: 2px solid var(--white);
  box-shadow: 0 1px 3px rgba(0,0,0,0.2); cursor: pointer;
}
.zp-zoom-slider::-moz-range-thumb {
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--primary); border: 2px solid var(--white);
  box-shadow: 0 1px 3px rgba(0,0,0,0.2); cursor: pointer;
}
