/* ============================================
   Attendance Dashboard Styles
   ============================================ */

/* CSS Variables */
:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --secondary-color: #64748b;
    --success-color: #22c55e;
    --success-bg: #dcfce7;
    --warning-color: #f59e0b;
    --warning-bg: #fef3c7;
    --danger-color: #ef4444;
    --danger-bg: #fee2e2;
    --info-color: #3b82f6;

    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;

    --bg-primary: #f8fafc;
    --bg-secondary: #f1f5f9;
    --bg-white: #ffffff;

    --border-color: #e2e8f0;
    --border-radius: 8px;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);

    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    --navbar-height: 60px;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
}

body {
    font-family: var(--font-family);
    font-size: 14px;
    line-height: 1.5;
    color: var(--text-primary);
    background-color: var(--bg-primary);
}

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

/* ============================================
   Login Page
   ============================================ */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px;
}

.login-card {
    background: var(--bg-white);
    padding: 40px;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 400px;
}

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

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

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

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--text-primary);
}

.form-group input {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

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

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background: var(--primary-hover);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--border-color);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-outline:hover:not(:disabled) {
    background: var(--bg-secondary);
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 18px;
    color: var(--text-secondary);
    padding: 4px 8px;
}

.btn-icon:hover {
    color: var(--danger-color);
}

/* Messages */
.error-message {
    background: var(--danger-bg);
    color: var(--danger-color);
    padding: 12px;
    border-radius: var(--border-radius);
    margin-bottom: 16px;
    font-size: 13px;
}

.success-message {
    background: var(--success-bg);
    color: var(--success-color);
    padding: 12px;
    border-radius: var(--border-radius);
    margin-bottom: 16px;
    font-size: 13px;
}

/* ============================================
   Navbar
   ============================================ */
.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--navbar-height);
    padding: 0 24px;
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-brand h1 {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary-color);
}

.navbar-menu {
    display: flex;
    gap: 8px;
}

.nav-link {
    padding: 8px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: all 0.2s;
}

.nav-link:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.nav-link.active {
    background: var(--primary-color);
    color: white;
}

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

.navbar-user span {
    color: var(--text-secondary);
    font-size: 13px;
}

/* Settings Dropdown */
.settings-dropdown {
    position: relative;
    display: inline-block;
}

.btn-icon {
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: all 0.2s ease;
}

.btn-icon:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--primary-color);
}

.settings-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    min-width: 160px;
    z-index: 1000;
    overflow: hidden;
}

.settings-item {
    display: block;
    padding: 12px 16px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 14px;
    transition: background 0.2s ease;
}

.settings-item:hover {
    background: var(--bg-secondary);
    color: var(--primary-color);
}

.settings-divider {
    height: 1px;
    background: var(--border-color);
    margin: 4px 0;
}

/* ============================================
   Views
   ============================================ */
.view {
    padding: 24px;
    max-width: 1400px;
    margin: 0 auto;
}

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

.view-header h2 {
    font-size: 24px;
    font-weight: 600;
}

.view-header-left {
    display: flex;
    align-items: center;
    gap: 24px;
}

/* Date Filter */
.date-filter {
    display: flex;
    align-items: center;
    gap: 8px;
}

.date-filter label {
    font-size: 13px;
    color: var(--text-secondary);
}

.date-filter input[type="date"] {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 13px;
}

/* Filters */
.filters {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.filters input,
.filters select {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 13px;
    min-width: 150px;
}

.filters input:focus,
.filters select:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* ============================================
   Cards
   ============================================ */
.card {
    background: var(--bg-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    padding: 20px;
    margin-bottom: 20px;
}

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

.card-header h4 {
    font-size: 16px;
    font-weight: 600;
}

/* Summary Cards */
.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.summary-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px;
}

.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    background: var(--bg-secondary);
}

.summary-card .card-content h3 {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 4px;
}

.summary-card .card-content p {
    color: var(--text-secondary);
    font-size: 13px;
}

.card-success {
    border-left: 4px solid var(--success-color);
}

.card-success .card-icon {
    background: var(--success-bg);
    color: var(--success-color);
}

.card-warning {
    border-left: 4px solid var(--warning-color);
}

.card-warning .card-icon {
    background: var(--warning-bg);
    color: var(--warning-color);
}

.card-danger {
    border-left: 4px solid var(--danger-color);
}

.card-danger .card-icon {
    background: var(--danger-bg);
    color: var(--danger-color);
}

/* Icons (using text for simplicity) */
.icon-users::before { content: "👥"; }
.icon-check::before { content: "✓"; }
.icon-clock::before { content: "⏰"; }
.icon-x::before { content: "✗"; }

/* Stats */
.stats-row {
    margin-bottom: 24px;
}

.stats-card h4 {
    margin-bottom: 16px;
    font-size: 16px;
    font-weight: 600;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 24px;
}

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

.stat-value {
    display: block;
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 4px;
}

.stat-label {
    font-size: 13px;
    color: var(--text-secondary);
}

/* ============================================
   Tables
   ============================================ */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.data-table th {
    background: var(--bg-secondary);
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

.data-table tbody tr:hover {
    background: var(--bg-secondary);
}

.data-table td.loading {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

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

.status-green {
    background: var(--success-bg);
    color: #166534;
}

.status-yellow {
    background: #fef9c3;
    color: #854d0e;
}

.status-orange {
    background: #ffedd5;
    color: #9a3412;
}

.status-red {
    background: var(--danger-bg);
    color: #991b1b;
}

/* Status LED (colored dot) */
.status-led {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.2);
}

.status-led.status-green {
    background: #22c55e;
    box-shadow: 0 0 6px rgba(34, 197, 94, 0.5);
}

.status-led.status-yellow {
    background: #eab308;
    box-shadow: 0 0 6px rgba(234, 179, 8, 0.5);
}

.status-led.status-orange {
    background: #f97316;
    box-shadow: 0 0 6px rgba(249, 115, 22, 0.5);
}

.status-led.status-red {
    background: #ef4444;
    box-shadow: 0 0 6px rgba(239, 68, 68, 0.5);
}

/* Attendance Type Badges */
.type-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.type-complete {
    background: var(--success-bg);
    color: #166534;
}

.type-half-day {
    background: var(--warning-bg);
    color: #92400e;
}

.type-absent {
    background: var(--danger-bg);
    color: #991b1b;
}

.type-incomplete {
    background: #e0e7ff;
    color: #3730a3;
}

/* ============================================
   Alerts Section
   ============================================ */
#alerts-container {
    max-height: 300px;
    overflow-y: auto;
}

