:root {
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-darker: #1e40af;
    --secondary-color: #7c3aed;
    --secondary-dark: #5b21b6;
    --success-color: #10b981;
    --success-dark: #059669;
    --warning-color: #f59e0b;
    --warning-dark: #d97706;
    --error-color: #ef4444;
    --error-dark: #dc2626;
    --purple-color: #8b5cf6;
    --purple-dark: #7c3aed;
    --blue-color: #3b82f6;
    --blue-dark: #2563eb;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    --white: #ffffff;

    /* Body gradient colors */
    --gradient-start: #2563eb;
    --gradient-end: #1e40af;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);
    min-height: 100vh;
    color: var(--gray-900);
    line-height: 1.5;
}

/* Screen Management */
.screen {
    display: none;
}

.screen.active {
    display: block;
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Cards */
.card {
    background: var(--white);
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    margin-bottom: 24px;
    border: 1px solid var(--gray-200);
    min-width: 0;
}

/* Login & Signup */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-card {
    background: var(--white);
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    width: 100%;
    max-width: 400px;
}

.login-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
    text-align: center;
}

.login-subtitle {
    color: var(--gray-500);
    text-align: center;
    margin-bottom: 32px;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--gray-700);
    font-size: 14px;
}

.form-control {
    width: 90%;
    padding: 12px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.2s ease;
    background: var(--white);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    min-height: 48px;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);
    color: var(--white);
    border: none;
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #1e3a8a 100%);
    transform: translateY(-1px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
}

.btn-secondary {
    background: var(--gray-500);
    color: var(--white);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--gray-600);
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, var(--success-color) 0%, var(--success-dark) 100%);
    color: var(--white);
}

.btn-success:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--success-dark) 0%, #047857 100%);
    transform: translateY(-1px);
}

.btn-full-width {
    width: 100%;
}

/* Header */
.header {
    background: var(--white);
    border-radius: 16px;
    padding: 20px 32px;
    margin-bottom: 24px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--gray-900);
}

.header-user {
    display: flex;
    align-items: center;
    gap: 16px;
}

.user-welcome {
    font-weight: 600;
    color: var(--gray-700);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--white);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border-left: 4px solid var(--primary-color);
    transition: transform 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
}

.stat-card-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.stat-card-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 4px;
    line-height: 1.2;
}

.stat-card-value.success {
    color: var(--success-color);
}

.stat-card-value.warning {
    color: var(--warning-color);
}

.stat-card-value.error {
    color: var(--error-color);
}

.stat-card-timing {
    font-size: 14px;
    color: var(--gray-500);
}

/* Premium Status Card (Neo-Glass) */
/* Premium Status Card (Clean Theme Correction) */
.stat-card.premium-glass {
    position: relative;
    overflow: hidden;
    background: #ffffff;
    /* Remove glass effect to match other cards */
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: none;
    /* Other cards rely on shadow, or if they have border, match it */
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    cursor: pointer;
    padding: 24px;
    border-radius: 16px;
}

.stat-card.premium-glass:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.card-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.05) 0%, rgba(255, 255, 255, 0) 60%);
    opacity: 0;
    transition: opacity 0.5s ease;
    transform: rotate(30deg);
    pointer-events: none;
}

.stat-card.premium-glass:hover .card-glow {
    opacity: 1;
}

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

.status-title {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--gray-500);
}

.status-action-icon {
    font-size: 18px;
    color: var(--primary-color);
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s ease;
}

.stat-card.premium-glass:hover .status-action-icon {
    opacity: 1;
    transform: translateX(0);
}

.status-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
}

.status-metric {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
}

.progress-ring-container {
    position: relative;
    width: 80px;
    height: 80px;
    margin-bottom: 12px;
}

.progress-ring {
    transform: rotate(-90deg);
    transform-origin: 50% 50%;
}

.progress-ring-bg {
    transition: stroke-dashoffset 0.35s;
    transform-origin: 50% 50%;
}

.progress-ring-fill {
    stroke-dasharray: 201;
    /* 2 * PI * r (32) ≈ 201 */
    stroke-dashoffset: 201;
    /* Start empty */
    transition: stroke-dashoffset 1.5s cubic-bezier(0.22, 1, 0.36, 1);
    stroke-linecap: round;
}

.metric-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
}

.metric-details {
    text-align: center;
}

.metric-value {
    display: block;
    font-size: 20px;
    font-weight: 800;
    color: var(--gray-900);
    line-height: 1.2;
}

.metric-label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--gray-500);
    letter-spacing: 0.05em;
}

.vertical-divider {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, transparent, var(--gray-300), transparent);
}

.status-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--gray-500);
    font-weight: 700;
    margin-bottom: 2px;
}

.status-count {
    font-size: 24px;
    font-weight: 800;
    color: var(--gray-900);
    line-height: 1.2;
}

.status-divider {
    width: 1px;
    height: 32px;
    background-color: var(--gray-300);
    margin: 0 8px;
}

.stat-card.status-card .stat-card-timing {
    text-align: center;
    font-size: 12px;
    color: var(--gray-600);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 8px;
    /* Added spacing */
}

/* Actions Grid */
.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.action-card {
    background: var(--white);
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border: 2px solid var(--gray-200);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.action-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.action-card-icon {
    font-size: 48px;
    margin-bottom: 16px;
    display: block;
}

.action-card-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.action-card-description {
    color: var(--gray-500);
    font-size: 14px;
    line-height: 1.5;
}

.action-card.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: var(--gray-200);
    background: var(--gray-50);
    transform: none;
}

.action-card.disabled:hover {
    transform: none;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border-color: var(--gray-200);
}

/* Office Selection */
.office-selection {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 24px 0;
}

.office-card {
    background: var(--white);
    border: 2px solid var(--gray-200);
    border-radius: 16px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    position: relative;
}

.office-card:hover,
.office-card.selected {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #dbeafe 0%, #eff6ff 100%);
    transform: translateY(-2px);
}

.office-card.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.office-card h3 {
    color: var(--gray-900);
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
}

.office-card p {
    color: var(--gray-600);
    font-size: 14px;
    margin-bottom: 16px;
}

/* Location Status */
.location-status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.location-status.checking {
    background: var(--gray-100);
    color: #6b7280;
}

.location-status.in-range {
    background: #dcfce7;
    color: #166534;
}

.location-status.out-of-range {
    background: #fef3c7;
    color: #92400e;
}

.location-status.error {
    background: #fed7d7;
    color: #742a2a;
}

/* Camera */
.camera-container {
    position: relative;
    width: 100%;
    max-width: 400px;
    margin: 20px auto;
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    aspect-ratio: 4/3;
}

.camera-container video,
.camera-container img,
.camera-container #overlayCanvas {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.camera-container.mirrored video,
.camera-container.mirrored img,
.camera-container.mirrored #overlayCanvas {
    transform: scaleX(-1);
}

.camera-controls {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 20px;
    flex-wrap: wrap;
}

/* Admin Layout */
.admin-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

/* Tables */
.table-wrap {
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 12px;
    margin: 16px 0;
}

.records-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    min-width: 860px;
}

.records-table th,
.records-table td {
    padding: 16px;
    text-align: left;
    border-bottom: 1px solid var(--gray-200);
    vertical-align: top;
}

.records-table th {
    background: var(--gray-50);
    font-weight: 600;
    color: var(--gray-700);
    font-size: 14px;
    white-space: nowrap;
}

.records-table tr:hover {
    background: var(--gray-50);
}

/* Status Badges */
.status-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    display: inline-block;
    min-width: 80px;
    text-align: center;
}

.status-present {
    background: linear-gradient(135deg, var(--success-color) 0%, var(--success-dark) 100%);
    color: white;
}

.status-wfh {
    background: linear-gradient(135deg, var(--purple-color) 0%, var(--purple-dark) 100%);
    color: white;
}

.status-half_day {
    background: linear-gradient(135deg, var(--warning-color) 0%, var(--warning-dark) 100%);
    color: white;
}

.status-client {
    background: linear-gradient(135deg, var(--blue-color) 0%, var(--blue-dark) 100%);
    color: white;
}

.status-absent {
    background: linear-gradient(135deg, var(--error-color) 0%, var(--error-dark) 100%);
    color: white;
}

/* Notification */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    border-radius: 8px;
    color: var(--white);
    font-weight: 600;
    z-index: 10000;
    display: none;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
    display: block;
}

.notification.success {
    background: var(--success-color);
}

.notification.error {
    background: var(--error-color);
}

.notification.warning {
    background: var(--warning-color);
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.text-center {
    text-align: center;
}

/* Modals */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: 16px;
    padding: 32px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.calendar-modal-content {
    max-width: 900px;
}

/* Loading Spinner */
.loading-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Password Field */
.password-wrapper {
    position: relative;
}

.password-wrapper .form-control {
    padding-right: 44px;
}

.toggle-password-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 14px;
    color: var(--gray-500);
}

/* Document Rows */
.doc-row {
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    padding: 12px 16px;
    margin-bottom: 12px;
    background: #fafafa;
}

.doc-row .form-row {
    margin-top: 8px;
}

.text-muted {
    color: var(--gray-500);
}

/* ==================== ATTENDANCE RECORDS VIEW ==================== */

/* Common container for date / month groups */
.records-by-date,
.records-by-month {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Admin Day-wise View Header - plain card */
.admin-date-header {
    background: #ffffff;
    color: var(--gray-800);
    padding: 16px 24px;
    border-radius: 12px;
    margin: 24px 0 12px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--gray-200);
}

/* keep the inner text styling but with normal colors */
.admin-date-header .day-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.admin-date-header .day-name {
    font-size: 14px;
    opacity: 0.8;
    font-weight: 600;
    color: var(--gray-600);
}

.admin-date-header .date-main {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.3px;
    color: var(--gray-900);
}


/* User Month-wise View - plain card */
.month-header {
    background: #ffffff;
    color: var(--gray-800);
    padding: 16px 24px;
    border-radius: 12px;
    margin: 24px 0 12px 0;
    font-weight: 700;
    font-size: 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--gray-200);
}

/* we don't need the overlay any more */
.month-header::before {
    display: none;
}

.month-header .month-name {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gray-800);
}

.month-header .month-name::before {
    content: '📅';
    font-size: 20px;
}

/* old month-stats pill – we will not use it, hide */
.month-header .month-stats {
    display: none;
}

