@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --dtl-primary: #003A70;
    --dtl-sidebar: #00284F;
    --dtl-accent: #0B63CE;
    --dtl-accent-hover: #094FA6;
    --dtl-preview-bg: #FBBF24;
    --dtl-preview-text: #003A70;
    --dtl-bg: #F8FAFC;
    --dtl-card: #FFFFFF;
    --dtl-border: #E2E8F0;
    --dtl-text-main: #0F172A;
    --dtl-text-muted: #64748B;
    --dtl-text-light: #94A3B8;
    --sidebar-width: 256px;
    --header-height: 60px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--dtl-bg);
    color: var(--dtl-text-main);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* ================= Top Navigation Bar ================= */
.dtl-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background-color: var(--dtl-primary);
    color: #FFFFFF;
    display: flex;
    align-items: center;
    padding: 0 24px;
    z-index: 1000;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

/* Hamburger Menu Button (Mobile & Tablet) */
.dtl-hamburger-btn {
    display: none;
    background: transparent;
    border: none;
    color: #FFFFFF;
    padding: 8px;
    margin-right: 8px;
    border-radius: 6px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
    flex-shrink: 0;
}

.dtl-hamburger-btn:hover {
    background: rgba(255, 255, 255, 0.12);
}

.dtl-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #FFFFFF;
}

.dtl-logo-badge {
    background: #FFFFFF;
    border-radius: 6px;
    padding: 3px 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.dtl-logo-badge img {
    height: 36px;
    width: auto;
    object-fit: contain;
}

.dtl-titles {
    display: flex;
    flex-direction: column;
}

.dtl-title-main {
    font-size: 15px;
    font-weight: 700;
    letter-spacing: -0.2px;
}

.dtl-title-sub {
    font-size: 11px;
    color: #BFDBFE;
}

.dtl-preview-tag {
    background-color: var(--dtl-preview-bg);
    color: var(--dtl-preview-text);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.5px;
    padding: 2px 7px;
    border-radius: 4px;
    text-transform: uppercase;
    margin-left: 10px;
}

.dtl-search-wrap {
    margin-left: auto;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 6px;
    padding: 6px 12px;
    width: 320px;
    transition: background 0.2s ease;
}

.dtl-search-wrap:focus-within {
    background: rgba(255, 255, 255, 0.22);
}

.dtl-search-icon {
    width: 16px;
    height: 16px;
    color: #BFDBFE;
    margin-right: 8px;
    flex-shrink: 0;
}

.dtl-search-input {
    background: transparent;
    border: none;
    color: #FFFFFF;
    font-size: 13px;
    width: 100%;
    outline: none;
}

.dtl-search-input::placeholder {
    color: #BFDBFE;
}

.dtl-header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-left: 20px;
}

.dtl-icon-btn {
    background: transparent;
    border: none;
    color: #FFFFFF;
    padding: 8px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: background 0.2s ease;
    text-decoration: none;
}

.dtl-icon-btn:hover {
    background: rgba(255, 255, 255, 0.12);
}

.dtl-notif-count {
    position: absolute;
    top: 2px;
    right: 2px;
    background: var(--dtl-preview-bg);
    color: var(--dtl-preview-text);
    font-size: 10px;
    font-weight: 700;
    height: 16px;
    min-width: 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

.dtl-user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-left: 16px;
    border-left: 1px solid rgba(255, 255, 255, 0.2);
}

.dtl-user-avatar {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #BFDBFE;
}

.dtl-user-info {
    text-align: right;
    line-height: 1.25;
}

.dtl-user-name {
    font-size: 13px;
    font-weight: 600;
}

.dtl-user-role {
    font-size: 11px;
    color: #BFDBFE;
}

/* ================= Sidebar Navigation ================= */
.dtl-sidebar-mobile-header {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.dtl-sidebar-mobile-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dtl-sidebar-close-btn {
    background: transparent;
    border: none;
    color: #CBD5E1;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.dtl-sidebar-close-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #FFFFFF;
}

.dtl-sidebar-backdrop {
    display: none;
}

/* ================= Notification Dropdown ================= */
.dtl-notif-dropdown {
    position: absolute;
    top: 60px;
    right: 80px;
    width: 340px;
    background: #FFFFFF;
    border: 1px solid #CBD5E1;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    z-index: 1100;
    overflow: hidden;
}

.dtl-notif-header {
    background: #EAF3FF;
    color: #003A70;
    padding: 12px 16px;
    font-weight: 700;
    font-size: 13px;
    border-bottom: 1px solid #CBD5E1;
}

.dtl-notif-body {
    max-height: 300px;
    overflow-y: auto;
}

.dtl-notif-item {
    padding: 10px 16px;
    border-bottom: 1px solid #F1F5F9;
    font-size: 12.5px;
}

.dtl-notif-event {
    color: #0B63CE;
    font-weight: 700;
    font-size: 11px;
    text-transform: uppercase;
}

.dtl-notif-msg {
    color: #334155;
    margin-top: 2px;
}

.dtl-sidebar {
    position: fixed;
    top: var(--header-height);
    bottom: 0;
    left: 0;
    width: var(--sidebar-width);
    background-color: var(--dtl-sidebar);
    color: #F1F5F9;
    display: flex;
    flex-direction: column;
    z-index: 900;
    overflow-y: auto;
}

.dtl-nav-list {
    list-style: none;
    padding: 12px 0;
    flex: 1;
}

.dtl-nav-item {
    margin-bottom: 2px;
}

.dtl-nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 20px;
    color: #CBD5E1;
    text-decoration: none;
    font-size: 13.5px;
    border-left: 4px solid transparent;
    transition: all 0.15s ease-in-out;
}

.dtl-nav-link svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    opacity: 0.85;
}

.dtl-nav-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #FFFFFF;
}

.dtl-nav-link.active {
    background: var(--dtl-accent);
    color: #FFFFFF;
    border-left-color: #FFFFFF;
    font-weight: 600;
}