.alert-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    border-bottom: 1px solid var(--border-color);
}

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

.alert-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

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

.alert-detail {
    font-size: 13px;
    color: var(--text-secondary);
}

.no-alerts {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

/* ============================================
   Sortable Table Headers
   ============================================ */
.sortable {
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
}

.sortable:hover {
    background-color: var(--bg-secondary);
}

.sort-arrow {
    display: inline-block;
    margin-left: 6px;
    width: 0;
    height: 0;
    vertical-align: middle;
}

.sort-arrow.asc {
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-bottom: 6px solid var(--primary-color);
}

.sort-arrow.desc {
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid var(--primary-color);
}

/* ============================================
   Pagination
   ============================================ */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border-top: 1px solid var(--border-color);
}

.pagination span {
    color: var(--text-secondary);
    font-size: 14px;
}

/* ============================================
   Import Section
   ============================================ */
.import-section {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

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

.upload-card h4 {
    margin-bottom: 8px;
}

.upload-card .upload-area {
    max-width: 500px;
    margin: 0 auto;
}

.upload-info {
    color: var(--text-secondary);
    font-size: 13px;
    margin-bottom: 24px;
}

.upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--border-radius);
    padding: 48px 24px;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 16px;
}

.upload-area:hover,
.upload-area.dragover {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.05);
}

.upload-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.upload-area p {
    color: var(--text-secondary);
}

.file-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    margin-bottom: 16px;
}

#file-name {
    font-weight: 500;
}

/* ============================================
   Modal
   ============================================ */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.modal-content {
    position: relative;
    background: var(--bg-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 0;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
}

/* Employee Detail in Modal */
.employee-detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.detail-item {
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
}

.detail-label {
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    margin-bottom: 4px;
}

.detail-value {
    font-size: 18px;
    font-weight: 600;
}

.attendance-history h4 {
    margin-bottom: 16px;
}

/* ============================================
   Loading State
   ============================================ */
.loading {
    color: var(--text-secondary);
    font-style: italic;
}

.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
    .navbar {
        flex-wrap: wrap;
        height: auto;
        padding: 12px;
    }

    .navbar-menu {
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 12px;
        flex-wrap: wrap;
    }

    .view-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .filters {
        width: 100%;
    }

    .filters input,
    .filters select {
        flex: 1;
        min-width: 0;
    }

    .summary-cards {
        grid-template-columns: 1fr 1fr;
    }

    .data-table {
        font-size: 13px;
    }

    .data-table th,
    .data-table td {
        padding: 8px;
    }
}

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

    .nav-link {
        padding: 6px 12px;
        font-size: 13px;
    }
}

/* ============================================
   Work Calendar
   ============================================ */
.calendar-card {
    margin-top: 24px;
}

.calendar-card .card-header {
    flex-wrap: wrap;
    gap: 12px;
}

.calendar-card .card-header h4 {
    margin: 0;
}

.calendar-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.calendar-controls select {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 13px;
    min-width: 150px;
}

.calendar-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.calendar-nav button {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 6px 12px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.calendar-nav button:hover {
    background: var(--border-color);
}

.calendar-nav .month-year {
    font-weight: 600;
    min-width: 140px;
    text-align: center;
}

/* Calendar Grid */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    margin-bottom: 16px;
}

.calendar-day-header {
    padding: 8px 4px;
    text-align: center;
    font-weight: 600;
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.calendar-day {
    padding: 8px;
    text-align: center;
    cursor: pointer;
    border-radius: var(--border-radius);
    min-height: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    border: 2px solid transparent;
    background: var(--bg-secondary);
}

.calendar-day:hover {
    opacity: 0.8;
    transform: scale(1.02);
}

.calendar-day.other-month {
    opacity: 0.4;
    cursor: default;
}

.calendar-day.other-month:hover {
    transform: none;
}

/* Today highlight disabled */

.calendar-day .day-number {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}

.calendar-day .shift-label {
    font-size: 10px;
    text-transform: uppercase;
    font-weight: 500;
}

/* Work Day States */
.calendar-day.work-day.full-day {
    background: var(--success-bg);
    border-color: var(--success-color);
}

.calendar-day.work-day.full-day .shift-label {
    color: #166534;
}

.calendar-day.work-day.half-day {
    background: var(--warning-bg);
    border-color: var(--warning-color);
}

.calendar-day.work-day.half-day .shift-label {
    color: #92400e;
}

.calendar-day.no-work {
    background: var(--bg-secondary);
    border-color: transparent;
}

.calendar-day.no-work .shift-label {
    color: var(--text-muted);
}

/* Overtime Shifts */
.calendar-day.work-day.overtime-only {
    background: #ede9fe;
    border-color: #8b5cf6;
}

.calendar-day.work-day.overtime-only .shift-label {
    color: #6d28d9;
}

.calendar-day.work-day.has-overtime {
    background: linear-gradient(135deg, var(--success-bg) 65%, #c4b5fd 65%);
    border-color: var(--success-color);
    border-right-color: #8b5cf6;
    border-bottom-color: #8b5cf6;
}

.calendar-day.work-day.has-overtime .shift-label {
    color: #166534;
    font-size: 9px;
}

.calendar-day.work-day.half-day.has-overtime {
    background: linear-gradient(135deg, var(--warning-bg) 65%, #c4b5fd 65%);
    border-color: var(--warning-color);
    border-right-color: #8b5cf6;
    border-bottom-color: #8b5cf6;
}

.calendar-day.work-day.half-day.has-overtime .shift-label {
    color: #92400e;
    font-size: 9px;
}

/* Calendar Legend */
.calendar-legend {
    display: flex;
    gap: 24px;
    justify-content: center;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-secondary);
}

.legend-dot {
    width: 16px;
    height: 16px;
    border-radius: 4px;
}

.legend-dot.full-day {
    background: var(--success-bg);
    border: 2px solid var(--success-color);
}

.legend-dot.half-day {
    background: var(--warning-bg);
    border: 2px solid var(--warning-color);
}

.legend-dot.overtime {
    background: #ede9fe;
    border: 2px solid #8b5cf6;
}

.legend-dot.no-work {
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
}

/* Shift Type Selector Modal */
.shift-selector {
    padding: 16px;
}

.shift-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

.shift-option {
    display: flex;
    align-items: center;
    padding: 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s;
}

.shift-option:hover {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.05);
}

.shift-option.selected {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.1);
}

