/* ================= HEADER ================= */

.citizens-header {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
}

.citizens-header > div:first-child {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.citizens-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.citizens-actions input,
.citizens-actions select {
    background: #0f172a;
    border: 1px solid #1e293b;
    border-radius: 10px;
    padding: 0 14px;
    height: 42px;
    color: #cbd5e1;
    font-size: 13px;
    transition: 0.2s;
}

.citizens-actions input {
    width: 280px;
}

.citizens-actions input:focus,
.citizens-actions select:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59,130,246,0.15);
    outline: none;
}

.citizens-actions select {
    appearance: none;
    padding-right: 35px;
    background-image: url("data:image/svg+xml;utf8,<svg fill='%23cbd5e1' height='20' viewBox='0 0 24 24' width='20' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 14px;
}

/* ================= GRID ================= */

.citizens-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
}

/* ================= CARD ================= */

.citizen-item {
    background: linear-gradient(145deg, #182542, #111a30);
    padding: 20px;
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,0.05);
    cursor: pointer;
    transition: 0.25s ease;
}

.citizen-item:hover {
    transform: translateY(-4px);
    border-color: rgba(59,130,246,0.5);
    box-shadow: 0 15px 40px rgba(0,0,0,0.5);
}

/* ================= MODAL ================= */

.modal.large {
    width: 900px;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.grid-2 .full {
    grid-column: span 2;
}

.licenses {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

/* ================= PROFILE ================= */

.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.profile-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.profile-photo {
    width: 90px;
    height: 90px;
    border-radius: 16px;
    background: #0f172a;
    background-size: cover;
    background-position: center;
}

.profile-sub {
    color: #94a3b8;
    font-size: 14px;
}

/* ================= TABS ================= */

.profile-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
}

.tab {
    background: #1e293b;
    border: none;
    padding: 8px 14px;
    border-radius: 8px;
    color: #cbd5e1;
    cursor: pointer;
}

.tab.active {
    background: linear-gradient(90deg,#2563eb,#1d4ed8);
    color: white;
}

.profile-content {
    background: linear-gradient(145deg, #182542, #111a30);
    padding: 25px;
    border-radius: 18px;
}

.citizen-actions-row {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 15px;
}

.citizen-main {
    cursor: pointer;
}

/* ================= MODAL SCROLLBAR ================= */

.modal {
    scrollbar-width: thin;
    scrollbar-color: rgba(59,130,246,0.6) transparent;
}

/* Chrome / Edge */
.modal::-webkit-scrollbar {
    width: 6px;
}

.modal::-webkit-scrollbar-track {
    background: transparent;
}

.modal::-webkit-scrollbar-thumb {
    background: rgba(59,130,246,0.25);
    border-radius: 10px;
    transition: 0.2s;
}

.modal::-webkit-scrollbar-thumb:hover {
    background: rgba(59,130,246,0.7);
}

/* ================= FILTERS ================= */

.citizens-actions select {
    background: #0f172a;
    border: 1px solid #2a2f3d;
    border-radius: 10px;
    padding: 10px 14px;
    color: #cbd5e1;
    font-size: 13px;
    cursor: pointer;
    transition: 0.2s;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

/* Arrow custom */
.citizens-actions select {
    background-image: url("data:image/svg+xml;utf8,<svg fill='%23cbd5e1' height='20' viewBox='0 0 24 24' width='20' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 14px;
    padding-right: 35px;
}

/* Hover */
.citizens-actions select:hover {
    border-color: rgba(59,130,246,0.5);
}

/* Focus */
.citizens-actions select:focus {
    border-color: #3b82f6;
    outline: none;
    box-shadow: 0 0 0 2px rgba(59,130,246,0.2);
}

/* Match search input height */
.citizens-actions input {
    height: 40px;
}

.citizens-actions select {
    height: 40px;
}

/* ================= TABLE ================= */

.citizens-table-wrapper {
    margin-top: 30px;
    overflow-x: auto;
}

.citizens-table {
    width: 100%;
    border-collapse: collapse;
    background: linear-gradient(145deg, #182542, #111a30);
    border-radius: 16px;
    overflow: hidden;
}

.citizens-table thead {
    background: rgba(59,130,246,0.08);
}

.citizens-table th {
    text-align: left;
    padding: 10px 12px;
    font-size: 12px;
    font-weight: 600;
    color: #cbd5e1;
}

.citizens-table td {
    padding: 8px 12px;
    font-size: 12px;
    vertical-align: middle;
    color: #94a3b8;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.citizens-table tr:hover {
    background: rgba(59,130,246,0.06);
}

/* ================= LICENSE BADGES ================= */

.lic-badge {
    background: rgba(59,130,246,0.2);
    color: #3b82f6;
    padding: 3px 6px;
    border-radius: 6px;
    font-size: 11px;
    margin-right: 4px;
}

/* ================= ACTION BUTTONS ================= */

.actions-cell {
    display: flex;
    gap: 6px;
}

.btn-view {
    background: #2563eb;
    border: none;
    padding: 6px 10px;
    border-radius: 6px;
    color: white;
    font-size: 12px;
    cursor: pointer;
    transition: 0.2s;
}

.btn-view:hover {
    background: #3b82f6;
}

.sub-info {
    font-size: 11px;
    color: #64748b;
    margin-top: 3px;
}

.profile-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
}

.profile-grid strong {
    font-size: 12px;
    color: #64748b;
}

.profile-grid div div {
    margin-top: 6px;
    font-size: 14px;
    color: #cbd5e1;
}

.profile-licenses {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
}

.photo-preview {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: 0.2s;
    z-index: 9999;
}

.photo-preview.active {
    opacity: 1;
    pointer-events: all;
}

.photo-preview img {
    max-width: 500px;
    border-radius: 16px;
}

.linked-grid {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px,1fr));
    gap: 20px;
}

.linked-card {
    background: linear-gradient(145deg, #182542, #111a30);
    padding: 20px;
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.05);
}

.linked-list {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.linked-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: linear-gradient(145deg, #182542, #111a30);
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.05);
    transition: 0.2s;
}

.linked-row:hover {
    background: rgba(59,130,246,0.05);
}

.linked-left {
    display: flex;
    flex-direction: column;
}

.linked-sub {
    font-size: 13px;
    color: #94a3b8;
    margin-top: 4px;
}

.linked-right {
    display: flex;
    gap: 10px;
}

.danger-row {
    border: 1px solid rgba(239,68,68,0.4);
    background: rgba(239,68,68,0.05);
}

.confirm-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.confirm-box {
    background: linear-gradient(145deg, #182542, #111a30);
    padding: 30px;
    border-radius: 16px;
    width: 400px;
    border: 1px solid rgba(255,255,255,0.05);
}

.confirm-box h3 {
    margin-bottom: 10px;
}

.confirm-actions {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* TEXTAREA */

.form-group textarea {
    background: #0f172a;
    border: 1px solid #2a2f3d;
    border-radius: 10px;
    padding: 12px 14px;
    color: #cbd5e1;
    min-height: 100px;
    resize: vertical;
    font-family: inherit;
    font-size: 13px;
    transition: 0.2s;
}

.form-group textarea:focus {
    border-color: #3b82f6;
    outline: none;
    box-shadow: 0 0 0 2px rgba(59,130,246,0.2);
}

/* CHECKBOX STYLE */

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #3b82f6;
    cursor: pointer;
}

/* STATUS BADGE */

.status-badge {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
}

.status-active {
    background: rgba(34,197,94,0.2);
    color: #22c55e;
}

.status-warning {
    background: rgba(245,158,11,0.2);
    color: #f59e0b;
}

.status-danger {
    background: rgba(239,68,68,0.2);
    color: #ef4444;
}

/* STRIP BADGE */

.badge-strip {
    background: linear-gradient(90deg,#2563eb,#1d4ed8);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    color: white;
}

.badge-success {
    background: rgba(34,197,94,0.2);
    color: #22c55e;
    padding: 4px 8px;
    border-radius: 6px;
}

.badge-danger {
    background: rgba(239,68,68,0.2);
    color: #ef4444;
    padding: 4px 8px;
    border-radius: 6px;
}

.status-badge,
.badge-strip,
.badge-success,
.badge-danger {
    padding: 3px 6px;
    font-size: 11px;
    border-radius: 5px;
}

.sub-info {
    font-size: 10px;
    margin-top: 2px;
    opacity: 0.7;
}

.citizens-table td:nth-child(3), /* Fonction */
.citizens-table td:nth-child(5), /* Divisions */
.citizens-table td:nth-child(6), /* Spécialités */
.citizens-table td:nth-child(12) /* Mail */
{
    max-width: 140px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.actions-cell button {
    padding: 4px 8px;
    font-size: 11px;
}

.actions-cell {
    gap: 4px;
}

.citizens-table tr {
    height: 46px;
}

.agent-section {
    margin-top: 30px;
    background: linear-gradient(145deg, #182542, #111a30);
    padding: 20px;
    border-radius: 16px;
}

.agent-section h3 {
    margin-bottom: 12px;
    font-size: 16px;
}

.multi-select{
    background:#0f172a;
    border-radius:10px;
    padding:8px;
    min-height:42px;
    display:flex;
    flex-wrap:wrap;
    gap:6px;
    cursor:text;
}

.multi-tag{
    background:#1d4ed8;
    color:white;
    padding:4px 8px;
    border-radius:6px;
    font-size:12px;
    display:flex;
    align-items:center;
    gap:6px;
}

.multi-tag span{
    cursor:pointer;
}

.multi-dropdown{
    position:absolute;
    background:#0f172a;
    border-radius:10px;
    padding:8px;
    margin-top:4px;
    max-height:200px;
    overflow:auto;
    box-shadow:0 10px 30px rgba(0,0,0,0.5);
}

.multi-option{
    padding:6px 8px;
    border-radius:6px;
    cursor:pointer;
}

.multi-option:hover{
    background:#1e293b;
}

/* ================= MODERN CITIZEN PROFILE ================= */

.citizen-profile-modern {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.profile-shell {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.profile-hero,
.profile-section-card,
.summary-card,
.info-card,
.linked-panel {
    background:
        linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow: 0 20px 45px rgba(0,0,0,0.28);
    backdrop-filter: blur(10px);
}

.profile-hero {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 22px;
    padding: 24px;
    border-radius: 22px;
}

.profile-hero-left {
    display: flex;
    align-items: center;
    gap: 18px;
    min-width: 0;
}

.profile-photo-wrap {
    position: relative;
    width: 108px;
    height: 108px;
    flex: 0 0 108px;
}

.profile-photo {
    width: 108px;
    height: 108px;
    border-radius: 22px;
    background: linear-gradient(145deg, #111b31, #0d1425);
    background-size: cover;
    background-position: center;
    position: relative;
    z-index: 2;
    cursor: pointer;
    border: 1px solid rgba(255,255,255,0.08);
}

.profile-photo-ring {
    position: absolute;
    inset: -5px;
    border-radius: 26px;
    background: linear-gradient(135deg, rgba(37,99,235,0.4), rgba(59,130,246,0.08));
    filter: blur(8px);
    z-index: 1;
}

.profile-hero-copy {
    min-width: 0;
}

.profile-kicker {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .16em;
    color: #7dd3fc;
    opacity: .9;
    margin-bottom: 8px;
}

.profile-hero-copy h1 {
    margin: 0;
    font-size: 34px;
    font-weight: 800;
    line-height: 1.05;
}

.profile-sub {
    margin-top: 8px;
    color: rgba(226,232,240,.72);
    font-size: 14px;
}

.profile-hero-badges,
.profile-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.profile-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 30px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    font-size: 12px;
    font-weight: 700;
    color: #e2e8f0;
}

.profile-chip.ok {
    background: rgba(34,197,94,0.12);
    border-color: rgba(34,197,94,0.22);
    color: #86efac;
}

.profile-summary-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
}

.summary-card {
    border-radius: 18px;
    padding: 18px;
}

.summary-card span {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .08em;
    opacity: .66;
}

.summary-card strong {
    display: block;
    margin-top: 10px;
    font-size: 30px;
    font-weight: 800;
    color: #fff;
    line-height: 1;
}

.summary-card small {
    display: block;
    margin-top: 8px;
    font-size: 12px;
    color: rgba(226,232,240,.64);
}

.summary-card.danger {
    border-color: rgba(239,68,68,0.24);
}

.profile-section-card {
    border-radius: 22px;
    padding: 22px;
}

.profile-section-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
}

.profile-section-head h3 {
    margin: 0;
    font-size: 22px;
    font-weight: 800;
    color: #fff;
}

.profile-section-head p {
    margin: 6px 0 0;
    color: rgba(226,232,240,.62);
}

.profile-content {
    padding: 0;
    background: transparent;
    border-radius: 0;
}

.profile-info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.info-card {
    border-radius: 16px;
    padding: 16px;
}

.info-card-wide {
    grid-column: span 2;
}

.info-card span {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .08em;
    opacity: .6;
    margin-bottom: 10px;
}

.info-card strong {
    display: block;
    font-size: 15px;
    line-height: 1.5;
    color: #e2e8f0;
    font-weight: 700;
}

.profile-linked-panels {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.linked-panels-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

.linked-panel {
    border-radius: 18px;
    padding: 18px;
}

.linked-panel-full {
    grid-column: 1 / -1;
}

.linked-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
}

.linked-panel-head h4 {
    margin: 0;
    font-size: 17px;
    font-weight: 800;
    color: #fff;
}

.linked-panel-head span {
    min-width: 28px;
    height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(37,99,235,0.16);
    border: 1px solid rgba(59,130,246,0.24);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 800;
    color: #93c5fd;
}

.linked-table-wrap {
    overflow-x: auto;
}

.linked-table {
    width: 100%;
    border-collapse: collapse;
}

.linked-table th,
.linked-table td {
    text-align: left;
    padding: 12px 10px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    vertical-align: middle;
    white-space: nowrap;
}

.linked-table th {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: rgba(226,232,240,.58);
    font-weight: 800;
}

.linked-table td {
    font-size: 13px;
    color: #dbe7f5;
}

.profile-mini-badge {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    font-size: 12px;
    font-weight: 700;
    color: #e2e8f0;
}

.profile-mini-badge.warn {
    background: rgba(245,158,11,0.12);
    border-color: rgba(245,158,11,0.25);
    color: #fcd34d;
}

.row-danger-soft {
    background: rgba(239,68,68,0.06);
}

.profile-empty {
    padding: 16px;
    border-radius: 14px;
    background: rgba(255,255,255,0.04);
    border: 1px dashed rgba(255,255,255,0.1);
    color: rgba(226,232,240,.62);
    font-size: 13px;
}

@media (max-width: 1280px) {
    .profile-summary-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .profile-hero {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-summary-grid,
    .profile-info-grid {
        grid-template-columns: 1fr;
    }

    .info-card-wide {
        grid-column: span 1;
    }

    .profile-hero-left {
        align-items: flex-start;
        flex-direction: column;
    }
}

.citizens-page,
.citizens-page * {
    box-sizing: border-box;
}

.citizens-page {
    display: flex;
    flex-direction: column;
    gap: 18px;
    min-height: 100%;
    color: rgba(255,255,255,.94);
    padding: 4px;
}

/* HERO */

.citizens-hero {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 18px;
    padding: 26px 28px;
    border-radius: 24px;
    background:
        radial-gradient(circle at top right, rgba(59,130,246,.18), transparent 30%),
        linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
    border: 1px solid rgba(255,255,255,.08);
    box-shadow: 0 24px 60px rgba(0,0,0,.28);
}

.citizens-kicker {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .16em;
    color: #7dd3fc;
    margin-bottom: 8px;
}

.citizens-hero h1 {
    margin: 0;
    font-size: 38px;
    font-weight: 800;
    line-height: 1;
    color: #fff;
}

.citizens-hero p {
    margin: 10px 0 0;
    max-width: 760px;
    color: rgba(226,232,240,.68);
    font-size: 14px;
}

.citizens-hero-side {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.citizens-hero-stat {
    min-width: 120px;
    padding: 16px 18px;
    border-radius: 18px;
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.08);
    text-align: right;
}

.citizens-hero-stat span {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: rgba(226,232,240,.58);
}

.citizens-hero-stat strong {
    display: block;
    margin-top: 8px;
    font-size: 30px;
    font-weight: 800;
    color: #fff;
}

/* TOOLBAR */

.citizens-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.citizens-search-wrap {
    flex: 1 1 340px;
    min-width: 260px;
}

.citizens-actions,
.citizens-filters {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.citizens-search-wrap input,
.citizens-filters select {
    width: 100%;
    height: 46px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(9,16,34,.72);
    color: #dbe7f5;
    padding: 0 16px;
    font-size: 13px;
    transition: .18s ease;
    outline: none;
}

.citizens-search-wrap input::placeholder {
    color: rgba(226,232,240,.45);
}

.citizens-search-wrap input:focus,
.citizens-filters select:focus {
    border-color: rgba(59,130,246,.55);
    box-shadow: 0 0 0 3px rgba(59,130,246,.14);
}

.citizens-filters select {
    width: auto;
    min-width: 160px;
    padding-right: 38px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg fill='%23cbd5e1' height='20' viewBox='0 0 24 24' width='20' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 14px;
}

.citizens-add-btn {
    height: 46px;
    padding: 0 18px;
    border-radius: 14px;
    font-weight: 800;
}

/* TABLE SHELL */

.citizens-table-shell {
    border-radius: 24px;
    background:
        linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.02));
    border: 1px solid rgba(255,255,255,.08);
    box-shadow: 0 24px 60px rgba(0,0,0,.22);
    overflow: hidden;
}

.citizens-table-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 20px 22px 16px;
    border-bottom: 1px solid rgba(255,255,255,.06);
}

.citizens-table-topbar h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 800;
    color: #fff;
}

.citizens-table-topbar p {
    margin: 6px 0 0;
    font-size: 13px;
    color: rgba(226,232,240,.6);
}

.citizens-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.citizens-table-wrapper::-webkit-scrollbar {
    height: 8px;
}

.citizens-table-wrapper::-webkit-scrollbar-thumb {
    background: rgba(59,130,246,.24);
    border-radius: 999px;
}

.citizens-table {
    width: 100%;
    min-width: 1180px;
    border-collapse: collapse;
}

.citizens-table thead th {
    padding: 16px 14px;
    text-align: left;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: rgba(226,232,240,.6);
    background: rgba(255,255,255,.02);
    border-bottom: 1px solid rgba(255,255,255,.06);
}

.citizens-table tbody tr {
    transition: .15s ease;
}

.citizens-table tbody tr:hover {
    background: rgba(255,255,255,.025);
}

.citizens-table tbody td {
    padding: 16px 14px;
    border-bottom: 1px solid rgba(255,255,255,.05);
    vertical-align: middle;
    font-size: 13px;
    color: #dbe7f5;
}

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

.citizen-main-cell {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 220px;
}

.citizen-avatar {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 14px;
    background: linear-gradient(145deg, #1d4ed8, #1e3a8a);
    color: #fff;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    border: 1px solid rgba(255,255,255,.1);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.08);
}

.citizen-main-text strong {
    display: block;
    font-size: 14px;
    color: #fff;
    font-weight: 800;
    line-height: 1.2;
}

.sub-info {
    margin-top: 5px;
    font-size: 12px;
    color: rgba(226,232,240,.5);
}

.contact-stack {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.contact-stack div {
    white-space: nowrap;
}

.licenses-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.lic-badge {
    min-width: 24px;
    height: 24px;
    padding: 0 8px;
    border-radius: 8px;
    background: rgba(37,99,235,.18);
    border: 1px solid rgba(59,130,246,.22);
    color: #93c5fd;
    font-size: 11px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.actions-col {
    width: 220px;
}

.actions-cell {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.actions-cell button {
    height: 34px;
    padding: 0 12px;
    border-radius: 11px;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    transition: .16s ease;
}

.btn-view {
    border: 1px solid rgba(59,130,246,.24);
    background: linear-gradient(180deg, rgba(37,99,235,.24), rgba(37,99,235,.12));
    color: #dbeafe;
}

.btn-view:hover {
    transform: translateY(-1px);
    border-color: rgba(96,165,250,.38);
}

.btn-secondary {
    border: 1px solid rgba(255,255,255,.1);
    background: rgba(255,255,255,.06);
    color: #e5edf8;
}

.btn-secondary:hover {
    transform: translateY(-1px);
    background: rgba(255,255,255,.09);
}

.btn-danger {
    border: 1px solid rgba(239,68,68,.18);
    background: linear-gradient(180deg, rgba(239,68,68,.96), rgba(220,38,38,.88));
    color: #fff;
    box-shadow: 0 10px 28px rgba(239,68,68,.22);
}

.btn-danger:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 32px rgba(239,68,68,.28);
}

.empty-state-row td {
    padding: 36px 18px;
    text-align: center;
    color: rgba(226,232,240,.55);
    font-size: 14px;
}

/* FOCUS ROW */

.citizen-row-focus {
    animation: citizenPulse 2.2s ease;
}

@keyframes citizenPulse {
    0% { background: rgba(37,99,235,.18); }
    100% { background: transparent; }
}

/* MODAL */

.modal.large {
    width: min(980px, calc(100vw - 40px));
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.grid-2 .full {
    grid-column: span 2;
}

.licenses {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.licenses label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #dbe7f5;
}

/* CONFIRM */

.confirm-overlay {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(2,6,23,.72);
    backdrop-filter: blur(8px);
    z-index: 9999;
}

.confirm-overlay.active {
    display: flex;
}

.confirm-box {
    width: min(460px, 100%);
    padding: 22px;
    border-radius: 22px;
    border: 1px solid rgba(255,255,255,.08);
    background: linear-gradient(180deg, rgba(26,36,61,.98), rgba(17,24,39,.98));
    box-shadow: 0 30px 90px rgba(0,0,0,.4);
}

.confirm-box h3 {
    margin: 0;
    font-size: 22px;
    font-weight: 800;
    color: #fff;
}

.confirm-box p {
    margin: 10px 0 0;
    color: rgba(226,232,240,.68);
    line-height: 1.6;
}

.confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

/* PROFILE LEGACY SUPPORT */

.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.profile-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.profile-photo {
    width: 90px;
    height: 90px;
    border-radius: 16px;
    background: #0f172a;
    background-size: cover;
    background-position: center;
}

.profile-sub {
    color: #94a3b8;
    font-size: 14px;
}

.profile-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
}

.tab {
    background: #1e293b;
    border: none;
    padding: 8px 14px;
    border-radius: 8px;
    color: #cbd5e1;
    cursor: pointer;
}

.tab.active {
    background: linear-gradient(90deg,#2563eb,#1d4ed8);
    color: white;
}

.profile-content {
    background: linear-gradient(145deg, #182542, #111a30);
    padding: 25px;
    border-radius: 18px;
}

.citizen-actions-row {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 15px;
}

.citizen-main {
    cursor: pointer;
}

/* RESPONSIVE */

@media (max-width: 1100px) {
    .citizens-hero {
        flex-direction: column;
        align-items: flex-start;
    }

    .grid-2 {
        grid-template-columns: 1fr;
    }

    .grid-2 .full {
        grid-column: span 1;
    }
}