/* === Google Fonts === */
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800&family=Poppins:wght@300;400;500;600;700;800&display=swap');

/* === Variables === */
:root {
  --primary: #1B4F72;
  --primary-light: #2E86C1;
  --primary-dark: #154360;
  --accent: #48CAE4;
  --accent-light: #90E0EF;
  --success: #27AE60;
  --warning: #F39C12;
  --danger: #E74C3C;
  --text: #2C3E50;
  --text-muted: #7F8C8D;
  --bg: #F8FAFD;
  --bg-card: #FFFFFF;
  --border: #E8EDF2;
  --shadow: 0 4px 20px rgba(27,79,114,0.10);
  --shadow-lg: 0 10px 40px rgba(27,79,114,0.15);
  --radius: 12px;
  --radius-lg: 20px;
  --transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
}

/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: 'Cairo', 'Poppins', sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  overflow-x: hidden;
}
body[dir="ltr"] { font-family: 'Poppins', 'Cairo', sans-serif; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
button { cursor: pointer; border: none; outline: none; }
input, textarea, select { outline: none; font-family: inherit; }

/* === Utility === */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.text-center { text-align: center; }
.text-primary { color: var(--primary); }
.bg-primary { background: var(--primary); }
.mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; } .mb-2 { margin-bottom: 16px; } .mb-3 { margin-bottom: 24px; }
.d-flex { display: flex; } .gap-1 { gap: 8px; } .gap-2 { gap: 16px; }
.flex-wrap { flex-wrap: wrap; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.w-100 { width: 100%; }
.hidden { display: none !important; }

/* === Scrollbar === */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--primary-light); border-radius: 3px; }

/* ==================== NAVBAR ==================== */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}
.navbar.scrolled { box-shadow: var(--shadow); }
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 70px;
}
.nav-brand {
  display: flex; align-items: center; gap: 12px;
}
.nav-logo {
  width: 44px; height: 44px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
}
.nav-title { font-size: 16px; font-weight: 700; color: var(--primary); line-height: 1.2; }
.nav-subtitle { font-size: 11px; color: var(--text-muted); }
.nav-links {
  display: flex; align-items: center; gap: 2px;
  list-style: none;
}
.nav-links a {
  display: flex; align-items: center;
  padding: 7px 11px; border-radius: 8px;
  font-size: 13px; font-weight: 500; color: var(--text);
  transition: var(--transition); white-space: nowrap;
}
.nav-links a:hover {
  background: rgba(27,79,114,.08); color: var(--primary);
}
.nav-links a.active {
  background: var(--primary); color: white; font-weight: 700;
}
.nav-links a.active:hover {
  background: var(--primary-dark, #163d5a); color: white;
}
.nav-actions {
  display: flex; align-items: center; gap: 10px;
}
.lang-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 8px;
  font-size: 13px; font-weight: 600;
  background: var(--bg); color: var(--primary);
  border: 1px solid var(--border);
  transition: var(--transition);
}
.lang-btn:hover { background: var(--primary); color: white; }
.nav-book-btn {
  padding: 9px 20px; border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: white; font-size: 14px; font-weight: 600;
  transition: var(--transition); white-space: nowrap;
}
.nav-book-btn:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.hamburger {
  display: none; flex-direction: column; gap: 5px;
  background: none; padding: 5px;
}
.hamburger span {
  display: block; width: 24px; height: 2px;
  background: var(--primary); border-radius: 2px;
  transition: var(--transition);
}
.mobile-nav {
  display: none; position: fixed; top: 70px; left: 0; right: 0;
  background: white; border-bottom: 1px solid var(--border);
  padding: 16px 20px; z-index: 999;
  box-shadow: var(--shadow);
}
.mobile-nav.open { display: block; }
.mobile-nav a {
  display: block; padding: 12px 0;
  border-bottom: 1px solid var(--border);
  font-size: 15px; font-weight: 500; color: var(--text);
}
.mobile-nav a:last-child { border-bottom: none; }

/* ==================== HERO ==================== */
.hero {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
  display: flex; align-items: center;
  padding-top: 70px; position: relative; overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-inner {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 60px; align-items: center; position: relative; z-index: 1;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.15); backdrop-filter: blur(10px);
  color: white; padding: 8px 18px; border-radius: 30px;
  font-size: 13px; font-weight: 600; margin-bottom: 24px;
  border: 1px solid rgba(255,255,255,0.2);
}
.hero-title {
  font-size: clamp(36px, 5vw, 56px); font-weight: 800;
  color: white; line-height: 1.15; margin-bottom: 12px;
}
.hero-subtitle {
  font-size: 20px; font-weight: 500; color: var(--accent-light);
  margin-bottom: 20px;
}
.hero-desc {
  font-size: 16px; color: rgba(255,255,255,0.8);
  line-height: 1.8; margin-bottom: 36px; max-width: 500px;
}
.hero-btns { display: flex; gap: 16px; flex-wrap: wrap; }
.btn-hero-primary {
  padding: 14px 32px; border-radius: 12px;
  background: white; color: var(--primary);
  font-size: 15px; font-weight: 700;
  transition: var(--transition);
  box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}