.shift-option input[type="radio"] {
    margin-right: 12px;
}

.shift-option-info {
    flex: 1;
}

.shift-option-name {
    font-weight: 600;
    margin-bottom: 4px;
}

.shift-option-times {
    font-size: 13px;
    color: var(--text-secondary);
}

.shift-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* Calendar Responsive */
@media (max-width: 768px) {
    .calendar-controls {
        flex-wrap: wrap;
        width: 100%;
    }

    .calendar-controls select {
        width: 100%;
    }

    .calendar-day {
        min-height: 50px;
        padding: 4px;
    }

    .calendar-day .day-number {
        font-size: 14px;
    }

    .calendar-day .shift-label {
        font-size: 8px;
    }

    .calendar-legend {
        flex-wrap: wrap;
        gap: 12px;
    }
}

@media (max-width: 480px) {
    .calendar-day-header {
        font-size: 10px;
        padding: 4px;
    }

    .calendar-day {
        min-height: 40px;
    }

    .calendar-day .shift-label {
        display: none;
    }
}

/* ============================================
   Jornadas (Shift Types) Management
   ============================================ */
.jornadas-section {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Form Row - Two columns */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 480px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* Form Actions */
.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

/* Checkbox Label */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: normal;
}

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

/* Textarea */
textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.2s, box-shadow 0.2s;
}

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

/* Status Active/Inactive Badges */
.status-active {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    background: var(--success-bg);
    color: #166534;
}

.status-inactive {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    background: var(--bg-secondary);
    color: var(--text-secondary);
}

/* Default Badge */
.badge-default {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    background: var(--primary-color);
    color: white;
}

/* Overtime Badge */
.badge-overtime {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    background: #8b5cf6;
    color: white;
}

/* Normal Shift Badge */
.badge-normal {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    background: #22c55e;
    color: white;
}

/* Action Buttons in Tables */
.action-buttons {
    display: flex;
    gap: 8px;
}

.btn-edit {
    background: var(--info-color);
    color: white;
    padding: 6px 12px;
    font-size: 12px;
}

.btn-edit:hover {
    background: #2563eb;
}

.btn-deactivate {
    background: var(--warning-color);
    color: white;
    padding: 6px 12px;
    font-size: 12px;
}

.btn-deactivate:hover {
    background: #d97706;
}

.btn-activate {
    background: var(--success-color);
    color: white;
    padding: 6px 12px;
    font-size: 12px;
}

.btn-activate:hover {
    background: #16a34a;
}

.btn-danger {
    background: #ef4444;
    color: white;
    padding: 6px 12px;
    font-size: 12px;
}

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

.btn-members {
    background: var(--secondary-color);
    color: white;
    padding: 6px 12px;
    font-size: 12px;
}

.btn-members:hover {
    background: #475569;
}

/* Members List */
.members-list {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    margin-bottom: 24px;
}

.member-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
}

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

.member-info {
    display: flex;
    flex-direction: column;
}

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

.member-id {
    font-size: 12px;
    color: var(--text-secondary);
}

.btn-remove-member {
    background: var(--danger-color);
    color: white;
    padding: 4px 10px;
    font-size: 11px;
}

.btn-remove-member:hover {
    background: #dc2626;
}

/* Add Member Section */
.add-member-section {
    border-top: 1px solid var(--border-color);
    padding-top: 16px;
}

.add-member-section h4 {
    margin-bottom: 12px;
}

