:root {
    --uiy-primary: #2563eb;
    --uiy-primary-dark: #1d4ed8;
    --uiy-surface: #ffffff;
    --uiy-surface-alt: #f8fafc;
    --uiy-border: #e2e8f0;
    --uiy-text: #0f172a;
    --uiy-muted: #64748b;
    --uiy-shadow: 0 16px 38px rgba(15, 23, 42, 0.08);
}

body {
    font-family: "Inter", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(180deg, #f8fbff 0%, #f1f5f9 100%);
    color: var(--uiy-text);
}

body.menu-open,
body.sidebar-open {
    overflow: hidden;
}

.hero {
    background: radial-gradient(circle at top left, #3b82f6, #1e3a8a);
    color: #fff;
    padding: 72px 0;
}

.hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 9999px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: rgba(255, 255, 255, 0.1);
    font-size: 0.85rem;
    font-weight: 600;
}

.section-card {
    background: var(--uiy-surface);
    border: 1px solid var(--uiy-border);
    border-radius: 18px;
    box-shadow: var(--uiy-shadow);
    padding: 28px;
}

.verification-result img {
    width: min(100%, 170px);
    border-radius: 14px;
    border: 3px solid #dbeafe;
}

.public-nav {
    border-bottom: 1px solid var(--uiy-border);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(10px);
}

.public-nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 74px;
}

.public-nav-logo {
    height: 40px;
    width: auto;
}

.public-nav-title {
    font-weight: 700;
    letter-spacing: 0.2px;
    color: #0f172a;
}

.public-nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
    gap: 4px;
}

.public-nav-link {
    display: inline-flex;
    text-decoration: none;
    color: #334155;
    font-weight: 600;
    border-radius: 10px;
    padding: 10px 14px;
    transition: all 0.2s ease;
}

.public-nav-link:hover,
.public-nav-link.active {
    color: var(--uiy-primary);
    background: #eff6ff;
}

.public-nav-toggle {
    border: 0;
    background: #eff6ff;
    color: #1e3a8a;
    border-radius: 12px;
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.public-nav-mobile {
    position: fixed;
    inset: 0;
    z-index: 1200;
}

.public-nav-mobile-panel {
    position: absolute;
    top: 0;
    left: 0;
    width: min(86vw, 320px);
    height: 100%;
    background: #fff;
    border-right: 1px solid var(--uiy-border);
    box-shadow: var(--uiy-shadow);
    padding: 20px 18px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.public-nav-mobile-links {
    display: grid;
    gap: 8px;
}

.public-nav-mobile-link {
    text-decoration: none;
    color: #334155;
    font-weight: 600;
    border-radius: 10px;
    padding: 11px 12px;
}

.public-nav-mobile-link.active,
.public-nav-mobile-link:hover {
    color: var(--uiy-primary);
    background: #eff6ff;
}

.public-nav-close {
    border: 0;
    background: #f1f5f9;
    color: #334155;
    border-radius: 10px;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.public-nav-backdrop {
    position: absolute;
    inset: 0;
    border: 0;
    background: rgba(15, 23, 42, 0.45);
}

.public-footer {
    margin-top: 48px;
    background: #fff;
    border-top: 1px solid var(--uiy-border);
}

.public-footer-title {
    color: #0f172a;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    background: #dbeafe;
    color: #1d4ed8;
    font-size: 0.8rem;
    font-weight: 600;
}

.admin-layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 270px;
    min-height: 100vh;
    background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
    color: #fff;
    border-right: 1px solid rgba(148, 163, 184, 0.22);
}

.sidebar-title {
    font-weight: 700;
}

.sidebar .nav-link {
    color: #cbd5e1;
    text-decoration: none;
    border-radius: 10px;
    padding: 10px 12px;
    font-weight: 600;
}

.sidebar .nav-link:hover,
.sidebar .nav-link.active {
    background: rgba(37, 99, 235, 0.25);
    color: #fff;
}

.admin-main {
    flex: 1;
    padding: 24px;
}

.id-preview {
    background: #f8fafc;
    border-radius: 12px;
    padding: 16px;
}

.stat-card {
    border-radius: 14px;
    border: 1px solid var(--uiy-border);
    box-shadow: var(--uiy-shadow);
}

.form-label {
    font-weight: 600;
    color: #334155;
}

.form-control,
.form-select {
    border-radius: 10px;
    border-color: #cbd5e1;
    padding: 10px 12px;
    box-shadow: none;
}

.form-control:focus,
.form-select:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

.btn {
    border-radius: 10px;
    font-weight: 600;
    border-width: 1px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--uiy-primary), var(--uiy-primary-dark));
    border-color: var(--uiy-primary);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
    border-color: #1d4ed8;
}

