/* =============================================
   Vervier Hypotheken — Klantenportaal Styling
   Professioneel, modern, betrouwbaar
   ============================================= */

:root {
    --primary: #1a5276;
    --primary-light: #2980b9;
    --primary-dark: #0e2f44;
    --accent: #27ae60;
    --accent-light: #2ecc71;
    --danger: #c0392b;
    --danger-light: #e74c3c;

    --bg: #f0f2f5;
    --bg-card: #ffffff;
    --bg-section: #f8f9fa;
    --border: #e1e5ea;
    --border-focus: #2980b9;

    --text: #2c3e50;
    --text-light: #7f8c8d;
    --text-muted: #95a5a6;
    --text-white: #ffffff;

    --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);

    --radius: 12px;
    --radius-sm: 8px;
    --radius-xs: 6px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* ---- Typography ---- */
h1 { font-size: 1.5rem; font-weight: 700; color: var(--primary-dark); }
h2 { font-size: 1.15rem; font-weight: 600; color: var(--primary-dark); margin-bottom: 1rem; }
h3 { font-size: 1rem; font-weight: 600; color: var(--primary-dark); margin-bottom: 0.5rem; }
p { color: var(--text); }
.subtitle { font-size: 0.85rem; color: var(--text-light); font-weight: 400; }

/* ---- Buttons ---- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 1.25rem;
    border: none;
    border-radius: var(--radius-xs);
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--primary);
    color: var(--text-white);
}
.btn-primary:hover { background: var(--primary-light); }

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--border);
}
.btn-outline:hover { border-color: var(--primary); background: var(--bg-section); }

.btn-danger {
    background: var(--danger);
    color: var(--text-white);
}
.btn-danger:hover { background: var(--danger-light); }

.btn-small { padding: 0.4rem 0.85rem; font-size: 0.8rem; }
.btn-tiny { padding: 0.3rem 0.65rem; font-size: 0.75rem; }
.btn-large { padding: 0.85rem 2rem; font-size: 1rem; }
.btn-full { width: 100%; justify-content: center; }

/* ---- Forms ---- */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.form-group label {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.6rem 0.85rem;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-xs);
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--text);
    background: var(--bg-card);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px rgba(41, 128, 185, 0.15);
}

.form-group textarea {
    resize: vertical;
}

.input-prefix {
    display: flex;
    align-items: stretch;
}

.input-prefix span {
    display: flex;
    align-items: center;
    padding: 0 0.75rem;
    background: var(--bg-section);
    border: 1.5px solid var(--border);
    border-right: none;
    border-radius: var(--radius-xs) 0 0 var(--radius-xs);
    font-size: 0.9rem;
    color: var(--text-light);
}

.input-prefix input {
    border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
    flex: 1;
}

/* ---- Landing Page ---- */
.landing-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
}

.landing-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 3rem;
    max-width: 480px;
    width: 100%;
    box-shadow: var(--shadow-lg);
    text-align: center;
}

.login-card {
    max-width: 420px;
}

.logo-area {
    margin-bottom: 2rem;
}

.logo-icon {
    width: 220px;
    height: 220px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.logo-icon img {
    width: 220px;
    height: 220px;
    object-fit: contain;
}

.landing-content {
    text-align: left;
    margin-bottom: 2rem;
}

.landing-content p {
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
    color: var(--text);
}

.landing-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: var(--bg-section);
    border-radius: var(--radius-sm);
}

.info-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
}

.info-icon {
    font-size: 1.1rem;
}

.landing-footer {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.error-content {
    padding: 2rem 0;
}

.error-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.link-muted {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
}
.link-muted:hover { color: var(--primary); }

/* ---- Login Form ---- */
.login-form {
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1.5rem;
}

.notice {
    background: #fef9e7;
    border: 1px solid #f9e79f;
    border-radius: var(--radius-xs);
    padding: 0.75rem 1rem;
    font-size: 0.85rem;
    text-align: left;
    color: #7d6608;
}

/* ---- Alert ---- */
.alert {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-xs);
    font-size: 0.85rem;
    margin-bottom: 1rem;
}
.alert-error {
    background: #fdedec;
    color: var(--danger);
    border: 1px solid #f5c6cb;
}
.alert-success {
    background: #eafaf1;
    color: #1e8449;
    border: 1px solid #a9dfbf;
}

