/* ================================================
   LawBooking — Main Stylesheet
   Colors: #1a3a5c (navy), #c9a84c (gold), #f8f5f0 (cream)
   ================================================ */

:root {
  --navy: #1a3a5c;
  --navy-light: #2a5080;
  --gold: #c9a84c;
  --gold-light: #e8c875;
  --cream: #f8f5f0;
  --text: #2c3e50;
  --muted: #6c757d;
  --border: #e8e8e8;
  --radius: 12px;
  --shadow: 0 4px 20px rgba(26,58,92,0.08);
  --shadow-hover: 0 8px 30px rgba(26,58,92,0.15);
}

* { box-sizing: border-box; }

body {
  font-family: 'Inter', -apple-system, sans-serif;
  color: var(--text);
  background: #fff;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ---- TYPOGRAPHY ---- */
h1,h2,h3,h4,h5 { font-family: 'Playfair Display', Georgia, serif; }
.fw-500 { font-weight: 500; }
.fw-600 { font-weight: 600; }

/* ---- COLORS ---- */
.text-gold { color: var(--gold) !important; }
.text-navy { color: var(--navy) !important; }
.bg-navy { background-color: var(--navy) !important; }
.bg-gold { background-color: var(--gold) !important; }
.bg-navy-light { background-color: rgba(26,58,92,0.1) !important; }
.bg-gold-subtle { background-color: rgba(201,168,76,0.1) !important; }
.text-gold-subtle { color: rgba(201,168,76,0.7); }
.progress-bar.bg-gold { background-color: var(--gold) !important; }

/* ---- NAVBAR ---- */
#mainNav {
  background: var(--navy);
  box-shadow: 0 2px 12px rgba(0,0,0,0.15);
  padding: 0.75rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}
#mainNav .nav-link {
  color: rgba(255,255,255,0.85);
  font-weight: 500;
  padding: 0.5rem 0.8rem;
  transition: color 0.2s;
}
#mainNav .nav-link:hover,
#mainNav .nav-link.active {
  color: var(--gold);
}
.navbar-brand {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  color: #fff !important;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.brand-text { color: #fff; }
.navbar-toggler:focus { box-shadow: none; }

/* ---- BUTTONS ---- */
.btn-gold {
  background: var(--gold);
  color: var(--navy);
  border: none;
  font-weight: 600;
  border-radius: 8px;
  transition: all 0.2s;
}
.btn-gold:hover {
  background: #b8923e;
  color: var(--navy);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(201,168,76,0.35);
}
.btn-navy {
  background: var(--navy);
  color: #fff;
  border: none;
  font-weight: 600;
  border-radius: 8px;
  transition: all 0.2s;
}
.btn-navy:hover {
  background: var(--navy-light);
  color: #fff;
  transform: translateY(-1px);
}
.btn-outline-secondary { border-radius: 8px; }

/* ---- HERO ---- */
.hero-section {
  background: var(--navy);
  color: white;
  padding: 80px 0 100px;
  position: relative;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 70% 50%, rgba(201,168,76,0.12) 0%, transparent 70%),
              radial-gradient(ellipse at 20% 80%, rgba(255,255,255,0.04) 0%, transparent 50%);
}
.hero-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
}
.hero-subtitle {
  font-size: 1.125rem;
  color: rgba(255,255,255,0.75);
  max-width: 540px;
  margin: 0 auto 2rem;
}
.hero-search-box {
  background: white;
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.2);
  max-width: 720px;
  margin: 0 auto;
}
.hero-search-box .form-select,
.hero-search-box .form-control {
  border: none;
  font-size: 0.95rem;
  padding-left: 0;
  color: var(--text);
}
.hero-search-box .form-select:focus,
.hero-search-box .form-control:focus {
  box-shadow: none;
}
.hero-search-box .input-group {
  background: #f5f5f5;
  border-radius: 8px;
}
.hero-search-box .input-group-text {
  background: transparent;
  border: none;
}
.badge-pill-link {
  display: inline-block;
  background: rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.85);
  border-radius: 20px;
  padding: 4px 14px;
  font-size: 0.8rem;
  text-decoration: none;
  transition: all 0.2s;
  border: 1px solid rgba(255,255,255,0.2);
}
.badge-pill-link:hover {
  background: var(--gold);
  color: var(--navy);
  border-color: var(--gold);
}

/* ---- STATS SECTION ---- */
.stats-section { background: #fff; }
.stat-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 20px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.stat-number {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--navy);
}
.stat-label { color: var(--muted); font-size: 0.85rem; }

