/* Calendar Container */
#visit-calendar-container {
    border: 1px solid #e2e4e7;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin: 20px 0;
    overflow: hidden;
    width: 100%;
	background: white;
    position: relative;
    max-width: 100%;
}

/* Mobile responsive styles for the calendar container */
@media (max-width: 576px) and (min-width: 481px) {
    #visit-calendar-container {
        width: 100%;
    }
    
    .calendar-grid div {
        height: 40px; /* Reduced height for mobile */
    }
    
    .day {
        padding: 4px;
    }
    
    .day-number {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
}

/* Calendar Legend Explanation */
.calendar-legend-explanation {
    padding: 15px;
    text-align: center;
    color: #4a5568;
    font-size: 12px;
    line-height: 1.4;
    background-color: #f9f9f9;
    border-bottom: 1px solid #e2e4e7;
}

/* Calendar Header */
.calendar-header {
    align-items: center;
    background: #f7f7f7;
    border-bottom: 1px solid #e2e4e7;
    display: flex;
    justify-content: space-between;
    padding: 15px;
    margin-bottom: 0;
}

.month-year-label {
    font-size: 18px;
    font-weight: bold;
    text-align: center;
}

.nav-button {
    background: #f1f1f1;
    border: 1px solid #ddd;
    color: #333;
    cursor: pointer;
    font-size: 16px;
    padding: 5px 10px;
}

.nav-button:disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

/* Days Header */
.days-header {
    background: #f9f9f9;
    border-bottom: 1px solid #e2e4e7;
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    margin-bottom: 0;
}

.day-name {
    font-size: 14px;
    font-weight: bold;
    padding: 5px;
    text-align: center;
}

/* Calendar Grid */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0;
}

.calendar-grid div {
    height: 60px;
    width: 100%;
}

/* Day Cell */
.day {
    aspect-ratio: 1;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 14px;
    position: relative;
    transition: background-color 0.2s ease;
    border: 1px solid #ddd;
    padding: 10px;
    text-align: center;
    min-height: 40px;
    background-color: #fff;
}

/* Add subtle background colors for different seasons */
.day.low-season {
    background-color: #f1f8e9; /* Light green background */
}

.day.medium-season {
    background-color: #fff8e1; /* Light yellow background */
}

.day.high-season {
    background-color: #fff3e0; /* Light orange background */
}

.day:hover:not(.disabled) {
    background: #f7f7f7;
}

.day.empty {
    background: #f5f5f5;
    border: 1px solid #eee;
    cursor: default;
}

.day.past {
    color: #999;
    background: #f5f5f5;
}

.day-number {
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    font-weight: bold;
}

/* Special Day States - Sin textos pero con círculos de colores */
.day.today .day-number {
    font-weight: 900;
}

.day.past .day-number {
    background: #ffffff;
    color: #aaaaaa;
}

.day.closed .day-number {
    background: #ea384c;
    color: white;
}

/* Remove the default green for all available days and make it season-specific */
.day.low-season:not(.disabled):not(.selected):not(.past):not(.closed) .day-number {
    background: #40DD7F;
    color: white;
}

.day.medium-season:not(.disabled):not(.selected):not(.past):not(.closed) .day-number {
    background: #ffca28;
    color: white;
}

.day.high-season:not(.disabled):not(.selected):not(.past):not(.closed) .day-number {
    background: #ff7043;
    color: white;
}

.day.selected .day-number {
    background: #1EAEDB;
    color: white;
}

.day.disabled {
    cursor: not-allowed;
    opacity: 1;
}

/* Legend - Simplified version with only "Abierto" and "Fecha elegida" */
.calendar-legend {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 0;
    padding: 15px;
    border-top: 1px solid #e2e4e7;
    background-color: #f9f9f9;
}

.legend-items-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: nowrap;
    width: 100%;
}

