/* =============================================================================
   Berber Randevu Sistemi — Modern Yeşil/Krem Tema
   ============================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
    --green-dark:   #1a3c2e;
    --green-mid:    #2d6a4f;
    --green-light:  #40916c;
    --green-pale:   #d8f3dc;
    --cream:        #fdf8f0;
    --cream-dark:   #f5ede0;
    --gold:         #c9a84c;
    --gold-light:   #e8c97a;
    --text-dark:    #1a2e1f;
    --text-mid:     #4a5e50;
    --text-light:   #8a9e90;
    --white:        #ffffff;
    --shadow-sm:    0 2px 8px rgba(26,60,46,.12);
    --shadow-md:    0 8px 24px rgba(26,60,46,.18);
    --shadow-lg:    0 20px 60px rgba(26,60,46,.28);
    --radius:       14px;
    --radius-sm:    8px;
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* --- Body: Arka Plan --- */
body {
    min-height: 100vh;
    font-family: 'Inter', 'Segoe UI', sans-serif;
    color: var(--text-dark);
    padding: 2rem 1rem;

    /* Modern şehir/kuaför fotoğrafı — Unsplash CDN */
    background-image:
        linear-gradient(
            160deg,
            rgba(26, 60, 46, 0.82) 0%,
            rgba(45, 106, 79, 0.70) 50%,
            rgba(26, 60, 46, 0.88) 100%
        ),
        url('https://images.unsplash.com/photo-1585747860715-2ba37e788b70?w=1600&q=80&auto=format&fit=crop');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

/* --- Ana Kart --- */
.booking-container {
    max-width: 640px;
    margin: 0 auto;
    background: rgba(253, 248, 240, 0.97);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    border: 1px solid rgba(201, 168, 76, 0.25);
}

/* --- Başlık --- */
.header {
    background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-mid) 100%);
    color: var(--white);
    padding: 2.25rem 2rem 1.75rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: -40px; right: -40px;
    width: 180px; height: 180px;
    background: rgba(201, 168, 76, 0.12);
    border-radius: 50%;
}

.header::after {
    content: '';
    position: absolute;
    bottom: -30px; left: -30px;
    width: 120px; height: 120px;
    background: rgba(255,255,255, 0.06);
    border-radius: 50%;
}

.header h1 {
    font-size: 1.85rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    position: relative;
    z-index: 1;
    margin-bottom: 0.4rem;
}

.header p {
    opacity: 0.82;
    font-size: 0.95rem;
    position: relative;
    z-index: 1;
    font-weight: 400;
}

/* --- İçerik --- */
.p-4 { padding: 2rem; }

/* --- Grid --- */
.row { display: flex; flex-wrap: wrap; margin: 0 -0.5rem; }
.col-md-6 { flex: 0 0 50%; padding: 0 0.5rem; }
.mb-4 { margin-bottom: 1.5rem; }

