/* =============================================================
   Verigence — Unified Theme CSS
   Dark indigo brand: #1e1b4b → #312e81 → #4c1d95
   Accent gradient:  #6366f1 → #8b5cf6
   ============================================================= */

/* ── Design tokens ─────────────────────────────────────────── */
:root {
    /* Brand colours */
    --brand-dark:    linear-gradient(165deg, #1e1b4b 0%, #312e81 45%, #4c1d95 100%);
    --brand-accent:  linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --brand-50:  #eef2ff;
    --brand-100: #e0e7ff;
    --brand-500: #6366f1;
    --brand-600: #4f46e5;
    --brand-700: #4338ca;
    --brand-800: #3730a3;
    --brand-900: #312e81;

    /* Surface */
    --surface:       #ffffff;
    --surface-soft:  #f8fafd;
    --bg-page:       #f1f3f9;

    /* Ink */
    --ink-900: #0f172a;
    --ink-700: #334155;
    --ink-500: #64748b;
    --ink-400: #94a3b8;
    --ink-200: #e2e8f0;

    /* Status */
    --status-pending:     #f59e0b;
    --status-progress:    #0ea5e9;
    --status-completed:   #10b981;
    --status-expired:     #6b7280;
    --status-rejected:    #ef4444;

    /* Shadows */
    --sh-xs:  0 1px 3px rgba(15,23,42,.06);
    --sh-sm:  0 4px 12px rgba(15,23,42,.08);
    --sh-md:  0 8px 24px rgba(15,23,42,.10);
    --sh-lg:  0 16px 48px rgba(15,23,42,.13);
    --sh-brand: 0 8px 24px rgba(79,70,229,.28);

    /* Radii */
    --r-xs: 6px;
    --r-sm: 8px;
    --r-md: 12px;
    --r-lg: 16px;
    --r-xl: 20px;
    --r-2xl: 28px;
    --r-full: 999px;

    /* Motion */
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --dur: 0.25s;
}

/* ── Page background ───────────────────────────────────────── */
body {
    background: var(--bg-page);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--ink-700);
}

/* ── Page section wrapper ──────────────────────────────────── */
.t-page {
    padding: 1.5rem;
}

/* ── Page header ───────────────────────────────────────────── */
.t-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.t-page-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--ink-900);
    letter-spacing: -0.02em;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.t-page-title i {
    background: var(--brand-accent);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.t-page-subtitle {
    font-size: 0.82rem;
    color: var(--ink-500);
    margin: 0;
}

/* ── Cards ─────────────────────────────────────────────────── */
.t-card {
    background: var(--surface);
    border: 1px solid var(--ink-200);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-sm);
    overflow: hidden;
    transition: box-shadow var(--dur) var(--ease),
                transform var(--dur) var(--ease);
}

.t-card:hover {
    box-shadow: var(--sh-md);
    transform: translateY(-2px);
}

.t-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--ink-200);
    background: var(--surface-soft);
}

.t-card-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--ink-900);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.t-card-title i {
    color: var(--brand-500);
    font-size: 0.85rem;
}

.t-card-body {
    padding: 1.25rem;
}

/* Hero card — dark gradient banner */
.t-card-hero {
    background: var(--brand-dark);
    color: #fff;
    border: none;
    border-radius: var(--r-xl);
    padding: 1.75rem 2rem;
    position: relative;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.t-card-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 60% at 90% -10%, rgba(139,92,246,.35), transparent 65%);
    pointer-events: none;
}

.t-card-hero-content { position: relative; z-index: 1; }

.t-card-hero h2,
.t-card-hero h3 {
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.35rem;
}

.t-card-hero p { color: rgba(255,255,255,.78); margin: 0; font-size: 0.88rem; }

/* ── Stat cards ─────────────────────────────────────────────── */
.t-stat {
    background: var(--surface);
    border: 1px solid var(--ink-200);
    border-radius: var(--r-lg);
    padding: 1.25rem;
    box-shadow: var(--sh-sm);
    position: relative;
    overflow: hidden;
    transition: box-shadow var(--dur) var(--ease),
                transform var(--dur) var(--ease);
}

.t-stat::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: var(--brand-accent);
}

.t-stat:hover { transform: translateY(-4px); box-shadow: var(--sh-md); }