/* ---- Form Page (Client Intake) ---- */
.form-page {
    min-height: 100vh;
    padding: 2rem;
    background: var(--bg);
}

.form-container {
    max-width: 1000px;
    margin: 0 auto;
}

.form-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.5rem;
}

.logo-area-small {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-icon-small {
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.logo-icon-small img {
    width: 100px;
    height: 100px;
    object-fit: contain;
}

.logo-area-small h1 {
    font-size: 1.1rem;
    line-height: 1.3;
}
.logo-area-small .subtitle {
    font-size: 0.75rem;
}

.form-header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.lang-switcher {
    display: flex;
    gap: 0.25rem;
    background: var(--bg-section);
    border-radius: 20px;
    padding: 0.2rem;
}

.lang-btn {
    background: none;
    border: none;
    padding: 0.25rem 0.65rem;
    border-radius: 16px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}

.lang-btn.active {
    background: #fff;
    color: var(--primary);
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
}

.lang-btn:not(.active):hover {
    color: var(--text);
}

.security-badge {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    color: var(--accent);
    font-weight: 500;
    background: #eafaf1;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
}

.form-intro {
    background: var(--bg-card);
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.form-section {
    background: var(--bg-card);
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1rem;
}

.form-sub-section {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border);
}

.form-sub-section-title {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border);
}

.section-number {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--primary);
    color: var(--text-white);
    font-size: 0.8rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-grid-full {
    grid-template-columns: 1fr;
}

.form-group-small {
    max-width: 200px;
}

.form-group-wide {
    grid-column: 1 / -1;
}

.form-submit {
    margin-top: 1.5rem;
    text-align: center;
}

.form-submit-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}

.draft-saved-msg {
    margin-top: 0.75rem;
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 500;
}

/* ---- Form tabel (aanvraagformulier per sectie) ---- */
.form-table-wrap {
    overflow-x: auto;
    margin: 0 -0.25rem;
}

.form-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.form-table thead th {
    padding: 0.55rem 0.85rem;
    background: var(--bg-section);
    border-bottom: 2px solid var(--border);
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    text-align: left;
    white-space: nowrap;
}

.form-table tbody td {
    padding: 0.75rem 0.85rem;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

.form-table tbody tr:last-child td {
    border-bottom: none;
}

.form-table tbody tr:hover td {
    background: rgba(26, 82, 118, 0.025);
}

.ftr-locked .ftcol-field {
    opacity: 0.45;
}

.ftr-locked:hover td {
    background: transparent;
}

.ftcol-field {
    width: 42%;
}

.optional-badge {
    display: inline-block;
    margin-left: 0.4rem;
    padding: 0.05rem 0.35rem;
    font-size: 0.68rem;
    font-weight: 500;
    color: var(--text-muted);
    background: var(--bg-section);
    border: 1px solid var(--border);
    border-radius: 3px;
    vertical-align: middle;
    letter-spacing: 0.02em;
}

.ftcol-person {
    vertical-align: middle;
}

.ftcol-text {
    vertical-align: top;
}

.ftcol-na {
    vertical-align: middle;
    text-align: center;
}

.ft-person-header {
    font-weight: 600;
    color: var(--primary-dark);
    font-size: 0.72rem;
}

.ft-label {
    font-weight: 500;
    color: var(--text);
    line-height: 1.4;
    margin-bottom: 0.3rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.ft-instruction {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.45;
}

.ft-url {
    margin-top: 0.3rem;
    font-size: 0.75rem;
}

.ft-url a {
    color: var(--primary);
    text-decoration: none;
    word-break: break-all;
}

.ft-url a:hover {
    text-decoration: underline;
}

.btn-bijlage {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-top: 0.4rem;
    padding: 0.2rem 0.6rem;
    font-size: 0.73rem;
    font-weight: 500;
    color: var(--primary);
    background: rgba(41, 128, 185, 0.07);
    border: 1px solid rgba(41, 128, 185, 0.25);
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.15s;
}

.btn-bijlage:hover {
    background: rgba(41, 128, 185, 0.14);
}

.form-intro-bijlagen {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.75rem;
    flex-wrap: wrap;
}

.form-intro-bijlagen-label {
    font-size: 0.82rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* ---- Bevestiging indienen modal ---- */
.confirm-submit-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.confirm-submit-modal.hidden {
    display: none !important;
}
.confirm-submit-box {
    background: #fff;
    border-radius: 14px;
    padding: 2rem 2rem 1.75rem;
    max-width: 440px;
    width: 100%;
    box-shadow: 0 8px 40px rgba(0,0,0,0.22);
    text-align: center;
}
.confirm-submit-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.6rem;
}
.confirm-submit-text {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    line-height: 1.5;
}
.confirm-submit-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}

.bijlage-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.bijlage-modal.hidden {
    display: none !important;
}

.bijlage-modal-box {
    background: #fff;
    border-radius: 12px;
    width: 100%;
    max-width: 480px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.2);
    overflow: hidden;
}