.legend-item-simple {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.legend-circle {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

.legend-circle-open {
    background-color: #40DD7F;
    border: 1px solid #36c470;
}

.legend-circle-selected {
    background-color: #1EAEDB;
    border: 1px solid #1EAEDB;
}

.legend-text {
    font-size: 13px;
    color: #333;
    font-weight: 500;
    white-space: nowrap;
}

/* Hide visit date input field */
.visit-date-input {
    display: none !important;
}

#visit-date-field .form-row label {
    display: none !important;
}

/* Price Tooltip */
.price-tooltip {
    position: absolute;
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    padding: 10px;
    min-width: 180px;
    z-index: 1000;
    pointer-events: none;
}

.tooltip-header {
    font-weight: bold;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
    margin-bottom: 5px;
    font-size: 14px;
}

.price-list {
    margin: 0;
    padding: 0 0 0 15px;
    list-style: disc;
    font-size: 13px;
}

.price-list li {
    margin-bottom: 3px;
}

.tooltip-shifts {
    margin-top: 5px;
    padding-top: 5px;
    border-top: 1px dashed #eee;
    font-size: 12px;
    font-style: italic;
    color: #555;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .day-name {
        font-size: 12px;
        padding: 5px;
    }
    
    .day-number {
        font-size: 12px;
        width: 30px;
        height: 30px;
    }
    
    .legend-item {
        font-size: 10px;
    }
}

#visit-date-review {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    margin: 1rem 0;
    border: 1px solid #e3e8f2;
}

#visit-date-review h3 {
    color: #2d3748;
    font-size: 1rem;
    margin: 0 0 0.5rem 0;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

#visit-date-review h3::before {
    font-size: 0.9em;
    opacity: 0.8;
}

#selected-visit-date {
    color: #4a5568;
    font-size: 0.95rem;
    margin: 0;
    padding: 0.5rem 0;
    font-weight: 500;
    line-height: 1.4;
}

/* Versión compacta para pantallas pequeñas */
@media (max-width: 768px) {
    #visit-date-review {
        padding: 0.75rem;
        margin: 0.75rem 0;
    }
	.calendar-grid div {
		height:40px !important;
	}
	.day-number {
  
    width: 30px;
    height: 30px;

	}
	.calendar-legend {
		padding: 10px;
	}
	
	.legend-items-container {
		gap: 12px;
	}
	
	.legend-text {
		font-size: 11px;
	}	
}

p#selected-visit-date:first-letter {
    text-transform: capitalize;
}

.day.past.disabled .day-number {
    font-weight: 400;
}

/* Shift Selector Styles */
.shift-selector-container {
    margin: 15px 0;
    padding: 15px;
    background-color: #f7f9fc;
    border: 1px solid #e2e4e7;
    border-radius: 8px;
}

.shift-selector-container h4 {
    margin: 0 0 15px 0;
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
}

.shift-options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 10px;
}

.shift-option {
    padding: 10px;
    background-color: white;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    position: relative;
}

.shift-option:hover:not(.disabled) {
    border-color: #90cdf4;
    box-shadow: 0 2px 5px rgba(66, 153, 225, 0.15);
}

.shift-option.selected {
    background-color: #ebf8ff;
    border-color: #63b3ed;
    box-shadow: 0 2px 5px rgba(66, 153, 225, 0.2);
}

/* Check icon for selected shift */
.shift-option.selected::after {
    content: '';
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    background-color: #48bb78;
    border: 2px solid white;
    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.41L9 16.17z'/%3E%3C/svg%3E");
    background-size: 14px;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.shift-option.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #f8f8f8;
    border-color: #ddd;
}

.shift-time {
    font-weight: 500;
    color: #2d3748;
    margin-bottom: 4px;
}

.shift-capacity {
    font-size: 12px;
    color: #718096;
}

.no-shifts-message {
    padding: 10px;
    background-color: #fff5f5;
    border: 1px solid #fed7d7;
    border-radius: 6px;
    color: #c53030;
    font-size: 14px;
    text-align: center;
    margin: 10px 0;
}

#selected-visit-shift {
    color: #4a5568;
    font-size: 0.95rem;
    margin: 8px 0 0 0;
    padding: 0;
    font-weight: 500;
}