/* container for the whole records list (day-wise or month-wise) */
.records-by-date,
.records-by-month {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.no-records {
    text-align: center;
    padding: 60px;
    color: var(--gray-500);
    font-size: 18px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 16px;
    border: 2px dashed var(--gray-300);
}

/* ==================== CALENDAR STYLES (FUTURISTIC) ==================== */

.calendar-modal-content {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    border-radius: 24px;
    padding: 32px;
    width: 95%;
    max-width: 1000px;
    animation: fadeInScale 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
    margin-top: 24px;
    padding: 10px;
    background: rgba(243, 244, 246, 0.5);
    border-radius: 20px;
}

.calendar-day-label {
    text-align: center;
    font-size: 10px;
    font-weight: 800;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    padding-bottom: 8px;
    opacity: 90.7;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 700;
    color: var(--gray-700);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    background: var(--white);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    position: relative;
    overflow: hidden;
}

/* Hover effect */
.calendar-day:not(:empty):hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 12px 24px -6px rgba(0, 0, 0, 0.15);
    z-index: 10;
    background: white;
}

/* Empty slots */
.calendar-day:empty {
    background: transparent;
    box-shadow: none;
    cursor: default;
}

/* Legend Container - Ultra Compact */
.calendar-items-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
    justify-content: center;
    background: rgba(243, 244, 246, 0.5);
    padding: 6px;
    border-radius: 12px;
}

.legend-chip {
    display: flex;
    align-items: center;
    padding: 6px 12px;
    background: white;
    border-radius: 30px;
    font-size: 10px;
    font-weight: 700;
    color: var(--gray-600);
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.legend-chip:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px -2px rgba(0, 0, 0, 0.08);
}

.calendar-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    margin-right: 8px;
    box-shadow: 0 0 8px currentColor;
    /* Neon glow */
}

/* ==================== CALENDAR STATUS COLORS (NEON GLOW) ==================== */

/* Present - Neon Green */
.cal-present,
.calendar-day.cal-present {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.15), inset 0 0 10px rgba(16, 185, 129, 0.05);
}

.cal-present .calendar-dot {
    background: #10b981;
    box-shadow: 0 0 8px #10b981, 0 0 16px #10b981;
}

/* Work From Home - Neon Purple */
.cal-wfh,
.calendar-day.cal-wfh {
    background: rgba(139, 92, 246, 0.1);
    color: #8b5cf6;
    border: 1px solid rgba(139, 92, 246, 0.3);
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.15), inset 0 0 10px rgba(139, 92, 246, 0.05);
}

.cal-wfh .calendar-dot {
    background: #8b5cf6;
    box-shadow: 0 0 8px #8b5cf6, 0 0 16px #8b5cf6;
}

/* Client Visit - Neon Blue */
.cal-client,
.calendar-day.cal-client {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.3);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.15), inset 0 0 10px rgba(59, 130, 246, 0.05);
}

.cal-client .calendar-dot {
    background: #3b82f6;
    box-shadow: 0 0 8px #3b82f6, 0 0 16px #3b82f6;
}

/* Half Day - Neon Orange */
.cal-half,
.calendar-day.cal-half {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.3);
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.15), inset 0 0 10px rgba(245, 158, 11, 0.05);
}

.cal-half .calendar-dot {
    background: #f59e0b;
    box-shadow: 0 0 8px #f59e0b, 0 0 16px #f59e0b;
}

/* Absent - Neon Red */
.cal-absent,
.calendar-day.cal-absent {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.15), inset 0 0 10px rgba(239, 68, 68, 0.05);
}

.cal-absent .calendar-dot {
    background: #ef4444;
    box-shadow: 0 0 8px #ef4444, 0 0 16px #ef4444;
}

/* Empty/No Data - Subtle Gray */
.cal-empty,
.calendar-day.cal-empty {
    background: rgba(243, 244, 246, 0.3);
    color: var(--gray-400);
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: none;
}

.cal-empty .calendar-dot {
    background: var(--gray-300);
    box-shadow: none;
}

/* ==================== RESPONSIVE DESIGN ==================== */
/* Notification Bar */
.notification-bar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    margin-bottom: 24px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    color: white;
    overflow: hidden;
    transition: all 0.3s ease;
}

.notification-container {
    padding: 0;
}

.notification-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.1);
    transition: background 0.2s;
}

.notification-header:hover {
    background: rgba(255, 255, 255, 0.15);
}

.notification-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    font-size: 1.1rem;
}

.notification-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.notification-icon {
    font-size: 1.4rem;
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ef4444;
    color: white;
    border-radius: 10px;
    padding: 2px 6px;
    font-size: 0.75rem;
    font-weight: bold;
    min-width: 18px;
    text-align: center;
    border: 1px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.notification-text {
    letter-spacing: 0.5px;
}

.notification-toggle-btn {
    background: rgba(255, 255, 255, 0.2);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.8rem;
    transition: all 0.3s ease;
}

.notification-list {
    background: white;
    max-height: 400px;
    overflow-y: auto;
    animation: slideDown 0.3s ease-out;
    position: relative;
    z-index: 1000;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notification-item {
    cursor: pointer;
    padding: 16px 20px;
    border-bottom: 1px solid #f3f4f6;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    transition: background 0.2s;
    color: #1f2937;
}

.notification-item:hover {
    background: #f9fafb;
}

.notification-item:last-child {
    border-bottom: none;
}

.notification-item-icon {
    font-size: 1.5rem;
    background: #eff6ff;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

.notification-item-content {
    flex: 1;
}

.notification-item-message {
    font-size: 0.95rem;
    color: #374151;
    margin-bottom: 4px;
    font-weight: 500;
    line-height: 1.4;
}

.notification-item-time {
    font-size: 0.8rem;
    color: #9ca3af;
}

.notification-footer {
    padding: 10px;
    text-align: center;
    background: #f9fafb;
    border-top: 1px solid #e5e7eb;
}

/* Mobile responsive fixes */
@media (max-width: 640px) {
    .notification-bar {
        border-radius: 8px;
        margin-bottom: 16px;
    }

    .notification-header {
        padding: 12px 16px;
    }

    .notification-title {
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 12px;
    }

    .card {
        padding: 24px;
    }

    .header {
        flex-direction: column;
        gap: 16px;
        text-align: center;
        padding: 16px 24px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }

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

    .stats-grid,
    .actions-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .office-selection {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .camera-controls {
        flex-direction: column;
        align-items: center;
    }

    .admin-date-header,
    .month-header {
        flex-direction: column;
        gap: 12px;
        text-align: center;
        padding: 16px 20px;
    }

    .calendar-grid {
        gap: 4px;
        font-size: 12px;
    }

    .calendar-day-label,
    .calendar-day {
        padding: 10px 4px;
        min-height: 42px;
        font-size: 12px;
    }

    .calendar-legend {
        gap: 12px;
        justify-content: center;
        padding: 16px;
    }

    .calendar-legend-item {
        font-size: 12px;
        padding: 6px 12px;
    }

    .records-table {
        min-width: 700px;
    }

    .modal-content {
        padding: 24px;
        max-width: 95%;
    }
}

@media (max-width: 480px) {
    .login-card {
        padding: 24px;
    }

    .action-card {
        padding: 24px;
    }

    .stat-card {
        padding: 20px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 14px;
        min-height: 44px;
    }

    .calendar-day {
        min-height: 38px;
        padding: 8px 2px;
        font-size: 11px;
    }

    .admin-date-header .date-full {
        font-size: 18px;
    }

    .month-header {
        font-size: 18px;
        padding: 16px 20px;
    }
}

/* Attendance records toolbar / search */
.records-toolbar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.records-toolbar-left {
    margin-right: auto;
    font-weight: 600;
    color: var(--gray-700);
}

.records-search-input {
    min-width: 20px;
}

/* ==================== MY DOCUMENTS ==================== */

.my-docs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}

.my-doc-card {
    border: 1px solid var(--gray-200);
    border-radius: 10px;
    padding: 14px;
    background: var(--white);
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: all 0.2s ease;
}

.my-doc-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.my-doc-icon {
    font-size: 32px;
    text-align: center;
}

.my-doc-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-800);
    word-break: break-word;
}

.my-doc-actions {
    display: flex;
    gap: 8px;
    margin-top: auto;
}

.my-doc-actions a {
    flex: 1;
    text-align: center;
    font-size: 13px;
    padding: 6px 10px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
}

.my-doc-view {
    background: var(--primary-color);
    color: white;
}

.my-doc-download {
    background: var(--gray-200);
    color: var(--gray-800);
}

.my-doc-view:hover {
    background: var(--primary-dark);
}

.my-doc-download:hover {
    background: var(--gray-300);
}

.my-doc-card {
    position: relative;
}

.my-doc-checkbox {
    position: absolute;
    top: 8px;
    left: 8px;
    transform: scale(1.2);
}

/* =========================
   DOCUMENTS MODAL (FINAL)
========================= */

.docs-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.docs-modal.show {
    display: flex;
}

.docs-modal-content {
    background: #ffffff;
    width: 520px;
    max-width: 95%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
    animation: modalFadeIn 0.2s ease-out;
}

@keyframes modalFadeIn {
    from {
        transform: scale(0.95);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* ===== HEADER ===== */
.docs-modal-header {
    font-size: 18px;
    font-weight: 600;
    text-align: center;
    margin-bottom: 12px;
}

/* ===== DOCUMENT LIST ===== */
.docs-list {
    flex: 1;
    overflow-y: auto;
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 8px;
}

.doc-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 6px;
    border-bottom: 1px solid #eee;
}

.doc-row:last-child {
    border-bottom: none;
}

.doc-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.doc-name {
    font-weight: 500;
}

.doc-file {
    font-size: 12px;
    color: #777;
}

.doc-view {
    font-size: 13px;
    color: #1976d2;
    text-decoration: none;
}

.doc-view:hover {
    text-decoration: underline;
}

/* ===== FOOTER BUTTONS ===== */
.docs-actions {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 15px;
}

.docs-actions .btn {
    flex: 1;
    padding: 10px;
    border-radius: 8px;
    border: none;
    font-size: 14px;
    cursor: pointer;
}

.btn-primary {
    background: #1976d2;
    color: #fff;
}

.btn-primary:hover {
    background: #155a9c;
}

.btn-secondary {
    background: #e0e0e0;
    color: #333;
}

.btn-secondary:hover {
    background: #cfcfcf;
}

/* ==================== TASK MANAGER PREMIUM STYLING ==================== */

#taskManagerModal .modal-content {
    max-width: 1200px;
    max-height: 90vh;
    padding: 0;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(255, 255, 255, 0.05);
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
}

.modal-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 24px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 20px 20px 0 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.modal-header h3 {
    font-size: 24px;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal-header h3::before {
    content: "📝";
    font-size: 28px;
}

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

.task-manager-board {
    display: flex;
    gap: 24px;
    padding: 32px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    min-height: 600px;
    overflow-x: auto;
}

.task-column {
    background: white;
    border-radius: 16px;
    padding: 0;
    min-width: 320px;
    max-width: 320px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.task-column:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(37, 99, 235, 0.1);
}

.task-column-header {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    padding: 20px 24px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 16px 16px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.task-column-header h4 {
    font-size: 18px;
    font-weight: 700;
    color: var(--gray-800);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.task-column-header h4::before {
    font-size: 20px;
}

#todoColumn .task-column-header h4::before {
    content: "📋";
}

#inProgressColumn .task-column-header h4::before {
    content: "🔄";
}

#completedColumn .task-column-header h4::before {
    content: "✅";
}

.task-count {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    min-width: 24px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.task-list {
    padding: 16px;
    flex: 1;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.task-card-placeholder {
    color: var(--gray-400);
    font-style: italic;
    text-align: center;
    padding: 40px 20px;
    border: 2px dashed var(--gray-200);
    border-radius: 12px;
    background: rgba(248, 250, 252, 0.5);
    font-size: 14px;
}

.task-card {
    background: white;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06), 0 0 0 1px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    cursor: grab;
    position: relative;
    overflow: hidden;
}

.task-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(37, 99, 235, 0.1);
}

.task-card:active {
    cursor: grabbing;
    transform: rotate(2deg);
}

.task-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-dark));
    opacity: 90;
    transition: opacity 0.3s ease;
}