.btn-outline-primary {
    border-color: #60a5fa;
    color: #2563eb;
}

.btn-outline-primary:hover {
    background: #eff6ff;
    color: #1d4ed8;
    border-color: #2563eb;
}

.table {
    --bs-table-bg: transparent;
    --bs-table-border-color: #e2e8f0;
}

.table > :not(caption) > * > * {
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
    vertical-align: top;
}

.table thead th {
    color: #475569;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    white-space: nowrap;
}

.table td {
    word-break: break-word;
}

.table .btn-sm {
    white-space: nowrap;
}

.message-body {
    min-width: 220px;
    white-space: normal;
}

.alert {
    border-radius: 12px;
    border-width: 1px;
}

.pagination .page-link {
    border-radius: 10px;
    margin: 0 2px;
    border-color: #dbeafe;
    color: #1d4ed8;
}

.pagination .page-item.active .page-link {
    background: #2563eb;
    border-color: #2563eb;
}

.admin-topbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: #0f172a;
    color: #fff;
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.admin-topbar .btn {
    background: #eff6ff;
    border-color: #dbeafe;
    color: #1e3a8a;
}

.admin-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease;
    z-index: 1040;
}

.admin-header-action,
.admin-inline-action {
    width: 100%;
}

@media (min-width: 768px) {
    .admin-header-action,
    .admin-inline-action {
        width: auto;
    }
}

@media (max-width: 991.98px) {
    .section-card {
        padding: 22px;
    }
}

@media (max-width: 767.98px) {
    .hero {
        padding: 52px 0;
    }
    .admin-main {
        padding: 18px;
    }
    .table thead th,
    .table td {
        white-space: nowrap;
    }
    .mobile-stack-table {
        min-width: 0;
    }
    .mobile-stack-table thead {
        display: none;
    }
    .mobile-stack-table,
    .mobile-stack-table tbody,
    .mobile-stack-table tr,
    .mobile-stack-table td {
        display: block;
        width: 100%;
    }
    .mobile-stack-table tr {
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        padding: 10px 12px;
        margin-bottom: 10px;
        background: #fff;
    }
    .mobile-stack-table td {
        white-space: normal;
        border: 0;
        padding: 6px 0;
    }
    .mobile-stack-table td::before {
        content: attr(data-label);
        display: block;
        font-size: 0.72rem;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        color: #64748b;
        font-weight: 700;
        margin-bottom: 4px;
    }
    .mobile-stack-table td[data-label="Select"]::before {
        content: "";
        margin: 0;
    }
    .mobile-stack-table td[data-label="Actions"] .d-flex {
        justify-content: flex-start;
    }
    .mobile-stack-table td[data-label="Actions"] .btn {
        width: 100%;
    }
    .mobile-stack-table td[data-label="Actions"] form {
        width: 100%;
    }
    .message-body {
        min-width: 0;
        white-space: normal;
    }
    .sidebar {
        position: fixed;
        top: 0;
        left: -285px;
        height: 100vh;
        z-index: 1045;
        transition: left 0.25s ease;
    }
    .sidebar-open .sidebar {
        left: 0;
    }
    .sidebar-open .admin-overlay {
        opacity: 1;
        visibility: visible;
    }
}