.btn-hero-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(0,0,0,0.25); }
.btn-hero-secondary {
  padding: 14px 32px; border-radius: 12px;
  background: rgba(255,255,255,0.15); color: white;
  font-size: 15px; font-weight: 600;
  border: 2px solid rgba(255,255,255,0.3);
  transition: var(--transition);
}
.btn-hero-secondary:hover { background: rgba(255,255,255,0.25); }
.hero-visual {
  position: relative; display: flex; justify-content: center;
}
.hero-card {
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius-lg);
  padding: 40px;
  text-align: center; color: white;
}
.hero-icon { font-size: 100px; margin-bottom: 20px; display: block; }
.hero-stats-mini {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 16px; margin-top: 24px;
}
.hero-stat-item {
  background: rgba(255,255,255,0.1); border-radius: 10px;
  padding: 14px; text-align: center;
}
.hero-stat-num { font-size: 24px; font-weight: 800; }
.hero-stat-label { font-size: 11px; opacity: 0.8; margin-top: 2px; }

/* ==================== STATS SECTION ==================== */
.stats-section {
  background: white;
  padding: 60px 0;
  box-shadow: var(--shadow);
}
.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}
.stat-card {
  text-align: center; padding: 30px 20px;
  border-radius: var(--radius);
  background: var(--bg);
  transition: var(--transition);
}
.stat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.stat-icon {
  width: 60px; height: 60px; border-radius: 16px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; margin: 0 auto 16px;
}
.stat-num {
  font-size: 36px; font-weight: 800; color: var(--primary);
  line-height: 1;
}
.stat-label { font-size: 14px; color: var(--text-muted); margin-top: 6px; }

/* ==================== SECTION HEADER ==================== */
.section-header { text-align: center; margin-bottom: 50px; }
.section-tag {
  display: inline-block;
  background: rgba(27,79,114,0.08); color: var(--primary);
  padding: 6px 18px; border-radius: 20px;
  font-size: 13px; font-weight: 600; margin-bottom: 14px;
  border: 1px solid rgba(27,79,114,0.12);
}
.section-title {
  font-size: clamp(26px, 4vw, 38px); font-weight: 800;
  color: var(--text); line-height: 1.2; margin-bottom: 14px;
}
.section-subtitle {
  font-size: 16px; color: var(--text-muted);
  max-width: 500px; margin: 0 auto;
}

/* ==================== SERVICES ==================== */
.services-section { padding: 80px 0; }
.services-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.service-card {
  background: white; border-radius: var(--radius-lg);
  padding: 36px 28px; border: 1px solid var(--border);
  transition: var(--transition); position: relative; overflow: hidden;
}
.service-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transform: scaleX(0); transform-origin: left;
  transition: var(--transition);
}
.service-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.service-card:hover::before { transform: scaleX(1); }
.service-icon { font-size: 46px; margin-bottom: 18px; display: block; }
.service-title { font-size: 18px; font-weight: 700; color: var(--primary); margin-bottom: 10px; }
.service-desc { font-size: 14px; color: var(--text-muted); line-height: 1.7; }

/* ==================== BOOKING PAGE ==================== */
.page-hero {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  padding: 100px 0 50px; text-align: center; color: white;
}
.page-hero h1 { font-size: 38px; font-weight: 800; margin-bottom: 10px; }
.page-hero p { font-size: 16px; opacity: 0.85; }

.booking-section { padding: 60px 0; }
.booking-container { max-width: 860px; margin: 0 auto; }

/* Steps indicator */
.steps-bar {
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 44px; gap: 0;
}
.step-item {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  position: relative;
}
.step-item:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 20px;
  width: 100px;
  height: 2px;
  background: var(--border);
  transition: var(--transition);
}
body[dir="rtl"] .step-item:not(:last-child)::after { right: 100%; }
body[dir="ltr"] .step-item:not(:last-child)::after { left: 100%; }
.step-item.done::after { background: var(--primary); }
.step-num {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; color: var(--text-muted);
  transition: var(--transition); position: relative; z-index: 1;
}
.step-item.active .step-num {
  background: var(--primary); color: white; border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(27,79,114,0.15);
}
.step-item.done .step-num { background: var(--success); border-color: var(--success); color: white; }
.step-label { font-size: 12px; color: var(--text-muted); font-weight: 500; white-space: nowrap; }
.step-item.active .step-label { color: var(--primary); font-weight: 600; }

/* Booking card */
.booking-card {
  background: white; border-radius: var(--radius-lg);
  box-shadow: var(--shadow); padding: 40px;
}
.booking-step { display: none; }
.booking-step.active { display: block; }
.booking-step-title {
  font-size: 22px; font-weight: 700; color: var(--text);
  margin-bottom: 28px; display: flex; align-items: center; gap: 10px;
}
.booking-step-title .step-icon {
  width: 42px; height: 42px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: white;
}

