/* ==============================================================================
   4Achievers - UAE & Middle East Hub Enhancements & RTL System (2026)
   Covers Dubai, Abu Dhabi, and wider UAE Learning Pathways
   ============================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;700;800;900&display=swap');

/* Arabic Typography */
html[lang="ar"],
html[dir="rtl"] {
  font-family: 'Tajawal', 'Segoe UI', Tahoma, Arial, sans-serif !important;
}

html[lang="ar"] h1,
html[lang="ar"] h2,
html[lang="ar"] h3,
html[lang="ar"] h4,
html[dir="rtl"] h1,
html[dir="rtl"] h2,
html[dir="rtl"] h3,
html[dir="rtl"] h4 {
  font-family: 'Tajawal', 'Segoe UI', Tahoma, Arial, sans-serif !important;
  letter-spacing: normal !important;
}

/* ==============================================================================
   Topbar Enhancements for UAE
   ============================================================================== */
.topbar {
  background: #051428;
  color: #dbe6f2;
  font-size: 0.82rem;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.topbar-left {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
}

.topbar-right {
  display: inline-flex;
  align-items: center;
  gap: 16px;
}

.topbar-badge {
  background: rgba(229, 168, 33, 0.15);
  color: #f7c653;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  border: 1px solid rgba(247, 198, 83, 0.3);
}

.topbar-wa-link {
  color: #4ade80;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: opacity 0.2s;
}

.topbar-wa-link:hover {
  opacity: 0.85;
}

/* ==============================================================================
   Language Control (Modern Toggle with Globe Icon)
   ============================================================================== */
.language-control {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  padding: 6px 14px;
  font: inherit;
  transition: all 0.2s ease;
  position: relative;
}

.language-control:hover {
  background: #ffffff;
  border-color: #0d3b68;
  box-shadow: 0 2px 10px rgba(13, 59, 104, 0.1);
}

.language-control .lang-globe-icon {
  color: #0d3b68;
  flex-shrink: 0;
}

.language-control select {
  border: none;
  background: transparent;
  color: var(--navy, #071d38);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  outline: none;
  padding: 0;
}

.language-control select option {
  background: #ffffff;
  color: #071d38;
  padding: 6px;
}

/* ==============================================================================
   UAE Strategic Trust Strip
   ============================================================================== */
.uae-trust-strip {
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  padding: 16px 0;
}

.uae-trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  align-items: center;
}

.uae-trust-item {
  display: flex;
  align-items: center;
  gap: 12px;
}

.uae-trust-icon {
  font-size: 1.55rem;
  flex-shrink: 0;
}

.uae-trust-item strong {
  display: block;
  font-size: 0.86rem;
  color: var(--navy, #071d38);
  line-height: 1.3;
}

.uae-trust-item small {
  display: block;
  font-size: 0.74rem;
  color: var(--muted, #637286);
  line-height: 1.3;
}

/* ==============================================================================
   RTL & Arabic Overrides (CRITICAL FIX FOR OVERLAPPING HERO PANEL)
   ============================================================================== */
html[dir="rtl"] {
  direction: rtl;
}

html[dir="rtl"] body {
  text-align: right;
  direction: rtl;
}

html[dir="rtl"] .topbar .container {
  flex-direction: row-reverse;
}

html[dir="rtl"] .topbar-right {
  flex-direction: row-reverse;
}

html[dir="rtl"] .navbar .navinner {
  direction: rtl;
}

html[dir="rtl"] .navlinks {
  direction: rtl;
}

html[dir="rtl"] .navactions {
  direction: rtl;
}

html[dir="rtl"] .hero-copy {
  text-align: right;
}

/* KEY FIX: hero-panel must be anchored to the LEFT in RTL so it does NOT overlap text on the RIGHT */
html[dir="rtl"] .hero-panel {
  right: auto !important;
  left: max(30px, calc((100vw - 1160px) / 2)) !important;
  text-align: right !important;
  direction: rtl !important;
}

html[dir="rtl"] .hero-panel ul {
  padding-right: 20px !important;
  padding-left: 0 !important;
}

html[dir="rtl"] .trust-row {
  justify-content: flex-start;
  direction: rtl;
}

html[dir="rtl"] .trust-row span:before {
  margin-right: 0 !important;
  margin-left: 8px !important;
}

html[dir="rtl"] .section-head {
  text-align: right;
}

html[dir="rtl"] .card-body,
html[dir="rtl"] .card h3,
html[dir="rtl"] .card p {
  text-align: right;
}

html[dir="rtl"] .text-link {
  direction: rtl;
}

html[dir="rtl"] .text-link span {
  display: inline-block;
  transform: scaleX(-1);
}

html[dir="rtl"] .location-card {
  text-align: right;
  align-items: flex-start;
}

html[dir="rtl"] .floating-note {
  right: auto !important;
  left: -16px !important;
  text-align: right;
}

html[dir="rtl"] .feature {
  text-align: right;
}

html[dir="rtl"] .cta-band {
  text-align: right;
}

html[dir="rtl"] .content-box {
  text-align: right;
}

html[dir="rtl"] .field label,
html[dir="rtl"] .field input,
html[dir="rtl"] .field select,
html[dir="rtl"] .field textarea {
  text-align: right;
  direction: rtl;
}

html[dir="rtl"] .faq summary {
  text-align: right;
  direction: rtl;
}

html[dir="rtl"] .faq p {
  text-align: right;
  direction: rtl;
}

html[dir="rtl"] .whatsapp {
  right: auto !important;
  left: 22px !important;
}

html[dir="rtl"] .uae-trust-item {
  direction: rtl;
}

/* ==============================================================================
   Floating WhatsApp Button
   ============================================================================== */
.whatsapp {
  display: none !important;
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 99;
  background: #16a34a;
  color: #ffffff !important;
  border-radius: 999px;
  padding: 12px 18px;
  box-shadow: 0 10px 25px rgba(22, 163, 74, 0.35);
  font-weight: 800;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
}

.whatsapp:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(22, 163, 74, 0.45);
}

.whatsapp svg {
  flex-shrink: 0;
}

/* Hide Google Translate top banner & tooltip */
.google-translate-hidden {
  position: absolute !important;
  left: -9999px !important;
  top: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

.goog-te-banner-frame,
iframe.goog-te-banner-frame,
.skiptranslate iframe {
  display: none !important;
  visibility: hidden !important;
}

body {
  top: 0 !important;
  position: static !important;
}

#goog-gt-tt,
.goog-te-balloon-frame {
  display: none !important;
}

.goog-text-highlight {
  background: none !important;
  box-shadow: none !important;
}

/* ==============================================================================
   Responsive Queries
   ============================================================================== */
@media (max-width: 900px) {
  .uae-trust-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }
}

@media (max-width: 760px) {
  .topbar .container {
    flex-direction: column;
    text-align: center;
    gap: 6px;
  }
  .language-control select {
    padding: 2px 4px;
  }
}

@media (max-width: 540px) {
  .uae-trust-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .whatsapp span {
    display: none;
  }
  .whatsapp {
    padding: 12px;
    border-radius: 50%;
  }
}