.task-card:hover::before {
    opacity: 100;
}

.task-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
    gap: 12px;
}

.task-card-header h5 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-900);
    margin: 0;
    line-height: 1.4;
    flex: 1;
}

.task-priority {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.task-priority[data-priority="low"] {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.task-priority[data-priority="medium"] {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.task-priority[data-priority="high"] {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.task-priority[data-priority="urgent"] {
    background: linear-gradient(135deg, #7c3aed 0%, #5b21b6 100%);
    color: white;
}

.task-card-body {
    margin-bottom: 16px;
}

.task-card-body p {
    color: var(--gray-600);
    font-size: 14px;
    line-height: 1.5;
    margin: 0 0 8px 0;
}

.task-card-body small {
    color: var(--gray-500);
    font-size: 12px;
    display: block;
    margin-top: 4px;
}

.task-card-actions {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.task-card-actions button {
    padding: 6px 12px;
    border: none;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    min-height: 32px;
    flex: 1;
}

.task-card-actions button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.task-card-actions button:disabled {
    opacity: 100;
    cursor: not-allowed;
    transform: none;
}

.task-card-actions button:nth-child(1) {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
}

.task-card-actions button:nth-child(2) {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.task-card-actions button:nth-child(3) {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.task-card-actions button:nth-child(4) {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

#addTaskModal .modal-content {
    max-width: 500px;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

#addTaskModal h3 {
    font-size: 24px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 24px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

#addTaskModal h3::before {
    content: "➕";
    font-size: 28px;
}

#addTaskModal .form-group {
    margin-bottom: 20px;
}

#addTaskModal .form-label {
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 8px;
    display: block;
}

#addTaskModal .form-control {
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    padding: 12px 16px;
    font-size: 16px;
    transition: all 0.2s ease;
}

#addTaskModal .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

#addTaskModal .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

#addTaskModal select.form-control {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 12px center;
    background-repeat: no-repeat;
    background-size: 16px;
    padding-right: 40px;
}

@media (max-width: 1024px) {
    .task-manager-board {
        padding: 24px;
        gap: 16px;
    }

    .task-column {
        min-width: 280px;
        max-width: 280px;
    }
}

@media (max-width: 768px) {
    #taskManagerModal .modal-content {
        max-width: 95%;
        max-height: 95vh;
    }

    .task-manager-board {
        flex-direction: column;
        padding: 16px;
        gap: 16px;
        min-height: auto;
    }

    .task-column {
        min-width: auto;
        max-width: none;
        width: 100%;
    }

    .task-column-header h4 {
        font-size: 16px;
    }

    .task-card-actions {
        flex-direction: column;
    }

    .task-card-actions button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .modal-header {
        padding: 20px;
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

    .modal-header h3 {
        font-size: 20px;
    }

    .modal-actions {
        width: 100%;
        justify-content: center;
    }

    .task-manager-board {
        padding: 12px;
    }

    .task-column-header {
        padding: 16px 20px;
    }

    .task-card {
        padding: 12px;
    }

    .task-card-header h5 {
        font-size: 14px;
    }
}

.task-card.dragging {
    opacity: 100;
    transform: rotate(5deg);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.task-column.drag-over {
    background: rgba(37, 99, 235, 0.05);
    border: 2px dashed var(--primary-color);
}

.task-column.drag-over .task-column-header {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1) 0%, rgba(37, 99, 235, 0.05) 100%);
}

.task-priority {
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.7;
    }
}

.task-column.loading .task-list::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 24px;
    height: 24px;
    border: 2px solid transparent;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.task-card-actions .btn {
    border: none;
    font-size: 11px;
    padding: 8px 12px;
    min-height: 28px;
    border-radius: 6px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s ease;
}

.task-card-actions .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.task-card {
    position: relative;
}

.task-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.02) 0%, rgba(37, 99, 235, 0.05) 100%);
    opacity: 100;
    transition: opacity 0.3s ease;
    border-radius: 12px;
    pointer-events: none;
}

.task-card:hover::after {
    opacity: 1;
}

/* ==================== BIRTHDAY CALENDAR STYLING ==================== */

.birthday-calendar-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border-radius: 12px;
    box-shadow: none;
}

.calendar-header h4 {
    font-size: 20px;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.calendar-header h4::before {
    content: "🎂";
    font-size: 24px;
}

.calendar-header .btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    transition: all 0.2s ease;
}

.calendar-header .btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-1px);
}

.birthday-calendar-grid {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: none;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    margin-bottom: 12px;
}

.calendar-weekday {
    text-align: center;
    padding: 8px 4px;
    font-weight: 600;
    color: var(--gray-700);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: var(--gray-100);
    border-radius: 6px;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.birthday-calendar-grid .calendar-day {
    aspect-ratio: 1;
    min-height: 50px;
    padding: 6px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    background: white;
    color: var(--gray-700);
    font-size: 14px;
    font-weight: 500;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
}

.birthday-calendar-grid .calendar-day:hover {
    background: var(--gray-50);
    border-color: var(--primary-color);
    transform: translateY(-1px);
    box-shadow: none;
}

.birthday-calendar-grid .calendar-day.empty {
    background: transparent;
    border: none;
    cursor: default;
}

.birthday-calendar-grid .calendar-day.empty:hover {
    background: transparent;
    border: none;
    transform: none;
    box-shadow: none;
}

.birthday-calendar-grid .calendar-day.today {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    font-weight: 700;
}

.birthday-calendar-grid .calendar-day.has-birthday {
    background: var(--success-color);
    color: white;
    border-color: var(--success-color);
    font-weight: 600;
}

.birthday-calendar-grid .calendar-day.has-birthday:hover {
    background: var(--success-dark);
    border-color: var(--success-dark);
}

.day-number {
    font-size: 16px;
    font-weight: 600;
    line-height: 1;
}

.birthday-indicator {
    font-size: 10px;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.9);
    color: var(--success-color);
    padding: 1px 4px;
    border-radius: 6px;
    min-width: 16px;
    text-align: center;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.birthday-details-panel {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: none;
    border: 1px solid rgba(0, 0, 0, 0.05);
    min-height: 200px;
}

.birthday-details-panel h5 {
    font-size: 18px;
    font-weight: 700;
    color: var(--gray-900);
    margin: 0 0 16px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.birthday-details-panel h5::before {
    content: "📋";
    font-size: 20px;
}

.birthday-details-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.birthday-detail-item {
    padding: 16px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

.birthday-detail-item:hover {
    transform: translateY(-1px);
    box-shadow: none;
    border-color: var(--primary-color);
}

.birthday-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.birthday-detail-header strong {
    font-size: 16px;
    font-weight: 700;
    color: var(--gray-900);
}

.birthday-age {
    font-size: 12px;
    font-weight: 600;
    color: var(--primary-color);
    background: rgba(37, 99, 235, 0.1);
    padding: 4px 8px;
    border-radius: 12px;
    border: 1px solid rgba(37, 99, 235, 0.2);
}

.birthday-detail-info {
    font-size: 14px;
    color: var(--gray-600);
    line-height: 1.5;
}

.birthday-detail-info small {
    display: block;
    margin-bottom: 2px;
}

/* Calendar Redesign to match reference */
.birthday-calendar-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 10px;
}

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

.calendar-header h4 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-900);
    margin: 0;
}

.birthday-calendar-legend {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    align-items: center;
}

.birthday-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    color: var(--gray-600);
    font-weight: 500;
}

.birthday-legend-item::before {
    content: '';
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: block;
}

.birthday-legend-item.today::before {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    /* Green for today/active context */
}

.birthday-legend-item.birthday::before {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    /* Primary for Birthday */
}

.birthday-calendar-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Weekday Headers - Pill shaped */
.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
    margin-bottom: 10px;
}

.calendar-weekday {
    background-color: #f3f4f6;
    color: #6b7280;
    border-radius: 8px;
    padding: 12px 0;
    text-align: center;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* Sunday Header Red */
.calendar-weekday:nth-child(1) {
    color: #ef4444;
    background-color: #fef2f2;
}

/* Days Grid */
.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    color: var(--gray-800);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    background: white;
    box-shadow: none;
    border: 1px solid transparent;
}

.calendar-day:hover:not(.empty) {
    background-color: #f8fafc;
    transform: translateY(-3px);
    box-shadow: none;
    z-index: 5;
}

.calendar-day.empty {
    cursor: default;
    pointer-events: none;
    background: transparent;
    box-shadow: none;
}

/* Sunday Style - Red Text */
.calendar-day.sunday {
    color: #ef4444;
    background: #fef2f2;
}