.bijlage-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    font-size: 0.95rem;
}

.bijlage-modal-close {
    background: none;
    border: none;
    font-size: 1rem;
    cursor: pointer;
    color: var(--text-muted);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
}

.bijlage-modal-close:hover {
    background: var(--bg-section);
}

.bijlage-modal-body {
    padding: 0.75rem 1.25rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.bijlage-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.6rem 0.75rem;
    background: var(--bg-section);
    border-radius: 6px;
    flex-wrap: wrap;
}

.bijlage-naam {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text);
}

.bijlage-acties {
    display: flex;
    gap: 0.4rem;
}

.ft-upload-cell {
    border-radius: var(--radius-xs);
    transition: background 0.15s, outline 0.15s;
    padding: 0.15rem;
}

.ft-upload-cell.drag-over {
    outline: 2px dashed var(--primary-light);
    outline-offset: -2px;
    background: rgba(41, 128, 185, 0.06);
}

.ft-upload-locked {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.3rem;
    padding: 0.5rem 0.6rem;
    border-radius: var(--radius-xs);
    opacity: 0.6;
    background: repeating-linear-gradient(
        135deg,
        transparent,
        transparent 6px,
        rgba(0,0,0,0.04) 6px,
        rgba(0,0,0,0.04) 12px
    );
    pointer-events: none;
    user-select: none;
}

.ft-upload-empty {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
}