/* Branch cards */
.branch-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.branch-card {
  border: 2px solid var(--border); border-radius: var(--radius);
  padding: 20px; cursor: pointer; transition: var(--transition);
}
.branch-card:hover { border-color: var(--primary-light); background: rgba(27,79,114,0.02); }
.branch-card.selected { border-color: var(--primary); background: rgba(27,79,114,0.04); }
.branch-card-name { font-size: 16px; font-weight: 700; color: var(--primary); margin-bottom: 6px; }
.branch-card-addr { font-size: 13px; color: var(--text-muted); margin-bottom: 4px; }
.branch-card-phone { font-size: 13px; color: var(--text-muted); }

/* Date picker */
.date-picker-wrapper { max-width: 360px; }
.date-picker-wrapper input[type="date"] {
  width: 100%; padding: 14px 16px; border-radius: var(--radius);
  border: 2px solid var(--border); font-size: 15px; font-family: inherit;
  color: var(--text); transition: var(--transition);
}
.date-picker-wrapper input[type="date"]:focus { border-color: var(--primary); }

/* Time slots */
.slots-grid { display: flex; flex-wrap: wrap; gap: 12px; }
.slot-btn {
  padding: 10px 20px; border-radius: 10px;
  border: 2px solid var(--border); background: white;
  font-size: 14px; font-weight: 600; color: var(--text);
  transition: var(--transition); font-family: inherit;
}
.slot-btn:hover { border-color: var(--primary-light); color: var(--primary); }
.slot-btn.selected {
  background: var(--primary); border-color: var(--primary); color: white;
}
.no-slots-msg {
  text-align: center; padding: 40px; color: var(--text-muted);
  font-size: 15px;
}
.no-slots-msg .no-slots-icon { font-size: 40px; margin-bottom: 12px; }