/* Today State - Green Theme (Exchanged as per request) */
.calendar-day.today {
    background: #ecfdf5;
    color: #059669;
    border: 2px solid #10b981;
    box-shadow: none;
}

/* Birthday State - Futuristic Gradient Purple */
.calendar-day.has-birthday {
    background: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
    color: white;
    border: none;
    box-shadow: none;
}

.calendar-day.has-birthday:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: none;
}

/* Sunday collisions */
.calendar-day.has-birthday.sunday {
    color: white;
}

/* Indicator Styling */
.birthday-indicator {
    font-size: 0.75rem;
    margin-top: 2px;
    font-weight: 400;
    opacity: 0.95;
    background: rgba(255, 255, 255, 0.2);
    padding: 1px 6px;
    border-radius: 999px;
    backdrop-filter: blur(2px);
}

.calendar-day.has-birthday .birthday-indicator {
    color: white;
}

/* Futuristic Animations */
@keyframes popIn {
    0% {
        transform: scale(0.5);
        opacity: 100;
        filter: blur(4px);
    }

    100% {
        transform: scale(1);
        opacity: 100;
        filter: blur(0);
    }
}

.calendar-day {
    animation: popIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) backwards;
}

/* Stagger animation for days */
.calendar-day:nth-child(n) {
    animation-delay: 0ms;
}

.calendar-day:nth-child(7n) {
    animation-delay: 50ms;
}

.birthday-detail-item {
    position: relative;
    overflow: hidden;
}

.birthday-detail-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-dark));
    opacity: 100;
    transition: opacity 0.3s ease;
}

.birthday-detail-item:hover::before {
    opacity: 1;
}

/* Birthday Tooltip */
.birthday-tooltip {
    position: absolute;
    background: white;
    border-radius: 12px;
    padding: 12px;
    box-shadow: none;
    border: 1px solid rgba(0, 0, 0, 0.05);
    z-index: 10000;
    min-width: 200px;
    pointer-events: none;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.birthday-tooltip.visible {
    opacity: 1;
    transform: translateY(0);
}

.birthday-tooltip-header {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--gray-500);
    font-weight: 600;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--gray-100);
}

.birthday-tooltip-item {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.birthday-tooltip-item:last-child {
    margin-bottom: 0;
}

.birthday-tooltip-avatar {
    width: 24px;
    height: 24px;
    background: var(--primary-light);
    color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
}

.birthday-tooltip-info {
    display: flex;
    flex-direction: column;
}

.birthday-tooltip-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray-900);
    line-height: 1.2;
}


/* Split Layout for Feature-Rich Calendar */
.birthday-calendar-split {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 32px;
    height: 100%;
    min-height: 500px;
}

@media (max-width: 1024px) {
    .birthday-calendar-split {
        grid-template-columns: 1fr;
    }
}

.birthday-main-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.birthday-side-panel {
    background: #f8fafc;
    border-radius: 16px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    border: 1px solid #e2e8f0;
}

/* Feature: Search Bar */
.calendar-search {
    position: relative;
}

.calendar-search input {
    width: 100%;
    padding: 10px 16px 10px 40px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    font-size: 0.875rem;
    transition: all 0.2s;
}

.calendar-search input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
    outline: none;
}

.calendar-search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
}

/* Feature: Birthday List */
.birthday-list-container {
    flex: 1;
    overflow-y: auto;
    padding-right: 4px;
}

.birthday-list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: white;
    border-radius: 12px;
    margin-bottom: 12px;
    transition: all 0.2s;
    border: 1px solid transparent;
    cursor: pointer;
}

.birthday-list-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    border-color: #e2e8f0;
}

.birthday-list-item.active {
    border-color: var(--primary-color);
    background: #eff6ff;
}

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

.birthday-list-details h5 {
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0;
    color: var(--gray-900);
}

.birthday-list-details p {
    font-size: 0.8rem;
    color: var(--gray-500);
    margin: 2px 0 0 0;
}

/* Feature: Stats Pill */
.calendar-stat-pill {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

/* Feature: Action Button */
.btn-wish {
    width: 100%;
    background: linear-gradient(135deg, #8b5cf6, #d946ef);
    color: white;
    border: none;
    padding: 10px;
    border-radius: 10px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s;
}

.btn-wish:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(139, 92, 246, 0.3);
}

.btn-today {
    padding: 6px 16px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: white;
    color: var(--gray-700);
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s;
}


/* Employee Summary Modal Styles */
.summary-modal-container {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.summary-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 16px;
    margin-bottom: -8px;
}

.summary-header h3 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-900);
    display: flex;
    align-items: center;
    gap: 10px;
}

.summary-hero {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
    border-radius: 16px;
    padding: 30px;
    text-align: center;
    color: white;
    box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.4);
    position: relative;
    overflow: hidden;
}

.summary-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 60%);
    animation: rotate 20s linear infinite;
}

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

    to {
        transform: rotate(360deg);
    }
}

.hero-value {
    font-size: 3.5rem;
    font-weight: 800;
    display: block;
    line-height: 1;
    margin-bottom: 4px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hero-label {
    font-size: 1rem;
    opacity: 0.9;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

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

@media (max-width: 600px) {
    .summary-grid {
        grid-template-columns: 1fr;
    }
}

.summary-card {
    background: white;
    padding: 16px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.2s;
}

.summary-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    border-color: var(--primary-light);
}

.summary-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.icon-present {
    background: #ecfdf5;
    color: #10b981;
}

.icon-absent {
    background: #fef2f2;
    color: #ef4444;
}

.icon-leave {
    background: #fffbeb;
    color: #f59e0b;
}

.icon-wfh {
    background: #eff6ff;
    color: #3b82f6;
}

.icon-survey {
    background: #faf5ff;
    color: #a855f7;
}

.summary-data {
    display: flex;
    flex-direction: column;
}

.summary-data .value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    line-height: 1.1;
}

.summary-data .label {
    font-size: 0.8rem;
    color: var(--gray-500);
    font-weight: 500;
}

.modal-close-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #f1f5f9;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--gray-500);
    transition: all 0.2s;
}




/* --- Cyber Refinements (Phase 2) --- */

/* Cyber Scrollbar */
.futuristic-calendar-wrap ::-webkit-scrollbar {
    width: 6px;
    height: 6px;
    background: rgba(15, 23, 42, 0.5);
}

.futuristic-calendar-wrap ::-webkit-scrollbar-thumb {
    background: #475569;
    border-radius: 3px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.futuristic-calendar-wrap ::-webkit-scrollbar-thumb:hover {
    background: #6366f1;
}

/* Cyber Buttons */
.btn-cyber {
    background: transparent;
    border: 1px solid rgba(99, 102, 241, 0.5);
    color: #a5b4fc;
    padding: 6px 16px;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    /* Techy sharp edges or slightly rounded */
}

.btn-cyber:hover {
    background: rgba(99, 102, 241, 0.2);
    box-shadow: 0 0 15px rgba(99, 102, 241, 0.4);
    color: white;
    border-color: #818cf8;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.8);
}

.btn-cyber-primary {
    border-color: #10b981;
    color: #34d399;
}

.btn-cyber-primary:hover {
    background: rgba(16, 185, 129, 0.2);
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.4);
    border-color: #34d399;
}

.btn-cyber-danger {
    border-color: #ef4444;
    color: #f87171;
}

.btn-cyber-danger:hover {
    background: rgba(239, 68, 68, 0.2);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.4);
    border-color: #f87171;
}

/* Transmission Overlay */
.transmission-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.95);
    z-index: 100;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
    animation: fadeIn 0.3s;
}

.transmission-loader {
    width: 60px;
    height: 60px;
    border: 3px solid transparent;
    border-top-color: #6366f1;
    border-bottom-color: #ec4899;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.3);
}

.transmission-text {
    font-family: inherit;
    font-size: 1.2rem;
    color: #fff;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    animation: pulse 1.5s infinite;
}

.transmission-success {
    font-size: 3rem;
    margin-bottom: 16px;
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Tech Corner Accents for Glass Calendar */
.glass-calendar {
    position: relative;
    /* Ensuring existing styles are kept, adding to them via specificity or just rely on cascade if appending */
}

.glass-calendar::before,
.glass-calendar::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s;
}

.glass-calendar::before {
    top: -1px;
    left: -1px;
    border-right: none;
    border-bottom: none;
    border-top-color: #6366f1;
    border-left-color: #6366f1;
}

.glass-calendar::after {
    bottom: -1px;
    right: -1px;
    border-left: none;
    border-top: none;
    border-bottom-color: #ec4899;
    border-right-color: #ec4899;
}

.glass-calendar:hover::before,
.glass-calendar:hover::after {
    width: 100%;
    height: 100%;
    opacity: 0.1;
}

.requests-modal-container {
    padding: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #fdfdfd;
    background-image: radial-gradient(rgba(148, 163, 184, 0.1) 1px, transparent 1px);
    background-size: 24px 24px;
    border-radius: 20px;
    overflow: hidden;
}

/* Glass Header with Summary Stats */
.requests-dashboard-header {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    padding: 28px;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    display: flex;
    flex-direction: column;
    gap: 24px;
    z-index: 10;
}

.requests-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.requests-title-row h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #1e293b, #334155);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Futuristic Stats Row */
.requests-stats-row {
    display: flex;
    gap: 16px;
}

.stat-chip {
    flex: 1;
    background: white;
    border: 1px solid #f1f5f9;
    border-radius: 16px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px -1px rgba(0, 0, 0, 0.01);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-chip:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 20px -8px rgba(0, 0, 0, 0.08);
}

.stat-chip.stat-total {
    border-bottom: 3px solid #6366f1;
}

.stat-chip.stat-wfh {
    border-bottom: 3px solid #3b82f6;
}

.stat-chip.stat-leave {
    border-bottom: 3px solid #f59e0b;
}

.stat-chip-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    background: rgba(0, 0, 0, 0.03);
}

.stat-chip-info {
    display: flex;
    flex-direction: column;
}

.stat-chip-value {
    font-size: 1.25rem;
    font-weight: 800;
    line-height: 1;
    color: var(--gray-900);
}

.stat-chip-label {
    font-size: 0.75rem;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

/* Toolbar: Search & Filter */
.requests-toolbar {
    display: flex;
    gap: 16px;
    margin-top: 8px;
}

.tech-search {
    flex: 1;
    position: relative;
}

.tech-search input {
    width: 100%;
    background: #f1f5f9;
    border: none;
    padding: 12px 16px 12px 42px;
    border-radius: 10px;
    font-size: 0.9rem;
    color: var(--gray-800);
    transition: all 0.3s;
}

.tech-search input:focus {
    background: white;
    box-shadow: 0 0 0 2px var(--primary-light);
    outline: none;
}

.tech-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-400);
}

