/* ============================================
   ÖZEL TAKVİM COMPONENT - CSS
   REZERVASYON TARİHİ SEÇİMİ İÇİN ÖZELLEŞTİRİLMİŞ
   ============================================ */

.custom-calendar {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
}

/* Rezervasyon Modu */
.custom-calendar.reservation-mode {
    border: none;
}

.custom-calendar.reservation-mode .custom-calendar-header {
    background: #ffffff !important;
    color: #2c3e50;
    margin: -20px -20px 20px -20px;
    padding: 20px;
    border-radius: 8px 8px 0 0;
}

.custom-calendar.reservation-mode .custom-calendar-title {
    color: #2c3e50;
}

.custom-calendar.reservation-mode .custom-calendar-month-year {
    color: #2c3e50;
}

.custom-calendar.reservation-mode .custom-calendar-nav-btn {
    background: #f8f9fa;
    color: #2c3e50;
    border: 1px solid #dee2e6;
}

.custom-calendar.reservation-mode .custom-calendar-nav-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

/* Temizle butonu özel stili */
.custom-calendar-clear-btn {
    margin-left: 8px;
    background: #dc3545 !important;
    color: white !important;
    border-color: #dc3545 !important;
    padding: 6px 16px !important;
}

.custom-calendar-clear-btn:hover {
    background: #c82333 !important;
    border-color: #bd2130 !important;
}

/* Takvim Header */
.custom-calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e9ecef;
}

.custom-calendar-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

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

.custom-calendar-nav-btn {
    background: #007bff;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 12px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
    height: 34px;
    box-sizing: border-box;
}

.custom-calendar-nav-btn:hover {
    background: #0056b3;
    transform: translateY(-1px);
    box-shadow: 0 2px 5px rgba(0, 123, 255, 0.3);
}

.custom-calendar-nav-btn:active {
    transform: translateY(0);
}

.custom-calendar-nav-btn:disabled {
    background: #6c757d;
    cursor: not-allowed;
    transform: none;
}

.custom-calendar-month-year {
    font-size: 1.1rem;
    font-weight: 500;
    color: #495057;
    min-width: 150px;
    text-align: center;
}

/* Ay ve Yıl Seçici */
.custom-calendar-month-year-selector {
    display: flex;
    align-items: center;
    gap: 6px;
    justify-content: center;
    flex: 1;
}

.custom-calendar-month-select,
.custom-calendar-year-select {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    padding: 8px 32px 8px 12px;
    color: white;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    outline: none;
    transition: all 0.2s ease;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    min-width: 120px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='white' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 12px;
}

.custom-calendar-month-select:hover,
.custom-calendar-year-select:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='white' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 12px;
}

.custom-calendar-month-select:focus,
.custom-calendar-year-select:focus {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.2);
    outline: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='white' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 12px;
}

.custom-calendar-month-select option,
.custom-calendar-year-select option {
    background: #333;
    color: white;
    padding: 8px;
}

/* Mobile'da genel kuralı override et - Media query dışında ama mobile için */
@media (max-width: 768px) {
    /* Genel kuralı (background: #333; color: white;) mobile için override et */
    .custom-calendar-month-select option,
    .custom-calendar-year-select option {
        background: #ffffff !important;
        background-color: #ffffff !important;
        color: #2c3e50 !important;
        padding: 12px 16px !important;
    }
}

/* Mobile'da option'lar için özel stil - Genel kuralı override et */
@media (max-width: 768px) {
    /* Tüm option'lar için beyaz arka plan ve koyu metin - Genel kuralı override et */
    .custom-calendar-month-select option,
    .custom-calendar-year-select option,
    .custom-calendar:not(.reservation-mode) .custom-calendar-month-select option,
    .custom-calendar:not(.reservation-mode) .custom-calendar-year-select option,
    .custom-calendar.reservation-mode .custom-calendar-month-select option,
    .custom-calendar.reservation-mode .custom-calendar-year-select option,
    select.custom-calendar-month-select option,
    select.custom-calendar-year-select option {
        background: #ffffff !important;
        background-color: #ffffff !important;
        color: #2c3e50 !important;
        padding: 12px 16px !important;
        font-size: 1rem !important;
        font-weight: 500 !important;
    }
}

/* Normal modda ay/yıl seçici stilleri */
.custom-calendar:not(.reservation-mode) .custom-calendar-month-select,
.custom-calendar:not(.reservation-mode) .custom-calendar-year-select {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #495057;
    padding: 8px 32px 8px 12px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    min-width: 120px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23495057' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 12px;
}