.dtl-nav-link.active svg {
    opacity: 1;
}

.dtl-sidebar-footer {
    padding: 16px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 11px;
    color: #94A3B8;
    line-height: 1.5;
}

.dtl-sidebar-footer .poc-tag {
    color: rgba(148, 163, 184, 0.7);
    margin-top: 4px;
}

/* ================= Main Content Area ================= */
.dtl-main {
    margin-left: var(--sidebar-width);
    margin-top: var(--header-height);
    padding: 32px 40px;
    min-height: calc(100vh - var(--header-height));
    max-width: 1540px;
}

/* ================= Page Header & Breadcrumbs ================= */
.dtl-breadcrumb {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--dtl-accent);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    margin-bottom: 12px;
}

.dtl-breadcrumb:hover {
    text-decoration: underline;
}

.dtl-page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 24px;
}

.dtl-page-title-group h1 {
    font-size: 26px;
    font-weight: 800;
    color: var(--dtl-primary);
    line-height: 1.2;
}

.dtl-page-subtitle {
    font-size: 14px;
    color: var(--dtl-text-muted);
    margin-top: 4px;
}

.dtl-project-meta-strip {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 6px;
    font-size: 13px;
    color: var(--dtl-text-muted);
}

.dtl-header-btn-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* ================= Buttons ================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 18px;
    border-radius: 6px;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    border: 1px solid transparent;
    transition: all 0.15s ease;
}

.btn-primary {
    background-color: var(--dtl-accent);
    color: #FFFFFF;
}

.btn-primary:hover {
    background-color: var(--dtl-accent-hover);
}

.btn-secondary {
    background-color: #FFFFFF;
    border-color: #CBD5E1;
    color: #334155;
}

.btn-secondary:hover {
    background-color: #F1F5F9;
    border-color: #94A3B8;
}

.btn-danger {
    background-color: #EF4444;
    color: #FFFFFF;
}

.btn-danger:hover {
    background-color: #DC2626;
}

.btn-sm {
    padding: 4px 10px;
    font-size: 12px;
    border-radius: 4px;
}

/* ================= Filter & Search Bar ================= */
.dtl-filter-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    gap: 16px;
}

.dtl-search-box {
    display: flex;
    align-items: center;
    background: #FFFFFF;
    border: 1px solid #CBD5E1;
    border-radius: 6px;
    padding: 6px 14px;
    width: 320px;
}

.dtl-search-box input {
    border: none;
    outline: none;
    font-size: 13px;
    width: 100%;
    margin-left: 8px;
    color: var(--dtl-text-main);
}

.dtl-filter-options {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 13px;
    color: var(--dtl-text-muted);
}

/* ================= Tables ================= */
.dtl-table-card {
    background: #FFFFFF;
    border-radius: 8px;
    border: 1px solid var(--dtl-border);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    margin-bottom: 24px;
}

.dtl-table {
    width: 100%;
    min-width: 650px;
    border-collapse: collapse;
    font-size: 13px;
    text-align: left;
}

.dtl-table thead th {
    background-color: var(--dtl-primary);
    color: #FFFFFF;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 14px;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
}

.dtl-table tbody td {
    padding: 14px;
    border-bottom: 1px solid var(--dtl-border);
    color: var(--dtl-text-main);
    vertical-align: middle;
}

.dtl-table tbody tr:hover {
    background-color: #F8FAFC;
}

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

.dtl-row-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

/* ================= Status Badges ================= */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11.5px;
    font-weight: 600;
    line-height: 1;
}

.badge-success {
    background-color: #DCFCE7;
    color: #15803D;
    border: 1px solid #BBF7D0;
}

.badge-warning {
    background-color: #FEF3C7;
    color: #B45309;
    border: 1px solid #FDE68A;
}

.badge-danger {
    background-color: #FEE2E2;
    color: #B91C1C;
    border: 1px solid #FECACA;
}

.badge-info {
    background-color: #E0F2FE;
    color: #0369A1;
    border: 1px solid #BAE6FD;
}

/* ================= Metric Cards (Capture3) ================= */
.dtl-metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

.dtl-metric-card {
    background: #FFFFFF;
    border: 1px solid var(--dtl-border);
    border-radius: 8px;
    padding: 18px 20px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.dtl-metric-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--dtl-text-muted);
    margin-bottom: 8px;
}

.dtl-metric-val {
    font-size: 26px;
    font-weight: 800;
    color: var(--dtl-primary);
}

/* ================= Tab Navigation (Capture3, 4) ================= */
.dtl-tabs {
    display: flex;
    border-bottom: 2px solid #E2E8F0;
    margin-bottom: 24px;
    background: #FFFFFF;
    border-radius: 8px 8px 0 0;
    padding: 0 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    max-width: 100%;
}

.dtl-tabs::-webkit-scrollbar {
    display: none;
}

.dtl-tab-item {
    padding: 14px 18px;
    color: var(--dtl-text-muted);
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: all 0.15s ease;
    cursor: pointer;
    flex-shrink: 0;
    white-space: nowrap;
}

.dtl-tab-item:hover {
    color: var(--dtl-primary);
}

.dtl-tab-item.active {
    color: var(--dtl-accent);
    border-bottom-color: var(--dtl-accent);
    font-weight: 700;
}

/* ================= Detail Info Grid ================= */
.dtl-detail-card {
    background: #FFFFFF;
    border: 1px solid var(--dtl-border);
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.dtl-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--dtl-border);
}

.dtl-card-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--dtl-primary);
}

.dtl-info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    row-gap: 20px;
    column-gap: 32px;
}

.dtl-info-item {
    display: flex;
    flex-direction: column;
}

.dtl-info-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--dtl-text-muted);
    margin-bottom: 4px;
}

.dtl-info-value {
    font-size: 14px;
    font-weight: 500;
    color: var(--dtl-text-main);
}

.dtl-info-full {
    grid-column: 1 / -1;
}