.ft-upload-btn {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.ft-drag-hint {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.ft-upload-done {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.3rem;
}

.ft-filename {
    font-size: 0.8rem;
    color: var(--text);
    word-break: break-all;
    max-width: 200px;
}

.ft-filemeta {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.ft-janee-cell {
    display: flex;
    align-items: center;
}

.janee-buttons {
    display: flex;
    gap: 0.5rem;
}

.btn-janee {
    padding: 0.45rem 1.1rem;
    border: 2px solid var(--border);
    border-radius: 6px;
    background: var(--bg-section);
    color: var(--text-light);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.btn-janee:hover {
    border-color: var(--primary-light);
    color: var(--primary);
    background: #eaf3fb;
}

.btn-janee.selected-ja {
    border-color: var(--accent);
    background: #eafaf1;
    color: var(--accent);
    font-weight: 700;
}

.btn-janee.selected-nee {
    border-color: var(--danger);
    background: #fdf2f1;
    color: var(--danger);
    font-weight: 700;
}

.ft-info-cell .info-input {
    width: 100%;
}

.ftcol-text .info-input {
    width: 100%;
}

.ft-na {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.privacy-notice {
    background: var(--bg-section);
    padding: 1rem 1.25rem;
    border-radius: var(--radius-sm);
    font-size: 0.82rem;
    color: var(--text-light);
    margin-bottom: 1.25rem;
    text-align: left;
}

/* ---- Admin Page ---- */
.admin-page {
    min-height: 100vh;
}

.admin-header {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 100;
}

.admin-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
}

.admin-header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.admin-header-left h1 {
    font-size: 1.15rem;
}

.admin-header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.advisor-badge {
    font-size: 0.82rem;
    color: var(--text-muted);
    padding: 0.2rem 0.6rem;
    border: 1px solid var(--border);
    border-radius: 6px;
}

/* Super admin */
.sa-form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem 1.25rem;
}
@media (max-width: 640px) {
    .sa-form-grid { grid-template-columns: 1fr; }
}
.btn-danger {
    background: #e53935;
    color: white;
    border: none;
}
.btn-danger:hover { background: #c62828; }

/* Generic modal (super admin + other dialogs) */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.modal-box {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    width: 100%;
    max-width: 440px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.4);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.modal-box h3 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 600;
}
.modal-sub {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin: -0.5rem 0 0;
}
.modal-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    margin-top: 0.5rem;
}

.back-link {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
}
.back-link:hover { color: var(--primary-light); }

.admin-main {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 2rem;
}

/* ---- Stats ---- */
.stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stat-card {
    background: var(--bg-card);
    padding: 1.25rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 0.25rem;
}

/* ---- Section Card ---- */
.section-card {
    background: var(--bg-card);
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.25rem;
}

.inline-form {
    display: flex;
    align-items: flex-end;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.inline-form .form-group {
    flex: 1;
    min-width: 180px;
}

/* ---- Table ---- */
.table-wrapper {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

thead th {
    text-align: left;
    padding: 0.75rem;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-light);
    border-bottom: 2px solid var(--border);
}

tbody td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

tbody tr:hover {
    background: var(--bg-section);
}

/* ---- Status Badge ---- */
.status-badge {
    display: inline-block;
    padding: 0.25rem 0.65rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

.status-nieuw {
    background: #ebf5fb;
    color: var(--primary);
}
.status-in_behandeling {
    background: #fef9e7;
    color: #b7950b;
}
.status-documenten_nodig {
    background: #fdebd0;
    color: #ca6f1e;
}
.status-goedgekeurd {
    background: #eafaf1;
    color: #1e8449;
}
.status-afgewezen {
    background: #fdedec;
    color: var(--danger);
}
.status-afgerond {
    background: #f4f6f7;
    color: var(--text-light);
}

/* ---- Link Copy ---- */
.link-copy {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.link-url {
    font-size: 0.72rem;
    background: var(--bg-section);
    padding: 0.3rem 0.5rem;
    border-radius: 4px;
    max-width: 320px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ---- Detail Page ---- */
.detail-row {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}

.detail-status select {
    width: 100%;
    padding: 0.5rem;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-xs);
    font-family: inherit;
    font-size: 0.9rem;
}

.detail-notes textarea {
    width: 100%;
    padding: 0.6rem;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-xs);
    font-family: inherit;
    font-size: 0.85rem;
    resize: vertical;
    margin-bottom: 0.5rem;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.detail-field {
    padding: 0.75rem;
    background: var(--bg-section);
    border-radius: var(--radius-xs);
}

.detail-field-wide {
    grid-column: 1 / -1;
}

.detail-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.25rem;
}

.detail-value {
    display: block;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text);
}

.detail-value.sensitive {
    font-family: monospace;
    letter-spacing: 0.1em;
}

.empty-state {
    text-align: center;
    color: var(--text-muted);
    padding: 2rem;
    font-size: 0.9rem;
}

/* ---- Required field marker ---- */
.required { color: var(--danger); }

/* ---- Field error state ---- */
.field-error {
    border-color: var(--danger) !important;
    box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.15) !important;
}

/* ---- Upload Cards (client form) ---- */
.upload-fields {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.upload-card {
    background: var(--bg-section);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 1.25rem;
    transition: border-color 0.2s;
}

.upload-card-header {
    display: flex;
    align-items: flex-start;
    gap: 0.9rem;
    margin-bottom: 0.9rem;
}

.upload-card-icon {
    font-size: 1.6rem;
    flex-shrink: 0;
    line-height: 1;
}

.upload-card-meta {
    flex: 1;
}

.upload-card-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--primary-dark);
}

.upload-card-desc {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 0.15rem;
}

.upload-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.65rem;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
}

.upload-badge-done {
    background: #eafaf1;
    color: #1e8449;
}

.upload-badge-pending {
    background: #fef9e7;
    color: #b7950b;
}

.upload-badge-off {
    background: var(--bg-section);
    color: var(--text-muted);
}

.upload-instruction {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.82rem;
    color: var(--text-light);
    background: var(--bg-card);
    border-left: 3px solid var(--primary-light);
    padding: 0.6rem 0.85rem;
    border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
    margin-bottom: 0.9rem;
}

.instruction-icon {
    color: var(--primary-light);
    font-style: normal;
    flex-shrink: 0;
}