.custom-calendar:not(.reservation-mode) .custom-calendar-month-select:hover,
.custom-calendar:not(.reservation-mode) .custom-calendar-year-select:hover {
    background: #e9ecef;
    border-color: #adb5bd;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23495057' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 12px;
}

.custom-calendar:not(.reservation-mode) .custom-calendar-month-select:focus,
.custom-calendar:not(.reservation-mode) .custom-calendar-year-select:focus {
    background: #fff;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
    outline: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23007bff' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 12px;
}

.custom-calendar:not(.reservation-mode) .custom-calendar-month-select option,
.custom-calendar:not(.reservation-mode) .custom-calendar-year-select option {
    background: white;
    color: #495057;
}

/* Rezervasyon modunda ay/yıl seçici stilleri */
.custom-calendar.reservation-mode .custom-calendar-month-select,
.custom-calendar.reservation-mode .custom-calendar-year-select {
    background: #f8f9fa !important;
    border: 1px solid #dee2e6 !important;
    color: #2c3e50 !important;
    padding: 6px 28px 6px 12px !important;
    font-size: 0.9rem !important;
    font-weight: 500 !important;
    min-width: auto !important;
    max-width: none !important;
    width: auto !important;
    height: 34px !important;
    line-height: 1.2 !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    border-radius: 6px !important;
    cursor: pointer !important;
    box-shadow: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%232c3e50' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 10px center !important;
    background-size: 12px !important;
    transition: all 0.3s ease !important;
    box-sizing: border-box !important;
}

.custom-calendar.reservation-mode .custom-calendar-month-select:hover,
.custom-calendar.reservation-mode .custom-calendar-year-select:hover {
    background-color: #e9ecef !important;
    border-color: #adb5bd !important;
    box-shadow: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%232c3e50' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 10px center !important;
    background-size: 12px !important;
}

.custom-calendar.reservation-mode .custom-calendar-month-select:focus,
.custom-calendar.reservation-mode .custom-calendar-year-select:focus {
    background-color: #e9ecef !important;
    border-color: #adb5bd !important;
    box-shadow: none !important;
    outline: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%232c3e50' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 10px center !important;
    background-size: 12px !important;
}

.custom-calendar.reservation-mode .custom-calendar-month-select option,
.custom-calendar.reservation-mode .custom-calendar-year-select option {
    background: white !important;
    color: #2c3e50 !important;
    padding: 8px 12px;
}

/* Hafta Günleri Başlıkları */
.custom-calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    margin-bottom: 10px;
}