/* ================= Form Controls ================= */
.form-group {
    margin-bottom: 18px;
}

.form-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--dtl-text-main);
}

.form-control {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #CBD5E1;
    border-radius: 6px;
    font-size: 13.5px;
    color: var(--dtl-text-main);
    background-color: #FFFFFF;
    outline: none;
    transition: border 0.15s ease, box-shadow 0.15s ease;
}

.form-control:focus {
    border-color: var(--dtl-accent);
    box-shadow: 0 0 0 3px rgba(11, 99, 206, 0.15);
}

/* ================= Additional Application Table Wrappers ================= */
.portfolio-card,
.finance-table-wrapper,
.masters-table-wrapper,
.schedule-table-wrap,
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.portfolio-table,
.finance-table,
.masters-table,
.schedule-table {
    min-width: 650px;
}

/* ================= Additional Navigation Bars ================= */
.admin-tabs-nav,
.schedule-subtabs-bar {
    display: flex;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    max-width: 100%;
}

.admin-tabs-nav::-webkit-scrollbar,
.schedule-subtabs-bar::-webkit-scrollbar {
    display: none;
}

.admin-tab-btn,
.schedule-subtab {
    flex-shrink: 0;
    white-space: nowrap;
}

/* ================= Modals & Overlays ================= */
.dtl-modal-overlay {
    box-sizing: border-box;
    padding: 16px;
}

.dtl-modal-card {
    box-sizing: border-box;
    max-width: 100%;
}

/* ================= Modal Internal Form Grids ================= */
.finance-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.finance-breakdown-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 18px;
}

.finance-meta-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 18px;
    font-size: 13px;
    background: #FAFAFA;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    padding: 14px;
}

.finance-payment-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 14px;
}
@media (max-width: 600px) {
    .finance-payment-grid-3 {
        grid-template-columns: 1fr;
    }
}

/* ================= Modern Login Page Styles ================= */
.login-container {
    display: flex;
    min-height: 100vh;
    background: #0B192C;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    position: relative;
    overflow-x: hidden;
}

/* Left Showcase & Branding Panel */
.login-left-banner {
    flex: 1.15;
    position: relative;
    background: 
        radial-gradient(circle at 15% 15%, rgba(14, 165, 233, 0.22) 0%, transparent 40%),
        radial-gradient(circle at 85% 85%, rgba(59, 130, 246, 0.25) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(3, 105, 161, 0.15) 0%, transparent 60%),
        linear-gradient(155deg, #020F1F 0%, #002244 40%, #003A70 85%, #054A8C 100%);
    color: #FFFFFF;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 40px;
    text-align: center;
    overflow: hidden;
    z-index: 1;
}

/* Decorative ambient high-tech grid overlay on left banner */
.login-left-banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 32px 32px;
    pointer-events: none;
    mask-image: radial-gradient(circle at 50% 50%, black 50%, transparent 90%);
    -webkit-mask-image: radial-gradient(circle at 50% 50%, black 50%, transparent 90%);
}

.login-left-content {
    position: relative;
    z-index: 2;
    max-width: 520px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Top Badge Pill */
.login-brand-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.09);
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 6px 14px;
    border-radius: 9999px;
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: #E0F2FE;
    margin-bottom: 22px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.pulse-indicator {
    width: 7px;
    height: 7px;
    background-color: #38BDF8;
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(56, 189, 248, 0.7);
    animation: livePulse 2s infinite cubic-bezier(0.66, 0, 0, 1);
}

@keyframes livePulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(56, 189, 248, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(56, 189, 248, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(56, 189, 248, 0); }
}

/* Logo Pedestal */
.login-logo-card {
    background: rgba(255, 255, 255, 0.96);
    border-radius: 20px;
    padding: 20px 28px;
    box-shadow: 
        0 12px 30px rgba(0, 0, 0, 0.35),
        0 0 0 1px rgba(255, 255, 255, 0.3),
        0 0 40px rgba(11, 99, 206, 0.3);
    margin-bottom: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.login-logo-card:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 
        0 16px 40px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.5),
        0 0 50px rgba(56, 189, 248, 0.4);
}

.login-logo-card img {
    height: 105px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.08));
}