.filter-tabs {
    display: flex;
    background: #f1f5f9;
    padding: 4px;
    border-radius: 10px;
    gap: 4px;
}

.filter-tab {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--gray-500);
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}

.filter-tab.active {
    background: white;
    color: var(--gray-900);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* Card List */
.requests-futuristic-list {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.req-card-tech {
    background: white;
    border: 1px solid #f1f5f9;
    border-radius: 20px;
    padding: 24px;
    display: flex;
    gap: 24px;
    position: relative;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.01);
    overflow: hidden;
}

.req-card-tech:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.08);
    border-color: #e2e8f0;
}

/* Marker bar - slightly more subtle */
.req-card-tech::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 6px;
    height: 100%;
    background: #cbd5e1;
    transition: all 0.3s;
}

.req-card-tech.tech-wfh::after {
    background: linear-gradient(to bottom, #3b82f6, #60a5fa);
    box-shadow: 2px 0 10px rgba(59, 130, 246, 0.2);
}

.req-card-tech.tech-leave::after {
    background: linear-gradient(to bottom, #f59e0b, #fbbf24);
    box-shadow: 2px 0 10px rgba(245, 158, 11, 0.2);
}

.req-avatar-tech {
    width: 50px;
    height: 50px;
    border-radius: 14px;
    background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-600);
    box-shadow: inset 0 2px 4px rgba(255, 255, 255, 1);
}

.req-content-tech {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.req-header-tech {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.req-name-tech {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gray-900);
    margin: 0;
}

.req-badges-tech {
    display: flex;
    gap: 8px;
    align-items: center;
}

.req-badge {
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-tech-wfh {
    background: rgba(59, 130, 246, 0.1);
    color: #2563eb;
}

.badge-tech-leave {
    background: rgba(245, 158, 11, 0.1);
    color: #d97706;
}

.req-actions-tech {
    display: flex;
    gap: 12px;
}

.btn-tech {
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1.1rem;
}

.btn-tech-approve {
    background: #ecfdf5;
    color: #10b981;
}

.btn-tech-approve:hover {
    background: #10b981;
    color: white;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.4);
    transform: translateY(-2px);
}

.btn-tech-reject {
    background: #fef2f2;
    color: #ef4444;
}

.btn-tech-reject:hover {
    background: #ef4444;
    color: white;
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.4);
    transform: translateY(-2px);
}



/* --- Premium Birthday Calendar Styles (Light Theme) --- */
.premium-calendar-wrap {
    padding: 0;
    height: 100%;
    background: #f8fafc;
    display: flex;
    flex-direction: column;
    color: #334155;
    border-radius: 28px;
    overflow: hidden;
}

.premium-header {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.4);
    padding: 20px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.header-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1e293b;
    display: flex;
    align-items: center;
    gap: 12px;
}

.calendar-main-split {
    display: grid;
    grid-template-columns: 1fr 320px;
    height: 100%;
    overflow: hidden;
}

/* Checkered Grid Pattern for Main Area */
.clean-calendar-panel {
    padding: 0;
    overflow-y: auto;
    background-color: #f8fafc;
    background-image:
        radial-gradient(circle at 2px 2px, #e2e8f0 1px, transparent 0);
    background-size: 1px 24px;
}

.clean-calendar {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 32px;
    box-shadow: none;
}

.fc-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    margin-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 12px;
}

.fc-weekday {
    text-align: center;
    color: #64748b;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.8rem;
    padding: 0;
}

.fc-weekday.sun {
    color: #ef4444;
}

.fc-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
}

.fc-day {
    height: 60px;
    width: 100%;
    background: #ffffff;
    border-radius: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    border: 1px solid #f1f5f9;
    position: relative;
    font-weight: 600;
    color: #475569;
}

.fc-day:hover:not(.empty) {
    background: #ffffff;
    border-color: #3b82f6;
    transform: translateY(-4px) scale(1.04);
    box-shadow: 0 12px 24px -8px rgba(59, 130, 246, 0.25);
    z-index: 2;
}

.fc-day.today {
    background: #eff6ff;
    border: 2px solid #3b82f6;
    color: #1d4ed8;
}

.fc-day.has-birthday {
    background: #fdf2f8;
    border: 2px solid #ec4899;
    color: #db2777;
    box-shadow: 0 4px 12px rgba(236, 72, 153, 0.1);
}

.fc-day.sunday {
    color: #ef4444;
    background: #fef2f2;
}

/* Side Panel - Premium Glassmorphic */
.premium-side-panel {
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-left: 1px solid rgba(226, 232, 240, 0.4);
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.02);
}

/* Stats Chips */
.premium-stats {
    display: flex;
    gap: 12px;
}

.premium-stat-card {
    flex: 1;
    background: white;
    border: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: 16px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.premium-stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    border-color: #cbd5e1;
}

.premium-stat-val {
    font-size: 1.5rem;
    font-weight: 800;
    color: #0f172a;
}

.premium-stat-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: #64748b;
    letter-spacing: 0.05em;
    font-weight: 600;
}

/* Search Input */
.premium-search {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    padding: 12px 16px;
    border-radius: 10px;
    color: #334155;
    width: 100%;
    outline: none;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.premium-search:focus {
    background: white;
    border-color: #3b82f6;
    box-shadow: none;
}

/* List Items */
.premium-list {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-right: 12px;
}

/* Premium Scrollbar for List */
.premium-list::-webkit-scrollbar {
    width: 6px;
}

.premium-list::-webkit-scrollbar-track {
    background: transparent;
}

.premium-list::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.2);
    border-radius: 10px;
    transition: all 0.2s;
}

.premium-list::-webkit-scrollbar-thumb:hover {
    background: rgba(148, 163, 184, 0.4);
}

.premium-list-item {
    background: white;
    border: 1px solid #e2e8f0;
    padding: 12px;
    border-radius: 12px;
    display: flex;
    gap: 12px;
    align-items: center;
    transition: all 0.2s;
    cursor: pointer;
}

.premium-list-item:hover {
    transform: translateX(4px);
    border-color: #3b82f6;
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.08);
}

.premium-avatar {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: #2563eb;
    border: 1px solid #bfdbfe;
    font-size: 1.1rem;
}

.premium-info h5 {
    margin: 0;
    color: #1e293b;
    font-size: 1rem;
    font-weight: 600;
}

.premium-meta {
    display: flex;
    gap: 8px;
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 4px;
    align-items: center;
}

.premium-badge {
    background: #fce7f3;
    color: #be185d;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
}

/* --- Phase 10: Birthday Modal Specific Overrides --- */
/* --- Phase 10: Birthday Modal Specific Overrides --- */
#birthdayCalendarModal .birthday-modal-content {
    max-width: 950px !important;
    width: 95% !important;
    height: 85vh !important;
    max-height: 800px !important;
    padding: 0 !important;
    margin: auto !important;
    border-radius: 28px !important;
    border: none !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25) !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

#birthdayCalendarContent {
    width: 100%;
    height: 100%;
    padding: 0 !important;
    margin: 0 !important;
    display: flex;
    flex-direction: column;
}

#birthdayCalendarModal .premium-calendar-wrap {
    height: 100% !important;
    width: 100% !important;
    border-radius: 0 !important;
    /* Let container handle radius */
    margin: 0 !important;
    padding: 0 !important;
}

/* Premium Buttons & Toggles */
.btn-premium-toggle {
    background: transparent;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-premium-toggle:hover {
    color: #1e293b;
    background: rgba(255, 255, 255, 0.5);
}

.btn-premium-toggle.active {
    background: white;
    color: #3b82f6;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.btn-premium-close {
    background: #fef2f2;
    color: #ef4444;
    border: 1px solid #fee2e2;
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-premium-close:hover {
    background: #fee2e2 !important;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(239, 68, 68, 0.15);
}

.btn-premium {
    border: 1px solid #e2e8f0;
    color: #475569;
    padding: 8px 16px;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.btn-premium:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #1e293b;
}

.btn-premium-primary {
    background: #3b82f6;
    color: white;
    border: none;
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

.btn-premium-primary:hover {
    background: #2563eb;
    box-shadow: 0 6px 10px -1px rgba(59, 130, 246, 0.4);
    color: white;
}

.btn-premium-danger {
    color: #ef4444;
    border-color: #fee2e2;
    background: #fef2f2;
}

.btn-premium-danger:hover {
    background: #fee2e2;
    color: #dc2626;
}

/* Transmission Overlay - Clean */
.transmission-overlay {
    background: rgba(255, 255, 255, 0.95);
    /* Light frosted glass for overlay in premium mode */
}


/* --- Birthday Modal Sizing Override --- */
#birthdayCalendarModal .modal-content {
    width: 95%;
    height: 85vh;
    /* Tall for calendar grid */
    padding: 0;
    background: transparent;
    /* Let the futuristic wrapper handle bg */
    border: none;
    box-shadow: none;
    /* Wrapper has shadow */
    overflow: hidden;
    border-radius: 24px;
}

/* --- FIXED MODAL SIZING OVERRIDE --- */
#birthdayCalendarModal .modal-content {
    max-width: 1300px !important;
    /* Force wide width */
    width: 95% !important;
    height: 85vh !important;
    padding: 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* Ensure Split Layout works */
.calendar-main-split {
    display: grid;
    grid-template-columns: 1fr 350px !important;
    /* Fixed width for sidebar */
    height: 100%;
    overflow: hidden;
}

/* Fix mobile responsive */
@media (max-width: 1024px) {
    #birthdayCalendarModal .modal-content {
        height: 95vh !important;
    }

    .calendar-main-split {
        grid-template-columns: 1fr !important;
        grid-template-rows: 1fr auto;
    }

    .premium-side-panel {
        border-left: none;
        border-top: 1px solid #e2e8f0;
        height: 400px;
    }
}

/* --- Premium Task Manager Styles --- */

.premium-task-board {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    height: calc(100% - 85px);
    padding: 32px;
    background: #fdfdfd;
    background-image: radial-gradient(rgba(148, 163, 184, 0.1) 1px, transparent 1px);
    background-size: 24px 24px;
    border-radius: 0 0 24px 24px;
    overflow-x: auto;
}

.premium-column {
    background: #f8fafc;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-width: 320px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02);
    transition: box-shadow 0.3s ease;
}

.premium-column:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.04);
}