.t-stat-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ink-500);
    margin-bottom: 0.35rem;
}

.t-stat-value {
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    background: var(--brand-accent);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
}

.t-stat-value.warning { background: none; -webkit-text-fill-color: var(--status-pending); }
.t-stat-value.info    { background: none; -webkit-text-fill-color: var(--status-progress); }
.t-stat-value.success { background: none; -webkit-text-fill-color: var(--status-completed); }
.t-stat-value.danger  { background: none; -webkit-text-fill-color: var(--status-rejected); }

.t-stat-icon {
    width: 44px; height: 44px;
    border-radius: var(--r-md);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
    color: #fff;
    flex-shrink: 0;
    transition: transform var(--dur) var(--ease);
}

.t-stat:hover .t-stat-icon { transform: scale(1.1) rotate(5deg); }

.t-stat-icon.brand   { background: var(--brand-accent); box-shadow: var(--sh-brand); }
.t-stat-icon.warning { background: linear-gradient(135deg, #f59e0b, #ef4444); box-shadow: 0 6px 18px rgba(245,158,11,.3); }
.t-stat-icon.info    { background: linear-gradient(135deg, #0ea5e9, #6366f1); box-shadow: 0 6px 18px rgba(14,165,233,.3); }
.t-stat-icon.success { background: linear-gradient(135deg, #10b981, #0ea5e9); box-shadow: 0 6px 18px rgba(16,185,129,.3); }
.t-stat-icon.danger  { background: linear-gradient(135deg, #ef4444, #f43f5e); box-shadow: 0 6px 18px rgba(239,68,68,.3); }

/* ── Buttons ────────────────────────────────────────────────── */
.t-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.55rem 1.1rem;
    border-radius: var(--r-md);
    font-size: 0.85rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: transform var(--dur) var(--ease),
                box-shadow var(--dur) var(--ease),
                background var(--dur) var(--ease);
    white-space: nowrap;
}

.t-btn:hover { transform: translateY(-2px); }
.t-btn:active { transform: translateY(0); }

.t-btn-primary {
    background: var(--brand-accent);
    color: #fff;
    box-shadow: var(--sh-brand);
}
.t-btn-primary:hover {
    box-shadow: 0 12px 28px rgba(79,70,229,.38);
    color: #fff;
}

.t-btn-dark {
    background: var(--brand-dark);
    color: #fff;
    box-shadow: 0 6px 18px rgba(30,27,75,.35);
}
.t-btn-dark:hover { color: #fff; box-shadow: 0 10px 28px rgba(30,27,75,.45); }

.t-btn-ghost {
    background: transparent;
    color: var(--brand-600);
    border: 1.5px solid var(--brand-100);
}
.t-btn-ghost:hover {
    background: var(--brand-50);
    border-color: var(--brand-500);
}

.t-btn-outline {
    background: transparent;
    color: var(--ink-700);
    border: 1.5px solid var(--ink-200);
}
.t-btn-outline:hover {
    background: var(--surface-soft);
    border-color: var(--ink-400);
    color: var(--ink-900);
}

.t-btn-danger-ghost {
    background: transparent;
    color: var(--status-rejected);
    border: 1.5px solid #fecaca;
}
.t-btn-danger-ghost:hover {
    background: #fef2f2;
    border-color: var(--status-rejected);
}

.t-btn-sm  { padding: 0.35rem 0.75rem; font-size: 0.78rem; border-radius: var(--r-sm); }
.t-btn-lg  { padding: 0.75rem 1.75rem; font-size: 0.95rem; }
.t-btn-icon {
    width: 34px; height: 34px; padding: 0;
    border-radius: var(--r-sm);
    justify-content: center;
}

/* ── Tables ─────────────────────────────────────────────────── */
.t-table-wrap {
    overflow-x: auto;
    border-radius: var(--r-md);
}

.t-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 0.85rem;
}

.t-table thead th {
    background: linear-gradient(165deg, #1e1b4b 0%, #312e81 45%, #4c1d95 100%);
    color: rgba(255,255,255,.9);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    padding: 0.85rem 1rem;
    border: none;
    white-space: nowrap;
}

.t-table thead th:first-child { border-radius: var(--r-sm) 0 0 0; }
.t-table thead th:last-child  { border-radius: 0 var(--r-sm) 0 0; }

.t-table tbody tr {
    transition: background var(--dur) var(--ease);
}

.t-table tbody td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--ink-200);
    vertical-align: middle;
    color: var(--ink-700);
}

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

.t-table tbody tr:hover td {
    background: var(--brand-50);
}

/* Status row tints */
.t-table tbody tr.pending    td { border-left: 3px solid var(--status-pending); }
.t-table tbody tr.in_progress td { border-left: 3px solid var(--status-progress); }
.t-table tbody tr.completed  td { border-left: 3px solid var(--status-completed); }
.t-table tbody tr.expired    td { border-left: 3px solid var(--status-expired); }
.t-table tbody tr.rejected   td { border-left: 3px solid var(--status-rejected); }

/* ── Status badges ──────────────────────────────────────────── */
.t-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3em 0.7em;
    border-radius: var(--r-full);
    font-size: 0.72rem;
    font-weight: 600;
    white-space: nowrap;
}

.t-badge-pending   { background: #fef3c7; color: #92400e; }
.t-badge-progress  { background: #e0f2fe; color: #0369a1; }
.t-badge-completed { background: #d1fae5; color: #065f46; }
.t-badge-expired   { background: #f3f4f6; color: #4b5563; }
.t-badge-rejected  { background: #fee2e2; color: #991b1b; }
.t-badge-active    { background: #d1fae5; color: #065f46; }
.t-badge-inactive  { background: #f3f4f6; color: #4b5563; }
.t-badge-admin     { background: #fee2e2; color: #991b1b; }
.t-badge-officer   { background: var(--brand-100); color: var(--brand-700); }
.t-badge-client    { background: #e0f2fe; color: #0369a1; }
.t-badge-brand     { background: var(--brand-100); color: var(--brand-700); }

/* ── Avatar ─────────────────────────────────────────────────── */
.t-avatar {
    width: 36px; height: 36px;
    border-radius: 50%;
    background: var(--brand-accent);
    color: #fff;
    font-weight: 700;
    font-size: 0.78rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: var(--sh-brand);
    transition: transform var(--dur) var(--ease);
}
.t-avatar:hover { transform: scale(1.1) rotate(4deg); }
.t-avatar-lg { width: 48px; height: 48px; font-size: 0.95rem; }

/* ── Forms ──────────────────────────────────────────────────── */
.t-form-label {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--ink-700);
    margin-bottom: 0.35rem;
    display: block;
}

.t-form-control {
    width: 100%;
    padding: 0.6rem 0.9rem;
    border: 1.5px solid var(--ink-200);
    border-radius: var(--r-md);
    font-size: 0.875rem;
    background: var(--surface);
    color: var(--ink-900);
    transition: border-color var(--dur) var(--ease),
                box-shadow var(--dur) var(--ease);
}

.t-form-control:focus {
    outline: none;
    border-color: var(--brand-500);
    box-shadow: 0 0 0 3px rgba(99,102,241,.15);
}

/* ── Filter panel ───────────────────────────────────────────── */
.t-filter {
    background: var(--surface);
    border: 1px solid var(--ink-200);
    border-radius: var(--r-lg);
    padding: 1rem 1.25rem;
    margin-bottom: 1.25rem;
    box-shadow: var(--sh-xs);
}

/* ── Pagination ─────────────────────────────────────────────── */
.t-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    padding: 1rem;
}

.t-pagination a,
.t-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px; height: 34px;
    padding: 0 0.6rem;
    border-radius: var(--r-sm);
    font-size: 0.82rem;
    font-weight: 500;
    text-decoration: none;
    transition: background var(--dur) var(--ease),
                color var(--dur) var(--ease);
    color: var(--ink-700);
    border: 1px solid var(--ink-200);
    background: var(--surface);
}

.t-pagination a:hover { background: var(--brand-50); color: var(--brand-600); border-color: var(--brand-100); }
.t-pagination .active { background: var(--brand-accent); color: #fff; border-color: transparent; box-shadow: var(--sh-brand); }
.t-pagination .disabled { opacity: .45; pointer-events: none; }

/* ── Timeline ───────────────────────────────────────────────── */
.t-timeline { position: relative; padding-left: 1.5rem; }
.t-timeline::before {
    content: '';
    position: absolute;
    left: 0.45rem;
    top: 0.5rem; bottom: 0.5rem;
    width: 2px;
    background: var(--ink-200);
}

.t-timeline-item {
    position: relative;
    padding-bottom: 1.25rem;
}
.t-timeline-item:last-child { padding-bottom: 0; }

.t-timeline-dot {
    position: absolute;
    left: -1.5rem;
    top: 0.25rem;
    width: 14px; height: 14px;
    border-radius: 50%;
    background: var(--brand-accent);
    border: 2px solid #fff;
    box-shadow: 0 0 0 3px var(--brand-100);
}

.t-timeline-title {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--ink-900);
}

.t-timeline-time {
    font-size: 0.72rem;
    color: var(--ink-400);
}

/* ── Icon box ────────────────────────────────────────────────── */
.t-icon-box {
    width: 52px; height: 52px;
    border-radius: var(--r-lg);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.25rem;
    color: #fff;
    background: var(--brand-accent);
    box-shadow: var(--sh-brand);
    flex-shrink: 0;
    transition: transform var(--dur) var(--ease);
}
.t-icon-box:hover { transform: scale(1.08) rotate(4deg); }
.t-icon-box.sm { width: 38px; height: 38px; font-size: 0.95rem; border-radius: var(--r-md); }

/* ── Divider info row ────────────────────────────────────────── */
.t-info-row {
    display: flex;
    align-items: flex-start;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--ink-200);
    gap: 0.75rem;
    font-size: 0.85rem;
}
.t-info-row:last-child { border-bottom: none; }
.t-info-label { color: var(--ink-500); font-weight: 600; min-width: 130px; flex-shrink: 0; }
.t-info-value { color: var(--ink-900); }

/* ── Section heading ─────────────────────────────────────────── */
.t-section-title {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--ink-500);
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--ink-200);
    margin-bottom: 1rem;
}

/* ── Empty state ─────────────────────────────────────────────── */
.t-empty {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--ink-500);
}
.t-empty i {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
    opacity: .35;
    display: block;
    background: var(--brand-accent);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.t-empty p { font-size: 0.88rem; margin: 0 0 1rem; }

/* ── Login / auth card ───────────────────────────────────────── */
.t-auth-wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    background: var(--brand-dark);
}

.t-auth-card {
    width: 100%;
    max-width: 440px;
    background: var(--surface);
    border-radius: var(--r-2xl);
    overflow: hidden;
    box-shadow: 0 32px 80px rgba(30,27,75,.45);
}

.t-auth-header {
    background: var(--brand-dark);
    padding: 2.25rem 2rem 1.75rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.t-auth-header::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 70% 50% at 80% 0%, rgba(139,92,246,.5), transparent 60%);
    pointer-events: none;
}

.t-auth-logo {
    width: 72px; height: 72px;
    border-radius: var(--r-xl);
    background: rgba(255,255,255,.12);
    border: 1.5px solid rgba(255,255,255,.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    color: #fff;
    margin: 0 auto 1rem;
    position: relative;
    z-index: 1;
    backdrop-filter: blur(8px);
}

.t-auth-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.02em;
    margin: 0 0 0.25rem;
    position: relative;
    z-index: 1;
}

.t-auth-subtitle {
    font-size: 0.82rem;
    color: rgba(255,255,255,.7);
    margin: 0;
    position: relative;
    z-index: 1;
}

.t-auth-body { padding: 2rem; }

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 768px) {
    .t-page { padding: 1rem; }
    .t-card-hero { padding: 1.25rem; border-radius: var(--r-lg); }
    .t-stat-value { font-size: 1.4rem; }
    .t-auth-body { padding: 1.5rem; }
}


/* ── Card status variants for verification cards ────────────── */
.t-card {
    transition: all 0.3s var(--ease);
    border-left: 4px solid var(--brand-500);
    border-radius: var(--r-md);
}

.t-card:hover {
    transform: translateY(-3px) scale(1.01);
    box-shadow: var(--sh-brand) !important;
}

.t-card-pending {
    border-left-color: var(--status-pending);
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.05) 0%, rgba(245, 158, 11, 0.02) 100%);
}

.t-card-in-progress {
    border-left-color: var(--status-progress);
    background: linear-gradient(135deg, rgba(14, 165, 233, 0.05) 0%, rgba(14, 165, 233, 0.02) 100%);
}

.t-card-completed {
    border-left-color: var(--status-completed);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.05) 0%, rgba(16, 185, 129, 0.02) 100%);
}

.t-card-expired {
    border-left-color: var(--status-expired);
    background: linear-gradient(135deg, rgba(107, 114, 128, 0.05) 0%, rgba(107, 114, 128, 0.02) 100%);
}

.t-card-rejected {
    border-left-color: var(--status-rejected);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.05) 0%, rgba(239, 68, 68, 0.02) 100%);
}