/* Drop zone */
.drop-zone {
    border: 2px dashed var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg-card);
    transition: border-color 0.2s, background 0.2s;
    cursor: pointer;
    overflow: hidden;
}

.drop-zone.drag-over {
    border-color: var(--primary-light);
    background: #ebf5fb;
}

.drop-zone-inner {
    padding: 1.5rem;
    text-align: center;
}

.drop-icon {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: var(--primary-light);
}

.drop-text {
    font-size: 0.875rem;
    color: var(--text-light);
}

.drop-link {
    color: var(--primary);
    font-weight: 500;
    cursor: pointer;
    text-decoration: underline;
}

.drop-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.35rem;
}

.file-input {
    display: none;
}

/* Progress bar */
.upload-progress {
    padding: 1rem 1.5rem;
    background: var(--bg-card);
}

.progress-bar {
    height: 6px;
    background: var(--border);
    border-radius: 3px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--primary-light);
    border-radius: 3px;
    transition: width 0.2s;
    width: 0%;
}

.progress-label {
    font-size: 0.78rem;
    color: var(--text-light);
    margin-top: 0.4rem;
    text-align: center;
}

.upload-error {
    padding: 0.65rem 1rem;
    background: #fdedec;
    color: var(--danger);
    font-size: 0.82rem;
    border-top: 1px solid #f5c6cb;
}

/* Uploaded state */
.uploaded-file {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    padding: 0.9rem 1rem;
    background: #eafaf1;
    border: 1.5px solid #a9dfbf;
    border-radius: var(--radius-sm);
}

.uploaded-file-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
}

.file-type-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
}

.uploaded-filename {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text);
    word-break: break-all;
}

.uploaded-meta {
    font-size: 0.75rem;
    color: var(--text-light);
    margin-top: 0.1rem;
}

.hidden { display: none !important; }

/* ---- Checkbox group ---- */
.checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.35rem;
}

.checkbox-label {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.4rem 0.85rem;
    background: var(--bg-section);
    border: 1.5px solid var(--border);
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--text);
    transition: border-color 0.15s, background 0.15s;
}

.checkbox-label:has(input:checked) {
    background: #ebf5fb;
    border-color: var(--primary-light);
    color: var(--primary);
}

.checkbox-label input[type="checkbox"] {
    margin: 0;
}

.checkbox-label-lg {
    flex: 1;
    padding: 0;
    background: none;
    border: none;
    border-radius: 0;
    font-size: 0.9rem;
    font-weight: 600;
}

.checkbox-label-lg:has(input:checked) {
    background: none;
    border: none;
    color: var(--primary-dark);
}

/* ---- Doc tags (dashboard) ---- */
.doc-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    align-items: center;
}

.doc-tag {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 500;
}

.doc-tag-done {
    background: #eafaf1;
    color: #1e8449;
}

.doc-tag-pending {
    background: #fef9e7;
    color: #b7950b;
}

.doc-tag-partial {
    background: #fdebd0;
    color: #ca6f1e;
}

.text-muted-sm {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* ---- Detail top layout ---- */
.detail-top {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}

/* ---- Persons grid (naast elkaar in Klantgegevens) ---- */
.persons-grid {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
}
.persons-grid .person-card {
    flex: 1;
    min-width: 200px;
    padding: 0.75rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-section);
}
.person-details {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    font-size: 0.82rem;
}
.person-detail-row {
    display: flex;
    gap: 0.5rem;
}
.person-detail-label {
    color: var(--text-muted);
    min-width: 80px;
    flex-shrink: 0;
}
/* ---- Herinnering sturen knop (klantgegevens) ---- */
.reminder-btn {
    padding: 0.45rem 2rem;
    font-size: 0.875rem;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

/* ---- Per-persoon voortgangsindicator ---- */
.person-progress {
    margin-top: 0.75rem;
    padding-top: 0.65rem;
    border-top: 1px solid var(--border);
}
.person-progress-bar {
    height: 6px;
    background: var(--border);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 0.4rem;
}
.person-progress-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 3px;
    transition: width 0.3s ease;
}
.person-progress-label {
    font-size: 0.75rem;
    font-weight: 600;
}
.person-progress-done {
    color: #065f46;
}
.person-progress-open {
    color: var(--text-muted);
}