.login-dtl-name {
    font-size: 27px;
    font-weight: 800;
    letter-spacing: -0.4px;
    color: #FFFFFF;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.login-dtl-hindi {
    font-size: 16px;
    color: #BAE6FD;
    margin-top: 4px;
    font-family: 'Noto Sans Devanagari', 'Nirmala UI', 'Mangal', 'Segoe UI', Arial, sans-serif;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.login-system-title-wrap {
    margin-top: 14px;
    margin-bottom: 20px;
}

.login-system-title {
    font-size: 21px;
    font-weight: 700;
    color: #FFFFFF;
    letter-spacing: -0.2px;
}

.login-system-sub {
    display: block;
    font-size: 12.5px;
    color: #94A3B8;
    margin: 4px auto 0 auto;
    font-weight: 400;
    max-width: 340px;
    line-height: 1.4;
    word-break: normal;
    overflow-wrap: break-word;
}

/* GIS Substation Showcase Glass Card */
.login-gis-card {
    position: relative;
    width: 100%;
    max-width: 440px;
    border-radius: 16px;
    overflow: hidden;
    padding: 8px;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 
        0 16px 36px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
    margin-bottom: 20px;
}

.login-gis-card:hover {
    transform: translateY(-3px);
    box-shadow: 
        0 22px 45px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.login-gis-badge {
    position: absolute;
    top: 18px;
    left: 18px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: rgba(15, 23, 42, 0.78);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 9999px;
    padding: 4px 11px;
    font-size: 11px;
    font-weight: 600;
    color: #F8FAFC;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background-color: #10B981;
    box-shadow: 0 0 6px #10B981;
}

.login-gis-image {
    width: 100%;
    height: 190px;
    border-radius: 10px;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.login-gis-card:hover .login-gis-image {
    transform: scale(1.02);
}

.login-gis-caption {
    font-size: 11px;
    color: #CBD5E1;
    margin-top: 8px;
    letter-spacing: 0.2px;
}

/* Feature Highlights Bar */
.login-feature-strip {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    width: 100%;
    max-width: 440px;
    margin-bottom: 22px;
}

.login-feature-item {
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 10px;
    padding: 9px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    transition: all 0.2s ease;
}

.login-feature-item:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.feature-icon-svg {
    width: 18px;
    height: 18px;
    color: #38BDF8;
}

.login-feature-item strong {
    font-size: 11.5px;
    font-weight: 700;
    color: #FFFFFF;
}

.login-feature-item span {
    font-size: 10px;
    color: #94A3B8;
}

/* Left Footer */
.login-footer-poc {
    font-size: 11.5px;
    color: #94A3B8;
    line-height: 1.5;
}

.login-footer-sub {
    font-size: 10.5px;
    color: rgba(148, 163, 184, 0.7);
    margin-top: 2px;
}

/* ================= Right Form Panel ================= */
.login-right-form {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 24px;
    background-color: #F8FAFC;
    background-image: 
        radial-gradient(at 10% 10%, rgba(11, 99, 206, 0.05) 0px, transparent 50%),
        radial-gradient(at 90% 90%, rgba(0, 58, 112, 0.06) 0px, transparent 50%),
        radial-gradient(#CBD5E1 1px, transparent 1px);
    background-size: 100% 100%, 100% 100%, 20px 20px;
    min-height: 100vh;
    position: relative;
    z-index: 2;
}

.login-box {
    width: 100%;
    max-width: 450px;
    background: #FFFFFF;
    border-radius: 20px;
    border: 1px solid #E2E8F0;
    box-shadow: 
        0 1px 3px rgba(15, 23, 42, 0.04),
        0 12px 30px -5px rgba(0, 58, 112, 0.1),
        0 25px 45px -12px rgba(15, 23, 42, 0.06);
    padding: 30px 28px 22px 28px;
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    margin: 0 auto;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.login-box:hover {
    box-shadow: 
        0 2px 5px rgba(15, 23, 42, 0.05),
        0 18px 40px -5px rgba(0, 58, 112, 0.14),
        0 30px 50px -10px rgba(15, 23, 42, 0.08);
}

/* Gradient accent bar on top edge */
.login-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #003A70 0%, #0B63CE 50%, #38BDF8 100%);
}

.login-panel-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 11.5px;
    font-weight: 600;
    color: #0B63CE;
    background: #EFF6FF;
    border: 1px solid #BFDBFE;
    border-radius: 9999px;
    padding: 4px 11px;
    margin-bottom: 12px;
}

.status-dot-green {
    width: 6.5px;
    height: 6.5px;
    background: #10B981;
    border-radius: 50%;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
}

.login-box h2,
.login-heading {
    font-size: 25px;
    font-weight: 800;
    color: #003A70;
    letter-spacing: -0.4px;
    margin: 0;
}

.login-panel-sub,
.login-subtext {
    font-size: 13.5px;
    color: #64748B;
    margin-top: 5px;
    margin-bottom: 18px;
}

/* Tabs: Password vs Mobile OTP */
.login-auth-tabs {
    display: flex;
    background: #F1F5F9;
    padding: 4px;
    border-radius: 12px;
    border: 1px solid #E2E8F0;
    margin-bottom: 20px;
    gap: 4px;
    width: 100%;
    box-sizing: border-box;
}

.login-tab-btn {
    flex: 1 1 0;
    min-width: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 10px;
    font-size: 13px;
    font-weight: 600;
    color: #64748B;
    background: transparent;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    white-space: nowrap;
}

.login-tab-btn:hover {
    color: #0F172A;
}

.login-tab-btn.active {
    background: #FFFFFF;
    color: #003A70;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08), 0 1px 2px rgba(15, 23, 42, 0.04);
    font-weight: 700;
}

/* Modern Input Groups with Left Icons */
.login-box .form-group {
    margin-bottom: 16px;
    width: 100%;
}

.login-box .form-label {
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 6px;
    display: block;
}

.input-icon-wrapper {
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

.input-field-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 17px;
    height: 17px;
    color: #94A3B8;
    pointer-events: none;
    transition: color 0.15s ease;
}

.login-box .form-control {
    border: 1.5px solid #CBD5E1;
    border-radius: 9px;
    height: 44px;
    padding: 0 14px 0 42px;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.18s ease;
    background: #F8FAFC;
    color: #0F172A;
    width: 100%;
    box-sizing: border-box;
}

.login-box .form-control:focus {
    background: #FFFFFF;
    border-color: #0B63CE;
    box-shadow: 0 0 0 3.5px rgba(11, 99, 206, 0.14);
    outline: none;
}

.input-icon-wrapper:focus-within .input-field-icon {
    color: #0B63CE;
}

/* Password Toggle Button */
.btn-toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: #94A3B8;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s ease, background-color 0.15s ease;
}

.btn-toggle-password:hover {
    color: #334155;
    background-color: #E2E8F0;
}

.btn-toggle-password svg {
    width: 18px;
    height: 18px;
}

/* Security CAPTCHA Card */
.captcha-container {
    background: #F8FAFC;
    border: 1.5px solid #E2E8F0;
    border-radius: 12px;
    padding: 12px 14px;
    margin-top: 14px;
    margin-bottom: 18px;
    width: 100%;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
}

.captcha-container:focus-within {
    border-color: #CBD5E1;
    background: #FFFFFF;
}

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

.captcha-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
    font-weight: 600;
    color: #334155;
}

.captcha-badge {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: #0B63CE;
    background: #EFF6FF;
    border: 1px solid #BFDBFE;
    padding: 2px 7px;
    border-radius: 4px;
}

.captcha-row {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    box-sizing: border-box;
}

.captcha-image-wrapper {
    background: #FFFFFF;
    border: 1px solid #CBD5E1;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    flex: 0 0 120px;
    max-width: 130px;
    min-width: 0;
    box-sizing: border-box;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.05);
}

