/* ==========================================================================
   KINGDOM LEGAL - Premium UK Immigration Law & Advisory Services
   Theme & Design System (Inspired by Morgan Smith Immigration)
   Colors: Deep Navy (#002147), Warm Gold (#C5A059), Slate (#0B132B), Light (#F8FAFC)
   ========================================================================== */

:root {
  --primary-navy: #002147;
  --primary-navy-dark: #001530;
  --primary-navy-light: #0d3463;
  --gold-accent: #c5a059;
  --gold-light: #e5cd9c;
  --gold-dark: #a07d38;
  --gold-gradient: linear-gradient(135deg, #c5a059 0%, #dfc38a 50%, #b89047 100%);
  --dark-slate: #0b132b;
  --text-dark: #0f172a;
  --text-body: #334155;
  --text-muted: #64748b;
  --bg-light: #f8fafc;
  --bg-white: #ffffff;
  --bg-card: #ffffff;
  --border-color: #e2e8f0;
  --border-gold: rgba(197, 160, 89, 0.35);
  
  --font-serif: 'Playfair Display', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 33, 71, 0.08);
  --shadow-lg: 0 10px 30px rgba(0, 33, 71, 0.12);
  --shadow-gold: 0 4px 20px rgba(197, 160, 89, 0.25);
  
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  color: var(--text-body);
  background-color: var(--bg-light);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  color: var(--primary-navy);
  font-weight: 700;
  line-height: 1.25;
}

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ==========================================================================
   TOP NOTIFICATION BAR & HEADER
   ========================================================================== */

.top-bar {
  background-color: var(--primary-navy-dark);
  color: #cbd5e1;
  font-size: 0.85rem;
  padding: 8px 0;
  border-bottom: 1px solid rgba(197, 160, 89, 0.25);
}

.top-bar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.top-bar-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--gold-light);
  font-weight: 600;
}

.top-bar-contact {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}

.top-bar-contact a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #e2e8f0;
}

.top-bar-contact a:hover {
  color: var(--gold-light);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 84px;
}

.site-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-crest {
  width: 44px;
  height: 44px;
  background: var(--gold-gradient);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-navy-dark);
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 900;
  box-shadow: var(--shadow-gold);
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary-navy);
  letter-spacing: -0.5px;
  line-height: 1.1;
}

.brand-tagline {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--gold-dark);
}

.main-nav {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 28px;
}

.nav-item {
  position: relative;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-dark);
  padding: 10px 0;
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link:hover, .nav-item:hover > .nav-link {
  color: var(--gold-dark);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background: #ffffff;
  min-width: 260px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  padding: 12px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: var(--transition);
  z-index: 1010;
}

.nav-item:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item {
  display: block;
  padding: 10px 20px;
  font-size: 0.9rem;
  color: var(--text-dark);
  font-weight: 500;
}

.dropdown-item:hover {
  background-color: #f1f5f9;
  color: var(--primary-navy);
  padding-left: 24px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition: var(--transition);
  text-align: center;
}

.btn-primary {
  background: var(--gold-gradient);
  color: var(--primary-navy-dark);
  box-shadow: var(--shadow-gold);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #dfc38a 0%, #c5a059 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(197, 160, 89, 0.4);
}

.btn-navy {
  background-color: var(--primary-navy);
  color: #ffffff;
}

.btn-navy:hover {
  background-color: var(--primary-navy-light);
  transform: translateY(-2px);
}

.btn-outline-gold {
  border-color: var(--gold-accent);
  color: var(--gold-dark);
  background: transparent;
}

.btn-outline-gold:hover {
  background-color: var(--gold-accent);
  color: var(--primary-navy-dark);
}

.btn-outline-white {
  border-color: rgba(255, 255, 255, 0.4);
  color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.btn-outline-white:hover {
  border-color: #ffffff;
  background: rgba(255, 255, 255, 0.15);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--primary-navy);
}

.mobile-nav-cta {
  display: none;
}