.submission-dates {
    margin-top: 1rem;
    padding: 0.65rem 0.85rem;
    background: var(--bg-section);
    border-left: 3px solid var(--primary);
    border-radius: 0 6px 6px 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}
.submission-date-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.84rem;
}
.submission-date-label {
    color: var(--text-muted);
    min-width: 95px;
    flex-shrink: 0;
    font-weight: 500;
}
.submission-date-value {
    color: var(--text);
    font-weight: 600;
}

/* ---- Client name display ---- */
.client-name-display {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.client-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    font-size: 1.2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.client-full-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-dark);
}

.client-sub-meta {
    font-size: 0.78rem;
    color: var(--text-light);
    margin-top: 0.15rem;
}

.client-meta-bottom {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0;
    flex-wrap: wrap;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
}
.client-meta-bottom > * {
    flex: 0 0 50%;
    min-width: 0;
    box-sizing: border-box;
}
.client-meta-bottom .submission-dates {
    text-align: left;
    padding-right: 0.75rem;
}
.client-meta-bottom .meta-item {
    text-align: right;
    padding-left: 0.75rem;
}
.client-meta-bottom .link-copy {
    justify-content: flex-end;
}

.detail-meta-row {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
    margin-top: 0.75rem;
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    font-size: 0.85rem;
}

.meta-label {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

/* ---- Section card header ---- */
.section-card-header {
    margin-bottom: 1.25rem;
}

/* ---- Upload config grid (detail page) ---- */
.upload-config-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 0.85rem;
}

.upload-config-card {
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 1rem;
    background: var(--bg-section);
    transition: border-color 0.15s;
}

.upload-config-card.ucc-enabled {
    border-color: var(--primary-light);
    background: #f0f7ff;
}

.ucc-top {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.ucc-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-dark);
}

.ucc-desc {
    font-size: 0.78rem;
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

.ucc-file {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-card);
    border-radius: var(--radius-xs);
    font-size: 0.8rem;
    margin-top: 0.5rem;
}

.ucc-filename {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--text);
    font-weight: 500;
}

.ucc-filesize {
    color: var(--text-muted);
    flex-shrink: 0;
}

/* ---- Files list (detail page) ---- */
.files-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.file-row {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.75rem 1rem;
    background: var(--bg-section);
    border-radius: var(--radius-xs);
    border: 1px solid var(--border);
}

.file-row-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
}

.file-row-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
}

.file-row-label {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--primary);
}

.file-row-name {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-row-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* ---- Action row ---- */
.action-row {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

/* ---- Danger card ---- */
.section-card-danger {
    border: 1.5px solid #f5c6cb;
}

.section-card-danger h2 {
    color: var(--danger);
}

/* ---- Person badges ---- */
/* Dashboard voortgangsbalk */
.progress-cell {
    min-width: 160px;
    vertical-align: middle;
}
.dash-progress-bar-wrap {
    background: var(--bg-card-alt, #2a2a2a);
    border-radius: 6px;
    height: 8px;
    overflow: hidden;
    margin-bottom: 0.3rem;
}
.dash-progress-bar {
    height: 100%;
    border-radius: 6px;
    transition: width 0.3s ease;
    min-width: 4px;
}
.dash-progress-done  { background: #4caf50; }
.dash-progress-mid   { background: #ff9800; }
.dash-progress-low   { background: #e53935; }
.dash-progress-label {
    font-size: 0.78rem;
    color: var(--text-light);
    white-space: nowrap;
}

.persons-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-light);
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 0.1rem 0.4rem;
    border-radius: 10px;
    margin-left: 0.4rem;
    vertical-align: middle;
}

.person-number-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    background: var(--primary);
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Multi-person upload zones */
.person-upload-zones {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.person-upload-zone {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xs);
    padding: 0.85rem;
}

.person-zone-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.65rem;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--text);
}

/* UCC persons status */
.ucc-persons-status {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    margin-top: 0.65rem;
    padding-top: 0.65rem;
    border-top: 1px solid var(--border);
}

.ucc-person-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.78rem;
}

.ucc-person-name {
    font-weight: 500;
    color: var(--text);
    flex-shrink: 0;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 140px;
}

/* ---- Documenten tabel (client_detail) ---- */
.docs-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.docs-table thead th {
    text-align: left;
    padding: 0.5rem 0.75rem;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-light);
    border-bottom: 2px solid var(--border);
    white-space: nowrap;
}

