/* WooCommerce Date Picker Styles */

.woo-date-picker-wrapper {
    margin: 20px 0;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #f9f9f9;
}

.woo-date-picker-label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: #333;
}

.woo-date-picker-label .required {
    color: #e2401c;
    margin-left: 3px;
}

.woo-date-picker-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.woo-date-picker-input {
    width: 100%;
    padding: 12px 45px 12px 15px;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.woo-date-picker-input:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 1px rgba(0, 115, 170, 0.2);
}

.woo-date-picker-input.error {
    border-color: #e2401c;
    box-shadow: 0 0 0 1px rgba(226, 64, 28, 0.2);
}

.woo-date-picker-calendar-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    cursor: pointer;
    transition: color 0.3s ease;
}

.woo-date-picker-calendar-icon:hover {
    color: #0073aa;
}

.woo-date-picker-info {
    display: none;
    margin-top: 15px;
    font-size: 14px;
    color: #666;
}

.woo-date-picker-description {
    margin: 0 0 10px 0;
    line-height: 1.4;
}

.woo-date-picker-restrictions,
.woo-date-picker-unavailable {
    margin: 8px 0;
    padding: 8px 12px;
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 4px;
    font-size: 13px;
}

.woo-date-picker-restrictions strong,
.woo-date-picker-unavailable strong {
    color: #856404;
}

.woo-date-picker-error {
    margin-top: 10px;
    padding: 10px 15px;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    color: #721c24;
    font-size: 14px;
}

.woo-date-picker-error-message {
    font-weight: 500;
}

/* Date Picker Calendar Styles */
.ui-datepicker {
    background: #fff;
    border: 2px solid #0073aa;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    font-family: inherit;
    font-size: 14px;
    padding: 0;
    width: 280px;
}

.ui-datepicker .ui-datepicker-header {
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 6px 6px 0 0;
    padding: 10px;
    text-align: center;
    position: relative;
}

.ui-datepicker .ui-datepicker-title {
    font-weight: 600;
    font-size: 16px;
    margin: 0 40px;
    line-height: 30px;
}

.ui-datepicker .ui-datepicker-prev,
.ui-datepicker .ui-datepicker-next {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    color: #fff;
    cursor: pointer;
    height: 30px;
    width: 30px;
    top: 8px;
    transition: all 0.3s ease;
    position: absolute;
    overflow: hidden;
}

.ui-datepicker .ui-datepicker-prev:hover,
.ui-datepicker .ui-datepicker-next:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

/* Ensure icons are visible on hover */
.ui-datepicker .ui-datepicker-prev:hover .ui-icon:before,
.ui-datepicker .ui-datepicker-next:hover .ui-icon:before {
    color: #fff;
    text-shadow: 0 0 2px rgba(0, 0, 0, 0.5);
}

/* Button focus states */
.ui-datepicker .ui-datepicker-prev:focus,
.ui-datepicker .ui-datepicker-next:focus {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

.ui-datepicker .ui-datepicker-prev {
    left: 10px;
}

.ui-datepicker .ui-datepicker-next {
    right: 10px;
}

.ui-datepicker .ui-datepicker-prev .ui-icon,
.ui-datepicker .ui-datepicker-next .ui-icon {
    background-image: none;
    text-indent: 0;
    line-height: 30px;
    font-size: 18px;
    font-weight: bold;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    text-align: center;
}

.ui-datepicker .ui-datepicker-prev .ui-icon:before {
    content: "←";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: Arial, sans-serif;
    font-size: 20px;
    line-height: 1;
    color: #fff;
    font-weight: bold;
}

.ui-datepicker .ui-datepicker-next .ui-icon:before {
    content: "→";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: Arial, sans-serif;
    font-size: 20px;
    line-height: 1;
    color: #fff;
    font-weight: bold;
}

.ui-datepicker table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.ui-datepicker th {
    background: #f8f9fa;
    border: none;
    color: #666;
    font-weight: 600;
    padding: 10px 5px;
    text-align: center;
    font-size: 12px;
}

.ui-datepicker td {
    border: none;
    padding: 2px;
}

.ui-datepicker td span,
.ui-datepicker td a {
    border: none;
    background: transparent;
    color: #333;
    display: block;
    padding: 8px 5px;
    text-align: center;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.ui-datepicker td a:hover {
    background: #e3f2fd;
    color: #0073aa;
}

.ui-datepicker td a.ui-state-active {
    background: #0073aa;
    color: #fff;
    font-weight: 600;
}

.ui-datepicker td a.ui-state-hover {
    background: #e3f2fd;
    color: #0073aa;
}

/* Available/Unavailable Date Styles */
.ui-datepicker td a.available-date {
    background: #d4edda;
    color: #155724;
}

.ui-datepicker td a.available-date:hover {
    background: #c3e6cb;
}

.ui-datepicker td a.unavailable-date {
    background: #f8d7da;
    color: #721c24;
    cursor: not-allowed;
    opacity: 0.6;
}

.ui-datepicker td a.unavailable-date:hover {
    background: #f8d7da;
    color: #721c24;
}

.ui-datepicker td a.weekend-date {
    background: #fff3cd;
    color: #856404;
    cursor: not-allowed;
    opacity: 0.6;
}

.ui-datepicker td a.weekend-date:hover {
    background: #fff3cd;
    color: #856404;
}

/* Responsive Design */
@media (max-width: 768px) {
    .woo-date-picker-wrapper {
        margin: 15px 0;
        padding: 12px;
    }
    
    .woo-date-picker-input {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 10px 40px 10px 12px;
    }
    
    .ui-datepicker {
        width: 260px;
        font-size: 13px;
    }
    
    .ui-datepicker .ui-datepicker-header {
        padding: 8px;
    }
    
    .ui-datepicker .ui-datepicker-title {
        font-size: 15px;
    }
    
    .ui-datepicker td span,
    .ui-datepicker td a {
        padding: 6px 3px;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .woo-date-picker-wrapper {
        border-width: 2px;
    }
    
    .woo-date-picker-input {
        border-width: 2px;
    }
    
    .ui-datepicker {
        border-width: 3px;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .woo-date-picker-wrapper {
        background: #2d3748;
        border-color: #4a5568;
        color: #e2e8f0;
    }
    
    .woo-date-picker-label {
        color: #e2e8f0;
    }
    
    .woo-date-picker-input {
        background: #4a5568;
        border-color: #718096;
        color: #e2e8f0;
    }
    
    .woo-date-picker-input:focus {
        border-color: #63b3ed;
        box-shadow: 0 0 0 1px rgba(99, 179, 237, 0.2);
    }
    
    .woo-date-picker-info {
        display: none !important;
        color: #a0aec0;
    }
} 