.add-member-controls {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.add-member-controls select {
    flex: 1;
    min-height: 150px;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
}

/* Small form text */
small {
    display: block;
    margin-top: 4px;
    font-size: 12px;
}

/* Time Display in Tables */
.time-range {
    white-space: nowrap;
    font-family: monospace;
    font-size: 13px;
}

/* Empty State in Members List */
.members-empty {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

/* ============================================
   Calendar Multi-Select
   ============================================ */

/* Prevent text selection during drag */
.calendar-grid.selecting {
    user-select: none;
    -webkit-user-select: none;
}

/* Selected day state */
.calendar-day.selected {
    position: relative;
    box-shadow: inset 0 0 0 3px var(--primary-color) !important;
    background: rgba(37, 99, 235, 0.15) !important;
}

.calendar-day.selected::after {
    content: '';
    position: absolute;
    top: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    background: var(--primary-color);
    border-radius: 50%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E");
    background-size: 12px;
    background-position: center;
    background-repeat: no-repeat;
}

/* Drag hover state */
.calendar-day.drag-hover {
    background: rgba(37, 99, 235, 0.1) !important;
    box-shadow: inset 0 0 0 2px rgba(37, 99, 235, 0.5) !important;
}

/* Calendar Layout with Side Panel */
.calendar-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

.calendar-main {
    flex: 1;
    min-width: 0;
}

/* Side Panel */
.calendar-side-panel {
    width: 320px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    animation: slideIn 0.2s ease-out;
    position: sticky;
    top: 24px;
}

.calendar-side-panel.hidden {
    display: none;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.side-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
}

.side-panel-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.btn-icon {
    background: none;
    border: none;
    font-size: 20px;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    line-height: 1;
}

.btn-icon:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.side-panel-selection {
    padding: 16px 20px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.selection-count {
    background: var(--primary-color);
    color: white;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 14px;
    display: inline-block;
}

.selection-label {
    color: var(--text-secondary);
    font-size: 14px;
    margin-left: 8px;
}

.selected-dates-preview {
    margin-top: 8px;
    font-size: 13px;
    color: var(--text-secondary);
    max-height: 60px;
    overflow-y: auto;
    line-height: 1.5;
}

.side-panel-section {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
}

.side-panel-section:last-of-type {
    border-bottom: none;
}

.side-panel-section h4 {
    margin: 0 0 4px 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.section-hint {
    margin: 0 0 12px 0;
    font-size: 12px;
    color: var(--text-secondary);
}

.shift-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.shift-option {
    display: flex;
    align-items: flex-start;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s ease;
    background: var(--bg-primary);
}

.shift-option:hover {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.02);
}

.shift-option.selected {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.05);
}

.shift-option.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.shift-option.disabled:hover {
    border-color: var(--border-color);
    background: var(--bg-primary);
}

.shift-option input[type="radio"],
.shift-option input[type="checkbox"] {
    margin: 2px 10px 0 0;
    flex-shrink: 0;
}

.shift-option-content {
    flex: 1;
}

.shift-option-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.shift-option-time {
    font-size: 12px;
    color: var(--text-secondary);
}

.shift-option-indicator {
    width: 12px;
    height: 12px;
    border-radius: 3px;
    margin-left: auto;
    flex-shrink: 0;
    align-self: center;
}

.shift-option-indicator.full-day {
    background: #22c55e;
}

.shift-option-indicator.half-day {
    background: #f59e0b;
}

.shift-option-indicator.overtime {
    background: #8b5cf6;
}

.side-panel-actions {
    padding: 16px 20px;
    display: flex;
    gap: 12px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    border-radius: 0 0 var(--border-radius) var(--border-radius);
}

.side-panel-actions .btn {
    flex: 1;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 500;
}

/* Config Groups Display */
.config-groups {
    padding: 0;
}

.config-group {
    border-bottom: 1px solid var(--border-color);
    padding: 16px 20px;
}

.config-group:last-child {
    border-bottom: none;
}

.config-group-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.config-group-dates {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
}

.config-group-dates .date-count {
    font-weight: 400;
    color: var(--text-secondary);
    font-size: 12px;
}

.config-group-edit {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--primary-color);
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.config-group-edit:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.config-group-shifts {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.config-shift-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--text-secondary);
    padding: 4px 0;
}

.config-shift-tag .shift-dot {
    width: 10px;
    height: 10px;
    border-radius: 3px;
    flex-shrink: 0;
}

.config-shift-tag .shift-dot.full-day {
    background: #22c55e;
}

.config-shift-tag .shift-dot.half-day {
    background: #f59e0b;
}

.config-shift-tag .shift-dot.overtime {
    background: #8b5cf6;
}

.config-shift-tag .shift-name {
    font-weight: 500;
    color: var(--text-primary);
}

.config-shift-tag .shift-time {
    color: var(--text-secondary);
    font-size: 12px;
}

.config-no-shift {
    font-size: 13px;
    color: var(--text-secondary);
    font-style: italic;
    padding: 4px 0;
}

/* Single day view improvements */
.single-day-view {
    padding: 20px;
}

.single-day-date {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.single-day-weekday {
    font-size: 13px;
    color: var(--text-secondary);
    text-transform: capitalize;
    margin-bottom: 16px;
}

.single-day-config {
    margin-bottom: 16px;
}

.single-day-actions {
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.single-day-actions .btn {
    width: 100%;
}

/* Helper text */
.calendar-helper-text {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 8px;
    text-align: center;
}

.calendar-helper-text kbd {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 2px 6px;
    font-family: monospace;
    font-size: 11px;
}

/* Mobile adjustments for Calendar */
@media (max-width: 1024px) {
    .calendar-layout {
        flex-direction: column;
    }

    .calendar-side-panel {
        width: 100%;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        top: auto;
        border-radius: 16px 16px 0 0;
        box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.15);
        max-height: 70vh;
        overflow-y: auto;
        z-index: 1000;
    }

    @keyframes slideIn {
        from {
            opacity: 0;
            transform: translateY(100%);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .side-panel-actions {
        border-radius: 0;
        position: sticky;
        bottom: 0;
    }
}

/* ============================================
   CSV Viewer Modal
   ============================================ */
.modal-large {
    max-width: 1200px;
    width: 95%;
    max-height: 90vh;
}

.modal-large .modal-body {
    max-height: calc(90vh - 80px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.csv-viewer-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    flex-shrink: 0;
}

.csv-filename {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-primary);
}

.csv-count {
    font-size: 13px;
    color: var(--text-secondary);
    background: var(--bg-primary);
    padding: 4px 12px;
    border-radius: 20px;
    border: 1px solid var(--border-color);
}

.csv-viewer-table-wrapper {
    flex: 1;
    max-height: 70vh;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
}

.csv-viewer-table {
    margin: 0;
}

.csv-viewer-table th {
    position: sticky;
    top: 0;
    background: var(--bg-secondary);
    z-index: 1;
}

.csv-viewer-table td {
    font-size: 13px;
}

.csv-viewer-table .employee-id {
    font-family: monospace;
    font-weight: 500;
}

.csv-viewer-table .datetime-cell {
    white-space: nowrap;
    font-family: monospace;
}

/* Clickable filename in history table */
.file-link {
    color: var(--primary-color);
    cursor: pointer;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

.file-link:hover {
    text-decoration: underline;
    color: #1d4ed8;
}

/* ============================================
   Nomina (Payroll) View Styles
   ============================================ */

.nomina-summary {
    display: flex;
    gap: 24px;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    margin-bottom: 16px;
}

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

.nomina-summary .summary-label {
    color: var(--text-secondary);
    font-weight: 500;
}

.nomina-summary .summary-value {
    color: var(--text-primary);
    font-weight: 600;
}

.export-buttons {
    display: flex;
    gap: 8px;
}

/* Number columns in nomina table */
#nomina-table td.number {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

/* Highlight cells with issues */
#nomina-table td.highlight-red {
    background: var(--danger-bg);
    color: var(--danger-color);
    font-weight: 600;
}

#nomina-table td.highlight-orange {
    background: #fff7ed;
    color: #ea580c;
    font-weight: 600;
}

#nomina-table td.highlight-yellow {
    background: var(--warning-bg);
    color: #b45309;
    font-weight: 600;
}

#nomina-table td.highlight-purple {
    background: #f3e8ff;
    color: #7c3aed;
    font-weight: 600;
}

/* ============================================
   Test CSV Generator Styles
   ============================================ */

.test-generator-form {
    padding: 16px;
}

.test-generator-form .form-help-text {
    color: var(--text-secondary);
    font-size: 13px;
    margin-bottom: 16px;
}

.test-generator-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

/* ============================================
   Calendar Scope Selector Styles
   ============================================ */

.calendar-scope-selector {
    display: flex;
    align-items: center;
    gap: 12px;
}

.calendar-scope-selector label {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
}

.scope-select {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
    background: var(--bg-white);
    min-width: 150px;
}

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

.scope-indicator {
    font-size: 13px;
    color: var(--primary-color);
    font-weight: 600;
    background: rgba(37, 99, 235, 0.1);
    padding: 6px 12px;
    border-radius: 16px;
}

.scope-indicator:empty {
    display: none;
}

/* ============================================
   Nomina Detail Modal Styles
   ============================================ */

/* Clickable rows in nomina table */
#nomina-table .clickable-row {
    cursor: pointer;
    transition: background-color 0.15s;
}