.premium-column-header {
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
    border-radius: 20px 20px 0 0;
}

.premium-column-header h4 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 8px;
}

.premium-task-count {
    background: #e2e8f0;
    color: #64748b;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
}

.premium-task-list {
    padding: 16px;
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.premium-task-card {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.01);
    border: 1px solid #f1f5f9;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.premium-task-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.08);
    border-color: #cbd5e1;
}

.premium-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.premium-task-title {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.4;
}

.premium-task-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: #64748b;
}

.premium-avatar-group {
    display: flex;
    align-items: center;
}

.premium-card-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #3b82f6;
    color: white;
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid white;
    margin-right: -8px;
    font-weight: 700;
}

.premium-priority-badge {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
}

.priority-high {
    background: #fef2f2;
    color: #ef4444;
}

.priority-medium {
    background: #fffbeb;
    color: #f59e0b;
}

.priority-low {
    background: #f0f9ff;
    color: #0ea5e9;
}

/* Modal Override for Task Manager */
#taskManagerModal .modal-content {
    max-width: 1400px !important;
    width: 95% !important;
    height: 90vh !important;
    padding: 0 !important;
    background: #ffffff !important;
}

#taskManagerModal .modal-header,
#myTasksModal .modal-header {
    padding: 28px 32px;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: 24px 24px 0 0;
}

@keyframes slideInUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.btn-subtle {
    background: var(--gray-100);
    color: var(--gray-700);
    border: 1px solid var(--gray-200);
}

.btn-subtle:hover {
    background: var(--gray-200);
    color: var(--gray-900);
    transform: translateY(-1px);
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(10px);
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Premium Popup Table Styles */
#myRequestsModal .records-table {
    border-collapse: separate;
    border-spacing: 0 12px;
    /* Spacing between rows */
    margin-top: -12px;
    /* Offset spacing */
}

#myRequestsModal .records-table thead th {
    background: transparent;
    border: none;
    color: var(--gray-500);
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.1em;
    padding: 0 16px 8px 16px;
}

#myRequestsModal .records-table tbody tr {
    background: #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02), 0 1px 2px rgba(0, 0, 0, 0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border-radius: 12px;
}

#myRequestsModal .records-table tbody tr:hover {
    transform: scale(1.01);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.025);
    z-index: 10;
    position: relative;
}

#myRequestsModal .records-table td {
    padding: 16px;
    border: 1px solid var(--gray-100);
    border-width: 1px 0;
    vertical-align: middle;
}

#myRequestsModal .records-table td:first-child {
    border-left: 1px solid var(--gray-100);
    border-radius: 12px 0 0 12px;
}

#myRequestsModal .records-table td:last-child {
    border-right: 1px solid var(--gray-100);
    border-radius: 0 12px 12px 0;
}

/* Modal Improvements */
.modal {
    backdrop-filter: blur(8px);
    background-color: rgba(15, 23, 42, 0.4);
    /* Darker overlay */
}

.modal-content {
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.8);
    background: #fff;
    animation: modalSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.96);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Status Badges */
.status-badge {
    padding: 6px 12px;
    border-radius: 9999px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-badge.status-present {
    /* Approved */
    background-color: #dcfce7;
    color: #166534;
}

.status-badge.status-half_day {
    /* Pending */
    background-color: #fef9c3;
    color: #854d0e;
}

.status-badge.status-absent {
    /* Rejected */
    background-color: #fee2e2;
    color: #991b1b;
}

.text-muted {
    font-size: 13px;
    color: var(--gray-500);
}

/* Overview Modal Interactions */
.overview-footer-card:hover {
    background-color: var(--gray-50);
    border-color: var(--gray-300) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.stat-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05) !important;
}


/* Premium Popup Enhancements */

/* Staggered Entry Animation */
@keyframes fadeInUpSubtle {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-entry {
    animation: fadeInUpSubtle 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
    /* Hidden initially */
}

/* Stagger Delays */
.delay-1 {
    animation-delay: 0.1s;
}

.delay-2 {
    animation-delay: 0.15s;
}

.delay-3 {
    animation-delay: 0.2s;
}

.delay-4 {
    animation-delay: 0.25s;
}

/* Hero Card Subtle Shine */
.overview-hero-card {
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.overview-hero-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 255, 255, 0.1),
            transparent);
    transform: skewX(-20deg);
    animation: shine-pass 6s infinite ease-in-out;
}

@keyframes shine-pass {
    0% {
        left: -100%;
    }

    10% {
        left: 200%;
    }

    /* Fast pass */
    100% {
        left: 200%;
    }

    /* Wait */
}

/* Soft Premium Shadow */
.premium-shadow {
    box-shadow:
        0 4px 6px -1px rgba(0, 0, 0, 0.05),
        0 10px 15px -3px rgba(0, 0, 0, 0.05);
}

/* Glass-like Borders for Stat Boxes */
.stat-box {
    border: 1px solid rgba(255, 255, 255, 0.8);
    background: linear-gradient(180deg, #ffffff 0%, #fcfcfc 100%);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-box:hover {
    transform: translateY(-3px) scale(1.01);
    box-shadow:
        0 10px 25px -5px rgba(37, 99, 235, 0.1),
        0 8px 10px -6px rgba(37, 99, 235, 0.05) !important;
    border-color: rgba(37, 99, 235, 0.2);
}

/* View Transition */
.view-transition-enter {
    opacity: 0;
    transform: scale(0.98);
}

.view-transition-enter-active {
    opacity: 1;
    transform: scale(1);
    transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.view-transition-exit {
    opacity: 1;
    transform: scale(1);
}

.view-transition-exit-active {
    opacity: 0;
    transform: scale(0.98);
    transition: opacity 0.2s ease, transform 0.2s ease;
}


/* Fix for History View Layout */
#historyView {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Ensure hidden class always wins */
#historyView.hidden {
    display: none !important;
}

/* Additional fix for scrolling */
.history-list-container {
    scrollbar-width: thin;
    scrollbar-color: var(--gray-300) transparent;
}


/* Modal Scroll Fix */
.modal-content {
    max-height: 85vh;
    /* restrict height */
    display: flex;
    flex-direction: column;
    /* allow flex children */
    overflow: hidden;
    /* hide outer scroll */
}

/* Premium Scrollbar */
.history-list-container::-webkit-scrollbar {
    width: 6px;
}

.history-list-container::-webkit-scrollbar-track {
    background: transparent;
}

.history-list-container::-webkit-scrollbar-thumb {
    background-color: var(--gray-300);
    border-radius: 20px;
    border: 2px solid transparent;
    /* padding effect */
    background-clip: content-box;
}

.history-list-container::-webkit-scrollbar-thumb:hover {
    background-color: var(--gray-400);
}


/* Scroll Fix: Robust Flexbox Layout */
.modal-content {
    max-height: 85vh !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    /* Clip corners */
}

#historyView {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
    /* CRITICAL: Allows flex child to shrink below content size */
    overflow: hidden;
    /* Prevent spill */
}

#historyView.hidden {
    display: none !important;
}

.history-list-container {
    flex: 1;
    overflow-y: auto;
    min-height: 0;
    /* Safety measure */
    padding-right: 4px;
    /* Space for scrollbar */
}


/* Mini Calendar Widget */
.calendar-card {
    min-height: 160px;
    /* Ensure visual balance */
}

.mini-cal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 700;
    color: var(--gray-800);
}

.mini-cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    flex: 1;
    /* specific fill */
    align-content: center;
}

.mini-cal-day-name {
    font-size: 10px;
    color: var(--gray-400);
    text-align: center;
    font-weight: 600;
    margin-bottom: 4px;
}

.mini-cal-day {
    font-size: 11px;
    text-align: center;
    padding: 4px 0;
    color: var(--gray-700);
    border-radius: 4px;
    cursor: default;
}

.mini-cal-day.today {
    background: var(--primary-color);
    color: white;
    font-weight: bold;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.3);
}

.mini-cal-day.empty {
    pointer-events: none;
}


/* Mini Calendar Status Indicators */
.mini-cal-day {
    position: relative;
    /* transition: background 0.2s; */
}

/* Status dots or backgrounds */
.mini-cal-day.status-present {
    background-color: #dcfce7;
    color: #166534;
    font-weight: 600;
}

.mini-cal-day.status-wfh {
    background-color: #dbeafe;
    color: #1e40af;
    font-weight: 600;
}

.mini-cal-day.status-absent {
    background-color: #fee2e2;
    color: #991b1b;
}

.mini-cal-day.status-leave {
    background-color: #fef3c7;
    color: #b45309;
}

.mini-cal-day.status-half-day {
    background: linear-gradient(135deg, #dcfce7 50%, #fef3c7 50%);
    color: #1f2937;
}

/* Today highlight overrides or blends? */
.mini-cal-day.today {
    border: 2px solid var(--primary-color);
    box-shadow: none;
    /* simple border for today if status present */
    line-height: 18px;
    /* adjust for border */
}


/* Interactive Calendar Card */
.calendar-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.calendar-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Premium Confirmation Modal */
#confirmModal .modal-content {
    animation: fadeInScale 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(226, 232, 240, 0.5);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
}

#confirmIcon {
    background: #fef2f2;
    width: 80px;
    height: 80px;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
}

#confirmOkBtn:hover {
    background: #dc2626 !important;
    border-color: #dc2626 !important;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(239, 68, 68, 0.4);
}

#confirmCancelBtn:hover {
    background: #f1f5f9 !important;
    transform: translateY(-2px);
}

/* Rejection Modal (Dark Theme) */
.rejection-modal-content {
    background: #1e1e1e;
    /* Dark gray */
    color: #ffffff;
    max-width: 480px;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    border: 1px solid #333;
}

.rejection-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
}

.rejection-label {
    display: block;
    font-size: 14px;
    margin-bottom: 8px;
    color: #cccccc;
}

.rejection-input {
    width: 100%;
    padding: 10px 12px;
    background: #2d2d2d;
    border: 1px solid #444;
    border-radius: 6px;
    color: #ffffff;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.rejection-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2);
}

.rejection-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
}

.rejection-btn-cancel {
    background: #444;
    color: #fff;
    font-size: 13px;
    padding: 8px 20px;
    border-radius: 6px;
    font-weight: 500;
    min-height: 36px;
}

