/**
 * ============================================================
 * Anadolu Birlik Sigorta — Online Randevu Özel Stillleri
 * ============================================================
 * Sadece Randevu Takvimi, Saat Slotları ve Görüşme Kartları Stilleri
 */

/* 1. GÖRÜŞME TERCİHİ SEÇİCİ */
.meeting-type-selector {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 5px;
}

.meeting-type-card {
    border: 2px solid var(--color-gray-light, #cbd5e1);
    border-radius: var(--radius-lg, 12px);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 18px;
    cursor: pointer;
    background-color: var(--color-white, #ffffff);
    transition: all var(--transition-base, 0.25s);
    position: relative;
    user-select: none;
}

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

.meeting-type-card:hover {
    border-color: var(--color-gold, #d4af37);
    background: var(--color-gold-subtle, rgba(212, 175, 55, 0.04));
    transform: translateY(-2px);
}

.meeting-type-card.active {
    border-color: var(--color-anthracite, #1b2d50);
    background: #fcfbf7;
    box-shadow: var(--shadow-md);
}

.meeting-type-card.active::after {
    content: '✓';
    position: absolute;
    top: 12px;
    right: 12px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--color-anthracite, #1b2d50);
    color: var(--color-white, #fff);
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.card-icon {
    font-size: 28px;
    flex-shrink: 0;
}

.card-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.card-title {
    font-weight: 700;
    color: var(--color-anthracite, #1b2d50);
    font-size: 15px;
}

.card-desc {
    font-size: 12px;
    color: var(--color-gray, #5a6b85);
    line-height: 1.4;
}

/* 2. TARİH SAAT SEÇİCİ (LAYOUT) */
.datetime-picker-layout {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 35px;
    align-items: start;
}

/* TAKVİM */
.calendar-wrapper {
    border: 1px solid var(--color-gray-light, #e2e8f0);
    border-radius: var(--radius-lg, 12px);
    padding: 24px;
    background: var(--color-white, #ffffff);
    box-shadow: var(--shadow-sm);
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 22px;
}

.calendar-nav-btn {
    background: none;
    border: 1px solid var(--color-gray-light, #cbd5e1);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: bold;
    color: var(--color-anthracite, #1b2d50);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast, 0.15s);
}

.calendar-nav-btn:hover {
    background: var(--color-anthracite, #1b2d50);
    color: var(--color-white, #ffffff);
    border-color: var(--color-anthracite, #1b2d50);
}

.calendar-current-month {
    font-weight: 700;
    font-size: 17px;
    color: var(--color-anthracite, #1b2d50);
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-weight: 700;
    font-size: 13px;
    color: var(--color-gray, #5a6b85);
    margin-bottom: 15px;
    border-bottom: 1px solid var(--color-gray-light, #e2e8f0);
    padding-bottom: 10px;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    row-gap: 10px;
    column-gap: 6px;
    text-align: center;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 500;
    border-radius: 50%;
    cursor: not-allowed;
    color: var(--color-gray-light, #cbd5e1);
    position: relative;
    transition: all var(--transition-base, 0.25s);
}

.calendar-day.empty {
    cursor: default;
}

/* Müsait Günler */
.calendar-day.available {
    cursor: pointer;
    color: var(--color-anthracite, #1b2d50);
    font-weight: 600;
}

.calendar-day.available::after {
    content: '';
    position: absolute;
    bottom: 5px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background-color: var(--color-success, #2ecc71);
}

.calendar-day.available:hover {
    background: var(--color-cream, #f4f6fa);
    color: var(--color-gold, #d4af37);
    transform: scale(1.1);
}

/* Seçili Gün */
.calendar-day.selected {
    background: var(--color-anthracite, #1b2d50) !important;
    color: var(--color-white, #ffffff) !important;
    font-weight: 700;
    box-shadow: var(--shadow-md);
}

.calendar-day.selected::after {
    background-color: var(--color-gold, #d4af37);
}

/* SAAT SLOTLARI */
.slots-wrapper {
    background: var(--color-white, #ffffff);
    border: 1px solid var(--color-gray-light, #cbd5e1);
    border-radius: var(--radius-lg, 12px);
    padding: 24px;
    height: 100%;
    min-height: 380px;
    display: flex;
    flex-direction: column;
}

.slots-title {
    font-size: 17px;
    font-weight: 700;
    color: var(--color-anthracite, #1b2d50);
    margin-bottom: 4px;
}

.slots-subtitle {
    font-size: 13px;
    color: var(--color-gray, #5a6b85);
    margin-bottom: 20px;
}

.slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(85px, 1fr));
    gap: 12px;
    overflow-y: auto;
    flex: 1;
    max-height: 280px;
    padding-right: 4px;
}

/* Slot Bulunamadı */
.no-date-selected, .no-slots-available {
    grid-column: span 12;
    text-align: center;
    color: var(--color-gray, #5a6b85);
    font-size: 14px;
    padding: 50px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    line-height: 1.5;
}

/* Saat Butonu */
.slot-btn {
    padding: 12px 6px;
    border: 1.5px solid var(--color-gray-light, #cbd5e1);
    border-radius: var(--radius-md, 8px);
    background: var(--color-white, #ffffff);
    color: var(--color-anthracite, #1b2d50);
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-base, 0.25s);
    text-align: center;
    outline: none;
}

.slot-btn:hover:not(:disabled) {
    border-color: var(--color-gold, #d4af37);
    color: var(--color-gold, #d4af37);
    background: var(--color-gold-subtle, rgba(212, 175, 55, 0.04));
}

.slot-btn.selected {
    background: var(--color-anthracite, #1b2d50) !important;
    border-color: var(--color-anthracite, #1b2d50) !important;
    color: var(--color-white, #ffffff) !important;
    box-shadow: var(--shadow-md);
}

.slot-btn:disabled {
    background: #f1f5f9;
    border-color: #e2e8f0;
    color: #94a3b8;
    cursor: not-allowed;
    text-decoration: line-through;
    opacity: 0.6;
}

/* 3. OTP DOĞRULAMA ALANI */
.otp-verification-container {
    max-width: 400px;
    margin: 40px auto;
    padding: 30px;
    border: 1px solid var(--color-gray-light, #e2e8f0);
    border-radius: var(--radius-lg, 12px);
    background: var(--color-white, #ffffff);
    text-align: center;
    box-shadow: var(--shadow-md);
}

.otp-timer-and-resend {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 25px;
    font-size: 13.5px;
    color: var(--color-gray, #5a6b85);
}

.btn-resend-otp {
    background: none;
    border: none;
    color: var(--color-gold, #d4af37);
    font-weight: 700;
    cursor: pointer;
    padding: 0;
    transition: color 0.2s;
}

.btn-resend-otp:disabled {
    color: var(--color-gray-muted, #8494ac);
    cursor: not-allowed;
}

/* 4. BAŞARI EKRANI VE ÖZET */
.success-screen-wrapper {
    text-align: center;
    max-width: 550px;
    margin: 0 auto;
    padding: 20px 0;
}

.success-icon {
    font-size: 64px;
    margin-bottom: 25px;
    animation: successPop 0.6s var(--transition-spring, cubic-bezier(0.34, 1.56, 0.64, 1)) forwards;
}

@keyframes successPop {
    0% { transform: scale(0.5); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.success-title {
    font-family: var(--font-display, Georgia, serif);
    font-size: 26px;
    color: var(--color-anthracite, #1b2d50);
    margin-bottom: 12px;
    font-weight: 700;
}

.success-desc {
    font-size: 14.5px;
    color: var(--color-gray, #5a6b85);
    line-height: 1.6;
    margin-bottom: 35px;
}

.appointment-summary-card {
    background: var(--color-cream, #f4f6fa);
    border: 1px solid var(--color-gray-light, #e2e8f0);
    border-radius: var(--radius-lg, 12px);
    padding: 24px;
    text-align: left;
    margin-bottom: 35px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--color-gray-light, #e2e8f0);
}

.summary-row:last-child {
    border-bottom: none;
}

.summary-label {
    font-weight: 600;
    color: var(--color-gray, #5a6b85);
    font-size: 13.5px;
}

.summary-value {
    font-weight: 700;
    color: var(--color-anthracite, #1b2d50);
    font-size: 14px;
}

.summary-value a {
    color: var(--color-gold, #d4af37);
    text-decoration: underline;
}

.calendar-add-buttons {
    margin-top: 25px;
}

/* 5. FORM HATA VE YARDIMCI DOĞRULAMA */
.invalid-feedback {
    display: none;
    color: var(--color-danger, #e74c3c);
    font-size: 12.5px;
    font-weight: 500;
    margin-top: 4px;
}

.form-input.error ~ .invalid-feedback,
.form-select.error ~ .invalid-feedback {
    display: block;
}

/* RESPONSIVE DÜZENLEMELER */
@media (max-width: 992px) {
    .datetime-picker-layout {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 768px) {
    .meeting-type-selector {
        grid-template-columns: 1fr;
    }
    
    .otp-verification-container {
        padding: 20px;
        margin: 20px auto;
    }
}

/* 6. BAŞARI EKRANI TAKVİM BUTONLARI */
.calendar-add-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 20px;
    flex-wrap: wrap;
    position: relative;
    z-index: 10;
    pointer-events: auto !important;
}

.calendar-add-buttons a {
    pointer-events: auto !important;
}

.calendar-add-buttons .btn--outline {
    color: var(--color-anthracite, #1B2D50) !important;
    border-color: var(--color-gray-light, #CED4E0) !important;
    background: transparent !important;
}

.calendar-add-buttons .btn--outline:hover {
    background: var(--color-gold, #D4AF37) !important;
    color: var(--color-charcoal, #0F1D38) !important;
    border-color: var(--color-gold, #D4AF37) !important;
}

/* 7. LOADING OVERLAY VE SPINNER STİLLERİ */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 29, 56, 0.75);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity var(--transition-base, 0.25s), visibility var(--transition-base, 0.25s);
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.loading-overlay .spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.2);
    border-left-color: var(--color-gold, #D4AF37);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