.hero-cta-group {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */

.hero {
  position: relative;
  background: radial-gradient(circle at 80% 20%, #0d3463 0%, #002147 60%, #001530 100%);
  color: #ffffff;
  padding: 80px 0 100px;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: radial-gradient(rgba(197, 160, 89, 0.12) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 50px;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(197, 160, 89, 0.15);
  border: 1px solid rgba(197, 160, 89, 0.4);
  color: var(--gold-light);
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 24px;
}

.hero-title {
  font-size: 3.2rem;
  color: #ffffff;
  line-height: 1.15;
  margin-bottom: 20px;
}

.hero-title span {
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: #cbd5e1;
  line-height: 1.6;
  margin-bottom: 32px;
  max-width: 580px;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-badge-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-badge-icon {
  width: 38px;
  height: 38px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(197, 160, 89, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-light);
  font-size: 1.1rem;
}

.hero-badge-text {
  font-size: 0.82rem;
  line-height: 1.3;
}

.hero-badge-text strong {
  display: block;
  color: #ffffff;
}

.hero-card {
  background: #ffffff;
  color: var(--text-dark);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-gold);
}

.hero-card-title {
  font-size: 1.5rem;
  margin-bottom: 8px;
  color: var(--primary-navy);
}

.hero-card-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.92rem;
  color: var(--text-dark);
  transition: var(--transition);
  background-color: #f8fafc;
}

.form-control:focus {
  outline: none;
  border-color: var(--gold-dark);
  background-color: #ffffff;
  box-shadow: 0 0 0 3px rgba(197, 160, 89, 0.2);
}

/* ==========================================================================
   TRUST BAR & STATS
   ========================================================================== */

.trust-section {
  background: #ffffff;
  border-bottom: 1px solid var(--border-color);
  padding: 32px 0;
}

.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  align-items: center;
}

.trust-stat {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 16px;
  border-right: 1px solid var(--border-color);
}

.trust-stat:last-child {
  border-right: none;
}

.stat-number {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--primary-navy);
  line-height: 1;
}

.stat-number span {
  color: var(--gold-dark);
}

.stat-text {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.3;
}

/* ==========================================================================
   PRACTICE ROUTES & CATEGORIES
   ========================================================================== */

.section {
  padding: 80px 0;
}

.section-bg-white {
  background-color: #ffffff;
}

.section-header {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 50px;
}

.section-tag {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 12px;
}

.section-title {
  font-size: 2.4rem;
  color: var(--primary-navy);
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-muted);
}

.route-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.route-card {
  background: #ffffff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  padding: 32px;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.route-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gold-gradient);
  opacity: 0;
  transition: var(--transition);
}

.route-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-gold);
}

.route-card:hover::before {
  opacity: 1;
}

.route-icon-box {
  width: 54px;
  height: 54px;
  background: rgba(0, 33, 71, 0.05);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 20px;
  color: var(--primary-navy);
}

.route-card:hover .route-icon-box {
  background: var(--gold-gradient);
  color: var(--primary-navy-dark);
}

.route-card-title {
  font-size: 1.4rem;
  margin-bottom: 12px;
}

.route-card-desc {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin-bottom: 20px;
  flex-grow: 1;
}

.route-links {
  list-style: none;
  margin-bottom: 24px;
  border-top: 1px solid var(--border-color);
  padding-top: 16px;
}

.route-links li {
  margin-bottom: 8px;
}

.route-links a {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-body);
  display: flex;
  align-items: center;
  gap: 6px;
}

.route-links a:hover {
  color: var(--gold-dark);
  padding-left: 4px;
}

/* ==========================================================================
   INTERACTIVE VISA ROUTE FINDER & CALCULATOR
   ========================================================================== */

.calculator-wrapper {
  background: radial-gradient(circle at 10% 20%, #001530 0%, #002147 100%);
  color: #ffffff;
  border-radius: var(--radius-lg);
  padding: 48px;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(197, 160, 89, 0.3);
}

.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.calc-option-title {
  font-size: 1.1rem;
  color: var(--gold-light);
  margin-bottom: 12px;
}

.calc-selector-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 24px;
}