.t-card-reopened {
    border-left-color: var(--status-progress);
    background: linear-gradient(135deg, rgba(14, 165, 233, 0.05) 0%, rgba(14, 165, 233, 0.02) 100%);
}


/* ── Quick action / CTA card ─────────────────────────────────── */
.t-card-cta {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
    border: 1px solid rgba(99, 102, 241, 0.1);
    border-radius: var(--r-lg);
    padding: 2rem;
    text-align: center;
    transition: all 0.3s var(--ease);
}

.t-card-cta:hover {
    transform: translateY(-5px);
    box-shadow: var(--sh-brand);
}


/* ── Avatar ──────────────────────────────────────────────────── */
.t-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--brand-accent);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.3s var(--ease);
    box-shadow: var(--sh-brand);
}

.t-card:hover .t-avatar {
    transform: scale(1.15) rotate(5deg);
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
}

/* ── Modal ───────────────────────────────────────────────────── */
.t-modal {
    border-radius: var(--r-2xl);
    border: none;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.25);
}

.t-modal-header {
    background: var(--brand-dark);
    color: white;
    border-radius: var(--r-2xl) var(--r-2xl) 0 0;
    padding: 1.5rem;
}


/* ── Auth container & form enhancements ──────────────────────── */
.t-auth-container {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.t-auth-card {
    border: none;
    border-radius: var(--r-2xl);
    box-shadow: 0 20px 60px rgba(99, 102, 241, 0.2);
    overflow: hidden;
    max-width: 500px;
    width: 100%;
}

.t-auth-toggle {
    border-radius: 0 var(--r-md) var(--r-md) 0;
    border: 2px solid #e9ecef;
    border-left: none;
    background: rgba(99, 102, 241, 0.05);
    transition: all 0.3s var(--ease);
    color: var(--brand-500);
}

.t-auth-toggle:hover {
    background: var(--brand-500);
    color: white;
    border-color: var(--brand-500);
}

.input-group .form-control {
    border-radius: var(--r-md) 0 0 var(--r-md);
}

.t-auth-body {
    padding: 2.5rem 2rem;
    background: white;
}

@media (max-width: 768px) {
    .t-auth-card { border-radius: var(--r-lg); }
    .t-auth-header { padding: 2rem 1.5rem 1.75rem; }
    .t-auth-body { padding: 2rem 1.5rem; }
}


/* ── Timeline component ──────────────────────────────────────── */
.t-timeline {
    position: relative;
    padding-left: 1.5rem;
    margin: 0;
}

.t-timeline::before {
    content: '';
    position: absolute;
    left: 0.5rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: #e9ecef;
}

.t-timeline-item {
    position: relative;
    padding-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.t-timeline-item:last-child {
    padding-bottom: 0;
}

.t-timeline-item::before {
    content: '';
    position: absolute;
    left: -0.5rem;
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    background-color: var(--brand-500);
    top: 0.25rem;
}

.t-timeline-content {
    background: white;
    border-radius: var(--r-sm);
    padding: 0.75rem 1rem;
    position: relative;
    box-shadow: var(--sh-xs);
}

.t-timeline-content h6 {
    font-size: 0.875rem;
    font-weight: 600;
}

.t-timeline-content p {
    font-size: 0.8125rem;
    margin-bottom: 0.25rem;
}

.t-timeline-content small {
    font-size: 0.75rem;
}

/* ── Document card enhancements ──────────────────────────────── */
.t-document-card {
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: all 0.3s var(--ease);
    border: 1px solid #dee2e6;
}

.t-document-card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.t-document-card .card-body {
    flex: 1;
}

.t-document-card .card-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--ink-900);
}