.docs-table tbody td {
    padding: 0.55rem 0.75rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

.docs-table tbody tr:last-child td {
    border-bottom: none;
}

.docs-row-disabled {
    opacity: 0.45;
}

.toggle-saved {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--accent);
    color: #fff;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 0.65rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    animation: toggle-pop 0.2s ease;
}

@keyframes toggle-pop {
    from { transform: translate(-50%, -50%) scale(0.6); opacity: 0; }
    to   { transform: translate(-50%, -50%) scale(1);   opacity: 1; }
}

.docs-field-name {
    font-weight: 500;
    color: var(--text);
}

.docs-status-cell {
    white-space: nowrap;
}

.docs-cell-actions {
    display: inline-flex;
    gap: 0.3rem;
    margin-left: 0.4rem;
    vertical-align: middle;
}

.upload-badge-locked {
    background: #eaf0fb;
    color: var(--primary);
}

.cell-locked {
    opacity: 0.45;
    background: repeating-linear-gradient(
        135deg,
        transparent,
        transparent 6px,
        rgba(0,0,0,0.04) 6px,
        rgba(0,0,0,0.04) 12px
    );
}

.cell-locked input[type="checkbox"] {
    cursor: not-allowed;
}

.file-row-locked {
    opacity: 0.55;
    border-color: var(--border);
    background: repeating-linear-gradient(
        135deg,
        var(--bg-section),
        var(--bg-section) 8px,
        rgba(0,0,0,0.03) 8px,
        rgba(0,0,0,0.03) 16px
    );
}

/* ---- Status badge extra ---- */
.status-wachten {
    background: var(--bg-section);
    color: var(--text-muted);
}

/* ---- Preview modal ---- */
.preview-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.preview-modal.hidden {
    display: none !important;
}

.preview-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
}

.preview-modal-content {
    position: relative;
    width: 90vw;
    height: 90vh;
    background: var(--bg-card);
    border-radius: var(--radius);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.preview-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
    gap: 1rem;
    flex-shrink: 0;
}

.preview-frame {
    flex: 1;
    border: none;
    width: 100%;
    background: #f0f0f0;
}

/* ---- Docs accordion ---- */
.docs-accordion {
    margin-top: 1rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
}
.accordion-section {
    border-bottom: 1px solid var(--border);
}
.accordion-section:last-child {
    border-bottom: none;
}
.accordion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.85rem 1rem;
    background: var(--bg-section);
    cursor: pointer;
    user-select: none;
    transition: background 0.15s;
}
.accordion-header:hover {
    background: #e4eaf5;
}
.accordion-header .section-name {
    font-size: 0.92rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--primary);
}
.accordion-content {
    overflow-x: auto;
}
.accordion-content .docs-table {
    border-top: none;
    border-radius: 0;
}
.accordion-content .docs-table thead th {
    border-top: none;
}

/* ---- Formulier instellen: veldenlijst ---- */
.settings-accordion {
    margin-top: 1rem;
}
.settings-accordion .accordion-drag-handle,
.settings-accordion .field-drag-handle {
    display: inline-block;
    cursor: grab;
}
.settings-accordion .accordion-header {
    cursor: default;
}
.settings-accordion .accordion-header:hover {
    background: #e4eaf5;
}
.settings-field-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.settings-field-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.75rem;
    border-bottom: 1px solid var(--border);
    font-size: 0.85rem;
}
.settings-field-item:last-child {
    border-bottom: none;
}
.settings-field-label {
    flex: 1;
}

/* ---- Drag-and-drop hulpelementen (gebruikt door instellingenpagina) ---- */
.accordion-drag-handle {
    display: none;
    cursor: grab;
    font-size: 1.1rem;
    color: var(--text-muted);
    padding: 0 0.25rem;
    user-select: none;
    line-height: 1;
    flex-shrink: 0;
}
.field-drag-handle {
    display: none;
    cursor: grab;
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-right: 0.4rem;
    user-select: none;
    vertical-align: middle;
}
.sort-ghost {
    opacity: 0.35;
    background: #dbeafe !important;
}
.sort-ghost .accordion-header {
    background: #dbeafe !important;
}