/* --- Etiket --- */
.form-label {
    display: block;
    margin-bottom: 0.45rem;
    font-weight: 600;
    color: var(--text-mid);
    font-size: 0.88rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

/* --- Input / Select --- */
.form-control {
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.97rem;
    font-family: inherit;
    border: 2px solid var(--cream-dark);
    border-radius: var(--radius-sm);
    background: var(--white);
    color: var(--text-dark);
    transition: border-color .18s, box-shadow .18s;
}

.form-control:focus {
    border-color: var(--green-mid);
    outline: 0;
    box-shadow: 0 0 0 3px rgba(45,106,79,.15);
}

input[type="date"].form-control {
    cursor: pointer;
}

select.form-control { cursor: pointer; }

/* --- Hızlı Tarih Butonları --- */
.quick-dates {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.55rem;
}

.quick-date {
    padding: 0.38rem 1rem;
    border: 2px solid var(--cream-dark);
    border-radius: 20px;
    background: var(--white);
    cursor: pointer;
    font-size: 0.83rem;
    font-weight: 600;
    color: var(--text-mid);
    font-family: inherit;
    transition: all .18s;
}

.quick-date:hover { border-color: var(--green-mid); color: var(--green-mid); }

.quick-date.active {
    background: var(--green-mid);
    border-color: var(--green-mid);
    color: var(--white);
}

/* --- Doluluk Göstergesi --- */
.legend {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 0.85rem;
    font-size: 0.83rem;
    color: var(--text-light);
}

.legend-item { display: flex; align-items: center; gap: 0.45rem; }

.legend-color {
    width: 16px; height: 16px;
    border-radius: 4px; flex-shrink: 0;
}

.available-color { background: #d8f3dc; border: 2px solid var(--green-light); }
.busy-color      { background: #fde8e8; border: 2px solid #e05252; }

/* --- Saat Slotları --- */
.time-slots-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    min-height: 3rem;
}

.time-slot {
    padding: 0.55rem 1rem;
    border: 2px solid var(--cream-dark);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    font-size: 0.88rem;
    font-family: inherit;
    background: var(--white);
    transition: transform .15s, box-shadow .15s, background .15s, border-color .15s;
    line-height: 1;
}

.time-slot.available {
    background: var(--green-pale);
    border-color: var(--green-light);
    color: var(--green-dark);
}

.time-slot.busy {
    background: #fde8e8;
    border-color: #e05252;
    color: #8b2020;
    cursor: not-allowed;
    opacity: 0.65;
}

.time-slot.selected {
    background: var(--green-mid) !important;
    border-color: var(--green-mid) !important;
    color: var(--white) !important;
    transform: scale(1.07);
    box-shadow: 0 4px 14px rgba(45,106,79,.35);
}

.time-slot.available:hover:not(.selected) {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
    border-color: var(--green-mid);
}

/* --- Sonraki Gün Butonu --- */
.btn-next-day {
    padding: 0.55rem 1.1rem;
    border: 2px solid var(--green-mid);
    border-radius: var(--radius-sm);
    background: var(--white);
    color: var(--green-mid);
    font-weight: 600;
    font-size: 0.88rem;
    font-family: inherit;
    cursor: pointer;
    transition: background .18s, color .18s;
}

.btn-next-day:hover { background: var(--green-mid); color: var(--white); }

/* --- Seçim Özeti --- */
.booking-summary {
    background: linear-gradient(90deg, var(--green-pale), #f0faf2);
    border: 1.5px solid var(--green-light);
    color: var(--green-dark);
    border-radius: var(--radius-sm);
    padding: 0.8rem 1.1rem;
    margin-bottom: 1.1rem;
    font-weight: 600;
    font-size: 0.92rem;
}

/* --- Mesaj Kutusu --- */
.booking-message {
    padding: 0.85rem 1.1rem;
    border-radius: var(--radius-sm);
    margin-bottom: 1rem;
    font-weight: 500;
    font-size: 0.92rem;
}

.booking-message.success {
    background: var(--green-pale);
    color: var(--green-dark);
    border: 1.5px solid var(--green-light);
}

.booking-message.error {
    background: #fde8e8;
    color: #7a1f1f;
    border: 1.5px solid #e05252;
}

/* --- Randevu Al Butonu --- */
.btn-book {
    display: block;
    width: 100%;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 700;
    font-family: inherit;
    letter-spacing: 0.03em;
    text-align: center;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-mid) 100%);
    color: var(--white);
    position: relative;
    overflow: hidden;
    transition: transform .18s, box-shadow .18s;
}

.btn-book::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(201,168,76,.25), transparent);
    opacity: 0;
    transition: opacity .18s;
}

.btn-book:hover:not(:disabled)::after { opacity: 1; }

.btn-book:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(26,60,46,.35);
}

.btn-book:disabled {
    background: #c8d5cb;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* --- Geri Linki --- */
.back-link {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.88rem;
}

.back-link a {
    color: var(--green-mid);
    text-decoration: none;
    font-weight: 500;
}

.back-link a:hover { text-decoration: underline; }

/* --- Yardımcı --- */
.text-muted  { color: var(--text-light); font-size: 0.9rem; }
.text-danger { color: #e05252; font-size: 0.9rem; }

/* --- Divider --- */
.section-divider {
    border: none;
    border-top: 1.5px solid var(--cream-dark);
    margin: 1.5rem 0;
}

/* --- Responsive --- */
@media (max-width: 600px) {
    body { padding: 0; background-attachment: scroll; }

    .booking-container {
        border-radius: 0;
        box-shadow: none;
        min-height: 100vh;
    }

    .col-md-6 { flex: 0 0 100%; margin-bottom: 0.75rem; }

    .header { padding: 1.75rem 1.25rem 1.5rem; }
    .header h1 { font-size: 1.5rem; }

    .p-4 { padding: 1.25rem; }
}

/* --- Randevu Onay Ekranı --- */
.booking-confirm {
    text-align: center;
    padding: 1.5rem 0 0.5rem;
}

.confirm-icon { font-size: 4rem; margin-bottom: 0.75rem; }

.booking-confirm h2 {
    font-size: 1.45rem;
    color: var(--green-dark);
    margin: 0 0 1.5rem;
    font-weight: 700;
}

.confirm-details {
    background: var(--cream);
    border: 1.5px solid var(--cream-dark);
    border-radius: var(--radius-sm);
    padding: 1rem 1.25rem;
    text-align: left;
    margin-bottom: 0.5rem;
}

.confirm-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.55rem 0;
    border-bottom: 1px solid var(--cream-dark);
    font-size: 0.92rem;
}

.confirm-row:last-child { border-bottom: none; }
.confirm-row span  { color: var(--text-light); }
.confirm-row strong { color: var(--text-dark); font-weight: 600; }