/* Medium Screens */
@media (max-width: 768px) {
    .shift-options {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 8px;
    }
    
    .shift-option {
        padding: 8px;
    }
    
    .shift-time {
        font-size: 14px;
    }
}

/* Small Screens */
@media (max-width: 480px) {
    .shift-options {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .shift-selector-container h4 {
        font-size: 15px;
    }
}

/* Add loading indicator styles at the end of the file */
.cat-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.7);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

.cat-loading-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid #3498db;
    border-radius: 50%;
    animation: cat-spin 1s linear infinite;
}

@keyframes cat-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Toast notification system - enhanced with accessibility and improved design */
.cat-toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    max-width: 350px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none; /* Allow clicking through the container */
}

.cat-toast {
    background-color: white;
    color: #333;
    padding: 14px 16px;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    margin-bottom: 10px;
    opacity: 0;
    transform: translateY(-20px);
    transition: all 0.3s ease;
    pointer-events: auto; /* Make the toast itself clickable */
    display: flex;
    align-items: center;
    border-left: 4px solid transparent;
    max-width: 100%;
    overflow: hidden;
    position: relative;
    outline: none; /* Remove default focus outline */
}

/* Accessible focus styles */
.cat-toast:focus {
    box-shadow: 0 0 0 2px white, 0 0 0 4px #3498db;
}

.cat-toast.show {
    opacity: 1;
    transform: translateY(0);
}

.cat-toast-icon {
    margin-right: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    text-align: center;
    line-height: 1;
    flex-shrink: 0;
}

.cat-toast-content {
    flex: 1;
    font-size: 14px;
    line-height: 1.5;
    font-weight: 500;
    padding-right: 4px;
    color: #454545;
}