/* Form fields */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block; font-size: 14px; font-weight: 600;
  color: var(--text); margin-bottom: 8px;
}
.form-label .req { color: var(--danger); }
.form-control {
  width: 100%; padding: 12px 16px; border-radius: 10px;
  border: 2px solid var(--border); font-size: 15px; font-family: inherit;
  color: var(--text); background: white; transition: var(--transition);
}
.form-control:focus { border-color: var(--primary); }
.form-control.error { border-color: var(--danger); }
.form-error { font-size: 12px; color: var(--danger); margin-top: 4px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* Guest/Login toggle */
.auth-toggle {
  display: flex; background: var(--bg); border-radius: 12px;
  padding: 4px; margin-bottom: 24px;
}
.auth-toggle-btn {
  flex: 1; padding: 10px; border-radius: 9px;
  font-size: 14px; font-weight: 600; color: var(--text-muted);
  background: none; transition: var(--transition);
}
.auth-toggle-btn.active {
  background: white; color: var(--primary);
  box-shadow: var(--shadow);
}

/* Booking summary */
.booking-summary {
  background: var(--bg); border-radius: var(--radius);
  padding: 20px; margin-bottom: 24px;
}
.summary-row {
  display: flex; justify-content: space-between;
  padding: 8px 0; border-bottom: 1px solid var(--border);
  font-size: 14px;
}
.summary-row:last-child { border-bottom: none; }
.summary-label { color: var(--text-muted); }
.summary-value { font-weight: 600; color: var(--text); }

/* Navigation buttons */
.step-nav {
  display: flex; justify-content: space-between;
  align-items: center; margin-top: 32px;
}
.btn-prev {
  padding: 12px 24px; border-radius: 10px;
  border: 2px solid var(--border); background: white;
  font-size: 14px; font-weight: 600; color: var(--text);
  font-family: inherit; transition: var(--transition);
}
.btn-prev:hover { border-color: var(--primary); color: var(--primary); }
.btn-next, .btn-submit {
  padding: 12px 32px; border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: white; font-size: 14px; font-weight: 700;
  font-family: inherit; transition: var(--transition);
}
.btn-next:hover, .btn-submit:hover {
  transform: translateY(-1px); box-shadow: var(--shadow);
}

/* Success */
.booking-success {
  text-align: center; padding: 40px 20px;
}
.success-icon {
  width: 80px; height: 80px; border-radius: 50%;
  background: linear-gradient(135deg, var(--success), #2ECC71);
  display: flex; align-items: center; justify-content: center;
  font-size: 38px; margin: 0 auto 24px;
  animation: popIn 0.5s cubic-bezier(0.17,0.89,0.32,1.49);
}
@keyframes popIn {
  from { transform: scale(0); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}
.success-title { font-size: 26px; font-weight: 800; color: var(--text); margin-bottom: 10px; }
.success-msg { font-size: 15px; color: var(--text-muted); margin-bottom: 6px; }
.booking-ref {
  font-size: 22px; font-weight: 800; color: var(--primary);
  background: var(--bg); padding: 12px 24px; border-radius: 10px;
  display: inline-block; margin: 12px 0 28px; letter-spacing: 1px;
}
.btn-home {
  padding: 12px 28px; border-radius: 10px;
  background: var(--primary); color: white;
  font-size: 14px; font-weight: 600; font-family: inherit;
  transition: var(--transition);
}
.btn-home:hover { background: var(--primary-dark); }

/* ==================== ARTICLES ==================== */
.articles-section { padding: 60px 0; }
.articles-search-bar {
  max-width: 480px; margin: 0 auto 40px;
  position: relative;
}
.articles-search-bar input {
  width: 100%; padding: 14px 20px 14px 50px;
  border-radius: 30px; border: 2px solid var(--border);
  font-size: 15px; font-family: inherit;
  transition: var(--transition);
}
body[dir="rtl"] .articles-search-bar input { padding: 14px 50px 14px 20px; }
.articles-search-bar input:focus { border-color: var(--primary); }
.search-icon {
  position: absolute; top: 50%; transform: translateY(-50%);
  left: 18px; color: var(--text-muted); font-size: 18px;
}
body[dir="rtl"] .search-icon { left: auto; right: 18px; }
.articles-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.article-card {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden; transition: var(--transition);
  display: flex; flex-direction: column;
}
.article-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.article-img {
  height: 200px; object-fit: cover; width: 100%;
}
.article-img-placeholder {
  height: 200px; background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex; align-items: center; justify-content: center; font-size: 60px;
}
.article-body { padding: 24px; flex: 1; display: flex; flex-direction: column; }
.article-meta {
  display: flex; align-items: center; gap: 12px;
  font-size: 12px; color: var(--text-muted); margin-bottom: 12px;
}
.article-date, .article-read {
  display: flex; align-items: center; gap: 4px;
}
.article-title {
  font-size: 17px; font-weight: 700; color: var(--text);
  margin-bottom: 10px; line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}
.article-excerpt {
  font-size: 13px; color: var(--text-muted); line-height: 1.6;
  flex: 1; margin-bottom: 16px;
  display: -webkit-box; -webkit-line-clamp: 3;
  -webkit-box-orient: vertical; overflow: hidden;
}
.btn-read-more {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 18px; border-radius: 8px;
  background: rgba(27,79,114,0.08); color: var(--primary);
  font-size: 13px; font-weight: 600; transition: var(--transition);
  align-self: flex-start;
}
.btn-read-more:hover { background: var(--primary); color: white; }

/* Article detail modal */
.article-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.6);
  z-index: 2000; display: flex; align-items: flex-start;
  justify-content: center; padding: 80px 20px 20px;
  overflow-y: auto;
}
.article-modal {
  background: white; border-radius: var(--radius-lg);
  max-width: 800px; width: 100%;
  animation: slideUp 0.3s ease;
}
@keyframes slideUp {
  from { transform: translateY(40px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.article-modal-img {
  width: 100%; height: 300px; object-fit: cover;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}
.article-modal-body { padding: 36px; }
.article-modal-title { font-size: 26px; font-weight: 800; color: var(--text); margin-bottom: 16px; }
.article-modal-content {
  font-size: 15px; color: var(--text); line-height: 1.9;
  white-space: pre-line;
}
.modal-close {
  position: sticky; top: 0;
  display: flex; justify-content: flex-end;
  padding: 16px;
}
.modal-close-btn {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--bg); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; color: var(--text); transition: var(--transition);
}
.modal-close-btn:hover { background: var(--danger); color: white; border-color: var(--danger); }

/* ==================== VIDEOS ==================== */
.videos-section { padding: 60px 0; }
.videos-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.video-card {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden; transition: var(--transition);
}
.video-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; }
.video-thumb {
  position: relative; padding-top: 56.25%; /* 16:9 */
  background: #000; overflow: hidden; cursor: pointer;
}
.video-thumb img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; transition: var(--transition);
}
.video-thumb:hover img { transform: scale(1.05); opacity: 0.8; }
.play-btn {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
}
.play-circle {
  width: 56px; height: 56px; border-radius: 50%;
  background: rgba(255,255,255,0.9);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; transition: var(--transition);
}
.video-thumb:hover .play-circle { background: white; transform: scale(1.1); }
.video-iframe-container {
  position: absolute; inset: 0; display: none;
}
.video-iframe-container iframe {
  width: 100%; height: 100%; border: none;
}
.video-iframe-container.playing { display: block; }
.video-body { padding: 20px; }
.video-title { font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.video-desc { font-size: 13px; color: var(--text-muted); line-height: 1.6; }

/* ==================== AUTH ==================== */
/* ==================== AUTH PAGE ==================== */
.auth-page {
  min-height: 100vh; display: flex;
  background: var(--bg);
}

/* Brand panel */
.auth-brand {
  width: 44%; position: relative; overflow: hidden;
  background: linear-gradient(150deg, #0a1628 0%, #1B4F72 55%, #2980b9 100%);
  display: flex; flex-direction: column; justify-content: center;
  padding: 60px 50px;
}
.auth-brand-shape {
  position: absolute; border-radius: 50%;
  background: rgba(255,255,255,0.04); pointer-events: none;
}
.auth-brand-shape.s1 { width: 340px; height: 340px; top: -80px; left: -80px; }
.auth-brand-shape.s2 { width: 220px; height: 220px; bottom: 60px; right: -60px; background: rgba(72,202,228,0.07); }
.auth-brand-shape.s3 { width: 140px; height: 140px; bottom: -30px; left: 30%; background: rgba(255,255,255,0.05); }

.auth-brand-eye {
  margin-bottom: 36px;
}
.auth-brand-eye svg { width: 72px; height: 72px; opacity: .9; }

.auth-brand h1 {
  font-size: clamp(1.5rem, 2.5vw, 2rem); font-weight: 800;
  color: #fff; margin-bottom: 8px; line-height: 1.3;
}
.auth-brand-sub {
  font-size: 14px; color: rgba(255,255,255,.65); margin-bottom: 44px; line-height: 1.6;
}
.auth-brand-features { display: flex; flex-direction: column; gap: 18px; }
.auth-brand-feat {
  display: flex; align-items: center; gap: 14px;
}
.auth-feat-icon {
  width: 42px; height: 42px; border-radius: 12px; flex-shrink: 0;
  background: rgba(255,255,255,0.1);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
}
.auth-feat-text { color: rgba(255,255,255,.85); font-size: 14px; line-height: 1.4; }
.auth-feat-text strong { color: #fff; display: block; font-size: 14px; font-weight: 700; }

.auth-brand-bottom {
  margin-top: 44px; padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,.1);
  color: rgba(255,255,255,.45); font-size: 12px;
}

/* Form panel */
.auth-form-panel {
  flex: 1; display: flex; align-items: center; justify-content: center;
  padding: 40px 24px; overflow-y: auto;
}
.auth-card {
  width: 100%; max-width: 440px;
}
.auth-back {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; color: var(--text-muted); margin-bottom: 32px;
  transition: color .2s;
}
.auth-back:hover { color: var(--primary); }
.auth-logo {
  margin-bottom: 32px;
}
.auth-logo-mark {
  width: 56px; height: 56px; border-radius: 16px;
  background: linear-gradient(135deg, var(--primary) 0%, #2980b9 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; margin-bottom: 16px;
  box-shadow: 0 8px 24px rgba(27,79,114,.25);
}
.auth-logo h2 { font-size: 22px; font-weight: 800; color: var(--text); margin-bottom: 4px; }
.auth-logo p { font-size: 13px; color: var(--text-muted); }

.auth-tabs {
  display: flex; background: var(--bg); border-radius: 12px;
  padding: 4px; margin-bottom: 28px; border: 1px solid var(--border);
}
.auth-tab {
  flex: 1; padding: 10px; border-radius: 9px;
  font-size: 14px; font-weight: 600; color: var(--text-muted);
  background: none; transition: var(--transition); font-family: inherit;
}
.auth-tab.active {
  background: white; color: var(--primary);
  box-shadow: 0 2px 8px rgba(0,0,0,.08);
}
.auth-form { display: none; }
.auth-form.active { display: block; animation: authFadeIn .25s ease; }
@keyframes authFadeIn { from { opacity:0; transform:translateY(6px); } to { opacity:1; transform:translateY(0); } }

.auth-form .form-label {
  font-size: 13px; font-weight: 600; color: var(--text);
  display: block; margin-bottom: 7px;
}
.auth-input-wrap { position: relative; }
.auth-input-wrap .form-control {
  padding-left: 44px;
}
body[dir="rtl"] .auth-input-wrap .form-control { padding-left: 14px; padding-right: 44px; }
.auth-input-icon {
  position: absolute; top: 50%; transform: translateY(-50%);
  left: 14px; color: var(--text-muted); font-size: 16px; pointer-events: none;
}
body[dir="rtl"] .auth-input-icon { left: auto; right: 14px; }
.auth-pass-toggle {
  position: absolute; top: 50%; transform: translateY(-50%);
  right: 12px; background: none; border: none; cursor: pointer;
  color: var(--text-muted); font-size: 16px; padding: 4px;
  transition: color .2s;
}
body[dir="rtl"] .auth-pass-toggle { right: auto; left: 12px; }
.auth-pass-toggle:hover { color: var(--primary); }

.auth-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 20px; margin-top: -4px;
}
.auth-remember { display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--text-muted); cursor: pointer; }
.auth-remember input { accent-color: var(--primary); width: 15px; height: 15px; }
.auth-forgot { font-size: 13px; color: var(--primary); font-weight: 600; }
.auth-forgot:hover { text-decoration: underline; }

.btn-auth {
  width: 100%; padding: 13px; border-radius: 10px;
  background: linear-gradient(135deg, #1B4F72 0%, #2980b9 100%);
  color: white; font-size: 15px; font-weight: 700;
  font-family: inherit; transition: var(--transition);
  box-shadow: 0 4px 16px rgba(27,79,114,.3);
}
.btn-auth:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(27,79,114,.4); }
.btn-auth:disabled { opacity: .7; cursor: default; }

.auth-divider {
  text-align: center; position: relative; margin: 20px 0;
  font-size: 13px; color: var(--text-muted);
}
.auth-divider::before, .auth-divider::after {
  content: ''; position: absolute; top: 50%; width: 42%;
  height: 1px; background: var(--border);
}
.auth-divider::before { right: 0; }
body[dir="ltr"] .auth-divider::before { left: 0; right: auto; }
.auth-divider::after { left: 0; }
body[dir="ltr"] .auth-divider::after { right: 0; left: auto; }

.btn-guest {
  width: 100%; padding: 12px; border-radius: 10px;
  border: 1.5px solid var(--border); background: white;
  color: var(--text); font-size: 14px; font-weight: 600;
  font-family: inherit; transition: var(--transition);
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.btn-guest:hover { border-color: var(--primary); color: var(--primary); background: rgba(27,79,114,.03); }

.auth-error {
  background: rgba(231,76,60,0.06); border: 1px solid rgba(231,76,60,0.2);
  color: var(--danger); padding: 11px 14px; border-radius: 10px;
  font-size: 13px; margin-bottom: 18px;
  display: none; align-items: center; gap: 8px;
}
.auth-error.show { display: flex; }

@media (max-width: 860px) {
  .auth-brand { display: none; }
  .auth-form-panel { padding: 30px 20px; }
  .auth-page { background: white; }
}

/* ==================== PROFILE ==================== */
.profile-page { padding: 100px 0 60px; }
.profile-header {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  padding: 40px 0; margin-bottom: 40px; color: white;
}
.profile-info {
  display: flex; align-items: center; gap: 24px;
}
.profile-avatar {
  width: 80px; height: 80px; border-radius: 50%;
  background: rgba(255,255,255,0.2);
  display: flex; align-items: center; justify-content: center;
  font-size: 36px; font-weight: 800; color: white;
  border: 3px solid rgba(255,255,255,0.3);
  flex-shrink: 0;
}
.profile-name { font-size: 24px; font-weight: 800; margin-bottom: 4px; }
.profile-email { font-size: 14px; opacity: 0.8; margin-bottom: 4px; }
.profile-phone { font-size: 14px; opacity: 0.8; }
.profile-tabs {
  display: flex; gap: 4px; background: white;
  border-radius: 12px; padding: 4px;
  margin-bottom: 32px;
  box-shadow: var(--shadow);
  width: fit-content;
}
.profile-tab {
  padding: 10px 22px; border-radius: 9px;
  font-size: 14px; font-weight: 600; color: var(--text-muted);
  background: none; font-family: inherit; transition: var(--transition);
}
.profile-tab.active { background: var(--primary); color: white; }
.booking-history-list { display: flex; flex-direction: column; gap: 16px; }
.booking-item {
  background: white; border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 20px 24px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; transition: var(--transition);
}
.booking-item:hover { box-shadow: var(--shadow); border-color: transparent; }
.booking-item-info { flex: 1; }
.booking-item-ref { font-size: 12px; color: var(--text-muted); margin-bottom: 4px; }
.booking-item-branch { font-size: 16px; font-weight: 700; color: var(--primary); margin-bottom: 4px; }
.booking-item-datetime {
  font-size: 13px; color: var(--text-muted);
  display: flex; gap: 14px; flex-wrap: wrap;
}
.booking-item-status {
  padding: 6px 14px; border-radius: 20px;
  font-size: 12px; font-weight: 700; white-space: nowrap;
}
.status-pending { background: rgba(243,156,18,0.12); color: #d68910; }
.status-confirmed { background: rgba(39,174,96,0.12); color: var(--success); }
.status-completed { background: rgba(27,79,114,0.12); color: var(--primary); }
.status-cancelled { background: rgba(231,76,60,0.1); color: var(--danger); }
.btn-cancel-booking {
  padding: 7px 14px; border-radius: 8px;
  border: 1px solid rgba(231,76,60,0.3); background: rgba(231,76,60,0.05);
  color: var(--danger); font-size: 12px; font-weight: 600;
  font-family: inherit; transition: var(--transition);
}
.btn-cancel-booking:hover { background: var(--danger); color: white; border-color: var(--danger); }
.empty-state {
  text-align: center; padding: 60px 20px; color: var(--text-muted);
}
.empty-icon { font-size: 60px; margin-bottom: 16px; }
.empty-title { font-size: 18px; font-weight: 700; margin-bottom: 8px; color: var(--text); }
.empty-desc { font-size: 14px; }

/* ==================== FOOTER ==================== */
.footer {
  background: var(--primary-dark); color: white;
  padding: 60px 0 30px;
}
.footer-grid {
  display: grid; gap: 36px; margin-bottom: 40px;
}
.footer-cols-3 { grid-template-columns: 1.8fr 1fr 1.2fr; }
.footer-cols-4 { grid-template-columns: 1.5fr 1fr 1.2fr 1fr; }
.footer-brand p { font-size: 14px; opacity: 0.7; line-height: 1.8; margin-top: 12px; max-width: 280px; }
.footer-title { font-size: 16px; font-weight: 700; margin-bottom: 16px; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { font-size: 14px; opacity: 0.7; transition: var(--transition); }
.footer-links a:hover { opacity: 1; color: var(--accent-light); }
.footer-contact-item {
  display: flex; gap: 10px; align-items: flex-start;
  margin-bottom: 12px; font-size: 14px; opacity: 0.8;
}
.footer-contact-item .icon { font-size: 16px; flex-shrink: 0; margin-top: 1px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 24px; text-align: center;
  font-size: 13px; opacity: 0.6;
}

/* ==================== TOAST ==================== */
.toast-container {
  position: fixed; bottom: 24px;
  z-index: 9999;
}
body[dir="rtl"] .toast-container { right: 24px; }
body[dir="ltr"] .toast-container { left: 24px; }
.toast {
  background: var(--text); color: white;
  padding: 14px 20px; border-radius: 12px;
  font-size: 14px; font-weight: 500;
  box-shadow: var(--shadow-lg);
  display: flex; align-items: center; gap: 10px;
  margin-top: 10px;
  animation: toastIn 0.3s ease;
  max-width: 320px;
}
.toast.success { background: var(--success); }
.toast.error { background: var(--danger); }
.toast.info { background: var(--primary); }
@keyframes toastIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
body[dir="rtl"] @keyframes toastIn {
  from { transform: translateX(-100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ==================== LOADING ==================== */
.loading-spinner {
  display: inline-block; width: 20px; height: 20px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white; border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.page-loader {
  display: flex; align-items: center; justify-content: center;
  min-height: 300px;
}
.page-loader .loader {
  width: 48px; height: 48px;
  border: 4px solid var(--border);
  border-top-color: var(--primary); border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* ==================== SURGERIES ==================== */
.surgeries-section {
  padding: 80px 0;
  background: linear-gradient(180deg, #f0f4f8 0%, #ffffff 100%);
}
.surgery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-top: 48px;
}
.surgery-card {
  background: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: var(--transition);
  display: flex; flex-direction: column;
  position: relative;
}
.surgery-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.surgery-img-wrap {
  position: relative; height: 200px; overflow: hidden;
}
.surgery-img-wrap img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s ease;
}
.surgery-card:hover .surgery-img-wrap img { transform: scale(1.06); }
.surgery-icon-badge {
  position: absolute; top: 14px; right: 14px;
  width: 46px; height: 46px; border-radius: 12px;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  box-shadow: 0 2px 8px rgba(0,0,0,.12);
}
body[dir="ltr"] .surgery-icon-badge { right: auto; left: 14px; }
.surgery-body {
  padding: 22px 22px 18px;
  flex: 1; display: flex; flex-direction: column;
}
.surgery-title {
  font-size: 17px; font-weight: 800; color: var(--text);
  margin-bottom: 10px; line-height: 1.35;
}
.surgery-desc {
  font-size: 13px; color: var(--text-muted);
  line-height: 1.65; flex: 1; margin-bottom: 16px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.surgery-meta {
  display: flex; gap: 10px; flex-wrap: wrap;
  margin-bottom: 18px;
}
.surgery-meta-item {
  display: flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 600; color: var(--primary);
  background: rgba(27,79,114,.07); border-radius: 50px;
  padding: 5px 12px;
}
.surgery-book-btn {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  width: 100%; padding: 11px;
  background: linear-gradient(135deg, var(--primary) 0%, #2980b9 100%);
  color: white; border-radius: 10px;
  font-size: 14px; font-weight: 700;
  transition: var(--transition);
  box-shadow: 0 3px 12px rgba(27,79,114,.2);
}
.surgery-book-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(27,79,114,.3); }

/* Skeleton for surgery */
.sk-surgery-card {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--border); overflow: hidden;
}
.sk-surgery-img { height: 200px; width: 100%; border-radius: 0; }
.sk-surgery-body { padding: 22px; display: flex; flex-direction: column; gap: 10px; }

/* ==================== SHIMMER ==================== */
@keyframes shimmer {
  0%   { background-position: -800px 0; }
  100% { background-position:  800px 0; }
}
.shimmer-block {
  background: linear-gradient(90deg, #ececec 25%, #d8d8d8 50%, #ececec 75%);
  background-size: 800px 100%;
  animation: shimmer 1.4s ease-in-out infinite;
  border-radius: 6px;
}

/* Article skeleton */
.sk-article-card {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--border); overflow: hidden;
  display: flex; flex-direction: column;
}
.sk-article-img  { height: 200px; width: 100%; border-radius: 0; }
.sk-article-body { padding: 24px; display: flex; flex-direction: column; gap: 10px; }
.sk-line         { height: 13px; }
.sk-line.w100    { width: 100%; }
.sk-line.w80     { width: 80%; }
.sk-line.w60     { width: 60%; }
.sk-line.w40     { width: 40%; }
.sk-line.w30     { width: 30%; }
.sk-line.h20     { height: 20px; }
.sk-line.h16     { height: 16px; }
.sk-meta { display: flex; gap: 12px; }
.sk-btn  { height: 34px; width: 110px; border-radius: 8px; margin-top: 6px; }

/* Video skeleton */
.sk-video-card {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--border); overflow: hidden;
}
.sk-video-thumb { padding-top: 56.25%; position: relative; }
.sk-video-thumb .shimmer-block { position: absolute; inset: 0; border-radius: 0; height: 100%; }
.sk-video-body  { padding: 18px; display: flex; flex-direction: column; gap: 10px; }

/* Gallery skeleton */
.sk-gallery-item {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--border); overflow: hidden;
}
.sk-gallery-img  { height: 240px; width: 100%; border-radius: 0; }
.sk-gallery-body { padding: 14px; display: flex; flex-direction: column; gap: 8px; }

/* ==================== PAGINATION ==================== */
.pagination {
  display: flex; align-items: center; justify-content: center;
  gap: 6px; margin-top: 44px; flex-wrap: wrap;
}
.pg-btn {
  min-width: 40px; height: 40px; padding: 0 12px;
  border-radius: 10px; border: 1.5px solid var(--border);
  background: white; color: var(--text); font-size: 14px; font-weight: 600;
  cursor: pointer; transition: var(--transition);
  display: flex; align-items: center; justify-content: center;
}
.pg-btn:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); }
.pg-btn.active { background: var(--primary); color: white; border-color: var(--primary); }
.pg-btn:disabled { opacity: .4; cursor: default; }
.pg-ellipsis {
  min-width: 40px; height: 40px; display: flex; align-items: center;
  justify-content: center; color: var(--text-muted); font-size: 14px;
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 992px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; }
  .hero-desc { margin: 0 auto 36px; }
  .hero-btns { justify-content: center; }
  .hero-visual { display: none; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .articles-grid { grid-template-columns: repeat(2, 1fr); }
  .videos-grid { grid-template-columns: repeat(2, 1fr); }
  .surgery-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid,
  .footer-cols-3,
  .footer-cols-4 { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  /* Navbar */
  .nav-links, .nav-book-btn { display: none; }
  .hamburger { display: flex; }
  .nav-title { font-size: 14px; }
  .nav-subtitle { font-size: 10px; }

  /* Container */
  .container { padding: 0 16px; }

  /* Page hero */
  .page-hero { padding: 90px 0 40px; }
  .page-hero h1 { font-size: 26px; }

  /* Sections */
  .services-section, .surgeries-section { padding: 50px 0; }
  .services-grid { grid-template-columns: 1fr; }
  .surgery-grid { grid-template-columns: 1fr 1fr; gap: 16px; }

  /* Articles / Videos */
  .articles-section, .videos-section { padding: 40px 0; }
  .articles-grid { grid-template-columns: 1fr; }
  .videos-grid { grid-template-columns: 1fr; }

  /* Booking */
  .booking-card { padding: 20px 16px; }
  .branch-cards { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .steps-bar { gap: 0; }
  .step-label { display: none; }
  .step-item:not(:last-child)::after { width: 50px; }

  /* Stats */
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .stat-card { padding: 20px 14px; }
  .stat-num { font-size: 28px; }

  /* Footer */
  .footer-grid,
  .footer-cols-3,
  .footer-cols-4 { grid-template-columns: 1fr; gap: 28px; }
  .footer { padding: 40px 0 20px; }
  .footer-brand p { max-width: 100%; }
  .footer-bottom { flex-direction: column; gap: 8px; }

  /* Profile */
  .profile-page { padding: 80px 0 40px; }
  .profile-info { flex-direction: column; align-items: flex-start; gap: 16px; }
  .profile-tabs { width: 100%; overflow-x: auto; white-space: nowrap; }
  .profile-tab { padding: 10px 16px; font-size: 13px; }
  .booking-item { flex-direction: column; align-items: flex-start; gap: 10px; }
  .booking-item-datetime { flex-direction: column; gap: 4px; }

  /* Article modal */
  .article-modal-overlay { padding: 70px 10px 10px; }
  .article-modal-body { padding: 20px; }
  .article-modal-title { font-size: 20px; }

  /* Section header */
  .section-header { margin-bottom: 32px; }
  .section-subtitle { font-size: 14px; }
}

@media (max-width: 600px) {
  /* Surgery grid → single column */
  .surgery-grid { grid-template-columns: 1fr; }
  .surgery-img-wrap { height: 180px; }

  /* Services */
  .services-grid { grid-template-columns: 1fr; }
  .service-card { padding: 24px 20px; }

  /* Articles / Videos */
  .articles-grid { grid-template-columns: 1fr; }
  .videos-grid { grid-template-columns: 1fr; }

  /* Booking steps */
  .steps-bar { justify-content: space-between; }
  .step-item:not(:last-child)::after { width: 30px; }
}

@media (max-width: 480px) {
  /* Stats */
  .stats-grid { grid-template-columns: 1fr 1fr; }

  /* Hero */
  .hero-btns { flex-direction: column; }
  .btn-hero-primary, .btn-hero-secondary { width: 100%; text-align: center; }

  /* Navbar brand */
  .nav-logo { width: 36px; height: 36px; font-size: 18px; }
  .nav-title { font-size: 13px; }
  .nav-subtitle { display: none; }
  .lang-btn { padding: 6px 10px; font-size: 12px; }

  /* Booking card */
  .booking-card { padding: 16px 12px; }
  .booking-step-title { font-size: 18px; }

  /* Profile */
  .profile-name { font-size: 20px; }
  .profile-avatar { width: 64px; height: 64px; font-size: 28px; }

  /* Surgery */
  .surgery-grid { grid-template-columns: 1fr; }

  /* Footer */
  .footer-brand p { max-width: 100%; }

  /* Auth */
  .auth-card { padding: 0; }

  /* Pagination */
  .pg-btn { min-width: 34px; height: 34px; font-size: 13px; }

  /* Slots */
  .slot-btn { padding: 8px 14px; font-size: 13px; }
}