.rejection-btn-cancel:hover {
    background: #555;
    transform: none;
}

.rejection-btn-ok {
    background: #8ab4f8;
    /* Softer blue for dark mode */
    color: #1e1e1e;
    font-size: 13px;
    padding: 8px 20px;
    border-radius: 6px;
    font-weight: 600;
    min-height: 36px;
}

.rejection-btn-ok:hover {
    background: #aecbfa;
    transform: none;
}

/* Fix for Pending Requests Scrolling */
.clean-calendar-panel {
    max-height: 480px;
    /* Restrict height */
    overflow-y: auto;
    /* Enable vertical scroll */
    min-height: 0;
    /* Flexbox safety */
}

/* Scrollbar for Requests List */
.clean-calendar-panel::-webkit-scrollbar {
    width: 6px;
}

.clean-calendar-panel::-webkit-scrollbar-track {
    background: transparent;
}

.clean-calendar-panel::-webkit-scrollbar-thumb {
    background-color: var(--gray-300);
    border-radius: 20px;
}

.clean-calendar-panel::-webkit-scrollbar-thumb:hover {
    background-color: var(--gray-400);
}

/* Active Request Card */
.req-card-tech.active {
    border-color: var(--primary-color) !important;
    background: #eff6ff !important;
    /* light blue */
    box-shadow: 0 4px 6px -1px rgba(37, 99, 235, 0.1), 0 2px 4px -1px rgba(37, 99, 235, 0.06);
    transform: translateX(4px);
}

/* Side Panel Layout Fix (Scrollable) */
.premium-side-panel {
    display: flex;
    flex-direction: column;
    padding: 24px;
    background: #ffffff;
    max-height: 480px;
    /* Match left side */
    overflow-y: auto;
    /* Allow scrolling */
    border-left: 1px solid #f1f5f9;
}

/* Detail Card Internal Button Fix */
.premium-side-panel .btn-tech {
    min-height: 48px;
    width: 100% !important;
}

/* Scrollbar for Side Panel */
.premium-side-panel::-webkit-scrollbar {
    width: 6px;
}

.premium-side-panel::-webkit-scrollbar-track {
    background: transparent;
}

.premium-side-panel::-webkit-scrollbar-thumb {
    background-color: var(--gray-300);
    border-radius: 20px;
}

.premium-side-panel::-webkit-scrollbar-thumb:hover {
    background-color: var(--gray-400);
}

/* Custom Calendar Tooltip */
.calendar-tooltip {
    position: fixed;
    background: #1e293b;
    color: #fff;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    line-height: 1.5;
    z-index: 10000;
    pointer-events: none;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    opacity: 0;
    transition: opacity 0.2s ease, transform 0.2s ease;
    transform: translateY(4px);
    white-space: pre-line;
    /* Handle newlines */
    text-align: left;
    border: 1px solid #334155;
    max-width: 200px;
}

.calendar-tooltip.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Incomplete Document Row Highlighting */
.row-warning-incomplete {
    background-color: #fff1f2 !important;
    /* Light red/rose */
}

.row-warning-incomplete:hover {
    background-color: #ffe4e6 !important;
}

.row-warning-incomplete td {
    border-bottom-color: #fecdd3;
}

/* Multi-date Calendar Selection */
.calendar-day.selected {
    background: rgba(37, 99, 235, 0.1) !important;
    border: 2px solid #2563eb !important;
    color: #2563eb !important;
    font-weight: 700;
    box-shadow: 0 0 15px rgba(37, 99, 235, 0.2);
}

.multi-select-toggle-container {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    background: rgba(248, 250, 252, 0.8);
    border-radius: 12px;
    margin-bottom: 16px;
    border: 1px solid #e2e8f0;
}

.multi-select-actions {
    margin-top: 16px;
    display: none;
    text-align: center;
}

.multi-select-actions.visible {
    display: block;
}

/* Slider Switch for Multi-date Toggle */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5e1;
    transition: .4s;
}

.slider.round {
    border-radius: 24px;
}

.slider.round:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

input:checked+.slider {
    background-color: #10b981;
    /* Green for active */
}

input:checked+.slider:before {
    transform: translateX(20px);
}

/* Leave Color - Neon Cyan/Teal Style */
.cal-leave,
.calendar-day.cal-leave {
    background: rgba(6, 182, 212, 0.1) !important;
    color: #06b6d4 !important;
    border: 1px solid rgba(6, 182, 212, 0.3) !important;
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.15), inset 0 0 10px rgba(6, 182, 212, 0.05);
}

.calendar-dot.cal-leave {
    background: #06b6d4 !important;
    box-shadow: 0 0 8px #06b6d4, 0 0 16px #06b6d4;
}

/* Modal Popup Size & Responsiveness Improvements - Symmetrical Version */
.calendar-modal-content {
    width: 95% !important;
    max-width: 580px !important;
    /* Narrower to match square grid footprint */
    max-height: 92vh !important;
    overflow-y: auto;
    padding: clamp(12px, 2vw, 24px) !important;
    border-radius: 16px !important;
    margin: 5px auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* Center all child elements */
}

@media (min-width: 1200px) {
    .calendar-modal-content {
        max-width: 550px !important;
        padding: 24px !important;
    }
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    /* Balanced gap */
    margin-top: 10px;
    width: 100%;
    /* Ensure it spans the modal width */
}

.calendar-day {
    aspect-ratio: 1 / 1;
    /* Perfect symmetry */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: clamp(0.75rem, 1.8vw, 0.95rem);
    font-weight: 700;
    border-radius: clamp(4px, 1vw, 10px);
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
}

/* Fix for small screens */
@media (max-width: 480px) {
    .calendar-grid {
        gap: 4px;
    }

    .calendar-day {
        font-size: 0.8rem;
    }
}

/* ========== Attendance Predictions Styles ========== */

.predictions-table {
    font-size: 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    overflow: hidden;
}

.predictions-table thead tr {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: white;
}

.predictions-table thead th {
    padding: 16px 12px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.5px;
}

.predictions-table tbody tr {
    transition: background-color 0.2s ease;
}

.predictions-table tbody tr:hover {
    background-color: var(--gray-50);
}

.predictions-table tbody td {
    padding: 16px 12px;
    vertical-align: middle;
}

/* Performance ring animation */
.predictions-table circle {
    transition: stroke-dashoffset 0.6s ease;
}

/* Responsive table */
@media (max-width: 1200px) {
    .predictions-table {
        font-size: 12px;
    }

    .predictions-table thead th,
    .predictions-table tbody td {
        padding: 12px 8px;
    }
}

/* ========== Intelligence Hub Card Styles ========== */