.calc-btn-option {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  padding: 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  text-align: left;
  font-size: 0.88rem;
  transition: var(--transition);
}

.calc-btn-option:hover, .calc-btn-option.active {
  background: var(--gold-gradient);
  color: var(--primary-navy-dark);
  border-color: transparent;
  font-weight: 700;
}

.calc-result-box {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(197, 160, 89, 0.3);
  border-radius: var(--radius-md);
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.calc-result-title {
  font-size: 1.4rem;
  color: var(--gold-light);
  margin-bottom: 12px;
}

.calc-result-text {
  font-size: 0.95rem;
  color: #e2e8f0;
  margin-bottom: 20px;
  line-height: 1.6;
}

/* ==========================================================================
   PRIORITY & 100 SUBPAGE DIRECTORY (SEO GRID)
   ========================================================================== */

.keyword-hub-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.keyword-box {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px;
  transition: var(--transition);
}

.keyword-box:hover {
  border-color: var(--gold-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.keyword-badge {
  display: inline-block;
  padding: 2px 8px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
  background: #f1f5f9;
  color: var(--text-muted);
}

.keyword-badge.local { background: #e0f2fe; color: #0369a1; }
.keyword-badge.work { background: #fef3c7; color: #92400e; }
.keyword-badge.business { background: #dcfce7; color: #166534; }
.keyword-badge.community { background: #fce7f3; color: #9d174d; }
.keyword-badge.settlement { background: #ede9fe; color: #5b21b6; }
.keyword-badge.trust { background: #fae8ff; color: #86198f; }

.keyword-title {
  font-size: 1.05rem;
  font-family: var(--font-sans);
  font-weight: 700;
  color: var(--primary-navy);
  margin-bottom: 8px;
  line-height: 1.35;
}

.keyword-link {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gold-dark);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* ==========================================================================
   COMMUNITY & MULTILINGUAL SECTION
   ========================================================================== */

.multilingual-banner {
  background: linear-gradient(135deg, #0b132b 0%, #1e293b 100%);
  border-radius: var(--radius-lg);
  padding: 48px;
  color: #ffffff;
  border: 1px solid rgba(197, 160, 89, 0.35);
  margin-bottom: 40px;
}

.multilingual-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
}

.lang-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 20px 0;
}

.lang-pill {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(197, 160, 89, 0.3);
  padding: 8px 18px;
  border-radius: var(--radius-full);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--gold-light);
}

/* ==========================================================================
   FAQ SECTION
   ========================================================================== */

.faq-list {
  max-width: 860px;
  margin: 0 auto;
}

.faq-item {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  overflow: hidden;
  transition: var(--transition);
}

.faq-question {
  width: 100%;
  text-align: left;
  padding: 22px 28px;
  font-size: 1.15rem;
  font-family: var(--font-serif);
  font-weight: 600;
  color: var(--primary-navy);
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-question:hover {
  color: var(--gold-dark);
}

.faq-icon {
  font-size: 1.2rem;
  transition: var(--transition);
  color: var(--gold-dark);
}

.faq-answer {
  padding: 0 28px 24px;
  font-size: 0.95rem;
  color: var(--text-body);
  display: none;
  line-height: 1.7;
}

.faq-item.active .faq-answer {
  display: block;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

/* ==========================================================================
   SUBPAGE & ARTICLE TEMPLATE STYLES
   ========================================================================== */

.page-header {
  background: radial-gradient(circle at 75% 25%, #0d3463 0%, #002147 70%, #001530 100%);
  color: #ffffff;
  padding: 60px 0;
  border-bottom: 2px solid var(--gold-accent);
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: #94a3b8;
  margin-bottom: 16px;
}

.breadcrumb a {
  color: var(--gold-light);
}

.page-title {
  font-size: 2.8rem;
  color: #ffffff;
  margin-bottom: 16px;
}

.page-intro {
  font-size: 1.15rem;
  color: #cbd5e1;
  max-width: 800px;
}

.subpage-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 48px;
  padding: 60px 0;
}

.article-content {
  background: #ffffff;
  border-radius: var(--radius-lg);
  padding: 44px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.article-content h2 {
  font-size: 1.85rem;
  margin: 36px 0 16px;
  color: var(--primary-navy);
  border-bottom: 2px solid #f1f5f9;
  padding-bottom: 10px;
}

.article-content h2:first-child {
  margin-top: 0;
}

.article-content h3 {
  font-size: 1.35rem;
  margin: 24px 0 12px;
  color: var(--primary-navy-light);
}

.article-content p {
  margin-bottom: 18px;
  font-size: 1rem;
  color: var(--text-body);
}

.article-content ul, .article-content ol {
  margin: 16px 0 24px 24px;
  color: var(--text-body);
}

.article-content li {
  margin-bottom: 8px;
}

.info-callout {
  background: #f0fdf4;
  border-left: 4px solid #16a34a;
  padding: 20px;
  border-radius: var(--radius-sm);
  margin: 24px 0;
  font-size: 0.95rem;
}

.warning-callout {
  background: #fef2f2;
  border-left: 4px solid #dc2626;
  padding: 20px;
  border-radius: var(--radius-sm);
  margin: 24px 0;
  font-size: 0.95rem;
}

.sidebar-sticky {
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.sidebar-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 28px;
  box-shadow: var(--shadow-md);
}

.sidebar-card.gold-border {
  border: 1px solid var(--border-gold);
}

.sidebar-title {
  font-size: 1.25rem;
  margin-bottom: 16px;
  color: var(--primary-navy);
}

/* ==========================================================================
   FOOTER
   ========================================================================== */

.site-footer {
  background-color: var(--primary-navy-dark);
  color: #cbd5e1;
  padding: 80px 0 24px;
  border-top: 2px solid var(--gold-accent);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
  margin-bottom: 60px;
}

.footer-col h4 {
  font-family: var(--font-sans);
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 24px;
  letter-spacing: 0.5px;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 12px;
}

.footer-col a {
  color: #94a3b8;
  font-size: 0.9rem;
}

.footer-col a:hover {
  color: var(--gold-light);
  padding-left: 4px;
}

.footer-desc {
  font-size: 0.9rem;
  color: #94a3b8;
  margin: 16px 0 24px;
  line-height: 1.6;
}

.footer-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(197, 160, 89, 0.12);
  border: 1px solid rgba(197, 160, 89, 0.35);
  border-radius: var(--radius-sm);
  color: var(--gold-light);
  font-size: 0.8rem;
  font-weight: 600;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.82rem;
  color: #64748b;
}

/* ==========================================================================
   MODAL DIALOG
   ========================================================================== */

.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 21, 48, 0.8);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.modal-backdrop.open {
  opacity: 1;
  visibility: visible;
}

.modal-box {
  background: #ffffff;
  border-radius: var(--radius-lg);
  max-width: 580px;
  width: 100%;
  padding: 40px;
  position: relative;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-gold);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-muted);
}

.modal-close:hover {
  color: var(--primary-navy);
}

/* ==========================================================================
   RESPONSIVE DESIGN & MOBILE OPTIMIZATION
   ========================================================================== */

@media (max-width: 1024px) {
  .hero-grid, .subpage-layout, .calc-grid, .multilingual-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .route-cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .trust-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .trust-stat {
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 16px;
  }
  .keyword-hub-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.director-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 40px;
  align-items: center;
}

/* Floating Mobile Quick Action Bar */
.mobile-floating-bar {
  display: none;
}

@media (max-width: 992px) {
  html, body {
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
    position: relative;
  }

  body {
    padding-bottom: 58px; /* space for fixed bottom action bar */
  }

  .container {
    padding: 0 16px;
    width: 100%;
    max-width: 100%;
  }

  /* Top Bar */
  .top-bar {
    padding: 6px 0;
    font-size: 0.76rem;
  }
  .top-bar .container {
    justify-content: center;
    text-align: center;
    gap: 4px;
    flex-direction: column;
  }
  .top-bar-badge {
    font-size: 0.74rem;
    text-align: center;
    line-height: 1.25;
  }
  .top-bar-contact {
    justify-content: center;
    gap: 8px;
    font-size: 0.74rem;
  }
  .top-bar-contact a[href^="mailto:"] {
    display: none;
  }

  /* Sticky Header */
  .site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
  }

  .site-header .container {
    height: 70px;
    padding: 0 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .site-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 1;
    min-width: 0;
  }

  .site-brand img {
    height: 38px !important;
    width: auto;
    object-fit: contain;
    flex-shrink: 0;
  }

  .brand-crest {
    width: 38px;
    height: 38px;
    font-size: 1.25rem;
    flex-shrink: 0;
  }

  .brand-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
  }

  .brand-name {
    font-size: 1.15rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .brand-tagline {
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.8px;
    color: var(--gold-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  /* Header actions */
  .header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
  }

  /* Hide the 180px desktop button on mobile to prevent overflow */
  .header-actions .btn-primary {
    display: none !important;
  }

  .mobile-menu-btn {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 1.5rem;
    color: var(--primary-navy);
    cursor: pointer;
    transition: var(--transition);
    padding: 0;
    flex-shrink: 0;
  }

  .mobile-menu-btn:hover, .mobile-menu-btn:active {
    background: var(--gold-accent);
    color: #ffffff;
    border-color: var(--gold-dark);
  }

  /* Mobile Slide-down Drawer: anchored to .site-header so it never overlaps the header/close button */
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: calc(100vh - 72px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background: #ffffff;
    box-shadow: 0 25px 50px rgba(0, 33, 71, 0.25);
    padding: 16px 18px 80px;
    z-index: 1001;
    border-top: 1px solid var(--border-color);
  }

  .main-nav.active {
    display: block;
    animation: fadeInNav 0.2s ease-out;
  }

  @keyframes fadeInNav {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
  }

  .nav-list {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    width: 100%;
    list-style: none;
  }

  .nav-item {
    width: 100%;
    border-bottom: 1px solid #f1f5f9;
  }

  .nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 6px;
    font-size: 1.02rem;
    font-weight: 600;
    color: var(--primary-navy);
    width: 100%;
  }

  .nav-item.has-dropdown > .nav-link {
    cursor: pointer;
  }

  .dropdown-arrow {
    display: inline-block;
    font-size: 0.85rem;
    color: var(--gold-dark);
    transition: transform 0.25s ease;
  }

  .nav-item.open .dropdown-arrow {
    transform: rotate(180deg);
  }

  /* Accordion Dropdown Content */
  .dropdown-menu {
    display: none;
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: none;
    background: #f8fafc;
    border-radius: 8px;
    padding: 6px 0;
    margin: 0 0 10px;
    width: 100%;
    min-width: 100%;
  }

  .nav-item.open .dropdown-menu {
    display: block;
  }

  .dropdown-item {
    display: block;
    padding: 10px 16px;
    font-size: 0.9rem;
    color: var(--text-dark);
    border-bottom: 1px solid #edf2f7;
    font-weight: 500;
  }

  .dropdown-item:last-child {
    border-bottom: none;
  }

  .dropdown-item:hover, .dropdown-item:active {
    background-color: #f1f5f9;
    color: var(--gold-dark);
    padding-left: 20px;
  }

  /* Mobile Drawer CTAs */
  .mobile-nav-cta {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 2px solid #e2e8f0;
  }

  .mobile-nav-cta .btn {
    width: 100%;
    padding: 13px 18px;
    font-size: 0.95rem;
    justify-content: center;
  }

  /* Persistent Floating Mobile Action Bar */
  .mobile-floating-bar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 56px;
    background: var(--primary-navy-dark);
    border-top: 2px solid var(--gold-accent);
    z-index: 990;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.2);
  }

  .mobile-bar-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    text-align: center;
    border-right: 1px solid rgba(255, 255, 255, 0.12);
    text-decoration: none;
    padding: 4px 2px;
    transition: var(--transition);
  }

  .mobile-bar-btn:last-child {
    border-right: none;
  }

  .mobile-bar-btn span.icon {
    font-size: 1.15rem;
    line-height: 1;
  }

  .mobile-bar-btn.book-btn {
    background: var(--gold-gradient);
    color: var(--primary-navy-dark);
    flex: 1.25;
  }

  .mobile-bar-btn.whatsapp-btn {
    color: #4ade80;
  }

  /* Hero Section */
  .hero {
    padding: 36px 0 50px;
  }

  .hero-pill {
    font-size: 0.75rem;
    padding: 4px 12px;
    margin-bottom: 16px;
    display: inline-flex;
    max-width: 100%;
    word-break: break-word;
  }

  .hero-title {
    font-size: 1.85rem;
    line-height: 1.22;
    margin-bottom: 14px;
    word-wrap: break-word;
  }

  .hero-subtitle {
    font-size: 0.95rem;
    line-height: 1.55;
    margin-bottom: 22px;
  }

  .hero-cta-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
    margin-bottom: 24px;
  }

  .hero-cta-group .btn {
    width: 100%;
    justify-content: center;
    padding: 12px 16px;
    font-size: 0.9rem;
  }

  .hero-badges {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 24px;
    padding-top: 18px;
  }

  .hero-badge-item {
    gap: 8px;
  }

  .hero-badge-icon {
    width: 32px;
    height: 32px;
    font-size: 0.95rem;
    flex-shrink: 0;
  }

  .hero-badge-text {
    font-size: 0.74rem;
    line-height: 1.25;
  }

  /* Calculator & Cards */
  .hero-card, .calculator-wrapper, .multilingual-banner, .article-content {
    padding: 22px 16px;
    border-radius: 12px;
  }

  .calc-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .calc-selector-list {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .calc-btn-option {
    padding: 11px 14px;
    font-size: 0.88rem;
  }

  .calc-result-box {
    padding: 20px 16px;
  }

  /* Practice Routes & Directory Grids */
  .route-cards-grid, .keyword-hub-grid, .trust-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .director-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    text-align: center;
  }

  .director-img {
    margin: 0 auto;
    max-width: 220px;
  }

  .trust-section {
    padding: 24px 0;
  }

  .trust-stat {
    padding: 12px 0;
    border-right: none;
    border-bottom: 1px solid var(--border-color);
  }

  .stat-number {
    font-size: 1.85rem;
  }

  .section {
    padding: 44px 0;
  }

  .section-title {
    font-size: 1.75rem;
    line-height: 1.25;
  }

  .section-subtitle {
    font-size: 0.92rem;
  }

  /* Subpage Articles */
  .page-header {
    padding: 36px 0;
  }

  .page-title {
    font-size: 1.85rem;
    line-height: 1.25;
  }

  .page-intro {
    font-size: 0.95rem;
  }

  .subpage-layout {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 30px 0;
  }

  .article-content {
    padding: 24px 16px;
  }

  .sidebar-sticky {
    position: static;
  }

  /* Multilingual Banner */
  .multilingual-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .lang-pills {
    gap: 8px;
  }

  .lang-pill {
    padding: 6px 14px;
    font-size: 0.82rem;
  }

  /* FAQ */
  .faq-question {
    padding: 16px 18px;
    font-size: 1rem;
  }

  .faq-answer {
    padding: 0 18px 18px;
    font-size: 0.9rem;
  }

  /* Footer */
  .site-footer {
    padding: 48px 0 24px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 36px;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }

  /* Modal */
  .modal-box {
    padding: 24px 18px;
  }
}

@media (max-width: 480px) {
  .hero-badges {
    grid-template-columns: 1fr;
  }
  .brand-name {
    font-size: 1.05rem;
  }
  .brand-tagline {
    font-size: 0.58rem;
  }
}

