/* ═══════════════════════════════════════════════════════════════
   Fizyoterapi, Manuel Terapi & Kayropraktik — Global Stiller & Dinamik Tema Paletleri
   Tailwind CDN ile uyumlu, 4 Medikal & Rehabilitasyon Teması Destekli
   ═══════════════════════════════════════════════════════════════ */

/* ── Temel ───────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ── FİZYOTERAPİ & REHABİLİTASYON TEMALARI ────────────────── */
/* 1. Medikal Petrol & Klinik Turkuaz (Varsayılan - clinical_teal) */
body.theme-clinical_teal, body:not([class*="theme-"]) {
    --bg-main: #f0fdfa;
    --bg-card: #ffffff;
    --bg-subcard: #ccfbf1;
    --border-color: #99f6e4;
    --border-hover: #2dd4bf;
    --text-primary: #134e4a;
    --text-secondary: #115e59;
    --btn-primary: #0d9488;
    --btn-primary-hover: #0f766e;
    --btn-primary-50: #f0fdfa;
    --btn-primary-100: #ccfbf1;
    --btn-primary-200: #99f6e4;
    --btn-primary-800: #115e59;
    --accent: #14b8a6;
    --hero-gradient: linear-gradient(145deg, #042f2e 0%, #134e4a 35%, #115e59 70%, #0d9488 100%);
}

/* 2. Kobalt & Dinamik Hareket (theme-kinetic_blue) */
body.theme-kinetic_blue {
    --bg-main: #eff6ff;
    --bg-card: #ffffff;
    --bg-subcard: #dbeafe;
    --border-color: #bfdbfe;
    --border-hover: #60a5fa;
    --text-primary: #1e3a8a;
    --text-secondary: #1e40af;
    --btn-primary: #2563eb;
    --btn-primary-hover: #1d4ed8;
    --btn-primary-50: #eff6ff;
    --btn-primary-100: #dbeafe;
    --btn-primary-200: #bfdbfe;
    --btn-primary-800: #1e3a8a;
    --accent: #3b82f6;
    --hero-gradient: linear-gradient(145deg, #0f172a 0%, #1e3a8a 35%, #1e40af 70%, #2563eb 100%);
}

/* 3. Zümrüt & Biyolojik İyileşme (theme-health_emerald) */
body.theme-health_emerald {
    --bg-main: #ecfdf5;
    --bg-card: #ffffff;
    --bg-subcard: #d1fae5;
    --border-color: #a7f3d0;
    --border-hover: #34d399;
    --text-primary: #064e3b;
    --text-secondary: #065f46;
    --btn-primary: #059669;
    --btn-primary-hover: #047857;
    --btn-primary-50: #ecfdf5;
    --btn-primary-100: #d1fae5;
    --btn-primary-200: #a7f3d0;
    --btn-primary-800: #064e3b;
    --accent: #10b981;
    --hero-gradient: linear-gradient(145deg, #022c22 0%, #064e3b 35%, #065f46 70%, #059669 100%);
}

/* 4. Modern Grafit & Buz Mavisi (theme-slate_graphite) */
body.theme-slate_graphite {
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --bg-subcard: #f1f5f9;
    --border-color: #cbd5e1;
    --border-hover: #94a3b8;
    --text-primary: #0f172a;
    --text-secondary: #334155;
    --btn-primary: #475569;
    --btn-primary-hover: #334155;
    --btn-primary-50: #f8fafc;
    --btn-primary-100: #f1f5f9;
    --btn-primary-200: #cbd5e1;
    --btn-primary-800: #0f172a;
    --accent: #0ea5e9;
    --hero-gradient: linear-gradient(145deg, #020617 0%, #0f172a 35%, #1e293b 70%, #334155 100%);
}

/* ── Dinamik Tema Renk Bağlamaları (Tüm Arayüzü Canlı Yönetir) ─── */
body {
    background-color: var(--bg-main) !important;
    color: var(--text-primary) !important;
}

.hero-default-bg {
    background: var(--hero-gradient) !important;
}

.bg-forest-600,
button.bg-forest-600,
a.bg-forest-600,
div.bg-forest-600,
span.bg-forest-600 {
    background-color: var(--btn-primary, #0d9488) !important;
    color: #ffffff !important;
}

.hover\:bg-forest-700:hover,
button.hover\:bg-forest-700:hover,
a.hover\:bg-forest-700:hover {
    background-color: var(--btn-primary-hover, #0f766e) !important;
    color: #ffffff !important;
}

.text-forest-600,
i.text-forest-600,
span.text-forest-600,
strong.text-forest-600,
a.text-forest-600 {
    color: var(--btn-primary, #0d9488) !important;
}

.border-forest-600 {
    border-color: var(--btn-primary, #0d9488) !important;
}

.focus\:border-forest-600:focus {
    border-color: var(--btn-primary, #0d9488) !important;
}

.bg-forest-600\/10 {
    background-color: color-mix(in srgb, var(--btn-primary, #0d9488) 10%, transparent) !important;
}

.bg-forest-600\/15 {
    background-color: color-mix(in srgb, var(--btn-primary, #0d9488) 15%, transparent) !important;
}

.border-cream-200 {
    border-color: var(--border-color, #99f6e4) !important;
}

.border-cream-100 {
    border-color: var(--border-color, #99f6e4) !important;
}

.bg-cream-100 {
    background-color: var(--bg-subcard, #ccfbf1) !important;
}

.bg-cream-50 {
    background-color: var(--bg-card, #ffffff) !important;
}

/* ── Scrollbar ───────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: rgba(0,0,0,0.04); }
::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.2); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.35); }

/* ── Nav Geçiş Efektleri ─────────────────────────────────────── */
#main-nav {
    transition: background-color 0.3s ease,
                border-color     0.3s ease,
                box-shadow       0.3s ease,
                backdrop-filter  0.3s ease;
}

.nav-link {
    position: relative;
    transition: color 0.2s ease;
}
.nav-link:hover::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    right: 0;
    height: 2px;
    background: currentColor;
    border-radius: 1px;
}

/* ── Form Elemanları ─────────────────────────────────────────── */
.bk-field {
    -webkit-appearance: none;
    -moz-appearance:    none;
    appearance:         none;
    transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.bk-field:focus {
    border-color: var(--btn-primary, #0d9488);
    background-color: #ffffff;
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.15);
}

/* Tarih Input İkonu (Yalnızca Ön Yüz Hızlı Randevu Kartı ve Sihirbaz İleri Tarih için) */
.bk-field[type="date"]::-webkit-calendar-picker-indicator,
#wz-custom-date::-webkit-calendar-picker-indicator {
    opacity: 0;
    position: absolute;
    right: 0;
    top: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

/* Standart ve Admin modal tarih inputları için katman çakışmasını önle */
input[type="date"]:not(.bk-field):not(#wz-custom-date)::-webkit-calendar-picker-indicator {
    position: static;
    width: auto;
    height: auto;
    opacity: 1;
    cursor: pointer;
}

/* ── Modal Animasyonları ─────────────────────────────────────── */
.modal-overlay {
    animation: fadeIn 0.2s ease;
}

.modal-overlay > div {
    animation: slideUp 0.25s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(16px) scale(0.98); }
    to   { opacity: 1; transform: translateY(0)    scale(1);    }
}

/* ── Galeri Kartları ─────────────────────────────────────────── */
.gallery-item {
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}
.gallery-item:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}
.gallery-item img {
    transition: transform 0.5s ease;
}
.gallery-item:hover img {
    transform: scale(1.05);
}

/* ── Buton Vurguları ─────────────────────────────────────────── */
.btn-primary-theme {
    background-color: var(--btn-primary, #0d9488);
    color: #ffffff;
    transition: all 0.2s ease;
}
.btn-primary-theme:hover {
    background-color: var(--btn-primary-hover, #0f766e);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

/* ── 3 Adımlı Sihirbaz Seçim Kartları ───────────────────────── */
.wizard-card {
    transition: all 0.2s ease;
    cursor: pointer;
}
.wizard-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}
.wizard-card.active {
    border-color: var(--btn-primary, #0d9488) !important;
    background-color: var(--bg-subcard, #ccfbf1) !important;
    box-shadow: 0 0 0 2px var(--btn-primary, #0d9488), 0 8px 24px rgba(13, 148, 136, 0.15) !important;
}

/* ── Randevu Saat Hapları (Slot Pills) ────────────────────────── */
.slot-pill {
    transition: all 0.2s ease;
    cursor: pointer;
}
.slot-pill.active,
button.slot-pill.active,
.slot-pill.border-forest-600.bg-forest-600,
button.slot-pill.border-forest-600.bg-forest-600 {
    background-color: var(--btn-primary, #0d9488) !important;
    border-color: var(--btn-primary, #0d9488) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(13, 148, 136, 0.3) !important;
}

/* ── Adım Hapları (Step Pills) ───────────────────────────────── */
.wz-pill.bg-forest-600,
div.wz-pill.border-forest-600.bg-forest-600,
.wz-pill.border-forest-600.bg-forest-600 {
    background-color: var(--btn-primary, #0d9488) !important;
    border-color: var(--btn-primary, #0d9488) !important;
    color: #ffffff !important;
}

.wz-pill.bg-forest-600\/15,
div.wz-pill.bg-forest-600\/15,
div.wz-pill.border-forest-600.bg-forest-600\/15 {
    background-color: #ccfbf1 !important;
    border-color: #0d9488 !important;
    color: #0d9488 !important;
}

/* ── Sihirbaz İlerleme & Onay Butonları ───────────────────────── */
#wz-btn-step1,
#wz-btn-step2,
#wz-submit-btn,
#bk-hero-btn {
    transition: all 0.2s ease;
}

#wz-btn-step1:not(:disabled),
#wz-btn-step2:not(:disabled),
#wz-submit-btn:not(:disabled),
#bk-hero-btn:not(:disabled) {
    background-color: var(--btn-primary, #0d9488) !important;
    border-color: var(--btn-primary, #0d9488) !important;
    color: #ffffff !important;
    box-shadow: 0 6px 18px rgba(13, 148, 136, 0.25) !important;
}

#wz-btn-step1:not(:disabled):hover,
#wz-btn-step2:not(:disabled):hover,
#wz-submit-btn:not(:disabled):hover,
#bk-hero-btn:not(:disabled):hover {
    background-color: var(--btn-primary-hover, #0f766e) !important;
    transform: translateY(-1px);
    box-shadow: 0 8px 22px rgba(13, 148, 136, 0.35) !important;
}

#wz-btn-step1:disabled,
#wz-btn-step2:disabled,
#wz-submit-btn:disabled,
#bk-hero-btn:disabled {
    background-color: #cbd5e1 !important;
    border-color: #cbd5e1 !important;
    color: #64748b !important;
    opacity: 0.75 !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
}

/* ── Modern Randevu Sihirbazı Tarih Kartları (Adım 2) ────────── */
.wz-date-btn, 
.wz-custom-date-card {
    transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    user-select: none;
    background-color: #ffffff;
    border: 1.5px solid var(--border-color, #99f6e4);
    border-radius: 1.1rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.03);
}

.wz-date-btn:hover, 
.wz-custom-date-card:hover {
    border-color: var(--btn-primary, #0d9488);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px -3px rgba(13, 148, 136, 0.15);
}

.wz-date-btn.active, 
.wz-custom-date-card.active {
    background: linear-gradient(145deg, var(--btn-primary, #0d9488), var(--btn-primary-hover, #0f766e)) !important;
    border-color: var(--btn-primary, #0d9488) !important;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 10px 24px -3px rgba(13, 148, 136, 0.35), 0 0 0 2px rgba(13, 148, 136, 0.25) !important;
}

.wz-date-btn.active .wz-day-badge, 
.wz-custom-date-card.active .wz-day-badge {
    background-color: rgba(255, 255, 255, 0.22) !important;
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
}

.wz-date-btn.active .wz-day-num,
.wz-date-btn.active .wz-day-month,
.wz-custom-date-card.active #wz-custom-day-text,
.wz-custom-date-card.active #wz-custom-day-text i {
    color: #ffffff !important;
}

.wz-date-btn.active .wz-day-dot,
.wz-custom-date-card.active .wz-day-dot {
    background-color: #ffffff !important;
    opacity: 1 !important;
    transform: scale(1.3);
}

/* ── Tema Uyarlamaları ────────────────────────────────────────── */
body.theme-clinical_teal {
    --primary: #0d9488;
    --primary-hover: #0f766e;
}

body.theme-kinetic_blue {
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
}

body.theme-health_emerald {
    --primary: #059669;
    --primary-hover: #047857;
}

body.theme-slate_graphite {
    --primary: #475569;
    --primary-hover: #334155;
}

body.theme-clinical_teal .wz-date-btn.active, 
body.theme-clinical_teal .wz-custom-date-card.active {
    background: linear-gradient(145deg, #0d9488, #0f766e) !important;
    border-color: #0d9488 !important;
    box-shadow: 0 10px 24px -3px rgba(13, 148, 136, 0.35) !important;
}

body.theme-kinetic_blue .wz-date-btn.active, 
body.theme-kinetic_blue .wz-custom-date-card.active {
    background: linear-gradient(145deg, #2563eb, #1d4ed8) !important;
    border-color: #2563eb !important;
    box-shadow: 0 10px 24px -3px rgba(37, 99, 235, 0.35) !important;
}

body.theme-health_emerald .wz-date-btn.active, 
body.theme-health_emerald .wz-custom-date-card.active {
    background: linear-gradient(145deg, #059669, #047857) !important;
    border-color: #059669 !important;
    box-shadow: 0 10px 24px -3px rgba(5, 150, 105, 0.35) !important;
}

body.theme-slate_graphite .wz-date-btn.active, 
body.theme-slate_graphite .wz-custom-date-card.active {
    background: linear-gradient(145deg, #475569, #334155) !important;
    border-color: #475569 !important;
    box-shadow: 0 10px 24px -3px rgba(71, 85, 105, 0.35) !important;
}

/* ── Admin Canlı Bildirim Animasyonları ───────────────────────── */
@keyframes bellRing {
    0%, 100% { transform: rotate(0); }
    15% { transform: rotate(14deg); }
    30% { transform: rotate(-14deg); }
    45% { transform: rotate(10deg); }
    60% { transform: rotate(-10deg); }
    75% { transform: rotate(4deg); }
    85% { transform: rotate(-4deg); }
}
.bell-ring {
    animation: bellRing 0.8s ease-in-out;
    transform-origin: top center;
}