/* ---- Docs tabel: secties (legacy) ---- */
.docs-section-header {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--primary);
    padding: 0.35rem 0 0.35rem 0;
    border-bottom: 2px solid var(--primary-light);
    margin-bottom: 0.35rem;
}
.docs-section-row {
    cursor: pointer;
    user-select: none;
}
.docs-section-row td {
    background: var(--bg-section);
    padding: 0.75rem 0.75rem;
    border-top: 2px solid var(--border);
    transition: background 0.15s;
}
.docs-section-row:hover td {
    background: #e4eaf5;
}
.docs-section-header-inline {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.92rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--primary);
}
.section-toggle-left {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.section-arrow {
    display: inline-block;
    font-size: 0.75rem;
    color: var(--primary);
    transition: transform 0.2s ease;
    transform: rotate(0deg);
    line-height: 1;
}
.docs-section-row.section-open .section-arrow {
    transform: rotate(90deg);
}
tr.section-row-hidden {
    display: none;
}

.optional-hint {
    font-style: italic;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-left: 0.25rem;
}

.docs-type-badge {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 0.1rem 0.35rem;
    border-radius: 4px;
    margin-left: 0.3rem;
    vertical-align: middle;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.docs-type-upload  { background: #dbeafe; color: #1d4ed8; }
.docs-type-ja_nee  { background: #d1fae5; color: #065f46; }
.docs-type-info    { background: #fef9c3; color: #92400e; }
.docs-type-text    { background: #ede9fe; color: #5b21b6; }

/* ---- Per-persoon toggle in docs tabel ---- */
.person-toggle-wrap {
    margin-bottom: 0.3rem;
}

.person-toggle-label {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    cursor: pointer;
    user-select: none;
}

.person-toggle-label input[type="checkbox"] {
    cursor: pointer;
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.person-toggle-text {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.th-person-group {
    text-align: center;
    border-left: 2px solid var(--border);
}

.th-gevraagd {
    text-align: center;
    border-left: 2px solid var(--border);
    width: 72px;
}

.th-status {
    text-align: left;
    width: auto;
}

.th-row-all {
    text-align: center;
    width: 44px;
    padding: 0.35rem 0.5rem;
}

.docs-row-all-cell {
    text-align: center;
    vertical-align: middle;
    width: 44px;
    padding: 0.4rem 0.5rem;
}

.docs-gevraagd-cell {
    text-align: center;
    vertical-align: middle;
    width: 72px;
    border-left: 2px solid var(--border);
    white-space: nowrap;
}

.toggle-saved-inline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--accent);
    color: #fff;
    border-radius: 50%;
    width: 14px;
    height: 14px;
    font-size: 0.6rem;
    font-weight: 700;
    flex-shrink: 0;
}

.docs-cell-disabled {
    background: var(--bg-section);
}

.docs-cell-content {
}

/* ---- Selecteer alles knop ---- */
.select-all-btn {
    background: var(--primary);
    color: var(--text-white) !important;
    border: none;
    font-size: 0.7rem;
    padding: 0.2rem 0.55rem;
    flex-shrink: 0;
}
.select-all-btn:hover {
    background: var(--primary-light);
    color: var(--text-white) !important;
    border-color: transparent;
}

/* ---- Dashboard: checkbox secties ---- */
.checkbox-section {
    margin-bottom: 1rem;
}

.checkbox-section-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary);
    padding: 0.3rem 0;
    border-bottom: 1.5px solid var(--border);
    margin-bottom: 0.4rem;
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
    .form-group-small {
        max-width: none;
    }
    .stats-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .detail-row {
        grid-template-columns: 1fr;
    }
    .detail-grid {
        grid-template-columns: 1fr 1fr;
    }
    .detail-top {
        grid-template-columns: 1fr;
    }
    .admin-header-inner {
        padding: 0.75rem 1rem;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    .admin-main {
        padding: 0 1rem;
    }
    .form-header {
        flex-direction: column;
        gap: 0.75rem;
        align-items: flex-start;
    }
    .landing-card {
        padding: 2rem 1.5rem;
    }
    .inline-form {
        flex-direction: column;
        align-items: stretch;
    }
    .upload-config-grid {
        grid-template-columns: 1fr;
    }
    .action-row {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .detail-grid {
        grid-template-columns: 1fr;
    }
    .stats-row {
        grid-template-columns: 1fr 1fr;
    }
}