/* ---- HOW IT WORKS ---- */
.how-card {
  background: white;
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}
.how-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}
.how-card--featured {
  background: var(--navy);
  color: white;
  border-color: var(--navy);
  box-shadow: 0 8px 30px rgba(26,58,92,0.2);
}
.how-card--featured p { color: rgba(255,255,255,0.8); }
.how-step {
  position: absolute;
  top: 12px;
  right: 16px;
  font-family: 'Playfair Display', serif;
  font-size: 3rem;
  font-weight: 700;
  color: rgba(0,0,0,0.06);
  line-height: 1;
}
.how-card--featured .how-step { color: rgba(255,255,255,0.08); }
.how-icon {
  font-size: 2rem;
  color: var(--gold);
  margin-bottom: 1rem;
}

/* ---- SECTION STYLING ---- */
.section-tag {
  display: inline-block;
  background: rgba(201,168,76,0.15);
  color: var(--gold);
  padding: 4px 14px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
}
.section-title {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

/* ---- SPEC CARDS ---- */
.spec-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.2s;
}
.spec-card:hover {
  border-color: var(--navy);
  color: var(--navy);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.spec-card i:first-child { font-size: 1.2rem; color: var(--gold); }

/* ---- LAWYER CARDS ---- */
.lawyer-card {
  background: white;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: all 0.2s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.lawyer-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-4px);
  border-color: rgba(26,58,92,0.15);
}
.lawyer-card__link { text-decoration: none; color: inherit; display: block; }
.lawyer-card__img-wrap { position: relative; height: 180px; overflow: hidden; }
.lawyer-card__img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.lawyer-card:hover .lawyer-card__img { transform: scale(1.05); }
.lawyer-card__badge-rating {
  position: absolute;
  top: 10px;
  right: 10px;
  background: white;
  border-radius: 20px;
  padding: 3px 10px;
  font-size: 0.8rem;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.lawyer-card__header {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 1rem;
  padding-bottom: 0.5rem;
}
.lawyer-card__avatar {
  width: 56px;
  height: 56px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}
.lawyer-card__footer {
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--border);
}
.lawyer-card__meta { display: flex; justify-content: space-between; align-items: center; }
.lawyer-card__rating { text-align: right; }
.lawyer-bio-preview { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }

/* Badges */
.badge-spec {
  background: rgba(201,168,76,0.15);
  color: #8b6914;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 6px;
  padding: 3px 8px;
}
.badge-spec-lg {
  background: rgba(201,168,76,0.15);
  color: #8b6914;
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: 8px;
  padding: 4px 12px;
}

/* ---- CTA SECTION ---- */
.cta-section { background: var(--cream); }
.cta-card {
  background: white;
  border-radius: 16px;
  padding: 2.5rem;
  border: 1px solid var(--border);
  height: 100%;
}
.cta-card--lawyer {
  background: var(--navy);
  color: white;
  border-color: var(--navy);
}
.cta-card--lawyer p { color: rgba(255,255,255,0.75); }
.cta-icon { font-size: 2.5rem; margin-bottom: 1rem; }

/* ---- FILTERS ---- */
.filter-sidebar {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  position: sticky;
  top: 80px;
}
.page-header {
  background: var(--cream);
  border-bottom: 1px solid var(--border);
}

/* ---- PROFILE PAGE ---- */
.profile-card { border: none; box-shadow: var(--shadow); }
.profile-avatar {
  width: 120px;
  height: 120px;
  object-fit: cover;
  border: 4px solid white;
  box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}
.verified-badge {
  position: absolute;
  bottom: 4px;
  right: 4px;
  background: white;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}
.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 0.9rem;
}
.meta-item i { color: var(--gold); }
.rating-display { text-align: center; }
.rating-num { font-size: 2rem; font-weight: 700; color: var(--navy); }
.stars { color: var(--gold); font-size: 0.85rem; }
.stars-sm { color: var(--gold); font-size: 0.7rem; }
.stars-lg { color: var(--gold); font-size: 1.1rem; }
.big-rating { font-family: 'Playfair Display', serif; font-size: 3.5rem; font-weight: 700; color: var(--navy); line-height: 1; }

.working-day {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
}
.working-day--active { border-color: rgba(201,168,76,0.4); background: rgba(201,168,76,0.05); }
.working-day--off { opacity: 0.5; }
.day-name { font-weight: 500; font-size: 0.875rem; }
.day-hours { font-size: 0.8rem; color: var(--muted); }
.border-gold { border-color: var(--gold) !important; }

/* ---- BOOKING WIDGET ---- */
.price-display { margin-bottom: 4px; }
.price-amount { font-family: 'Playfair Display', serif; font-size: 2.2rem; font-weight: 700; color: var(--navy); }
.price-unit { color: var(--muted); font-size: 0.9rem; }
.time-slot { font-size: 0.8rem; border-radius: 8px; padding: 4px 12px; }
.time-slot.active, .time-slot.btn-navy { background: var(--navy); color: white; border-color: var(--navy); }

/* ---- BOOKING PAGE ---- */
.booking-details {}
.booking-detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
}
.step-num {
  width: 28px;
  height: 28px;
  min-width: 28px;
  background: rgba(201,168,76,0.2);
  color: var(--gold);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
}