.cat-toast-close {
    padding: 4px;
    background: transparent;
    border: none;
    cursor: pointer;
    color: #666;
    font-size: 18px;
    opacity: 0.7;
    transition: opacity 0.2s, background-color 0.2s;
    margin-left: 8px;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.cat-toast-close:hover {
    opacity: 1;
    background-color: rgba(0, 0, 0, 0.05);
}

.cat-toast-close:focus {
    opacity: 1;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

/* Toast progress bar */
.cat-toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background-color: rgba(0, 0, 0, 0.05);
    width: 100%;
    border-radius: 0 0 0 8px; /* Match the toast border radius */
    overflow: hidden;
}

.cat-toast-progress-bar {
    height: 100%;
    width: 100%;
    background-color: currentColor;
    transform-origin: left;
    animation: cat-toast-progress 5s linear forwards;
    opacity: 0.5;
}

@keyframes cat-toast-progress {
    from { transform: scaleX(1); }
    to { transform: scaleX(0); }
}

/* Toast types with improved colors and contrast */
.cat-toast-info {
    border-left-color: #3498db;
    color: #2980b9;
}

.cat-toast-success {
    border-left-color: #2ecc71;
    color: #27ae60;
}

.cat-toast-warning {
    border-left-color: #f1c40f;
    color: #f39c12;
}

.cat-toast-error {
    border-left-color: #e74c3c;
    color: #c0392b;
}

/* Enhanced responsive adjustments */
@media (max-width: 768px) {
    .cat-toast-container {
        top: auto;
        bottom: 20px;
        right: 20px;
        left: 20px;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .cat-toast-container {
        right: 10px;
        left: 10px;
        bottom: 10px;
    }
    
    .cat-toast {
        width: 100%;
        padding: 12px 14px;
        border-radius: 6px;
    }
    
    .cat-toast-icon {
        font-size: 16px;
        width: 20px;
        height: 20px;
    }
    
    .cat-toast-content {
        font-size: 13px;
    }
    
    .cat-toast-close {
        font-size: 16px;
        width: 20px;
        height: 20px;
    }
}

/* Responsive adjustments for legend */
@media (max-width: 768px) {
    .calendar-legend {
        padding: 12px;
    }
    
    .legend-items-container {
        gap: 15px;
        flex-wrap: nowrap;
    }
    
    .legend-item-simple {
        gap: 6px;
    }
    
    .legend-circle {
        width: 14px;
        height: 14px;
    }
    
    .legend-text {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .calendar-legend {
        padding: 10px;
    }
    
    .legend-items-container {
        gap: 12px;
        flex-wrap: nowrap;
        justify-content: center;
    }
    
    .legend-item-simple {
        gap: 5px;
    }
    
    .legend-circle {
        width: 12px;
        height: 12px;
    }
    
    .legend-text {
        font-size: 11px;
    }
}

.required {
    color: #e2401c;
    font-weight: 700;
}

.shift-required-note {
    font-size: 0.9em;
    margin-top: 10px;
    color: #777;
}

.shift-unavailable {
    font-size: 0.85em;
    margin-top: -10px;
    color: #e2401c;
    font-style: italic;
}

.shift-option.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #f8f8f8;
    border-color: #ddd;
}

/* Mobile Responsiveness - Comprehensive overhaul */
@media (max-width: 480px) {
    #visit-calendar-container {
        width: 100%;
        margin: 15px 0;
        border-radius: 6px;
    }
    
    .calendar-header {
        padding: 10px;
    }
    
    .month-year-label {
        font-size: 16px;
    }
    
    .nav-button {
        padding: 4px 8px;
        font-size: 14px;
    }
    
    .days-header {
        gap: 0;
    }
    
    .day-name {
        font-size: 11px;
        padding: 3px 0;
    }
    
    .calendar-grid {
        gap: 0;
    }
    
    .calendar-grid div {
        height: 36px !important;
    }
    
    .day {
        padding: 2px;
        border-width: 1px;
    }
    
    .day-number {
        width: 24px;
        height: 24px;
        font-size: 11px;
    }
    
    /* Better fit legends on small screens */
    .calendar-legend {
        padding: 10px;
    }
    
    /* Make shifts selector better fit mobile screens */
    .shift-options {
        grid-template-columns: 1fr 1fr;
        gap: 6px;
    }
    
    .shift-option {
        padding: 6px;
    }
    
    .shift-time {
        font-size: 12px;
    }
    
    .shift-capacity {
        font-size: 10px;
    }
}

/* Hotel Daypass Info Styles */
.hotel-daypass-info-container {
    background: #f0f9ff;
    border: 2px solid #0ea5e9;
    border-radius: 12px;
    padding: 0;
    margin: 0 0 -20px 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    overflow: hidden;
}

.daypass-schedule {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #e0f2fe;
    padding: 20px;
    border-left: 4px solid #0ea5e9;
}

.schedule-icon {
    font-size: 20px;
    margin-top: 2px;
}

.schedule-text {
    flex: 1;
    color: #0c4a6e;
    line-height: 1.5;
}

.schedule-text strong {
    color: #0c4a6e;
    font-weight: 600;
}

.schedule-text small {
    color: #075985;
    font-size: 13px;
}


/* Review section styles for hotel daypass */
.hotel-daypass-schedule {
    color: #0ea5e9;
    font-weight: 600;
}

.daypass-label {
    color: #6b7280;
    font-size: 13px;
    font-style: italic;
}

/* Mobile responsive styles for hotel daypass */
@media (max-width: 768px) {
    .hotel-daypass-info-container {
        margin: 20px 0 0 0;
    }
    
    .daypass-schedule {
        padding: 16px;
        gap: 8px;
    }
    
    .schedule-icon {
        font-size: 16px;
    }
    
    .schedule-text {
        font-size: 13px;
        color: #0c4a6e;
    }
}

@media (max-width: 480px) {
    .daypass-schedule {
        flex-direction: column;
        text-align: center;
        gap: 8px;
        padding: 12px;
    }
    
    .schedule-icon {
        align-self: center;
    }
}

/* Mobile responsive styles for visit details review section */
@media (max-width: 768px) {
    #selected-visit-details {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 8px;
    }
    
    #selected-visit-date-container,
    #selected-visit-shift-container {
        margin: 0 !important;
        width: 100%;
        display: block !important;
    }
    
    /* Hide separator on mobile */
    #visit-details-separator {
        display: none !important;
    }
}