.t-document-actions .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.8rem;
}

/* ── Sidebar content ─────────────────────────────────────────── */
.t-sidebar-content {
    position: sticky;
    top: 1rem;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}


/* ── Form inputs styling ─────────────────────────────────────── */
.form-control,
.form-select {
    border: 2px solid #e9ecef;
    border-radius: var(--r-md);
    padding: 0.5rem 0.875rem;
    font-size: 0.9375rem;
    font-family: inherit;
    transition: all 0.3s var(--ease);
    background-color: #fafbfc;
    height: auto;
    min-height: 36px;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--brand-500);
    box-shadow: 0 0 0 0.2rem rgba(99, 102, 241, 0.15);
    outline: none;
    background-color: white;
}

.form-control::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.input-group-text {
    border: 2px solid #e9ecef;
    border-radius: 0;
    background-color: #f1f5f9;
    color: var(--brand-500);
    font-weight: 600;
    padding: 0.5rem 0.875rem;
    min-height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.input-group .form-control:focus,
.input-group .form-select:focus {
    border-color: var(--brand-500);
    z-index: 5;
}

.input-group {
    display: flex;
    border-radius: var(--r-md);
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.3s var(--ease);
}

.input-group:focus-within {
    box-shadow: 0 0 0 0.2rem rgba(99, 102, 241, 0.1);
}

.input-group .form-control,
.input-group .form-select {
    border-radius: 0;
    border-left: none;
    border-right: none;
}

.form-label {
    color: var(--ink-700);
    font-weight: 600;
    margin-bottom: 0.375rem;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-check-input {
    border: 2px solid #cbd5e1;
    border-radius: var(--r-sm);
    width: 1.5rem;
    height: 1.5rem;
    margin-top: 0;
    transition: all 0.3s ease;
    cursor: pointer;
    flex-shrink: 0;
}

.form-check-input:checked {
    background-color: var(--brand-500);
    border-color: var(--brand-500);
}

.form-check-input:focus {
    border-color: var(--brand-500);
    box-shadow: 0 0 0 0.3rem rgba(99, 102, 241, 0.25);
}

.form-check-label {
    margin-bottom: 0;
    cursor: pointer;
    user-select: none;
}

/* ── Textarea styling ───────────────────────────────────────── */
textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

textarea.form-control:focus {
    border-color: var(--brand-500);
}

/* ── Form group improvements ────────────────────────────────── */
.form-group {
    position: relative;
}

.form-text {
    color: #64748b;
    font-size: 0.85rem;
    margin-top: 0.35rem;
}

.invalid-feedback {
    color: var(--status-rejected);
    font-size: 0.85rem;
    margin-top: 0.35rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

/* ── Form hints ─────────────────────────────────────────────── */
.form-hint {
    color: #64748b;
    font-size: 0.85rem;
    padding: 0.5rem 0.75rem;
    background: #f1f5f9;
    border-left: 3px solid var(--brand-500);
    border-radius: 0 var(--r-sm) var(--r-sm) 0;
    margin-top: 0.5rem;
}

/* ── Form validation states ─────────────────────────────────– */
.is-invalid {
    border-color: var(--status-rejected) !important;
}

.is-invalid:focus {
    border-color: var(--status-rejected) !important;
    box-shadow: 0 0 0 0.2rem rgba(239, 68, 68, 0.15) !important;
}

.is-valid {
    border-color: var(--status-completed) !important;
}

.is-valid:focus {
    border-color: var(--status-completed) !important;
    box-shadow: 0 0 0 0.2rem rgba(16, 185, 129, 0.15) !important;
}

/* ── Select field enhancements ──────────────────────────────– */
.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%236366f1' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
    padding-right: 2.5rem;
}

/* ── Input with clear button ────────────────────────────────– */
.input-with-clear {
    position: relative;
}

.input-with-clear .form-control {
    padding-right: 2.5rem;
}

.input-with-clear .clear-btn {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    padding: 0.25rem;
    transition: all 0.2s ease;
}

.input-with-clear .clear-btn:hover {
    color: var(--brand-500);
    transform: translateY(-50%) scale(1.1);
}

/* ── Required field indicator ───────────────────────────────– */
.required-indicator {
    color: var(--status-rejected);
    font-weight: bold;
    margin-left: 0.25rem;
}

/* ── Form field wrapper ─────────────────────────────────────– */
.form-field-wrapper {
    margin-bottom: 1.5rem;
}

.form-field-wrapper.has-error .form-control,
.form-field-wrapper.has-error .form-select {
    border-color: var(--status-rejected);
}

/* ── Responsive form fields ─────────────────────────────────– */
@media (max-width: 768px) {
    .form-control,
    .form-select {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 0.875rem 1rem;
    }

    .form-label {
        font-size: 0.9rem;
    }

    .input-group-text {
        padding: 0.875rem 0.75rem;
    }
}


/* ── Form sections ──────────────────────────────────────────── */
.form-section {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
    border-radius: var(--r-lg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(99, 102, 241, 0.1);
    box-shadow: var(--sh-xs);
    transition: all 0.3s var(--ease);
}

.form-section:hover {
    box-shadow: var(--sh-sm);
    border-color: rgba(99, 102, 241, 0.2);
}

.form-section h5 {
    color: var(--brand-500);
    padding-bottom: 0.75rem;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid rgba(99, 102, 241, 0.15);
    font-weight: 600;
}

.form-section h6 {
    color: var(--brand-600);
    font-weight: 600;
    margin-top: 1rem;
}

/* ── Document upload area ───────────────────────────────────── */
.document-upload {
    border: 2px dashed rgba(99, 102, 241, 0.3);
    border-radius: var(--r-md);
    padding: 1.5rem 1rem;
    text-align: center;
    margin-bottom: 1rem;
    background: white;
    cursor: pointer;
    transition: all 0.3s var(--ease);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 180px;
}

.document-upload h6 {
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0.75rem 0 0.5rem 0;
    word-break: break-word;
    color: var(--ink-900);
}

.document-upload p {
    font-size: 0.75rem;
    color: #64748b;
    margin: 0.25rem 0;
    word-break: break-word;
    max-width: 100%;
    white-space: normal;
    line-height: 1.3;
}

.document-upload input[type="file"] {
    display: block;
    width: 100%;
    max-width: 220px;
    margin-top: 0.75rem;
    font-size: 0.8rem;
}

.document-upload:hover {
    border-color: var(--brand-500);
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
    transform: translateY(-2px);
    box-shadow: var(--sh-md);
}

.document-upload i {
    font-size: 2rem;
    color: var(--brand-500);
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
}

.document-upload:hover i {
    transform: scale(1.1) rotate(5deg);
}

.document-upload:hover {
    border-color: var(--brand-500);
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
    transform: translateY(-2px);
    box-shadow: var(--sh-md);
}

.document-upload i {
    font-size: 2rem;
    color: var(--brand-500);
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
}

.document-upload:hover i {
    transform: scale(1.1) rotate(5deg);
}

.document-preview {
    max-width: 100%;
    max-height: 200px;
    margin-top: 1rem;
    border-radius: var(--r-md);
    box-shadow: var(--sh-md);
}

/* ── Tab styling ────────────────────────────────────────────── */
.nav-tabs .nav-link {
    font-weight: 500;
    border-radius: var(--r-md) var(--r-md) 0 0;
    padding: 0.75rem 1.25rem;
    transition: all 0.3s var(--ease);
    color: var(--ink-700);
}

.nav-tabs .nav-link.active {
    background: var(--brand-dark);
    color: white;
    border-color: transparent;
}

.nav-tabs .nav-link:hover {
    color: var(--brand-600);
    border-color: rgba(99, 102, 241, 0.2);
}

.tab-content {
    padding: 1.5rem 0;
}

/* ── Expiry badge ───────────────────────────────────────────– */
.expiry-badge {
    background: linear-gradient(135deg, #f59e0b 0%, #dc2626 100%);
    border-radius: var(--r-full);
    padding: 0.5em 1em;
    font-weight: 600;
    color: white;
    font-size: 0.875rem;
}

/* ── Submit button ──────────────────────────────────────────── */
.btn-submit {
    background: var(--brand-dark);
    border: none;
    border-radius: var(--r-md);
    padding: 0.875rem 2rem;
    font-weight: 600;
    transition: all 0.3s var(--ease);
    box-shadow: var(--sh-brand);
    color: white;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
}

.btn-submit:active {
    transform: translateY(0);
}

@media (max-width: 768px) {
    .form-section {
        padding: 1rem;
        border-radius: var(--r-md);
    }

    .document-upload {
        padding: 1.5rem;
    }

    .form-section h5 {
        font-size: 1.1rem;
    }
}