.intelligence-hub-card {
    grid-column: span 2;
    background: linear-gradient(135deg, #e9d5ff 0%, #ddd6fe 50%, #c4b5fd 100%) !important;
    border: 1px solid rgba(168, 85, 247, 0.2) !important;
    padding: 24px !important;
    cursor: default !important;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.intelligence-hub-content-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    flex: 1;
}

.intelligence-hub-card::before {
    content: "";
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.intelligence-hub-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.intelligence-hub-title-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.intelligence-hub-icon {
    font-size: 20px;
}

.intelligence-hub-title {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    color: #6b21a8;
    text-transform: uppercase;
}

.intelligence-hub-trend-badge {
    font-size: 10px;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 20px;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.intelligence-hub-trend-badge.down {
    background-color: #fee2e2;
    color: #991b1b;
}

.intelligence-hub-trend-badge.up {
    background-color: #dcfce7;
    color: #166534;
}

.intelligence-hub-trend-badge.stable {
    background-color: #f3f4f6;
    color: #4b5563;
}

.intelligence-hub-main {
    flex: 1.5;
    text-align: left;
    margin: 0;
    display: flex;
    flex-direction: column;
}

.intelligence-hub-percentage {
    font-size: 64px;
    font-weight: 800;
    color: #581c87;
    line-height: 1;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.intelligence-hub-subtitle {
    font-size: 16px;
    font-weight: 600;
    color: #7c3aed;
    opacity: 0.9;
}

.intelligence-hub-stats-v2 {
    flex: 2;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 16px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 16px;
    backdrop-filter: blur(5px);
}

.intelligence-hub-confidence {
    text-align: left;
    font-size: 14px;
    color: #6b21a8;
    margin-bottom: 0;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.intelligence-hub-confidence span span {
    font-weight: 800;
    font-size: 16px;
}

.intelligence-hub-actions {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}

/* Predictive Analysis Modal Styles */
.predictive-modal-content {
    background-color: #fff;
    margin: 3% auto;
    padding: 30px;
    border: none;
    width: 90%;
    max-width: 600px;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
}

.predictive-modal {
    background: #ffffff;
    border-radius: 24px;
    padding: 0;
    width: 800px;
    /* Increased to 800px for a more spacious feel */
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    position: relative;
    color: #1f2937;
    overflow: hidden;
    /* Added to ensure border-radius clips children */
}

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

.predictive-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 700;
}

.forecast-day-label {
    font-size: 14px;
    color: #6b7280;
}

.main-forecast-card {
    background: #f3f0ff;
    border-radius: 20px;
    padding: 40px 20px;
    text-align: center;
    margin-bottom: 24px;
}

.main-forecast-value {
    font-size: 64px;
    font-weight: 800;
    color: #8b5cf6;
    line-height: 1;
    margin-bottom: 8px;
}

.main-forecast-caption {
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.main-forecast-subtext {
    margin-top: 16px;
    font-size: 15px;
    font-weight: 600;
    color: #374151;
}

.activity-chart-header {
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
}

.activity-bars {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    height: 100px;
    padding: 0 20px;
    margin-bottom: 8px;
    gap: 8px;
}

.activity-bar-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
}

.activity-bar {
    width: 100%;
    max-width: 35px;
    background: #e5e7eb;
    border-radius: 6px;
    transition: height 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.activity-bar.next-bar {
    background: #8b5cf6;
}

.activity-bar-value {
    position: absolute;
    top: -22px;
    width: 100%;
    text-align: center;
    font-size: 11px;
    font-weight: 700;
    color: #4b5563;
}

.activity-bar.next-bar .activity-bar-value {
    color: #8b5cf6;
}

.activity-days {
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    margin-bottom: 24px;
    gap: 8px;
}

.activity-day {
    flex: 1;
    text-align: center;
    font-size: 11px;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
}

.activity-day.next-day {
    color: #6b7280;
}

.metric-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 24px;
}

.metric-card {
    background: #fff;
    border: 1px solid #f3f4f6;
    border-radius: 16px;
    padding: 16px;
}

.metric-card-title {
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    margin-bottom: 8px;
}

.metric-card-value {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 18px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 4px;
}

.metric-card-caption {
    font-size: 11px;
    color: #9ca3af;
}

.insight-banner {
    background: #fffbeb;
    border: 1px solid #fef3c7;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 24px;
}

.insight-text {
    font-size: 13px;
    color: #92400e;
    line-height: 1.5;
}

.insight-footer {
    margin-top: 8px;
    font-size: 12px;
    color: #b45309;
}

.predictive-understood-btn {
    width: 100%;
    padding: 16px;
    background: #2563eb;
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.predictive-understood-btn:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
}

/* Global Tooltip Styles */
.info-tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.tooltip-content {
    visibility: hidden;
    width: 220px;
    background-color: rgba(31, 41, 55, 0.95);
    color: #fff;
    text-align: center;
    border-radius: 8px;
    padding: 10px;
    position: absolute;
    z-index: 1000;
    bottom: 150%;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 12px;
    font-weight: 500;
    line-height: 1.4;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    pointer-events: none;
}

.tooltip-content::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: rgba(31, 41, 55, 0.95) transparent transparent transparent;
}

.info-tooltip:hover .tooltip-content {
    visibility: visible;
    opacity: 1;
    bottom: 125%;
}

.info-icon {
    font-size: 10px;
    font-weight: bold;
}

.intelligence-hub-btn {
    flex: 1;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 8px;
    padding: 10px 16px;
    font-size: 13px;
    font-weight: 600;
    color: #6b21a8;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.intelligence-hub-btn:hover {
    background: rgba(255, 255, 255, 1);
    border-color: rgba(139, 92, 246, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(139, 92, 246, 0.2);
}

.intelligence-hub-btn .btn-icon {
    font-size: 14px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .intelligence-hub-percentage {
        font-size: 36px;
    }

    .intelligence-hub-actions {
        flex-direction: column;
    }
}

/* --- Phase 12: Global Mobile Responsiveness --- */
@media (max-width: 768px) {

    /* 1. Dashboard & Action Grids (Single Column) */
    .stats-grid,
    .actions-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    /* 2. Intelligence Hub Mobile Stack */
    .intelligence-hub-card {
        height: auto !important;
        grid-column: auto !important;
    }

    .intelligence-hub-content-row {
        flex-direction: column !important;
        align-items: flex-start !important;
    }

    .intelligence-hub-main {
        width: 100% !important;
        border-right: none !important;
        border-bottom: 1px solid rgba(226, 232, 240, 0.6);
        padding-bottom: 16px !important;
        margin-bottom: 16px !important;
    }

    .intelligence-hub-stats-v2 {
        width: 100% !important;
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    .intelligence-hub-actions {
        flex-direction: column !important;
        width: 100% !important;
    }

    /* 3. Birthday Modal Mobile Stack */
    #birthdayCalendarModal .birthday-modal-content {
        max-width: 95% !important;
        width: 95% !important;
        height: auto !important;
        max-height: 85vh !important;
        margin: 20px auto !important;
        overflow-y: auto !important;
        display: flex !important;
        flex-direction: column !important;
    }

    #birthdayCalendarModal .premium-calendar-wrap {
        height: auto !important;
        flex-direction: column !important;
        overflow: visible !important;
    }

    .calendar-main-split {
        grid-template-columns: 1fr !important;
        height: auto !important;
        overflow: visible !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .premium-side-panel {
        width: 100% !important;
        border-left: none !important;
        border-top: 1px solid rgba(226, 232, 240, 0.4);
        padding: 20px !important;
        gap: 16px !important;
    }

    .clean-calendar-panel {
        padding: 12px !important;
        max-height: 400px;
        /* Limit calendar height on mobile */
        overflow-y: auto;
    }

    /* 4. General Global Polish */
    .modal-content {
        width: 95% !important;
        margin: 10px auto !important;
        padding: 20px !important;
    }

    .btn,
    button {
        min-height: 48px;
        /* Larger touch targets */
    }

    /* 5. Pending Requests Modal Header */
    .premium-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 16px !important;
    }

    .header-title {
        width: 100%;
    }

    .premium-header>div:last-child {
        width: 100%;
        flex-wrap: wrap;
        justify-content: space-between;
    }
}

/* Export Modal Improvements */
#exportModal .modal-content {
    max-width: 500px;
    padding: 32px;
}

#exportModal .form-group {
    margin-bottom: 20px;
    text-align: left;
}

#exportModal .form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--gray-700);
    font-size: 0.95rem;
}

#exportModal .export-options-grid {
    display: grid;
    grid-template-columns: auto 1fr 1fr;
    gap: 16px;
    align-items: end;
}

#exportModal .export-checkbox-wrapper {
    display: flex;
    align-items: center;
    height: 48px;
    /* Match input height approx */
    padding-top: 28px;
    /* Offset for labels */
}

#exportModal .export-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    color: var(--gray-700);
    cursor: pointer;
    margin: 0;
}

#exportModal input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary-color);
    cursor: pointer;
}

/* Task Due Date Coloring */
.task-card-safe {
    border-left: 4px solid #10b981 !important;
    /* Green */
    background: linear-gradient(to right, #f0fdf4, #ffffff) !important;
}

.task-card-warning {
    border-left: 4px solid #f59e0b !important;
    /* Amber */
    background: linear-gradient(to right, #fffbeb, #ffffff) !important;
}

.task-card-urgent {
    border-left: 4px solid #ef4444 !important;
    /* Red */
    background: linear-gradient(to right, #fef2f2, #ffffff) !important;
}

.task-card-overdue {
    border-left: 4px solid #b91c1c !important;
    /* Dark Red */
    background: linear-gradient(to right, #fef2f2, #fff1f2) !important;
}

.due-tomorrow-badge {
    background-color: #ef4444;
    color: white;
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: bold;
    margin-left: 8px;
    display: inline-block;
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
    }

    70% {
        box-shadow: 0 0 0 6px rgba(239, 68, 68, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
    }
}

/* Multi-Select & Teams UI */
.multi-select-container {
    position: relative;
    width: 100%;
}

.multi-select-display {
    min-height: 42px;
    padding: 8px 12px;
    background: #fff;
    border: 1px solid var(--gray-300);
    border-radius: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    cursor: pointer;
    align-items: center;
}

.multi-select-dropdown {
    position: static;
    /* Force parent to expand */
    width: 100%;
    max-height: 400px;
    overflow-y: auto;
    background: #fff;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    margin-top: 8px;
    display: none;
    box-shadow: none;
}

.multi-select-dropdown.show {
    display: block;
}

.multi-select-item {
    padding: 12px 16px;
    /* Increased padding */
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: all 0.2s;
    border-bottom: 1px solid #f8fafc;
}

.multi-select-item:hover {
    background: var(--gray-50);
}

.multi-select-item span {
    font-size: 0.95rem;
    /* Slightly larger font */
    color: #1e293b;
    font-weight: 500;
}

.multi-select-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.selected-tag {
    background: var(--blue-50);
    color: var(--blue-600);
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
    border: 1px solid var(--blue-100);
}

.tag-remove {
    cursor: pointer;
    font-size: 1.1rem;
    line-height: 1;
}

.tag-remove:hover {
    color: var(--blue-800);
}

.team-action-row {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
    align-items: center;
}

.team-badge {
    background: #f0f9ff;
    color: #0369a1;
    border: 1px solid #bae6fd;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
}

.team-info-box {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.badge-success {
    background: #ecfdf5;
    color: #059669;
    border: 1px solid #a7f3d0;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
}

.hidden {
    display: none !important;
}

/* Drawer Modal Styles */
.drawer-modal {
    position: fixed;
    top: 0;
    right: -600px;
    width: 550px;
    height: 100vh;
    background: #ffffff;
    z-index: 2000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
}

.drawer-modal.active {
    right: 0;
}

.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.drawer-header {
    padding: 24px 32px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    position: sticky;
    top: 0;
    z-index: 10;
}

.drawer-header h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 12px;
}

.drawer-body {
    padding: 32px;
    flex: 1;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #e2e8f0 transparent;
}

.drawer-body::-webkit-scrollbar {
    width: 6px;
}

.drawer-body::-webkit-scrollbar-track {
    background: transparent;
}

.drawer-body::-webkit-scrollbar-thumb {
    background-color: #e2e8f0;
    border-radius: 20px;
}

.drawer-footer {
    padding: 24px 32px;
    border-top: 1px solid #f1f5f9;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    background: #f8fafc;
}

.drawer-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 24px;
}

.drawer-form-group {
    margin-bottom: 24px;
}

.drawer-form-group:last-child {
    margin-bottom: 0;
}

.drawer-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 8px;
}

/* Responsive Drawer */
@media (max-width: 640px) {
    .drawer-modal {
        width: 100%;
        right: -100%;
    }

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

/* Premium Modal Redesign */
.premium-modal-container {
    position: fixed;
    inset: 0;
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    padding: 20px;
}

.premium-modal-container.active {
    display: flex;
}

.premium-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(8px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.premium-modal-container.active .premium-modal-backdrop {
    opacity: 1;
}

.premium-modal-content {
    position: relative;
    background: #ffffff;
    width: 100%;
    max-width: 850px;
    max-height: 90vh;
    border-radius: 28px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: scale(0.95);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.premium-modal-container.active .premium-modal-content {
    transform: scale(1);
    opacity: 1;
}

.premium-modal-header {
    padding: 24px 32px;
    background: #fff;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.premium-modal-header h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.025em;
}

.premium-modal-body {
    padding: 32px;
    overflow-y: auto;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: #e2e8f0 transparent;
}

.premium-modal-body::-webkit-scrollbar {
    width: 6px;
}

.premium-modal-body::-webkit-scrollbar-thumb {
    background: #e2e8f0;
    border-radius: 10px;
}

.premium-modal-footer {
    padding: 24px 32px;
    background: #f8fafc;
    border-top: 1px solid #f1f5f9;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.premium-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.premium-field-group {
    margin-bottom: 24px;
}

.premium-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #475569;
    margin-bottom: 8px;
    padding-left: 4px;
}

.premium-input-wrapper {
    position: relative;
}

.premium-card-section {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    padding: 20px;
}

@media (max-width: 768px) {
    .premium-grid {
        grid-template-columns: 1fr;
    }
}