#nomina-table .clickable-row:hover {
    background-color: var(--bg-secondary);
}

.clickable {
    cursor: pointer;
}

/* Detail summary in modal */
.nomina-detail-summary {
    margin-bottom: 24px;
}

.detail-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-label {
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-value {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

/* Detail sections */
.nomina-detail-sections {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.detail-section {
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.detail-section h4 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
    font-weight: 600;
}

.section-icon {
    font-size: 16px;
}

.section-count {
    font-weight: 400;
    color: var(--text-secondary);
    margin-left: auto;
}

.detail-table-wrapper {
    max-height: 200px;
    overflow-y: auto;
}

.detail-table {
    margin: 0;
}

.detail-table th,
.detail-table td {
    padding: 8px 12px;
    font-size: 13px;
}

.shift-code {
    font-size: 11px;
    color: var(--text-secondary);
}

/* Badges for detail modal */
.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-primary {
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary-color);
}

.badge-info {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.badge-warning {
    background: var(--warning-bg);
    color: #b45309;
}

.badge-danger {
    background: var(--danger-bg);
    color: var(--danger-color);
}

.badge-muted {
    background: var(--bg-secondary);
    color: var(--text-muted);
}

.badge-manual {
    background: rgba(139, 92, 246, 0.1);
    color: #7c3aed;
}

.badge-csv {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
}

/* Edit attendance button */
.btn-edit-attendance {
    padding: 4px 8px;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.2s;
}

.btn-edit-attendance:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Center column content */
.col-center {
    text-align: center;
}

/* Protect checkbox styling */
.protect-checkbox {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* Edit attendance modal info section */
.edit-attendance-info {
    background: var(--bg-secondary);
    padding: 12px 16px;
    border-radius: var(--border-radius);
    margin-bottom: 16px;
}

.edit-attendance-info p {
    margin: 4px 0;
    font-size: 14px;
}

/* Hide sections when empty */
.detail-section.hidden {
    display: none;
}

/* ============================================
   Config Sidebar Styles
   ============================================ */

/* Config button in navbar */
.navbar-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s;
}

.btn-icon:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.btn-icon svg {
    flex-shrink: 0;
}

.btn-icon.btn-delete-import {
    color: var(--danger);
}

.btn-icon.btn-delete-import:hover {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.btn-icon.btn-recalculate {
    color: var(--primary);
}

.btn-icon.btn-recalculate:hover {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary);
}

/* Small spinner for buttons */
.spinner-small {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid currentColor;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.8s linear infinite;
}

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

/* Config Sidebar */
.config-sidebar {
    position: fixed;
    top: 0;
    right: -450px;
    width: 450px;
    height: 100vh;
    background: var(--bg-white);
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transition: right 0.3s ease;
}

.config-sidebar.open {
    right: 0;
}

.config-sidebar-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

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

.config-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-secondary);
}

.config-sidebar-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.config-sidebar-nav {
    padding: 12px;
    border-bottom: 1px solid var(--border-color);
}

.config-nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 6px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.15s;
}

.config-nav-link:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.config-nav-link.active {
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary-color);
}

.config-sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

/* Config Page Styles */
.config-page-header {
    margin-bottom: 24px;
}

.config-page-header h4 {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
}

.config-page-desc {
    margin: 0;
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
}

.config-form .form-section {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.config-form .form-section:last-of-type {
    border-bottom: none;
}

.config-form .form-section h5 {
    margin: 0 0 12px 0;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

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

.config-form .form-group {
    margin-bottom: 12px;
}

.config-form .form-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-primary);
    cursor: pointer;
}

.config-form input[type="date"],
.config-form select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 14px;
    margin-top: 4px;
}

.config-form input[type="date"]:focus,
.config-form select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.1);
}

.config-form .multi-select {
    width: 100%;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 13px;
    margin-top: 8px;
}

.config-form .multi-select option {
    padding: 6px 8px;
}

/* Range slider styling */
.config-form input[type="range"] {
    width: 100%;
    margin-top: 8px;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    background: var(--bg-secondary);
    border-radius: 3px;
    outline: none;
}

.config-form input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.15s;
}

.config-form input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

.range-value {
    display: inline-block;
    margin-left: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--primary-color);
    min-width: 35px;
}

.form-hint {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: var(--text-muted);
}

.form-actions {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.form-actions .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
}

/* ==========================================
   Employee Selection Cards
   ========================================== */

.employee-selection-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.selection-card {
    display: block;
    cursor: pointer;
}

.selection-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.selection-card-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-white);
    transition: all 0.2s ease;
}

.selection-card:hover .selection-card-content {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.02);
}

