/* Jeb Stuart Rescue Squad Shift Scheduler - Public Styles */

/* Container Styles */
.jsrs-schedule-container,
.jsrs-monthly-container,
.jsrs-my-shifts {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Controls */
.jsrs-controls {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.jsrs-btn {
    padding: 10px 20px;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.3s;
}

.jsrs-btn:hover {
    background: #005177;
}

/* Weekly Schedule Table */
.jsrs-schedule-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.jsrs-schedule-table th,
.jsrs-schedule-table td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: center;
}

.jsrs-schedule-table th {
    background: #0073aa;
    color: #fff;
    font-weight: 600;
}

.jsrs-time-header {
    width: 120px;
}

.jsrs-day-header {
    background: #0073aa;
}

.jsrs-day-name {
    font-size: 16px;
    font-weight: 600;
}

.jsrs-day-date {
    font-size: 12px;
    opacity: 0.9;
    margin-top: 4px;
}

.jsrs-today {
    background: #fff3cd !important;
    border: 2px solid #ffc107;
}

.jsrs-time-cell {
    background: #f8f9fa;
    font-weight: 600;
    vertical-align: middle;
}

.jsrs-shift-cell {
    vertical-align: top;
    padding: 8px;
}

/* Role Blocks */
.jsrs-role-block {
    margin: 8px 0;
    padding: 10px;
    border-radius: 4px;
    background: #f8f9fa;
}

.jsrs-emt-block {
    border-left: 4px solid #dc3545;
}

.jsrs-driver-block {
    border-left: 4px solid #007bff;
}

.jsrs-role-label {
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    margin-bottom: 6px;
    color: #666;
    white-space: nowrap;
}

.jsrs-assigned {
    padding: 6px 10px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    color: #155724;
    font-weight: 500;
    white-space: nowrap;
}

.jsrs-my-shift {
    background: #cce5ff;
    border-color: #b8daff;
    color: #004085;
}

.jsrs-open {
    color: #856404;
    font-style: italic;
    white-space: nowrap;
}

.jsrs-unavailable {
    color: #721c24;
    font-style: italic;
    font-size: 12px;
    white-space: nowrap;
}

/* Buttons */
.jsrs-signup-btn {
    padding: 8px 16px;
    background: #28a745;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: background 0.3s;
    width: 100%;
    white-space: nowrap;
}

.jsrs-signup-btn:hover {
    background: #218838;
}

.jsrs-cancel-btn {
    padding: 4px 12px;
    background: #dc3545;
    color: #fff;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 11px;
    margin-left: 8px;
    transition: background 0.3s;
}

.jsrs-cancel-btn:hover {
    background: #c82333;
}

.jsrs-custom-time-display {
    font-size: 10px;
    color: #666;
    font-style: italic;
    display: block;
    margin-top: 3px;
}

/* Monthly Calendar */
.jsrs-monthly-calendar {
    margin-top: 20px;
}

.jsrs-month-title {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
    font-size: 24px;
}

.jsrs-calendar-table {
    width: 100%;
    border-collapse: collapse;
}

.jsrs-calendar-table th {
    background: #0073aa;
    color: #fff;
    padding: 12px;
    font-weight: 600;
    text-align: center;
}

.jsrs-calendar-day {
    border: 1px solid #ddd;
    padding: 10px;
    height: 80px;
    vertical-align: top;
    cursor: pointer;
    transition: background 0.3s;
}

.jsrs-calendar-day:hover {
    background: #f8f9fa;
}

.jsrs-empty-day {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
}

.jsrs-day-number {
    font-weight: 600;
    font-size: 18px;
    margin-bottom: 5px;
}

.jsrs-day-assignments {
    font-size: 11px;
    line-height: 1.4;
}

.jsrs-assignment-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 2px 4px;
    margin: 2px 0;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.7);
}

.jsrs-emt-name {
    color: #721c24;
    border-left: 3px solid #dc3545;
}

.jsrs-driver-name {
    color: #004085;
    border-left: 3px solid #007bff;
}

/* Coverage Colors */
.jsrs-coverage-full {
    background: #d4edda;
}

.jsrs-coverage-partial {
    background: #fff3cd;
}

.jsrs-coverage-none {
    background: #f8d7da;
}

/* Legend */
.jsrs-legend {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 4px;
}

.jsrs-legend h4 {
    margin-top: 0;
    margin-bottom: 10px;
}

.jsrs-legend-item {
    display: flex;
    align-items: center;
    margin: 8px 0;
}

.jsrs-legend-color {
    width: 30px;
    height: 20px;
    border: 1px solid #ddd;
    margin-right: 10px;
    border-radius: 3px;
}

/* My Shifts List */
.jsrs-shifts-list {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.jsrs-shifts-list th,
.jsrs-shifts-list td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: left;
}

.jsrs-shifts-list th {
    background: #f8f9fa;
    font-weight: 600;
}

.jsrs-shifts-list tr:hover {
    background: #f8f9fa;
}

/* Loading State */
.jsrs-loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

.jsrs-loading:after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

/* Responsive Design */
@media (max-width: 768px) {
    .jsrs-schedule-table {
        font-size: 12px;
    }
    
    .jsrs-shift-cell {
        padding: 4px;
    }
    
    .jsrs-role-block {
        margin: 4px 0;
        padding: 6px;
    }
    
    .jsrs-signup-btn {
        padding: 6px 10px;
        font-size: 11px;
    }
    
    .jsrs-day-header {
        font-size: 12px;
    }
    
    .jsrs-day-name {
        font-size: 14px;
    }
    
    .jsrs-day-date {
        font-size: 10px;
    }
    
    .jsrs-calendar-day {
        height: 60px;
        padding: 5px;
    }
    
    .jsrs-day-number {
        font-size: 14px;
    }
}

/* Notifications */
.jsrs-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 4px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    z-index: 9999;
    animation: slideIn 0.3s ease-out;
}

.jsrs-notification.success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.jsrs-notification.error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}
/* Pending status styles */
.jsrs-pending {
    background: #fff3cd !important;
    border-left: 3px solid #ffc107 !important;
}

.jsrs-pending-badge {
    display: inline-block;
    font-size: 12px;
    padding: 2px 6px;
    background: #ffc107;
    color: #000;
    border-radius: 3px;
    margin-left: 5px;
    font-weight: bold;
}

/* Monthly view pending indicator */
.jsrs-day.jsrs-has-pending {
    border: 2px solid #ffc107;
}

.jsrs-day.jsrs-has-pending .jsrs-day-number {
    background: #fff3cd;
}