.captcha-img {
    height: 100%;
    width: 100%;
    object-fit: contain;
    display: block;
}

.btn-captcha-refresh {
    background: #FFFFFF;
    border: 1.5px solid #CBD5E1;
    border-radius: 8px;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    box-sizing: border-box;
}

.btn-captcha-refresh:hover {
    background: #EFF6FF;
    border-color: #0B63CE;
    color: #0B63CE;
    transform: rotate(45deg);
}

.btn-captcha-refresh.rotating svg {
    animation: spinRotate 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes spinRotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.captcha-input-wrapper {
    flex: 1 1 60px;
    min-width: 0;
    box-sizing: border-box;
}

.login-box .captcha-input-wrapper .captcha-input {
    height: 42px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 3px;
    text-align: center;
    text-transform: uppercase;
    padding: 0 6px !important;
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
}

.captcha-hint {
    display: block;
    font-size: 11px;
    color: #64748B;
    margin-top: 7px;
}

/* Primary Action Buttons */
.btn-primary,
.login-box .btn-primary {
    background: linear-gradient(135deg, #0B63CE 0%, #003A70 100%);
    border: none;
    border-radius: 10px;
    font-size: 14.5px;
    font-weight: 700;
    color: #FFFFFF;
    letter-spacing: 0.3px;
    box-shadow: 0 4px 14px rgba(11, 99, 206, 0.32);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 46px;
    width: 100%;
}

.login-box .btn-primary:hover {
    transform: translateY(-1.5px);
    box-shadow: 0 8px 22px rgba(11, 99, 206, 0.4);
    background: linear-gradient(135deg, #0e70e3 0%, #002e5b 100%);
}

.login-box .btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(11, 99, 206, 0.2);
}

/* Error and Success Alerts */
.login-error-alert {
    background-color: #FEF2F2;
    border: 1px solid #FECACA;
    color: #991B1B;
    border-radius: 10px;
    padding: 11px 14px;
    font-size: 13px;
    margin-bottom: 16px;
    line-height: 1.45;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: alertShake 0.4s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes alertShake {
    10%, 90% { transform: translate3d(-1px, 0, 0); }
    20%, 80% { transform: translate3d(2px, 0, 0); }
    30%, 50%, 70% { transform: translate3d(-3px, 0, 0); }
    40%, 60% { transform: translate3d(3px, 0, 0); }
}

.login-success-alert {
    background-color: #ECFDF5;
    border: 1px solid #A7F3D0;
    color: #065F46;
    border-radius: 10px;
    padding: 11px 14px;
    font-size: 13px;
    margin-bottom: 16px;
    line-height: 1.45;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Mobile OTP Elements */
.mobile-input-group {
    display: flex;
    align-items: stretch;
    width: 100%;
}

.mobile-prefix {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #F1F5F9;
    border: 1.5px solid #CBD5E1;
    border-right: none;
    border-radius: 9px 0 0 9px;
    padding: 0 14px;
    font-size: 13.5px;
    font-weight: 700;
    color: #334155;
    letter-spacing: 0.5px;
}

.mobile-input-group .form-control {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    padding-left: 14px;
}

.otp-verification-card {
    background: #F8FAFC;
    border: 1.5px solid #E2E8F0;
    border-radius: 12px;
    padding: 18px;
    text-align: center;
}

.otp-sent-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: #475569;
}

.otp-change-link, .otp-resend-link {
    color: #0B63CE;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    font-size: 12.5px;
    transition: color 0.15s ease;
}

.otp-change-link:hover, .otp-resend-link:hover {
    color: #003A70;
    text-decoration: underline;
}

.otp-input-field {
    text-align: center;
    font-size: 26px;
    font-weight: 800;
    letter-spacing: 12px;
    color: #003A70;
    height: 50px;
    border: 2px solid #CBD5E1 !important;
    border-radius: 10px !important;
    padding-left: 20px !important;
}

.otp-input-field:focus {
    border-color: #0B63CE !important;
    box-shadow: 0 0 0 4px rgba(11, 99, 206, 0.16) !important;
}

/* Card Footer Trust Notice */
.login-card-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-size: 11.5px;
    color: #94A3B8;
    margin-top: 18px;
    padding-top: 12px;
    border-top: 1px solid #F1F5F9;
}

.login-card-footer svg {
    color: #0B63CE;
    flex-shrink: 0;
}

/* ================= Responsive Layout (Fluid & Adaptive) ================= */
.login-mobile-footer {
    display: none;
    font-size: 11px;
    color: #94A3B8;
    text-align: center;
    margin-top: 14px;
    line-height: 1.4;
}

/* Laptops & Standard Desktops (1025px - 1280px) */
@media (max-width: 1280px) and (min-width: 1025px) {
    .login-left-banner {
        padding: 36px 28px;
    }
    .login-gis-card {
        max-width: 380px;
    }
    .login-gis-image {
        height: 160px;
    }
    .login-box {
        max-width: 420px;
        padding: 28px 28px 22px 28px;
    }
}

/* Tablets Landscape (851px - 1024px) */
@media (max-width: 1024px) and (min-width: 851px) {
    .login-container {
        flex-direction: row;
        min-height: 100vh;
    }
    .login-left-banner {
        flex: 1;
        padding: 24px 18px;
    }
    .login-brand-tag {
        font-size: 10.5px;
        padding: 4px 10px;
        margin-bottom: 12px;
    }
    .login-logo-card {
        padding: 10px 18px;
        margin-bottom: 10px;
        border-radius: 14px;
    }
    .login-logo-card img {
        height: 70px;
    }
    .login-dtl-name {
        font-size: 21px;
    }
    .login-dtl-hindi {
        font-size: 14px;
    }
    .login-system-title-wrap {
        margin-top: 8px;
        margin-bottom: 12px;
    }
    .login-system-title {
        font-size: 17px;
    }
    .login-system-sub {
        font-size: 11px;
    }
    .login-gis-card {
        max-width: 320px;
        margin-bottom: 12px;
        padding: 6px;
    }
    .login-gis-image {
        height: 125px;
    }
    .login-feature-strip {
        max-width: 320px;
        gap: 6px;
        margin-bottom: 12px;
    }
    .login-feature-item {
        padding: 6px 4px;
    }
    .login-feature-item strong {
        font-size: 10.5px;
    }
    .login-feature-item span {
        font-size: 9px;
    }
    .login-footer-poc {
        font-size: 10.5px;
        margin-top: 10px;
    }
    .login-right-form {
        flex: 1.1;
        padding: 20px 16px;
    }
    .login-box {
        max-width: 400px;
        padding: 24px 22px 18px 22px;
    }
}

/* Tablets Portrait & Mobile (< 850px) - Bring Sign-in Above the Fold */
@media (max-width: 850px) {
    .login-container {
        flex-direction: column;
        background: #020F1F;
        min-height: 100vh;
    }

    .login-left-banner {
        flex: none;
        width: 100%;
        padding: 26px 20px 16px 20px;
        background: linear-gradient(180deg, #020F1F 0%, #002244 80%, #003A70 100%);
    }

    /* Hide heavy graphics and secondary showcase cards to bring sign-in above the fold */
    .login-brand-tag,
    .login-gis-card,
    .login-feature-strip,
    .login-left-banner .login-footer-poc {
        display: none !important;
    }

    .login-left-content {
        max-width: 460px;
    }

    .login-logo-card {
        padding: 10px 18px;
        border-radius: 14px;
        margin-bottom: 10px;
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    }

    .login-logo-card img {
        height: 56px;
    }

    .login-dtl-name {
        font-size: 21px;
        letter-spacing: -0.3px;
    }

    .login-dtl-hindi {
        font-size: 14px;
        margin-top: 2px;
    }

    .login-system-title-wrap {
        margin-top: 6px;
        margin-bottom: 0;
    }

    .login-system-title {
        font-size: 16.5px;
        font-weight: 700;
        color: #E2E8F0;
    }

    .login-system-sub {
        font-size: 11.5px;
        color: #94A3B8;
        margin-top: 2px;
    }

    /* Form Container */
    .login-right-form {
        flex: 1;
        width: 100%;
        padding: 14px 16px 36px 16px;
        min-height: auto;
        background: transparent;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
    }

    .login-box {
        width: 100%;
        max-width: 460px;
        padding: 26px 24px 20px 24px;
        border-radius: 18px;
        background: #FFFFFF;
        box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
    }

    .login-mobile-footer {
        display: block;
    }
}

/* Smartphone Screens (<= 480px) */
@media (max-width: 480px) {
    .login-left-banner {
        padding: 20px 14px 12px 14px;
    }

    .login-logo-card {
        padding: 8px 14px;
        margin-bottom: 8px;
        border-radius: 12px;
    }

    .login-logo-card img {
        height: 48px;
    }

    .login-dtl-name {
        font-size: 19px;
    }

    .login-dtl-hindi {
        font-size: 13px;
    }

    .login-system-title {
        font-size: 15px;
    }

    .login-system-sub {
        display: none;
    }

    .login-right-form {
        padding: 8px 12px 28px 12px;
    }

    .login-box {
        padding: 20px 16px 16px 16px;
        border-radius: 16px;
    }

    .login-panel-badge {
        font-size: 11px;
        padding: 3px 9px;
        margin-bottom: 8px;
    }

    .login-heading {
        font-size: 21px;
    }

    .login-subtext {
        font-size: 12px;
        margin-top: 3px;
        margin-bottom: 12px;
    }

    .login-auth-tabs {
        margin-bottom: 14px;
        padding: 3px;
        gap: 3px;
        width: 100%;
        box-sizing: border-box;
    }

    .login-tab-btn {
        flex: 1 1 0;
        min-width: 0;
        padding: 7px 6px;
        font-size: 12px;
        gap: 5px;
        white-space: nowrap;
        box-sizing: border-box;
    }

    .login-tab-btn svg {
        flex-shrink: 0;
        width: 14px;
        height: 14px;
    }

    .login-box .form-group {
        margin-bottom: 12px;
        width: 100%;
    }

    .login-box .form-label {
        font-size: 12px;
        margin-bottom: 4px;
    }

    .login-box .form-control {
        height: 42px;
        font-size: 13.5px;
        padding: 0 12px 0 38px;
        width: 100%;
        box-sizing: border-box;
    }

    .input-field-icon {
        left: 12px;
        width: 15px;
        height: 15px;
    }

    .btn-toggle-password {
        right: 8px;
    }

    .captcha-container {
        padding: 10px 10px;
        margin-top: 10px;
        margin-bottom: 14px;
        width: 100%;
        box-sizing: border-box;
    }

    .captcha-header {
        margin-bottom: 8px;
    }

    .captcha-row {
        display: flex;
        align-items: center;
        gap: 6px;
        width: 100%;
        box-sizing: border-box;
    }

    .captcha-image-wrapper {
        flex: 0 0 100px;
        width: 100px;
        max-width: 100px;
        height: 38px;
        overflow: hidden;
        box-sizing: border-box;
    }

    .captcha-img {
        width: 100%;
        height: 100%;
        max-width: 100%;
        object-fit: cover;
        display: block;
    }

    .btn-captcha-refresh {
        flex: 0 0 38px;
        width: 38px;
        height: 38px;
        box-sizing: border-box;
    }

    .captcha-input-wrapper {
        flex: 1 1 0;
        min-width: 0;
        box-sizing: border-box;
    }

    .captcha-input-wrapper .captcha-input {
        height: 38px;
        font-size: 14px;
        letter-spacing: 2px;
        width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .btn-primary,
    .login-box .btn-primary {
        height: 44px;
        font-size: 14px;
    }
}

/* Extra small devices (<= 360px - e.g. Galaxy Fold, small screens) */
@media (max-width: 360px) {
    .login-box {
        padding: 16px 12px 14px 12px;
    }

    .captcha-row {
        flex-wrap: wrap;
    }

    .captcha-input-wrapper {
        width: 100%;
    }
}

/* ================= Modal Dialogs (User Creation & Password Change) ================= */
.dtl-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: dtlFadeIn 0.2s ease-out;
}

.dtl-modal-card {
    background: #FFFFFF;
    border-radius: 14px;
    width: 100%;
    max-width: 600px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: dtlSlideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.dtl-modal-header {
    padding: 18px 24px;
    background: #F8FAFC;
    border-bottom: 1px solid var(--dtl-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.dtl-modal-title {
    font-size: 17px;
    font-weight: 700;
    color: var(--dtl-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dtl-modal-close {
    background: transparent;
    border: none;
    font-size: 20px;
    color: #94A3B8;
    cursor: pointer;
    line-height: 1;
    padding: 4px;
    border-radius: 6px;
    transition: all 0.15s ease;
}

.dtl-modal-close:hover {
    color: #0F172A;
    background: #E2E8F0;
}

.dtl-modal-body {
    padding: 24px;
    max-height: 75vh;
    overflow-y: auto;
}

.dtl-modal-footer {
    padding: 16px 24px;
    background: #F8FAFC;
    border-top: 1px solid var(--dtl-border);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.btn-group-sm {
    display: inline-flex;
    gap: 6px;
    align-items: center;
}

@keyframes dtlFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes dtlSlideUp {
    from { opacity: 0; transform: translateY(16px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ================= Login Page Captcha Component ================= */
.captcha-container {
    margin-top: 18px;
    background: #F8FAFC;
    border: 1px solid var(--dtl-border);
    border-radius: 10px;
    padding: 13px 15px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.captcha-container:hover {
    border-color: #CBD5E1;
}

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

.captcha-label {
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: default;
}

.captcha-label svg {
    color: var(--dtl-primary);
}

.captcha-badge {
    font-size: 10.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 2px 7px;
    border-radius: 4px;
    background: #EFF6FF;
    color: var(--dtl-accent);
    border: 1px solid #BFDBFE;
}

.captcha-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.captcha-image-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #FFFFFF;
    border: 1.5px solid #CBD5E1;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.04);
}

.captcha-img {
    display: block;
    width: 150px;
    height: 42px;
    object-fit: cover;
    user-select: none;
    -webkit-user-select: none;
    pointer-events: none;
}

.btn-captcha-refresh {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    background: #FFFFFF;
    border: 1.5px solid #CBD5E1;
    border-radius: 8px;
    color: var(--dtl-primary);
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.btn-captcha-refresh:hover {
    background: #F1F5F9;
    border-color: var(--dtl-accent);
    color: var(--dtl-accent);
    transform: rotate(35deg);
}

.btn-captcha-refresh:active {
    transform: rotate(180deg) scale(0.95);
}

.captcha-input-wrapper {
    flex: 1;
    min-width: 0;
}

.captcha-input {
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 16px !important;
    font-weight: 700 !important;
    letter-spacing: 3px !important;
    text-transform: uppercase !important;
    text-align: center !important;
    height: 42px !important;
    background: #FFFFFF !important;
    border: 1.5px solid #CBD5E1 !important;
    border-radius: 8px !important;
    color: #0F172A !important;
    transition: all 0.15s ease-in-out;
}

.captcha-input::placeholder {
    font-family: 'Inter', -apple-system, sans-serif;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0;
    text-transform: none;
    color: #94A3B8;
}

.captcha-input:focus {
    border-color: var(--dtl-accent) !important;
    box-shadow: 0 0 0 3px rgba(11, 99, 206, 0.15) !important;
    outline: none !important;
}

.captcha-hint {
    display: block;
    margin-top: 6px;
    font-size: 11.5px;
    color: #64748B;
    line-height: 1.4;
}

@media (max-width: 440px) {
    .captcha-row {
        flex-wrap: wrap;
    }
    .captcha-input-wrapper {
        width: 100%;
        flex: 1 1 100%;
        margin-top: 6px;
    }
}

/* ==========================================================================
   GLOBAL RESPONSIVE WEB DESIGN (RWD) - SINGLE ADAPTIVE LAYOUT
   Automatically reflows structure, sizing, and navigation across all screens
   ========================================================================== */

/* --- Desktop & Laptop (1025px to 1280px) --- */
@media (max-width: 1280px) and (min-width: 1025px) {
    :root {
        --sidebar-width: 240px;
    }
    .dtl-main {
        padding: 28px 32px;
    }
    .dtl-search-wrap {
        width: 240px;
    }
    .dtl-metrics-grid {
        gap: 16px;
    }
    .dtl-info-grid {
        column-gap: 20px;
    }
}

/* --- Tablets (Landscape & Portrait: 769px to 1024px) --- */
@media (max-width: 1024px) {
    /* Prevent body background scrolling when drawer open */
    body.sidebar-open {
        overflow: hidden;
    }

    /* Top Header Adjustments */
    .dtl-header {
        padding: 0 16px;
    }

    /* Hamburger Toggle Button Appears */
    .dtl-hamburger-btn {
        display: flex;
    }

    .dtl-search-wrap {
        width: 200px;
    }

    .dtl-title-main {
        font-size: 14px;
    }

    .dtl-user-role {
        display: none;
    }

    /* Sidebar Transforms to Off-Canvas Slide Drawer */
    .dtl-sidebar-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(2, 15, 31, 0.65);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
        z-index: 1050;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.28s ease;
    }

    body.sidebar-open .dtl-sidebar-backdrop {
        opacity: 1;
        pointer-events: auto;
    }

    .dtl-sidebar {
        top: 0;
        bottom: 0;
        left: 0;
        width: 280px;
        max-width: 85vw;
        z-index: 1100;
        transform: translateX(-100%);
        transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.28s ease;
        box-shadow: none;
    }

    body.sidebar-open .dtl-sidebar,
    .dtl-sidebar.active {
        transform: translateX(0);
        box-shadow: 4px 0 28px rgba(0, 0, 0, 0.45);
    }

    .dtl-sidebar-mobile-header {
        display: flex;
    }

    /* Main Content Expands to Full Screen Width */
    .dtl-main {
        margin-left: 0 !important;
        margin-top: var(--header-height);
        padding: 24px 20px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    /* Responsive Grids */
    .dtl-metrics-grid,
    .kpi-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 14px;
    }

    .dtl-info-grid,
    .form-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 16px;
    }

    .charts-row,
    .doc-main-grid,
    .sch-main-grid {
        grid-template-columns: 1fr !important;
    }

    .dtl-page-header {
        flex-wrap: wrap;
        gap: 14px;
    }

    .dtl-filter-bar {
        flex-wrap: wrap;
        gap: 12px;
    }
}

/* --- Mobile Phones & Phablets (<= 768px) --- */
@media (max-width: 768px) {
    /* Header on Mobile */
    .dtl-header {
        height: 56px;
        padding: 0 12px;
    }

    .dtl-brand {
        gap: 8px;
    }

    .dtl-logo-badge {
        padding: 2px 6px;
    }

    .dtl-logo-badge img {
        height: 28px;
    }

    .dtl-title-main {
        font-size: 13px;
        max-width: 175px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .dtl-title-sub,
    .dtl-preview-tag {
        display: none !important;
    }

    .dtl-search-wrap {
        display: none;
    }

    .dtl-user-name {
        display: none;
    }

    .dtl-user-profile {
        padding-left: 6px;
        border-left: none;
    }

    .dtl-header-actions {
        gap: 8px;
        margin-left: auto;
    }

    /* Responsive Notifications Dropdown on Mobile */
    .dtl-notif-dropdown {
        position: fixed !important;
        top: 58px !important;
        left: 10px !important;
        right: 10px !important;
        width: auto !important;
        max-width: calc(100vw - 20px) !important;
        box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
    }

    /* Main Area on Mobile */
    .dtl-main {
        margin-left: 0 !important;
        margin-top: 56px !important;
        padding: 16px 12px !important;
        width: 100% !important;
        overflow-x: hidden;
    }

    /* Page Titles and Action Headers Reflow Vertically */
    .dtl-page-header,
    .eng-header-row,
    .sch-header-row {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 12px !important;
        margin-bottom: 18px !important;
    }

    .dtl-page-title-group h1,
    .eng-title-group h1,
    .sch-title-group h1,
    .dashboard-welcome {
        font-size: 22px !important;
        line-height: 1.25 !important;
    }

    .dtl-header-btn-group {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        gap: 8px !important;
    }

    .dtl-header-btn-group .btn,
    .dtl-header-btn-group a.btn {
        width: 100% !important;
        justify-content: center !important;
        min-height: 40px !important;
    }

    .dtl-project-meta-strip,
    .sch-status-strip,
    .doc-status-strip {
        flex-wrap: wrap !important;
        gap: 6px !important;
        font-size: 12px !important;
    }

    /* Filter & Search Toolbars Stack on Mobile */
    .dtl-filter-bar,
    .eng-filter-bar,
    .sch-filter-bar,
    .search-filter-panel {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 10px !important;
        width: 100% !important;
        padding: 12px !important;
        box-sizing: border-box;
    }

    .dtl-search-box,
    .eng-search-wrap,
    .search-filter-panel > div:first-child {
        width: 100% !important;
        box-sizing: border-box;
    }

    .dtl-filter-options {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 10px !important;
        width: 100% !important;
    }

    .dtl-filter-options select,
    .eng-status-select,
    #ddlStatusFilter {
        width: 100% !important;
        min-height: 38px;
    }

    #lblFinanceRecordsCount,
    .eng-filter-bar span:last-child {
        margin-left: 0 !important;
        align-self: flex-start;
    }

    /* Detail Grids and Forms reflow to 1 Column */
    .dtl-info-grid,
    .form-grid,
    .doc-details-grid,
    .sch-details-grid {
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .dtl-detail-card,
    .mywork-card,
    .sch-card,
    .doc-card {
        padding: 16px 14px !important;
    }

    .dtl-card-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 10px !important;
    }

    .dtl-card-header .btn {
        width: 100% !important;
        justify-content: center !important;
    }

    /* Schedules Add Form on Mobile */
    .schedule-add-form {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .schedule-form-group.name-group,
    .schedule-form-group.date-group,
    .schedule-form-group.status-group {
        width: 100% !important;
        min-width: 100% !important;
    }

    .schedule-add-btn {
        width: 100% !important;
    }

    .activity-row {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 8px !important;
    }

    /* Modals on Mobile */
    .dtl-modal-overlay {
        padding: 10px !important;
    }

    .dtl-modal-card {
        width: 100% !important;
        max-width: calc(100vw - 20px) !important;
        margin: 0 auto !important;
        max-height: 92vh !important;
    }

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

    .finance-breakdown-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .finance-meta-grid {
        grid-template-columns: 1fr !important;
    }
}

/* --- Ultra-Small Mobile Phones (<= 480px) --- */
@media (max-width: 480px) {
    .dtl-main {
        padding: 12px 10px !important;
    }

    .dtl-title-main {
        max-width: 130px !important;
        font-size: 12.5px !important;
    }

    .dtl-metrics-grid,
    .kpi-grid {
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }

    .finance-breakdown-grid {
        grid-template-columns: 1fr !important;
    }

    .btn {
        padding: 8px 14px;
        font-size: 13px;
    }

    .dtl-tabs .dtl-tab-item {
        padding: 10px 12px;
        font-size: 12.5px;
    }
}