.custom-calendar-weekday {
    text-align: center;
    font-weight: 600;
    color: #6c757d;
    font-size: 0.85rem;
    padding: 10px 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Takvim Günleri Grid */
.custom-calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

/* Takvim Cell (Gün) */
.custom-calendar-cell {
    position: relative;
    min-height: 80px;
    padding: 8px;
    border: 1px solid #f0f0f0;
    border-radius: 6px;
    background: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.custom-calendar-cell:hover:not(.cell-disabled):not(.cell-not-clickable) {
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.2);
    transform: translateY(-2px);
}

/* Cell İçeriği */
.custom-calendar-cell-day {
    font-size: 0.9rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 2px;
    text-align: center;
    width: 100%;
}

.custom-calendar-cell-content {
    width: 100%;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
}

/* Cell Text */
.custom-calendar-cell-text {
    font-size: 0.7rem;
    color: #495057;
    line-height: 1.3;
    word-wrap: break-word;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Rezervasyon Fiyat Gösterimi */
.custom-calendar-cell-price {
    font-size: 0.75rem;
    color: #20af56 !important;
    margin-top: 0;
    text-align: center;
    width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

/* Sezonluk Fiyat Info Icon */
.custom-calendar-price-info-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: help;
  color: #6c757d;
  font-size: 0.7rem;
  margin-left: 2px;
  transition: color 0.2s ease;
}

.custom-calendar-price-info-icon:hover {
  color: #0dcaf0;
}

.custom-calendar-price-info-icon .material-symbols-outlined {
  font-size: 0.7rem;
  line-height: 1;
}

/* Rezervasyon Durum İkonları */
.custom-calendar-cell-status {
    position: absolute;
    top: 5px;
    right: 5px;
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-calendar-status-icon {
    width: 14px;
    height: 14px;
    display: block;
}

.custom-calendar-cell-status.available {
    color: #28a745;
}

.custom-calendar-cell-status.reserved {
    color: #dc3545;
}

.custom-calendar-cell-status.blocked {
    color: #dc3545; /* Kırmızı ikon */
}

/* Cell Badge */
.custom-calendar-cell-badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    margin-top: 2px;
}

/* Cell Image */
.custom-calendar-cell-image {
    width: 100%;
    height: 30px;
    object-fit: cover;
    border-radius: 4px;
    margin-top: 4px;
}

/* Diğer Ay Günleri */
.custom-calendar-cell.other-month {
    background: #f8f9fa;
    opacity: 0.5;
    cursor: default;
}

.custom-calendar-cell.other-month:hover {
    border-color: #e9ecef;
    box-shadow: none;
    transform: none;
}

/* Bugün */
.custom-calendar-cell.today {
    border-color: #28a745;
    background: #f0fff4;
    font-weight: 700;
}

.custom-calendar-cell.today .custom-calendar-cell-day {
    color: #28a745;
}

/* Seçili Gün */
.custom-calendar-cell.selected {
    border-color: #007bff;
    background: #e7f3ff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.2);
}

.custom-calendar-cell.selected .custom-calendar-cell-day {
    color: #007bff;
}

/* Disabled Cell */
.custom-calendar-cell.cell-disabled {
    background: #e9ecef;
    color: #adb5bd;
    cursor: not-allowed;
    opacity: 0.6;
}

.custom-calendar-cell.cell-disabled:hover {
    border-color: #e9ecef;
    box-shadow: none;
    transform: none;
}

.custom-calendar-cell.cell-disabled .custom-calendar-cell-day,
.custom-calendar-cell.cell-disabled .custom-calendar-cell-text {
    color: #adb5bd;
    text-decoration: line-through;
}

/* Not Clickable Cell */
.custom-calendar-cell.cell-not-clickable {
    cursor: default;
}

.custom-calendar-cell.cell-not-clickable:hover {
    border-color: #e9ecef;
    box-shadow: none;
    transform: none;
}

/* Check-out ve seçilebilir check-in tarihleri için disabled class'ı override et */
.custom-calendar-cell.cell-check-out.cell-disabled,
.custom-calendar-cell.cell-reserved.cell-check-out.cell-disabled {
    cursor: pointer !important;
    opacity: 1 !important;
}

/* Seçilebilir check-in tarihleri için disabled class'ı override et (isCheckInAsCheckOut) */
.custom-calendar-cell.cell-check-in.cell-disabled:not(.cell-not-clickable),
.custom-calendar-cell.cell-reserved.cell-check-in.cell-disabled:not(.cell-not-clickable) {
    cursor: pointer !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}

/* Custom Background Colors */
.custom-calendar-cell.cell-bg-primary {
    background-color: #e7f3ff !important;
}

.custom-calendar-cell.cell-bg-success {
    background-color: #d4edda !important;
}

.custom-calendar-cell.cell-bg-warning {
    background-color: #fff3cd !important;
}

.custom-calendar-cell.cell-bg-danger {
    background-color: #f8d7da !important;
}

.custom-calendar-cell.cell-bg-info {
    background-color: #d1ecf1 !important;
}

.custom-calendar-cell.cell-bg-secondary {
    background-color: #e2e3e5 !important;
}

/* Rezervasyon Durumları */
.custom-calendar-cell.cell-available {
  background-color: #ffffff !important;
    border: none !important;
    position: relative;
}

.custom-calendar-cell.cell-reserved {
  background-color: #f5e6e8 !important;
    border: none !important;
    opacity: 0.85;
}

/* cell-reserved class'ı check-in/check-out ile birlikte kullanıldığında opacity override edilmeli */
.custom-calendar-cell.cell-reserved.cell-check-in,
.custom-calendar-cell.cell-reserved.cell-check-out {
    opacity: 1 !important;
}

/* Option durumundaki rezervasyonlar (sarı) - check-in/check-out olmayanlar için */
.custom-calendar-cell.cell-reserved-option:not(.cell-check-in):not(.cell-check-out) {
  background-color: #fef3c7 !important; /* yellow-100 */
  color: #92400e !important; /* yellow-800 */
  border-color: #fde68a !important; /* yellow-300 */
}

/* Check-out tarihi için özel kural - yarı seçim görünümü için */
.custom-calendar-cell.cell-check-out.cell-reserved-option {
    background: linear-gradient(135deg, #fef3c7 50%, #ffffff 50%) !important;
    background-color: transparent !important;
    color: #92400e !important;
    border: none !important;
    opacity: 1 !important;
}

/* Confirmed durumundaki rezervasyonlar (kırmızı) - check-in/check-out olmayanlar için */
.custom-calendar-cell.cell-reserved-confirmed:not(.cell-check-in):not(.cell-check-out) {
  background-color: #fdeaea !important; /* kırmızı */
  color: #b9383c !important;
  border-color: #fbd2d2 !important;
}

.custom-calendar-cell.cell-blocked {
  background-color: #fdeaea !important; /* Kırmızı arka plan */
  border-color: #dc3545 !important; /* Kırmızı border */
  color: #b9383c !important; /* Kırmızı metin */
    opacity: 0.85;
}

.custom-calendar-cell.cell-blocked .custom-calendar-cell-day {
  color: #b9383c !important; /* Kırmızı gün numarası */
}

.custom-calendar-cell.cell-blocked .custom-calendar-cell-text {
  color: #b9383c !important; /* Kırmızı metin */
}

.custom-calendar-cell.cell-blocked::before {
  content: "";
    position: absolute;
    top: 5px;
    right: 5px;
    width: 8px;
    height: 8px;
  background: #dc3545; /* Kırmızı nokta */
    border-radius: 50%;
    border: 1px solid white;
}

.custom-calendar-cell.cell-selected-range {
    background-color: #d1f2eb !important;
    border: none !important;
    color: #0d7377 !important;
    font-weight: 500;
}

.custom-calendar-cell.cell-selected-range .custom-calendar-cell-day {
    color: #0d7377 !important;
}

/* Rezervasyonlu tarihler için seçili aralık (sarı) */
.custom-calendar-cell.cell-selected-range.cell-reserved-option {
    background-color: #fef3c7 !important; /* yellow-100 */
    color: #92400e !important; /* yellow-800 */
    border-color: #fde68a !important; /* yellow-300 */
}

.custom-calendar-cell.cell-selected-range.cell-reserved-option .custom-calendar-cell-day {
    color: #92400e !important;
}

/* Rezervasyonlu tarihler için seçili aralık (kırmızı) */
.custom-calendar-cell.cell-selected-range.cell-reserved-confirmed {
    background-color: #fdeaea !important; /* kırmızı */
    color: #b9383c !important;
    border-color: #fbd2d2 !important;
}

.custom-calendar-cell.cell-selected-range.cell-reserved-confirmed .custom-calendar-cell-day {
    color: #b9383c !important;
}

.custom-calendar-cell.cell-selected-range .custom-calendar-cell-price {
    color: #20af56 !important;
}

.custom-calendar-cell.cell-check-in {
    background: linear-gradient(135deg, #ffffff 50%, #d1f2eb 50%) !important;
    color: #0d7377 !important;
    border: none !important;
    font-weight: 600;
}

.custom-calendar-cell.cell-check-in .custom-calendar-cell-day {
    color: #0d7377 !important;
    font-weight: 600;
}

.custom-calendar-cell.cell-check-in .custom-calendar-cell-price {
    color: #20af56 !important;
}

/* Check-in + Option rezervasyon (sarı yarı seçim) - En yüksek öncelik */
.custom-calendar-cell.cell-check-in.cell-reserved-option,
.custom-calendar-cell.cell-reserved-option.cell-check-in,
.custom-calendar-cell.cell-check-in.cell-reserved.cell-reserved-option {
    background: linear-gradient(135deg, #ffffff 50%, #fef3c7 50%) !important;
    background-color: transparent !important; /* cell-reserved-option'un background-color'unu override et */
    color: #92400e !important;
    border-color: #fde68a !important;
    opacity: 1 !important; /* cell-reserved'in opacity'sini override et */
    cursor: pointer !important; /* Seçilebilir olduğu için pointer cursor */
}

.custom-calendar-cell.cell-check-in.cell-reserved-option .custom-calendar-cell-day,
.custom-calendar-cell.cell-reserved-option.cell-check-in .custom-calendar-cell-day,
.custom-calendar-cell.cell-check-in.cell-reserved.cell-reserved-option .custom-calendar-cell-day {
    color: #92400e !important;
}

/* Check-in + Confirmed rezervasyon (kırmızı yarı seçim) - En yüksek öncelik */
.custom-calendar-cell.cell-check-in.cell-reserved-confirmed,
.custom-calendar-cell.cell-reserved-confirmed.cell-check-in,
.custom-calendar-cell.cell-check-in.cell-reserved.cell-reserved-confirmed {
    background: linear-gradient(135deg, #ffffff 50%, #fdeaea 50%) !important;
    background-color: transparent !important; /* cell-reserved-confirmed'in background-color'unu override et */
    color: #b9383c !important;
    cursor: pointer !important; /* Seçilebilir olduğu için pointer cursor */
    border-color: #fbd2d2 !important;
    opacity: 1 !important; /* cell-reserved'in opacity'sini override et */
}

.custom-calendar-cell.cell-check-in.cell-reserved-confirmed .custom-calendar-cell-day,
.custom-calendar-cell.cell-reserved-confirmed.cell-check-in .custom-calendar-cell-day,
.custom-calendar-cell.cell-check-in.cell-reserved.cell-reserved-confirmed .custom-calendar-cell-day {
    color: #b9383c !important;
}

.custom-calendar-cell.cell-check-out {
    background: linear-gradient(135deg, #d1f2eb 50%, #ffffff 50%) !important;
    color: #0d7377 !important;
    border: none !important;
    font-weight: 600;
}

/* Check-out + Seçili aralık - Gradient korunmalı */
.custom-calendar-cell.cell-check-out.cell-selected-range {
    background: linear-gradient(135deg, #d1f2eb 50%, #ffffff 50%) !important;
    background-color: transparent !important; /* cell-selected-range'in background-color'unu override et */
}

.custom-calendar-cell.cell-check-out .custom-calendar-cell-day {
    color: #0d7377 !important;
    font-weight: 600;
}

.custom-calendar-cell.cell-check-out .custom-calendar-cell-price {
    color: #20af56 !important;
}

/* Check-out + Option rezervasyon (sarı yarı seçim) - En yüksek öncelik - ÖNCE EKLENMELİ */
.custom-calendar-cell.cell-check-out.cell-reserved-option,
.custom-calendar-cell.cell-reserved-option.cell-check-out,
.custom-calendar-cell.cell-check-out.cell-reserved.cell-reserved-option,
.custom-calendar-cell.cell-check-out.cell-reserved.cell-reserved-option.cell-reserved {
    background: linear-gradient(135deg, #fef3c7 50%, #ffffff 50%) !important;
    background-color: transparent !important; /* cell-reserved-option'un background-color'unu override et */
    color: #92400e !important;
    border: none !important;
    border-color: #fde68a !important;
    opacity: 1 !important; /* cell-reserved'in opacity'sini override et */
    cursor: pointer !important; /* Seçilebilir olduğu için pointer cursor */
}

.custom-calendar-cell.cell-check-out.cell-reserved-option .custom-calendar-cell-day,
.custom-calendar-cell.cell-reserved-option.cell-check-out .custom-calendar-cell-day,
.custom-calendar-cell.cell-check-out.cell-reserved.cell-reserved-option .custom-calendar-cell-day {
    color: #92400e !important;
}

/* Check-out + Confirmed rezervasyon (kırmızı yarı seçim) - En yüksek öncelik */
.custom-calendar-cell.cell-check-out.cell-reserved-confirmed,
.custom-calendar-cell.cell-reserved-confirmed.cell-check-out,
.custom-calendar-cell.cell-check-out.cell-reserved.cell-reserved-confirmed {
    background: linear-gradient(135deg, #fdeaea 50%, #ffffff 50%) !important;
    background-color: transparent !important; /* cell-reserved-confirmed'in background-color'unu override et */
    color: #b9383c !important;
    border-color: #fbd2d2 !important;
    opacity: 1 !important; /* cell-reserved'in opacity'sini override et */
    cursor: pointer !important; /* Seçilebilir olduğu için pointer cursor */
}

.custom-calendar-cell.cell-check-out.cell-reserved-confirmed .custom-calendar-cell-day,
.custom-calendar-cell.cell-reserved-confirmed.cell-check-out .custom-calendar-cell-day,
.custom-calendar-cell.cell-check-out.cell-reserved.cell-reserved-confirmed .custom-calendar-cell-day {
    color: #b9383c !important;
}

/* Check-in + Check-out + Option rezervasyon (hem sarı hem yeşil - diagonal gradient) */
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved-option,
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved.cell-reserved-option,
.custom-calendar-cell.cell-reserved-option.cell-check-in.cell-check-out {
    background: linear-gradient(135deg, #fef3c7 50%, #d1f2eb 50%) !important;
    background-color: transparent !important;
    color: #0d7377 !important;
    border: none !important;
    border-color: #fde68a !important;
    opacity: 1 !important;
}

.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved-option .custom-calendar-cell-day,
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved.cell-reserved-option .custom-calendar-cell-day,
.custom-calendar-cell.cell-reserved-option.cell-check-in.cell-check-out .custom-calendar-cell-day {
    color: #0d7377 !important;
    font-weight: 600;
}

/* Check-in + Check-out + Confirmed rezervasyon (hem kırmızı hem yeşil - diagonal gradient) */
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved-confirmed,
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved.cell-reserved-confirmed,
.custom-calendar-cell.cell-reserved-confirmed.cell-check-in.cell-check-out {
    background: linear-gradient(135deg, #fdeaea 50%, #d1f2eb 50%) !important;
    background-color: transparent !important;
    color: #0d7377 !important;
    border: none !important;
    border-color: #fbd2d2 !important;
    opacity: 1 !important;
}

.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved-confirmed .custom-calendar-cell-day,
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved.cell-reserved-confirmed .custom-calendar-cell-day,
.custom-calendar-cell.cell-reserved-confirmed.cell-check-in.cell-check-out .custom-calendar-cell-day {
    color: #0d7377 !important;
    font-weight: 600;
}

/* Ters renkler: Eğer bir tarih hem başka bir rezervasyonun check-in'i hem de kullanıcının check-out seçimi ise,
   renkler ters olmalı (yeşil/sarı yerine sarı/yeşil) */
/* Option rezervasyon için ters renkler (yeşil sol üst, sarı sağ alt) */
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved-option.cell-reversed-colors,
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved.cell-reserved-option.cell-reversed-colors,
.custom-calendar-cell.cell-reserved-option.cell-check-in.cell-check-out.cell-reversed-colors {
    background: linear-gradient(135deg, #d1f2eb 50%, #fef3c7 50%) !important;
    background-color: transparent !important;
    color: #0d7377 !important;
    border: none !important;
    border-color: #fde68a !important;
    opacity: 1 !important;
}

.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved-option.cell-reversed-colors .custom-calendar-cell-day,
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved.cell-reserved-option.cell-reversed-colors .custom-calendar-cell-day,
.custom-calendar-cell.cell-reserved-option.cell-check-in.cell-check-out.cell-reversed-colors .custom-calendar-cell-day {
    color: #0d7377 !important;
    font-weight: 600;
}

/* Confirmed rezervasyon için ters renkler (yeşil sol üst, kırmızı sağ alt) */
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved-confirmed.cell-reversed-colors,
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved.cell-reserved-confirmed.cell-reversed-colors,
.custom-calendar-cell.cell-reserved-confirmed.cell-check-in.cell-check-out.cell-reversed-colors {
    background: linear-gradient(135deg, #d1f2eb 50%, #fdeaea 50%) !important;
    background-color: transparent !important;
    color: #0d7377 !important;
    border: none !important;
    border-color: #fbd2d2 !important;
    opacity: 1 !important;
}

.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved-confirmed.cell-reversed-colors .custom-calendar-cell-day,
.custom-calendar-cell.cell-check-in.cell-check-out.cell-reserved.cell-reserved-confirmed.cell-reversed-colors .custom-calendar-cell-day,
.custom-calendar-cell.cell-reserved-confirmed.cell-check-in.cell-check-out.cell-reversed-colors .custom-calendar-cell-day {
    color: #0d7377 !important;
    font-weight: 600;
}

/* Custom Text Colors */
.custom-calendar-cell.cell-text-primary .custom-calendar-cell-day,
.custom-calendar-cell.cell-text-primary .custom-calendar-cell-text {
    color: #007bff !important;
}

.custom-calendar-cell.cell-text-success .custom-calendar-cell-day,
.custom-calendar-cell.cell-text-success .custom-calendar-cell-text {
    color: #28a745 !important;
}

.custom-calendar-cell.cell-text-warning .custom-calendar-cell-day,
.custom-calendar-cell.cell-text-warning .custom-calendar-cell-text {
    color: #ffc107 !important;
}

.custom-calendar-cell.cell-text-danger .custom-calendar-cell-day,
.custom-calendar-cell.cell-text-danger .custom-calendar-cell-text {
    color: #dc3545 !important;
}

.custom-calendar-cell.cell-text-info .custom-calendar-cell-day,
.custom-calendar-cell.cell-text-info .custom-calendar-cell-text {
    color: #17a2b8 !important;
}

/* Responsive */
@media (max-width: 768px) {
    .custom-calendar {
        padding: 15px;
    }

    .custom-calendar-header {
        flex-direction: column;
        gap: 15px;
    }

    .custom-calendar-title {
        font-size: 1.2rem;
    }

    .custom-calendar-cell {
        min-height: 60px;
        padding: 6px;
    }

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

    .custom-calendar-cell-content {
        font-size: 0.7rem;
    }

    .custom-calendar-weekday {
        font-size: 0.75rem;
        padding: 8px 3px;
    }

    /* Mobile'da dropdown select elementleri için stil */
    .custom-calendar-month-select,
    .custom-calendar-year-select {
        z-index: 10000 !important;
        position: relative;
    }

    /* Mobile'da option'lar için çok spesifik ve güçlü stiller - Tüm kombinasyonlar */
    /* Genel kuralı (background: #333; color: white;) override et */
    .custom-calendar-month-select option,
    .custom-calendar-year-select option,
    select.custom-calendar-month-select option,
    select.custom-calendar-year-select option,
    .custom-calendar select.custom-calendar-month-select option,
    .custom-calendar select.custom-calendar-year-select option,
    .custom-calendar:not(.reservation-mode) .custom-calendar-month-select option,
    .custom-calendar:not(.reservation-mode) .custom-calendar-year-select option,
    .custom-calendar.reservation-mode .custom-calendar-month-select option,
    .custom-calendar.reservation-mode .custom-calendar-year-select option,
    .custom-calendar.reservation-mode select.custom-calendar-month-select option,
    .custom-calendar.reservation-mode select.custom-calendar-year-select option,
    .custom-calendar-datepicker-popup .custom-calendar-month-select option,
    .custom-calendar-datepicker-popup .custom-calendar-year-select option,
    .custom-calendar-datepicker-popup.reservation-mode .custom-calendar-month-select option,
    .custom-calendar-datepicker-popup.reservation-mode .custom-calendar-year-select option {
        background-color: #ffffff !important;
        background: #ffffff !important;
        color: #2c3e50 !important;
        padding: 12px 16px !important;
        font-size: 1rem !important;
        font-weight: 500 !important;
        border: none !important;
        -webkit-appearance: none !important;
        -moz-appearance: none !important;
        appearance: none !important;
    }

    .custom-calendar-month-select option:hover,
    .custom-calendar-year-select option:hover,
    select.custom-calendar-month-select option:hover,
    select.custom-calendar-year-select option:hover {
        background-color: #f8f9fa !important;
        background: #f8f9fa !important;
    }

    .custom-calendar-month-select option:checked,
    .custom-calendar-year-select option:checked,
    select.custom-calendar-month-select option:checked,
    select.custom-calendar-year-select option:checked {
        background-color: #007bff !important;
        background: #007bff !important;
        color: #ffffff !important;
    }
}

@media (max-width: 576px) {
    .custom-calendar-cell {
        min-height: 50px;
        padding: 4px;
    }

    .custom-calendar-cell-image {
        height: 20px;
    }
}

/* Custom Highlight Class (Örnek) */
.custom-calendar-cell.custom-highlight {
    animation: pulse 2s ease-in-out infinite;
    border-width: 3px;
}

@keyframes pulse {
  0%,
  100% {
        box-shadow: 0 0 0 0 rgba(0, 123, 255, 0.4);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(0, 123, 255, 0);
    }
}

/* Rezervasyon Legend (Açıklama) */
.custom-calendar-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
    font-size: 0.85rem;
}

.custom-calendar-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.custom-calendar-legend-color {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    border: 2px solid #dee2e6;
}

.custom-calendar-legend-color.available {
  background-color: #ffffff;
  border-color: #5b9bd5;
    border-width: 2px;
}

.custom-calendar-legend-color.reserved {
  background-color: #f5e6e8;
  border-color: #c55a5a;
}

.custom-calendar-legend-color.blocked {
  background-color: #fff8e1;
  border-color: #d4af37;
}

.custom-calendar-legend-color.selected {
  background-color: #e3f2fd;
  border-color: #4a90e2;
}

.custom-calendar-legend-color.check-in {
  background: linear-gradient(135deg, #4a90e2 0%, #5b9bd5 100%);
  border-color: #4a90e2;
}

.custom-calendar-legend-color.check-out {
  background: linear-gradient(135deg, #4a90e2 0%, #5b9bd5 100%);
  border-color: #4a90e2;
}

/* Loading State */
.custom-calendar-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    color: #6c757d;
}

.custom-calendar-loading::after {
    content: "";
    width: 40px;
    height: 40px;
    border: 4px solid #e9ecef;
    border-top-color: #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* ============================================
   DATE PICKER MODE - POPUP/MODAL STİLLERİ
   ============================================ */

/* Date Picker Wrapper */
.custom-calendar-datepicker-wrapper {
    position: relative;
    display: inline-block;
    width: 100%;
}

/* Date Picker Input */
.custom-calendar-datepicker-input {
    position: relative;
    cursor: pointer;
}

.custom-calendar-datepicker-input input {
    cursor: pointer;
}

/* Date Picker Popup - Desktop (Center Modal) */
.custom-calendar-datepicker-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) translateY(-10px);
    z-index: 1050;
    background: white;
    border: none;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    min-width: 350px;
    max-height: 90vh;
    overflow-y: auto;
}

.custom-calendar-datepicker-popup.show {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) translateY(0);
}

/* Date Picker Popup - Mobile (Bottom Sheet) */
@media (max-width: 768px) {
    .custom-calendar-datepicker-popup {
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        transform: translateY(100%) !important;
        border-radius: 24px 24px 0 0 !important;
        min-width: 100% !important;
        max-width: 100% !important;
        max-height: 90vh !important;
        z-index: 9999 !important;
    }

    .custom-calendar-datepicker-popup.show {
        transform: translateY(0) !important;
    }
}

/* Date Picker Popup Arrow - Modal modda gizle */
.custom-calendar-datepicker-popup::before {
    display: none;
}

/* Date Picker Range Mode (İki input için) */
.custom-calendar-datepicker-range {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.custom-calendar-datepicker-range .custom-calendar-datepicker-wrapper {
    flex: 1;
}

/* Date Picker Range Connector */
.custom-calendar-datepicker-range-connector {
    display: flex;
    align-items: center;
    padding-top: 32px;
    color: #6c757d;
    font-weight: 600;
}

/* Date Picker Popup - Range Mode için genişletilmiş */
.custom-calendar-datepicker-popup.range-mode {
    min-width: 700px;
}

/* Date Picker Popup - Rezervasyon Modu için genişletilmiş */
.custom-calendar-datepicker-popup.reservation-mode {
    min-width: 800px;
}

/* Date Picker Overlay (Dışına tıklayınca kapatmak için) */
.custom-calendar-datepicker-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1040;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.custom-calendar-datepicker-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* Date Picker Footer (Rezervasyon modu için) */
.custom-calendar-datepicker-footer {
    padding: 15px 20px;
    border-top: 1px solid #e9ecef;
    background: #f8f9fa;
    border-radius: 0 0 8px 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.custom-calendar-datepicker-footer-info {
    display: flex;
    gap: 20px;
    font-size: 0.9rem;
}

.custom-calendar-datepicker-footer-info-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.custom-calendar-datepicker-footer-actions {
    display: flex;
    gap: 10px;
}

.custom-calendar-datepicker-footer-btn {
    padding: 6px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s ease;
}

.custom-calendar-datepicker-footer-btn-primary {
    background: #007bff;
    color: white;
}

.custom-calendar-datepicker-footer-btn-primary:hover {
    background: #0056b3;
}

.custom-calendar-datepicker-footer-btn-secondary {
    background: #6c757d;
    color: white;
}

.custom-calendar-datepicker-footer-btn-secondary:hover {
    background: #545b62;
}

/* Responsive - Date Picker Popup */
@media (max-width: 768px) {
    /* Mobilde Bottom Sheet Tarzında */
    .custom-calendar-datepicker-popup {
        position: fixed !important;
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        transform: translateY(100%) !important;
        min-width: 100% !important;
        max-width: 100% !important;
        border-radius: 24px 24px 0 0 !important;
        max-height: 90vh !important;
        z-index: 9999 !important;
        margin: 0 !important;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15) !important;
    }

    .custom-calendar-datepicker-popup.show {
        opacity: 1 !important;
        visibility: visible !important;
        transform: translateY(0) !important;
    }

    /* Mobilde Sheet Handle Ekle */
    .custom-calendar-datepicker-popup::before {
    content: "";
        display: block;
        width: 48px;
        height: 6px;
        background: #d1d5db;
        border-radius: 3px;
        margin: 12px auto 8px;
    }

    .custom-calendar-datepicker-popup.range-mode,
    .custom-calendar-datepicker-popup.reservation-mode {
        min-width: 100% !important;
        max-width: 100% !important;
        max-height: 90vh !important;
        border-radius: 24px 24px 0 0 !important;
    }

    .custom-calendar-datepicker-range {
        flex-direction: column;
    }

    .custom-calendar-datepicker-range-connector {
        padding-top: 0;
        padding: 10px 0;
        justify-content: center;
    }
    
    /* Overlay mobilde daha yüksek z-index */
    .custom-calendar-datepicker-overlay {
        z-index: 9998 !important;
    }
    
    .custom-calendar-datepicker-overlay.show {
        opacity: 1 !important;
        visibility: visible !important;
    }
}

/* Date Picker Input - Focus State */
.custom-calendar-datepicker-input input:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* Date Picker Input - Disabled State */
.custom-calendar-datepicker-input.disabled input {
    background-color: #e9ecef;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Date Picker Input - Readonly State */
.custom-calendar-datepicker-input.readonly input {
    background-color: #f8f9fa;
    cursor: pointer;
}