.selection-card input[type="radio"]:checked + .selection-card-content {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.05);
}

.selection-card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--bg-secondary);
    border-radius: 10px;
    color: var(--text-secondary);
    flex-shrink: 0;
}

.selection-card input[type="radio"]:checked + .selection-card-content .selection-card-icon {
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary-color);
}

.selection-card-text {
    flex: 1;
    min-width: 0;
}

.selection-card-title {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.selection-card-desc {
    display: block;
    font-size: 12px;
    color: var(--text-secondary);
}

.selection-card-check {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border: 2px solid var(--border-color);
    border-radius: 50%;
    color: transparent;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.selection-card input[type="radio"]:checked + .selection-card-content .selection-card-check {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Employee Checkbox List */
.employee-select-container {
    margin-top: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.employee-select-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.employee-select-count {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
}

.btn-link {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    padding: 0;
}

.btn-link:hover {
    text-decoration: underline;
}

.employee-checkbox-list {
    max-height: 200px;
    overflow-y: auto;
    padding: 8px 0;
}

.employee-checkbox-item {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    transition: background 0.15s;
}

.employee-checkbox-item:hover {
    background: var(--bg-secondary);
}

.employee-checkbox-item input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin-right: 10px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.employee-checkbox-item label {
    flex: 1;
    cursor: pointer;
    font-size: 13px;
    color: var(--text-primary);
}

.employee-checkbox-item .employee-id {
    font-size: 12px;
    color: var(--text-muted);
    margin-left: 8px;
}

/* ==========================================
   CSV Preview Section
   ========================================== */

.csv-preview-section {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 2px solid var(--primary-color);
}

.csv-preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.csv-preview-header h5 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.csv-preview-info {
    font-size: 13px;
    color: var(--text-secondary);
}

.csv-preview-table-wrapper {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    max-height: 350px;
    overflow-y: auto;
}

.csv-preview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.csv-preview-table thead {
    position: sticky;
    top: 0;
    z-index: 10;
}

.csv-preview-table th {
    background: var(--bg-secondary);
    padding: 10px 12px;
    text-align: left;
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--border-color);
}

.csv-preview-table td {
    padding: 0;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.csv-preview-table tr:last-child td {
    border-bottom: none;
}

.csv-preview-table tr:hover td {
    background: rgba(37, 99, 235, 0.02);
}

/* Editable cells */
.csv-preview-table .cell-editable {
    padding: 8px 10px;
    min-height: 36px;
    cursor: text;
    transition: background 0.15s;
}

.csv-preview-table .cell-editable:hover {
    background: var(--bg-secondary);
}

.csv-preview-table .cell-editable:focus {
    outline: none;
    background: rgba(37, 99, 235, 0.08);
    box-shadow: inset 0 0 0 2px var(--primary-color);
}

.csv-preview-table .col-actions {
    width: 40px;
    text-align: center;
}

.csv-preview-table .btn-delete-row {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 6px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.csv-preview-table .btn-delete-row:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* Preview Actions */
.csv-preview-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 16px;
}

.csv-preview-actions .btn {
    display: flex;
    align-items: center;
    gap: 6px;
}

.csv-form-actions {
    margin-bottom: 0;
}

/* ==========================================
   Generador Page Styles
   ========================================== */

.generador-layout {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 24px;
    padding: 20px;
    min-height: calc(100vh - 120px);
}

.generador-config {
    position: sticky;
    top: 20px;
    align-self: start;
}

.generador-config .card {
    margin-bottom: 0;
}

.generador-form .form-section {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.generador-form .form-section:last-of-type {
    border-bottom: none;
    margin-bottom: 16px;
}

.generador-form .form-section h5 {
    margin: 0 0 12px 0;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

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

.generador-form .form-group {
    margin-bottom: 12px;
}

.generador-form .form-group:last-child {
    margin-bottom: 0;
}

.generador-form input[type="range"] {
    width: 100%;
    margin-top: 8px;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    background: var(--bg-secondary);
    border-radius: 3px;
}

.generador-form input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

/* Preview Section */
.generador-preview .card {
    min-height: 500px;
    display: flex;
    flex-direction: column;
}

.generador-preview .card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.preview-stats {
    display: flex;
    gap: 8px;
}

.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 500;
    border-radius: 12px;
    background: var(--bg-secondary);
    color: var(--text-secondary);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: #d97706;
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: #059669;
}

/* Empty State */
.empty-state {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
    color: var(--text-secondary);
}

.empty-state-icon {
    margin-bottom: 16px;
    color: var(--border-color);
}

.empty-state h4 {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.empty-state p {
    margin: 0;
    font-size: 14px;
    max-width: 300px;
}

/* Preview Toolbar */
.preview-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    gap: 12px;
}

.preview-filters {
    display: flex;
    gap: 12px;
}

.form-select {
    padding: 6px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 13px;
    background: var(--bg-white);
    min-width: 160px;
}

.form-select:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Generador Table */
.generador-table-wrapper {
    flex: 1;
    overflow-y: auto;
    max-height: 450px;
}

.generador-table {
    font-size: 13px;
}

.generador-table th {
    position: sticky;
    top: 0;
    background: var(--bg-secondary);
    z-index: 10;
}

.generador-table .col-status {
    width: 36px;
    text-align: center;
}

.generador-table .col-actions {
    width: 50px;
    text-align: center;
}

.generador-table td {
    vertical-align: middle;
}

/* Row status indicator */
.row-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
}

.row-status-complete {
    color: #10b981;
}

.row-status-incomplete {
    color: #f59e0b;
}

/* Editable cells in table */
.generador-table .cell-edit {
    padding: 6px 8px;
    min-height: 32px;
    cursor: text;
    border-radius: 4px;
    transition: background 0.15s;
}

.generador-table .cell-edit:hover {
    background: var(--bg-secondary);
}

.generador-table .cell-edit:focus {
    outline: none;
    background: rgba(37, 99, 235, 0.08);
    box-shadow: inset 0 0 0 2px var(--primary-color);
}

/* Highlight incomplete rows */
.generador-table tr.row-incomplete {
    background: rgba(245, 158, 11, 0.05);
}

.generador-table tr.row-incomplete:hover {
    background: rgba(245, 158, 11, 0.1);
}

/* Delete button */
.btn-delete-row {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 6px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.btn-delete-row:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* Preview Actions */
.preview-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    border-top: 1px solid var(--border-color);
    background: var(--bg-white);
}

.preview-actions-left {
    font-size: 13px;
    color: var(--text-secondary);
}

.preview-actions-right {
    display: flex;
    gap: 12px;
}

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

/* Responsive */
@media (max-width: 1024px) {
    .generador-layout {
        grid-template-columns: 1fr;
    }

    .generador-config {
        position: static;
    }
}

/* ============================================
   Confirmation Modal
   ============================================ */
.confirm-modal-content {
    text-align: center;
    padding: 32px 24px;
    max-width: 400px;
}

.confirm-modal-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 32px;
}

.confirm-modal-icon.icon-info {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.confirm-modal-icon.icon-success {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.confirm-modal-icon.icon-warning {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.confirm-modal-icon.icon-danger {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

.confirm-modal-icon svg {
    width: 32px;
    height: 32px;
}

.confirm-modal-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 12px;
}

.confirm-modal-message {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0 0 24px;
    line-height: 1.5;
    white-space: pre-line;
}

.confirm-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.confirm-modal-actions .btn {
    min-width: 100px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.confirm-modal-actions .btn-cancel {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.confirm-modal-actions .btn-cancel:hover {
    background: var(--border-color);
}

.confirm-modal-actions .btn-confirm {
    border: none;
    color: white;
}

.confirm-modal-actions .btn-confirm.btn-info {
    background: #3b82f6;
}

.confirm-modal-actions .btn-confirm.btn-info:hover {
    background: #2563eb;
}

.confirm-modal-actions .btn-confirm.btn-success {
    background: #10b981;
}

.confirm-modal-actions .btn-confirm.btn-success:hover {
    background: #059669;
}

.confirm-modal-actions .btn-confirm.btn-warning {
    background: #f59e0b;
}

.confirm-modal-actions .btn-confirm.btn-warning:hover {
    background: #d97706;
}

.confirm-modal-actions .btn-confirm.btn-danger {
    background: #ef4444;
}

.confirm-modal-actions .btn-confirm.btn-danger:hover {
    background: #dc2626;
}

/* ============================================
   Guide View
   ============================================ */
.guide-container {
    max-width: 800px;
    margin: 0 auto;
}

.guide-intro {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    border-radius: 16px;
    margin-bottom: 32px;
    border: 1px solid var(--border-color);
}

.guide-intro-icon {
    width: 80px;
    height: 80px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: white;
}

.guide-intro h3 {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 12px;
}

.guide-intro p {
    font-size: 16px;
    color: var(--text-secondary);
    margin: 0;
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.6;
}

.guide-steps {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.guide-step {
    display: flex;
    gap: 20px;
    padding: 24px 0;
    border-bottom: 1px solid var(--border-color);
    position: relative;
}

.guide-step:last-child {
    border-bottom: none;
}

.step-number {
    width: 40px;
    height: 40px;
    min-width: 40px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 18px;
}

.guide-step::before {
    content: '';
    position: absolute;
    left: 19px;
    top: 64px;
    bottom: 0;
    width: 2px;
    background: var(--border-color);
}

.guide-step:last-child::before {
    display: none;
}

.step-content {
    flex: 1;
}

.step-content h4 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 8px;
}

.step-content p {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0 0 12px;
    line-height: 1.6;
}

.step-highlight {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 8px;
    color: #10b981;
    font-size: 13px;
    font-weight: 500;
    margin-top: 8px;
}

.step-highlight.highlight-primary {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

.step-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: 8px;
}

.step-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: var(--bg-primary);
    border-radius: 6px;
    font-size: 14px;
    color: var(--text-primary);
    border: 1px solid var(--primary-color);
}

.step-option.dimmed {
    opacity: 0.5;
    border-color: transparent;
}

.option-icon {
    font-size: 16px;
}

.step-list {
    margin: 12px 0;
    padding-left: 20px;
}

.step-list li {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    line-height: 1.5;
}

.step-list.numbered {
    list-style: decimal;
}

.step-tip {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 16px;
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 8px;
    color: #d97706;
    font-size: 13px;
    margin-top: 12px;
}

.step-tip svg {
    flex-shrink: 0;
    margin-top: 2px;
}

.step-action {
    margin-top: 16px;
}

.step-action .btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* FAQ Section */
.guide-faq {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 2px solid var(--border-color);
}

.guide-faq h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 24px;
}

.faq-item {
    background: var(--bg-secondary);
    border-radius: 12px;
    margin-bottom: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.faq-question {
    padding: 16px 20px;
    font-weight: 500;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.faq-question::after {
    content: '+';
    font-size: 20px;
    color: var(--text-muted);
}

.faq-answer {
    padding: 0 20px 16px;
}

.faq-answer p {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.6;
}

/* ============================================
   Mobile Responsive Styles
   ============================================ */

/* Mobile menu button - hidden on desktop */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    padding: 8px;
    margin-right: 8px;
}

/* Tablet breakpoint */
@media (max-width: 1024px) {
    .navbar-menu {
        gap: 4px;
    }

    .nav-link {
        padding: 8px 12px;
        font-size: 13px;
    }

    .view {
        padding: 16px;
    }

    .summary-cards {
        grid-template-columns: repeat(2, 1fr);
    }

    .calendar-grid {
        gap: 4px;
    }
}

/* Mobile breakpoint */
@media (max-width: 768px) {
    /* Navbar mobile styles */
    .navbar {
        flex-wrap: wrap;
        padding: 12px 16px;
        gap: 0;
    }

    .navbar-brand {
        flex: 1;
        display: flex;
        align-items: center;
    }

    .navbar-brand h1 {
        font-size: 16px;
    }

    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .navbar-menu {
        display: none;
        width: 100%;
        flex-direction: column;
        gap: 0;
        order: 3;
        padding-top: 12px;
        margin-top: 12px;
        border-top: 1px solid var(--border-color);
    }

    .navbar-menu.mobile-open {
        display: flex;
    }

    .nav-link {
        padding: 12px 0;
        border-radius: 0;
        border-bottom: 1px solid var(--border-color);
    }

    .nav-link:last-child {
        border-bottom: none;
    }

    .nav-link.active {
        background: transparent;
        color: var(--primary-color);
        font-weight: 600;
    }

    .navbar-actions {
        order: 2;
    }

    .navbar-user {
        gap: 8px;
    }

    .navbar-user span {
        display: none;
    }

    #logout-btn {
        padding: 6px 12px;
        font-size: 12px;
    }

    /* View header mobile */
    .view-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .view-header h2 {
        font-size: 20px;
    }

    /* Filters mobile */
    .filters,
    .date-filter {
        width: 100%;
        flex-wrap: wrap;
    }

    .filters select,
    .filters input,
    .date-filter input {
        flex: 1;
        min-width: 120px;
    }

    /* Summary cards mobile */
    .summary-cards {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .summary-card {
        padding: 16px;
    }

    .summary-card h3 {
        font-size: 12px;
    }

    .summary-card .value {
        font-size: 24px;
    }

    /* Tables mobile - horizontal scroll */
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 0 -16px;
        padding: 0 16px;
    }

    .data-table {
        min-width: 800px;
    }

    .data-table th,
    .data-table td {
        padding: 10px 8px;
        font-size: 12px;
        white-space: nowrap;
    }

    /* Action buttons in tables */
    .action-buttons {
        flex-wrap: nowrap;
        gap: 4px;
    }

    .action-buttons .btn {
        padding: 4px 8px;
        font-size: 11px;
    }

    /* Cards mobile */
    .card {
        padding: 16px;
        margin-bottom: 16px;
    }

    .card h3,
    .card h4 {
        font-size: 16px;
    }

    /* Modals mobile */
    .modal-content {
        width: 95%;
        max-width: none;
        margin: 16px;
        max-height: calc(100vh - 32px);
    }

    .modal-content.modal-lg {
        width: 95%;
    }

    .modal-header {
        padding: 16px;
    }

    .modal-body {
        padding: 16px;
    }

    .modal-footer {
        padding: 16px;
        flex-wrap: wrap;
        gap: 8px;
    }

    .modal-footer .btn {
        flex: 1;
        min-width: 100px;
    }

    /* Form grid mobile */
    .form-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .form-group label {
        font-size: 13px;
    }

    .form-group input,
    .form-group select {
        padding: 10px 12px;
        font-size: 14px;
    }

    /* Calendar mobile */
    .calendar-container {
        padding: 12px;
    }

    .calendar-header {
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
    }

    .calendar-nav {
        justify-content: space-between;
    }

    .calendar-grid {
        gap: 2px;
    }

    .calendar-day {
        min-height: 50px;
        padding: 4px;
        font-size: 12px;
    }

    .calendar-day-header {
        font-size: 11px;
    }

    /* Jornadas mobile */
    .shift-types-table {
        min-width: 700px;
    }

    /* Employee detail grid mobile */
    .employee-detail-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .detail-item {
        padding: 12px;
    }

    .detail-label {
        font-size: 11px;
    }

    .detail-value {
        font-size: 18px;
    }

    /* Import view mobile */
    .upload-area {
        padding: 24px 16px;
    }

    .upload-area svg {
        width: 40px;
        height: 40px;
    }

    /* Settings dropdown mobile */
    .settings-menu {
        right: -60px;
        min-width: 180px;
    }

    /* Confirmation modal mobile */
    .confirm-modal-content {
        padding: 24px 16px;
    }

    .confirm-modal-icon {
        width: 56px;
        height: 56px;
    }

    .confirm-modal-title {
        font-size: 16px;
    }

    .confirm-modal-actions {
        flex-direction: column;
    }

    .confirm-modal-actions .btn {
        width: 100%;
    }

    /* Guide mobile */
    .guide-intro {
        padding: 24px 16px;
    }

    .guide-intro-icon {
        width: 64px;
        height: 64px;
    }

    .guide-intro h3 {
        font-size: 20px;
    }

    .guide-step {
        gap: 12px;
    }

    .step-number {
        width: 32px;
        height: 32px;
        min-width: 32px;
        font-size: 14px;
    }

    .guide-step::before {
        left: 15px;
        top: 56px;
    }

    .step-content h4 {
        font-size: 16px;
    }

    /* Nomina view mobile */
    .nomina-actions {
        flex-wrap: wrap;
    }

    .nomina-actions .btn {
        flex: 1;
        min-width: 100px;
    }

    /* Historico view mobile */
    .historico-filters {
        flex-direction: column;
    }

    /* Alerts list mobile */
    .alerts-list {
        gap: 8px;
    }

    .alert-item {
        padding: 12px;
    }

    /* Generador mobile */
    .generador-layout {
        grid-template-columns: 1fr;
    }

    .generador-config {
        position: static;
    }
}

/* Small mobile breakpoint */
@media (max-width: 480px) {
    .navbar-brand h1 {
        font-size: 14px;
    }

    .summary-cards {
        grid-template-columns: 1fr;
    }

    .employee-detail-grid {
        grid-template-columns: 1fr;
    }

    .filters,
    .date-filter {
        flex-direction: column;
    }

    .filters select,
    .filters input,
    .date-filter input,
    .date-filter label {
        width: 100%;
    }

    .calendar-day {
        min-height: 40px;
        font-size: 11px;
    }

    .step-highlight {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
}

/* ============================================
   Sessions View
   ============================================ */

#sessions-view .view-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

#sessions-view .view-actions {
    display: flex;
    gap: 8px;
}

.current-session {
    background-color: rgba(37, 99, 235, 0.05);
}

.current-session td {
    border-left: 3px solid var(--primary-color);
}

.badge-sm {
    font-size: 10px;
    padding: 2px 6px;
    margin-left: 6px;
}

.badge-secondary {
    background: var(--bg-secondary);
    color: var(--text-secondary);
}

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

#sessions-table .username {
    font-weight: 500;
}