/* ---- AUTH PAGES ---- */
.auth-page { background: var(--cream); min-height: calc(100vh - 200px); }
.auth-card { border: none; border-radius: 16px; }
.role-toggle {
  display: flex;
  background: #f5f5f5;
  border-radius: 10px;
  padding: 4px;
  gap: 4px;
}
.role-btn {
  flex: 1;
  text-align: center;
  padding: 8px 16px;
  border-radius: 8px;
  text-decoration: none;
  color: var(--muted);
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.2s;
}
.role-btn.active {
  background: var(--navy);
  color: white;
  box-shadow: 0 2px 8px rgba(26,58,92,0.2);
}
.alert-info-soft {
  background: rgba(13,110,253,0.08);
  border: 1px solid rgba(13,110,253,0.15);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.875rem;
  color: var(--text);
}

/* ---- DASHBOARD ---- */
.dashboard-stat {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.dashboard-stat__icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.dashboard-stat__num {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1;
}
.dashboard-stat__label { color: var(--muted); font-size: 0.8rem; }

.appt-row { transition: background 0.15s; }
.appt-row:hover { background: var(--cream); }

.card-header {
  background: white;
  border-bottom: 1px solid var(--border);
  padding: 1rem 1.25rem;
}

/* ---- REVIEW ---- */
.review-item:last-child { border-bottom: none !important; }

/* ---- FOOTER ---- */
.footer { background: #111827; margin-top: auto; }
.footer-top {}
.footer-links { list-style: none; padding: 0; }
.footer-links li { margin-bottom: 8px; }
.footer-links a {
  color: #9ca3af;
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--gold); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.08); }
.social-link {
  color: #9ca3af;
  font-size: 1.2rem;
  text-decoration: none;
  transition: color 0.2s;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
}
.social-link:hover { color: var(--gold); border-color: var(--gold); }

/* ---- PAGINATION ---- */
.pagination .page-link {
  color: var(--navy);
  border-color: var(--border);
  border-radius: 8px !important;
  margin: 0 2px;
}
.pagination .page-item.active .page-link {
  background: var(--navy);
  border-color: var(--navy);
}
.pagination .page-link:hover { background: var(--cream); }

/* ---- WORKING HOURS SETUP ---- */
.working-hours-row {
  background: #fafafa;
  border-color: var(--border) !important;
}

/* ---- UTILITIES ---- */
.bg-success-subtle { background-color: rgba(25,135,84,0.1); }
.bg-warning-subtle { background-color: rgba(255,193,7,0.1); }
.bg-primary-subtle { background-color: rgba(13,110,253,0.1); }
.bg-danger-subtle { background-color: rgba(220,53,69,0.1); }
.bg-secondary-subtle { background-color: rgba(108,117,125,0.1); }

/* ---- RESPONSIVE ---- */
@media (max-width: 991px) {
  /* Navbar collapse styling */
  #navbarMain {
    background: var(--navy);
    padding: 12px 0;
    border-top: 1px solid rgba(255,255,255,0.1);
    margin-top: 8px;
  }
  #navbarMain .nav-link {
    padding: 10px 16px;
    border-radius: 8px;
    margin: 2px 8px;
  }
  #navbarMain .nav-link:hover {
    background: rgba(255,255,255,0.08);
  }
  #navbarMain .btn-gold {
    margin: 8px 16px;
    display: block;
    text-align: center;
  }
  /* Dropdown in collapsed navbar */
  #navbarMain .dropdown-menu {
    background: rgba(255,255,255,0.06);
    border: none;
    padding: 0;
  }
  #navbarMain .dropdown-item {
    color: rgba(255,255,255,0.8);
    padding: 9px 24px;
    font-size: 0.875rem;
  }
  #navbarMain .dropdown-item:hover {
    background: rgba(255,255,255,0.1);
    color: white;
  }
  #navbarMain .dropdown-divider {
    border-color: rgba(255,255,255,0.15);
  }
}

@media (max-width: 768px) {
  .hero-section { padding: 50px 0 60px; }
  .hero-search-box { padding: 12px; }
  .hero-search-box .row { gap: 8px; }
  .filter-sidebar { position: static; }
  .booking-widget { position: static !important; }
  .profile-avatar { width: 80px; height: 80px; }
  .section-title { font-size: 1.4rem; }
  .stat-card { padding: 14px; }
  .cta-card { padding: 1.5rem; }
  /* Lawyers grid */
  .lawyer-card__img-wrap { height: 140px; }
  /* Dashboard stats */
  .dashboard-stat { padding: 12px 14px; }
  .dashboard-stat__num { font-size: 1.3rem; }
  /* Footer */
  .footer-top .col-lg-4, .footer-top .col-lg-2 { margin-bottom: 8px; }
}
