/* ===== CSS RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Brand Colors — Vibrant & Rich */
  --sky: #0ea5e9;
  --sky-dark: #0369a1;
  --sky-light: #7dd3fc;
  --navy: #0c1e3c;
  --navy-mid: #163460;
  --navy-light: #1d4ed8;
  --green: #059669;
  --green-light: #d1fae5;

  /* Semantic tokens — Light Mode (richer, less washed out) */
  --bg: #f0f6ff;
  --bg-alt: #e8f0fa;
  --bg-card: #ffffff;
  --text-primary: #0c1e3c;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --border: #cbd5e1;
  --border-light: #dde5f0;

  /* Aliases */
  --white: #ffffff;
  --off-white: #eef3fb;
  --gray-50: #e8f0fa;
  --gray-100: #d1dded;
  --gray-300: #94a3b8;
  --gray-600: #334155;
  --gray-800: #0c1e3c;

  --shadow-sm: 0 2px 8px rgba(12,30,60,.1);
  --shadow-md: 0 6px 24px rgba(12,30,60,.14);
  --shadow-lg: 0 12px 40px rgba(12,30,60,.18);
  --shadow-xl: 0 24px 60px rgba(12,30,60,.25);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== DARK MODE VARIABLES ===== */
[data-theme="dark"] {
  --bg: #080e1a;
  --bg-alt: #0d1525;
  --bg-card: #111827;
  --text-primary: #f0f6ff;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --border: #1e2d45;
  --border-light: #162036;
  --off-white: #0d1525;
  --white: #111827;
  --gray-50: #162036;
  --gray-100: #1e2d45;
  --gray-300: #334155;
  --gray-600: #94a3b8;
  --gray-800: #f0f6ff;
  --shadow-sm: 0 2px 8px rgba(0,0,0,.5);
  --shadow-md: 0 6px 24px rgba(0,0,0,.6);
  --shadow-lg: 0 10px 40px rgba(0,0,0,.5);
  --shadow-xl: 0 20px 60px rgba(0,0,0,.6);
}

/* Prevent horizontal scroll on ALL browsers */
html {
  scroll-behavior: smooth;
  font-size: 16px;
  overflow-x: hidden;
  max-width: 100%;
}

body {
  font-family: 'Cairo', sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  direction: rtl;
  overflow-x: hidden;
  max-width: 100%;
  width: 100%;
  line-height: 1.7;
  transition: background 0.4s ease, color 0.4s ease;
  position: relative;
}

/* LTR mode for English */
body.ltr { direction: ltr; }

/* Global box-sizing fix */
*, *::before, *::after {
  box-sizing: border-box;
}

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 24px);
  width: 100%;
  box-sizing: border-box;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--navy); }
::-webkit-scrollbar-thumb { background: var(--sky); border-radius: 3px; }

/* ===== NAVBAR ===== */
.navbar {
  position: fixed;
  top: 0; right: 0; left: 0;
  z-index: 1000;
  padding: 12px 0;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  transition: background 0.35s ease, padding 0.35s ease, box-shadow 0.35s ease;
  background: transparent !important;
  border-bottom: none;
}

/* Safe area support for iOS notch */
@supports (padding-top: env(safe-area-inset-top)) {
  .navbar {
    padding-top: max(12px, env(safe-area-inset-top));
  }
}

.navbar.scrolled {
  background: rgba(10, 22, 40, 0.96) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 8px 0;
  box-shadow: 0 4px 30px rgba(0,0,0,.3);
}

[data-theme="dark"] .navbar.scrolled {
  background: rgba(13,17,23,.97) !important;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(14px, 4vw, 24px);
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  box-sizing: border-box;
  /* RTL: logo right, links fill middle, controls left */
}

.logo-img {
  height: 52px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(14,165,233,.3));
  flex-shrink: 0;
}

/* Mobile Nav Drawer */
.nav-links {
  display: flex;
  gap: 4px;
  margin-right: auto;
  flex-wrap: nowrap;
  align-items: center;
}

.nav-link {
  color: rgba(255,255,255,.85);
  font-size: 14px;
  font-weight: 500;
  padding: 7px 12px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  position: relative;
  white-space: nowrap;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 2px; right: 12px; left: 12px;
  height: 2px;
  background: var(--sky);
  border-radius: 1px;
  transform: scaleX(0);
  transition: var(--transition);
}

.nav-link:hover, .nav-link.active { color: var(--white); }
.nav-link:hover::after, .nav-link.active::after { transform: scaleX(1); }

/* Nav Controls Group */
.nav-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

/* Theme Toggle */
.theme-toggle {
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.25);
  background: rgba(255,255,255,.1);
  color: rgba(255,255,255,.9);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  flex-shrink: 0;
}

.theme-toggle:hover {
  background: rgba(255,255,255,.2);
  transform: rotate(15deg);
}

.theme-toggle .icon-sun,
.theme-toggle .icon-moon { display: none; }

[data-theme="light"] .theme-toggle .icon-sun,
:root:not([data-theme]) .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

/* Language Toggle */
.lang-toggle {
  height: 38px;
  padding: 0 14px;
  border-radius: 50px;
  border: 1px solid rgba(255,255,255,.25);
  background: rgba(255,255,255,.1);
  color: rgba(255,255,255,.9);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: 'Cairo', sans-serif;
  font-size: 13px;
  font-weight: 700;
  transition: var(--transition);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  white-space: nowrap;
  flex-shrink: 0;
}

.lang-toggle:hover {
  background: rgba(14,165,233,.25);
  border-color: var(--sky);
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: var(--white) !important;
  padding: 9px 18px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  transition: var(--transition);
  box-shadow: 0 4px 16px rgba(37,211,102,.3);
  flex-shrink: 0;
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37,211,102,.4);
}

/* Mobile Menu Overlay */
.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 9998;
  backdrop-filter: blur(4px);
}

.nav-overlay.open { display: block; }

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 8px;
  flex-shrink: 0;
  /* NO order:-1 — let HTML source order control position */
}

.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--white);
  border-radius: 1px;
  transition: var(--transition);
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  max-width: 100vw;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg-img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(10,22,40,.85) 0%, rgba(10,22,40,.65) 50%, rgba(2,132,199,.3) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 120px 24px 80px;
  width: 100%;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(14,165,233,.15);
  border: 1px solid rgba(14,165,233,.4);
  color: var(--sky-light);
  padding: 8px 20px;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 28px;
  backdrop-filter: blur(10px);
  animation: fadeInDown 0.8s ease both;
}

.badge-dot {
  width: 8px; height: 8px;
  background: #4ade80;
  border-radius: 50%;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.5); }
}

.hero-title {
  font-size: clamp(2.4rem, 5.5vw, 4.5rem);
  font-weight: 900;
  color: var(--white);
  line-height: 1.2;
  margin-bottom: 20px;
  animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-title-accent {
  background: linear-gradient(135deg, var(--sky), #60d0f7, var(--green));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: clamp(1rem, 2.2vw, 1.25rem);
  color: rgba(255,255,255,.8);
  margin-bottom: 36px;
  line-height: 1.8;
  animation: fadeInUp 0.8s ease 0.4s both;
}

.hero-subtitle strong {
  color: var(--sky-light);
}

.hero-btns {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 48px;
  animation: fadeInUp 0.8s ease 0.6s both;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 700;
  font-family: 'Cairo', sans-serif;
  transition: var(--transition);
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--sky), var(--sky-dark));
  color: var(--white);
  box-shadow: 0 6px 24px rgba(14,165,233,.4);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(14,165,233,.5);
}

.btn-whatsapp {
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: var(--white);
  box-shadow: 0 6px 24px rgba(37,211,102,.3);
}

.btn-whatsapp:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(37,211,102,.4);
}

.btn-white {
  background: var(--white);
  color: var(--navy);
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 700;
  display: inline-block;
  transition: var(--transition);
  box-shadow: 0 4px 16px rgba(0,0,0,.1);
}

.btn-white:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0,0,0,.2);
}

/* Trust Badges */
.trust-badges {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s ease 0.8s both;
}

.trust-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,.2);
  padding: 10px 18px;
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.trust-badge:hover {
  background: rgba(255,255,255,.18);
  transform: translateY(-2px);
}

.trust-icon { font-size: 20px; }

.trust-badge span {
  color: var(--white);
  font-size: 13px;
  font-weight: 600;
}

/* Scroll indicator */
.hero-scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
}

.scroll-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.scroll-indicator span {
  width: 2px;
  height: 8px;
  background: rgba(255,255,255,.6);
  border-radius: 1px;
  animation: scroll-bounce 1.5s ease infinite;
}

.scroll-indicator span:nth-child(2) { animation-delay: 0.2s; }
.scroll-indicator span:nth-child(3) { animation-delay: 0.4s; }

@keyframes scroll-bounce {
  0%, 100% { opacity: 0.3; transform: scaleY(1); }
  50% { opacity: 1; transform: scaleY(1.5); }
}

/* Animations */
@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===== STATS ===== */
.stats-section {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  padding: 60px 0;
  overflow: hidden;
  max-width: 100%;
}

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

.stat-card {
  text-align: center;
  padding: 32px 20px;
  border-radius: var(--radius-lg);
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(14,165,233,.2);
  transition: var(--transition);
}

.stat-card:hover {
  background: rgba(14,165,233,.1);
  border-color: rgba(14,165,233,.4);
  transform: translateY(-4px);
}

.stat-number {
  font-size: 3rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--sky), #60d0f7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 8px;
}

.stat-label {
  color: rgba(255,255,255,.7);
  font-size: 14px;
  font-weight: 500;
}

/* ===== SECTION COMMONS ===== */
.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-tag {
  display: inline-block;
  background: linear-gradient(135deg, rgba(14,165,233,.15), rgba(16,185,129,.1));
  border: 1px solid rgba(14,165,233,.3);
  color: var(--sky-dark);
  padding: 6px 20px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

.section-tag.light {
  background: rgba(255,255,255,.15);
  border-color: rgba(255,255,255,.3);
  color: var(--white);
}

.section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 12px;
  line-height: 1.3;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--gray-600);
  max-width: 600px;
  margin: 0 auto;
}

/* ===== ABOUT ===== */
.about {
  padding: 100px 0;
  background: var(--off-white);
  overflow: hidden;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 60px;
  align-items: center;
  max-width: 100%;
}

.about-img-wrapper {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
}

.about-img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  display: block;
}

.about-img-badge {
  position: absolute;
  bottom: 20px;
  right: 20px;
  background: rgba(10,22,40,.85);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(14,165,233,.3);
  color: var(--white);
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 600;
}

.about-text {
  font-size: 1.05rem;
  color: var(--gray-600);
  margin-bottom: 20px;
  line-height: 1.9;
}

.about-text strong { color: var(--sky-dark); }

.quality-pillars {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 32px;
}

.pillar {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 20px;
  background: var(--white);
  border-radius: var(--radius-md);
  border: 1px solid var(--gray-100);
  transition: var(--transition);
}

.pillar:hover {
  border-color: var(--sky-light);
  box-shadow: 0 4px 20px rgba(14,165,233,.1);
  transform: translateY(-3px);
}

.pillar-icon {
  width: 52px; height: 52px;
  background: linear-gradient(135deg, rgba(14,165,233,.1), rgba(16,185,129,.1));
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--sky-dark);
  flex-shrink: 0;
}

.pillar-content h4 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 4px;
}

.pillar-content p {
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.6;
}

/* ===== PROCESS ===== */
.process-section {
  padding: 100px 0;
  background: linear-gradient(180deg, var(--navy) 0%, var(--navy-mid) 100%);
  overflow: hidden;
}

.process-section .section-title {
  color: var(--white);
}

.process-steps {
  display: flex;
  align-items: center;
  gap: 0;
  overflow: hidden;  /* was overflow-x:auto — caused horizontal scroll */
  padding-bottom: 8px;
  flex-wrap: nowrap;
}

.process-step {
  flex: 1;
  min-width: 0;       /* remove 160px min-width that caused horizontal overflow */
  text-align: center;
  padding: 28px 16px;
  background: rgba(255,255,255,.05);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(14,165,233,.2);
  transition: var(--transition);
  position: relative;
}

.process-step:hover {
  background: rgba(14,165,233,.12);
  border-color: rgba(14,165,233,.5);
  transform: translateY(-6px);
}

.step-num,
.step-number {
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--sky);
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.step-icon {
  font-size: 2rem;
  margin-bottom: 12px;
}

.process-step h4,
.step-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 8px;
}

.process-step p,
.step-desc {
  font-size: 0.82rem;
  color: rgba(255,255,255,.6);
  line-height: 1.5;
}

.process-arrow {
  font-size: 1.5rem;
  color: var(--sky);
  padding: 0 8px;
  flex-shrink: 0;
  opacity: 0.6;
}

/* ===== PRODUCTS ===== */
.products {
  padding: 100px 0;
  background: var(--white);
  overflow: hidden;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  max-width: 100%;
}

.product-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 1px solid var(--gray-100);
  overflow: hidden;
  transition: var(--transition);
  position: relative;
  box-shadow: var(--shadow-sm);
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
  border-color: var(--sky-light);
}

.product-badge-tag {
  position: absolute;
  top: 16px;
  right: 16px;
  background: linear-gradient(135deg, var(--sky), var(--sky-dark));
  color: var(--white);
  padding: 5px 14px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 700;
  z-index: 2;
}

.product-badge-green {
  background: linear-gradient(135deg, var(--green), #059669);
}

/* Product Image Area */
.product-img-wrap {
  height: 280px;
  background: linear-gradient(160deg, #dbeeff 0%, #e8f4ff 50%, #cce8ff 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow: hidden;
  position: relative;
}

[data-theme="dark"] .product-img-wrap {
  background: linear-gradient(160deg, #0d2040 0%, #112a50 50%, #0a1a36 100%);
}

.product-img {
  max-height: 240px;
  max-width: 100%;
  width: auto;
  object-fit: contain;
  transition: transform 0.5s ease;
  margin: 0 auto;
  display: block;
  /* Ensure image renders correctly */
  image-rendering: auto;
}

.product-card:hover .product-img {
  transform: scale(1.08) translateY(-6px);
}

.product-info,
.product-body {
  padding: 24px;
}

/* Alias for product-badge-tag used in HTML */
.product-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background: linear-gradient(135deg, var(--sky), var(--sky-dark));
  color: var(--white);
  padding: 5px 14px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 700;
  z-index: 2;
}

/* product-btn: inherits from .btn .btn-primary, just ensure full width */
.product-btn {
  width: 100%;
  justify-content: center;
  margin-top: 8px;
}

.product-category {
  font-size: 12px;
  font-weight: 700;
  color: var(--sky-dark);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.product-name {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 10px;
}

.product-spec {
  font-size: 0.9rem;
  color: var(--gray-600);
  background: var(--gray-50);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  display: inline-block;
}

.product-features {
  margin-bottom: 24px;
}

.product-features li {
  font-size: 0.9rem;
  color: var(--gray-600);
  padding: 5px 0;
  border-bottom: 1px dashed var(--gray-100);
  display: flex;
  align-items: center;
  gap: 8px;
}

.product-features li:last-child { border-bottom: none; }

.product-order-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 13px;
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: var(--white);
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 700;
  font-family: 'Cairo', sans-serif;
  transition: var(--transition);
  border: none;
  cursor: pointer;
}

.product-order-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37,211,102,.35);
}

/* ===== SUBSCRIPTION ===== */
.subscription {
  padding: 100px 0;
  background: linear-gradient(135deg, var(--navy) 0%, #0f2b50 50%, var(--navy-mid) 100%);
  position: relative;
  overflow: hidden;
}

.subscription::before {
  content: '';
  position: absolute;
  top: -100px; left: -100px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(14,165,233,.15) 0%, transparent 70%);
}

.subscription::after {
  content: '';
  position: absolute;
  bottom: -100px; right: -100px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(16,185,129,.1) 0%, transparent 70%);
}

.subscription-wrapper {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.subscription-content h2 {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  font-weight: 800;
  color: var(--white);
  margin-bottom: 20px;
  line-height: 1.3;
}

.subscription-content p {
  color: rgba(255,255,255,.75);
  font-size: 1.05rem;
  margin-bottom: 32px;
  line-height: 1.8;
}

.subscription-benefits {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 36px;
}

.benefit-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: rgba(255,255,255,.08);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255,255,255,.1);
  transition: var(--transition);
}

.benefit-item:hover {
  background: rgba(14,165,233,.15);
  border-color: rgba(14,165,233,.3);
}

.benefit-icon { font-size: 1.2rem; }

.benefit-item span:last-child {
  color: rgba(255,255,255,.85);
  font-size: 0.9rem;
  font-weight: 600;
}

.sub-visual-card {
  background: rgba(255,255,255,.08);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: var(--radius-xl);
  padding: 36px;
  text-align: center;
}

.sub-icon {
  font-size: 3rem;
  margin-bottom: 24px;
  animation: spin-slow 6s linear infinite;
}

@keyframes spin-slow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.sub-schedule {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
}

.schedule-item {
  padding: 12px 20px;
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 600;
  transition: var(--transition);
}

.schedule-item.active {
  background: linear-gradient(135deg, rgba(14,165,233,.2), rgba(16,185,129,.15));
  border: 1px solid rgba(14,165,233,.4);
  color: var(--white);
}

.sub-cta-text {
  color: rgba(255,255,255,.7);
  font-size: 0.9rem;
}

/* ===== CONTACT ===== */
.contact {
  padding: 100px 0;
  background: var(--off-white);
  overflow: hidden;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 40px;
  margin-bottom: 60px;
  max-width: 100%;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Title above contact cards */
.contact-info-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 4px;
}

/* Container for contact cards */
.contact-cards {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-card {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  padding: 24px;
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-100);
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.contact-card:hover {
  border-color: var(--sky-light);
  box-shadow: 0 8px 30px rgba(14,165,233,.1);
  transform: translateY(-3px);
}

/* Alias: contact-card-icon maps to contact-icon */
.contact-icon,
.contact-card-icon {
  width: 50px; height: 50px;
  background: linear-gradient(135deg, rgba(14,165,233,.15), rgba(16,185,129,.1));
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--sky-dark);
  flex-shrink: 0;
}

.contact-detail h4,
.contact-card-body h4 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 6px;
}

.contact-detail p,
.contact-card-body p {
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.6;
}

.contact-link {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--sky-dark);
  display: block;
  margin-bottom: 10px;
  direction: ltr;
  text-align: right;
}

.contact-sub-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.sub-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--sky-dark);
  padding: 5px 12px;
  background: rgba(14,165,233,.08);
  border-radius: 50px;
  border: 1px solid rgba(14,165,233,.2);
  transition: var(--transition);
}

.sub-link:hover {
  background: rgba(14,165,233,.15);
  border-color: var(--sky);
}

.whatsapp-link {
  color: #128c7e;
  background: rgba(37,211,102,.08);
  border-color: rgba(37,211,102,.2);
}

.whatsapp-link:hover {
  background: rgba(37,211,102,.15);
}

.hours-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hour-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.88rem;
}

.hour-row span:first-child { color: var(--gray-600); }

.hour-time {
  font-weight: 600;
  color: var(--navy);
}

.badge-available {
  background: linear-gradient(135deg, var(--green), #059669);
  color: var(--white);
  padding: 3px 10px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 700;
}

/* Order Form */
.order-form-wrap { }

.order-form {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 36px;
  border: 1px solid var(--gray-100);
  box-shadow: var(--shadow-md);
}

.form-header {
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--gray-100);
}

.form-title {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 8px;
}

.form-title svg { color: var(--sky-dark); }

.form-subtitle {
  font-size: 0.9rem;
  color: var(--gray-300);
  margin-bottom: 28px;
}

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

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--gray-800);
  margin-bottom: 8px;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 13px 16px;
  border: 1.5px solid var(--gray-100);
  border-radius: var(--radius-md);
  font-size: 14px;
  font-family: 'Cairo', sans-serif;
  color: var(--gray-800);
  background: var(--off-white);
  transition: var(--transition);
  outline: none;
  direction: rtl;
}

.form-group input:focus,
.form-group select:focus {
  border-color: var(--sky);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(14,165,233,.1);
}

.form-submit-btn {
  width: 100%;
  padding: 15px;
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: var(--white);
  border: none;
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 700;
  font-family: 'Cairo', sans-serif;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.form-submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37,211,102,.35);
}

/* Map */
.map-wrap {
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  margin-top: 16px;
}

.map-header {
  background: var(--navy);
  padding: 20px 28px;
}

.map-header h3 {
  color: var(--white);
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.map-header p {
  color: rgba(255,255,255,.6);
  font-size: 0.9rem;
}

.map-container {
  position: relative;
  width: 100%;
  line-height: 0;
}

.map-container iframe {
  display: block;
  width: 100%;
  border: 0;
}

/* ===== FOOTER ===== */
.footer {
  background: var(--navy);
  padding: 80px 0 0;
}

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

.footer-logo {
  height: 72px;
  width: auto;
  margin-bottom: 16px;
}

.footer-brand p {
  font-size: 0.9rem;
  color: rgba(255,255,255,.6);
  line-height: 1.8;
  margin-bottom: 20px;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.social-btn {
  width: 44px; height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.social-btn.whatsapp {
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: var(--white);
}

.social-btn.phone {
  background: rgba(14,165,233,.2);
  border: 1px solid rgba(14,165,233,.3);
  color: var(--sky);
}

.social-btn:hover {
  transform: translateY(-3px) scale(1.1);
}

.footer-links h4,
.footer-contact-info h4 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,.1);
}

.footer-links ul li {
  margin-bottom: 10px;
}

.footer-links ul li a {
  color: rgba(255,255,255,.6);
  font-size: 0.9rem;
  transition: var(--transition);
}

.footer-links ul li a:hover {
  color: var(--sky-light);
  padding-right: 4px;
}

.footer-contact-info p {
  color: rgba(255,255,255,.6);
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.footer-contact-info p a {
  color: var(--sky-light);
  direction: ltr;
  display: inline-block;
}

.footer-badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.footer-badge {
  padding: 4px 12px;
  background: rgba(14,165,233,.1);
  border: 1px solid rgba(14,165,233,.25);
  color: var(--sky-light);
  border-radius: 50px;
  font-size: 11px;
  font-weight: 700;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 24px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.footer-bottom p {
  color: rgba(255,255,255,.4);
  font-size: 0.85rem;
}

.footer-tagline {
  color: var(--sky-light) !important;
}

/* ===== FLOATING WHATSAPP ===== */
.whatsapp-float {
  position: fixed;
  bottom: 28px;
  left: 28px;
  z-index: 99999 !important;
  background: linear-gradient(135deg, #25d366, #128c7e);
  width: 60px; height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 6px 24px rgba(37,211,102,.55);
  transition: var(--transition);
  animation: float-pulse 3s ease-in-out infinite;
  pointer-events: all;
  visibility: visible;
  opacity: 1;
}

@keyframes float-pulse {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.whatsapp-float:hover {
  transform: scale(1.12);
  box-shadow: 0 10px 36px rgba(37,211,102,.6);
  animation: none;
}

.float-tooltip {
  position: absolute;
  right: calc(100% + 12px);
  background: var(--navy);
  color: var(--white);
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: var(--transition);
}

.whatsapp-float:hover .float-tooltip {
  opacity: 1;
}

/* ===== BACK TO TOP ===== */
.back-to-top {
  position: fixed;
  bottom: 100px;
  right: 28px;
  z-index: 9000;
  background: var(--sky-dark);
  width: 46px; height: 46px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(14,165,233,.35);
  transition: var(--transition);
  opacity: 0;
  pointer-events: none;
}

.back-to-top.visible {
  opacity: 1;
  pointer-events: all;
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(14,165,233,.5);
}

/* =====================================================
   RESPONSIVE — MOBILE FIRST
   ===================================================== */

/* === TABLET 1024px === */
@media (max-width: 1024px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .products-grid { grid-template-columns: repeat(2, 1fr); }
  .about-grid { grid-template-columns: 1fr; }
  .about-img { height: 340px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .subscription-wrapper { grid-template-columns: 1fr; gap: 32px; }
  .contact-grid { grid-template-columns: 1fr; }
  .order-form-wrap { max-width: 600px; margin: 0 auto; width: 100%; }
  .cert-layout { grid-template-columns: 1fr; }
  .cert-left { position: static; }
  .cert-data-grid { grid-template-columns: repeat(2, 1fr); }
  .standards-grid { grid-template-columns: 1fr; }
}

/* === MOBILE 768px === */
@media (max-width: 768px) {

  /* ============================================
     CRITICAL: Prevent horizontal overflow
     The nav drawer MUST use transform not right/left negative values
     ============================================ */
  html, body { overflow-x: hidden !important; max-width: 100% !important; }

  /* NAVBAR - transparent always, dark when scrolled */
  .navbar,
  .navbar:not(.scrolled) {
    background: transparent !important;
    box-shadow: none !important;
    border-bottom: none !important;
  }
  .navbar.scrolled {
    background: rgba(10,22,40,.97) !important;
    box-shadow: 0 4px 30px rgba(0,0,0,.3) !important;
  }
  [data-theme="dark"] .navbar.scrolled {
    background: rgba(5,8,15,.98) !important;
  }

  /* ============================================
     NAVBAR LAYOUT (RTL mobile)
     Visual order: [Logo RIGHT] […Controls…] [☰ LEFT]
     HTML order:   hamburger → nav-logo → nav-links → nav-controls
     Use flex order in RTL: lower order = more to the right
     ============================================ */
  .nav-container {
    padding: 0 16px;
    gap: 8px;
    width: 100%;
    justify-content: space-between;
  }

  /* Logo → rightmost in RTL (order 1) */
  .nav-logo   { order: 1; flex-shrink: 0; }

  /* Controls → middle */
  .nav-controls { order: 2; gap: 6px; flex-shrink: 0; }

  /* Hamburger → leftmost in RTL (order 3 = end of RTL row) */
  .hamburger  { display: flex; order: 3; flex-shrink: 0; }

  /* nav-links is position:fixed so order doesn't matter, just hide it */

  /* LTR flip */
  body.ltr .nav-logo    { order: 3; }
  body.ltr .nav-controls{ order: 2; }
  body.ltr .hamburger   { order: 1; }

  /* Compact control buttons */
  .nav-cta span { display: none; }
  .nav-cta { padding: 8px 10px; gap: 0; min-width: 36px; justify-content: center; }
  .lang-toggle { padding: 0 9px; font-size: 12px; }
  .theme-toggle { width: 34px; height: 34px; }

  /* ============================================
     NAV DRAWER — Use transform (NOT right:-100%) to avoid overflow!
     ============================================ */
  .nav-links {
    position: fixed;
    top: 0;
    right: 0;                         /* anchor to right edge */
    transform: translateX(100%);      /* push off-screen using transform – no overflow */
    width: min(300px, 82vw);
    height: 100dvh;
    background: linear-gradient(180deg, #0a1628 0%, #0f2040 100%);
    flex-direction: column;
    padding: 80px 20px 40px;
    gap: 4px;
    z-index: 9999;
    transition: transform 0.38s cubic-bezier(0.4,0,0.2,1);
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: -8px 0 40px rgba(0,0,0,.5);
    margin-right: 0;
    align-items: stretch;
  }

  [data-theme="dark"] .nav-links {
    background: linear-gradient(180deg, #0d1117 0%, #161b22 100%);
  }

  /* LTR: slide from left */
  body.ltr .nav-links {
    right: auto;
    left: 0;
    transform: translateX(-100%);
    box-shadow: 8px 0 40px rgba(0,0,0,.5);
  }

  /* Open state */
  .nav-links.open               { transform: translateX(0); }
  body.ltr .nav-links.open      { transform: translateX(0); }

  .nav-link {
    font-size: 16px;
    padding: 14px 18px;
    border-radius: 12px;
    width: 100%;
    white-space: normal;
    color: rgba(255,255,255,.9);
  }

  .nav-link::after { display: none; }

  .nav-link.active,
  .nav-link:hover {
    background: rgba(14,165,233,.18);
    color: #fff;
  }

  /* HERO */
  .hero-content { padding: 100px 16px 70px; }
  .hero-title { font-size: clamp(1.9rem, 7vw, 2.5rem); }
  .hero-subtitle { font-size: 0.95rem; }
  .hero-btns { flex-direction: column; gap: 12px; }
  .hero-btns .btn { width: 100%; justify-content: center; }
  .trust-badges { gap: 8px; flex-wrap: wrap; }
  .trust-badge { padding: 8px 12px; flex: 1 1 calc(50% - 8px); min-width: 130px; }
  .trust-badge span { font-size: 12px; }

  /* STATS */
  .stats-section { padding: 50px 0; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .stat-card { padding: 20px 12px; }
  .stat-number { font-size: 2.2rem; }
  .stat-label { font-size: 13px; }

  /* SECTIONS */
  .section-header { margin-bottom: 32px; }
  .section-title { font-size: clamp(1.5rem, 5vw, 2rem); }
  .section-subtitle { font-size: 0.95rem; }

  /* ABOUT */
  .about { padding: 65px 0; }
  .about-grid { grid-template-columns: 1fr; gap: 28px; }
  .about-img { height: 260px; }
  .quality-pillars { gap: 14px; }
  .pillar { padding: 16px; }
  .pillar:hover { transform: translateY(-3px); }

  /* PROCESS */
  .process-section { padding: 65px 0; }
  .process-steps { flex-direction: column; align-items: center; gap: 12px; overflow-x: hidden; }
  .process-arrow { transform: rotate(90deg); font-size: 20px; padding: 4px 0; }
  .process-step { width: 100%; max-width: 100%; min-width: unset; }

  /* PRODUCTS */
  .products { padding: 65px 0; }
  .products-grid { grid-template-columns: 1fr; max-width: 100%; margin: 0 auto; gap: 20px; }
  .product-body { padding: 18px 16px; }

  /* CERTIFICATIONS — proper mobile single-column layout */
  .certifications { padding: 56px 0; overflow: hidden; }
  .cert-layout {
    display: flex;
    flex-direction: column;
    gap: 28px;
  }
  .cert-left { width: 100%; }
  .cert-right { width: 100%; }
  .cert-doc-frame {
    max-width: 100%;
    border-radius: 16px;
  }
  .cert-doc-img-wrap {
    height: auto;
    min-height: 220px;
  }
  .cert-doc-img {
    width: 100%;
    max-height: 60vw;
    object-fit: contain;
  }
  .cert-doc-footer {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px;
  }
  .cert-doc-detail {
    flex: 1;
    min-width: 80px;
    text-align: center;
    padding: 8px 4px;
  }
  .cert-data-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .standards-grid { grid-template-columns: 1fr; gap: 10px; }
  .cert-info-header h3 { font-size: 1.2rem; line-height: 1.4; }
  .standard-item:hover { transform: none; }

  /* SUBSCRIPTION */
  .subscription { padding: 56px 0; }
  .subscription-wrapper {
    display: flex;
    flex-direction: column;
    gap: 24px;
  }
  .subscription-benefits { grid-template-columns: 1fr 1fr; gap: 12px; }
  .sub-visual-card { padding: 24px 18px; }
  .benefit-item {
    flex-direction: column;
    text-align: center;
    padding: 14px 10px;
  }
  .benefit-item h4 { font-size: 0.95rem; }
  .benefit-item p { font-size: 0.82rem; }

  /* CONTACT */
  .contact { padding: 65px 0; }
  .contact-grid { grid-template-columns: 1fr; gap: 24px; }
  .order-form-wrap { max-width: 100%; }
  .order-form { padding: 24px 18px; }
  .contact-card:hover { transform: none; }

  /* MAP */
  .map-container iframe { height: 280px; }
  .map-wrap { border-radius: var(--radius-lg); }

  /* FOOTER */
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; text-align: center; gap: 8px; }

  /* LIGHTBOX */
  .lightbox-panel { max-height: 95vh; }

  /* FLOATING BUTTONS — no overlap with content */
  .back-to-top {
    bottom: 84px;
    right: 14px;
    width: 42px; height: 42px;
    font-size: 14px;
  }
  body.ltr .back-to-top { right: auto; left: 14px; }

  .whatsapp-float {
    bottom: 18px;
    left: 14px;
    width: 50px; height: 50px;
  }
  body.ltr .whatsapp-float { left: auto; right: 14px; }

  /* Product grid on mobile */
  .products-grid { grid-template-columns: 1fr; gap: 24px; }
  .product-img-wrap { height: 240px; }
  .product-img { max-height: 200px; }
  .product-btn { font-size: 15px; padding: 13px 20px; }
}

/* === SMALL MOBILE 480px === */
@media (max-width: 480px) {
  .hero-content { padding: 90px 14px 60px; }
  .hero-title { font-size: 1.85rem; }
  .trust-badge { flex: 1 1 100%; }

  .stat-number { font-size: 2rem; }
  .stats-grid { gap: 10px; }
  .stat-card { padding: 18px 10px; }

  .section-title { font-size: 1.5rem; }

  .products-grid { max-width: 100%; }
  .product-img-wrap { height: 220px; }

  .cert-data-grid { grid-template-columns: 1fr; }
  .subscription-benefits { grid-template-columns: 1fr; }
  .benefit-item h4 { font-size: 0.9rem; }

  .order-form { padding: 20px 14px; }
  .btn { font-size: 15px; padding: 12px 20px; }

  .footer-grid { gap: 24px; }
  .nav-links { width: 100%; border-radius: 0; }

  .about-img { height: 230px; }
  .about-img-badge { font-size: 12px; padding: 8px 14px; }

  .map-container iframe { height: 240px; }
  .btn-map-open { font-size: 14px; padding: 11px 20px; }

  /* On 480px: hero has no right-side wasted space */
  .hero-btns .btn { font-size: 15px; }
}

/* === EXTRA SMALL 360px === */
@media (max-width: 360px) {
  .nav-container { padding: 0 10px; gap: 6px; }
  .logo-img { height: 38px; }
  .hero-title { font-size: 1.65rem; }
  .stat-number { font-size: 1.8rem; }
  .lang-toggle { padding: 0 7px; font-size: 11px; }
  .theme-toggle { width: 30px; height: 30px; }
  .nav-cta { padding: 6px 8px; }
  .hero-content { padding: 85px 12px 55px; }
  .map-container iframe { height: 200px; }
}


/* =====================================================
   CERTIFICATIONS — ALL STYLES (Mobile-First)
   ===================================================== */

/* ---- Section wrapper ---- */
.certifications {
  padding: 60px 0;
  background: linear-gradient(180deg, var(--off-white) 0%, var(--bg) 100%);
  overflow: hidden;
}

/* ---- Layout: single-col on mobile, 2-col on desktop ---- */
.cert-layout {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-top: 16px;
}

/* ---- Certificate Frame Card ---- */
.cert-doc-frame {
  background: var(--bg-card);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 8px 40px rgba(10,22,40,.14), 0 2px 8px rgba(10,22,40,.06);
  border: 1px solid rgba(14,165,233,.15);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  width: 100%;
}

.cert-doc-frame:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(10,22,40,.18), 0 4px 16px rgba(14,165,233,.15);
}

/* ---- Frame Header ---- */
.cert-doc-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: linear-gradient(135deg, var(--navy), #163460);
}

.cert-doc-badge {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  color: #fff;
  padding: 4px 14px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1px;
}

.cert-doc-valid {
  color: #6ee7b7;
  font-size: 13px;
  font-weight: 700;
}

/* ---- Certificate Image ---- */
.cert-doc-img-wrap {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  background: #fff;
}

.cert-doc-img {
  width: 100%;
  display: block;
  transition: transform 0.5s ease;
}

.cert-doc-img-wrap:hover .cert-doc-img { transform: scale(1.02); }

/* ---- View Button (shows on hover) ---- */
.cert-view-btn {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(10,22,40,.85);
  color: #fff;
  border: 1px solid rgba(14,165,233,.5);
  padding: 9px 18px;
  border-radius: 50px;
  font-family: 'Cairo', sans-serif;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  opacity: 0;
  transition: all 0.35s ease;
  backdrop-filter: blur(10px);
  white-space: nowrap;
  z-index: 2;
}

.cert-doc-img-wrap:hover .cert-view-btn {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.cert-view-btn:hover {
  background: var(--sky);
  border-color: var(--sky);
}

/* On mobile — always show the button (no hover) */
@media (max-width: 768px) {
  .cert-view-btn {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    font-size: 12px;
    padding: 8px 16px;
    bottom: 10px;
  }
}

/* ---- Frame Footer (3 info cells) ---- */
.cert-doc-footer {
  display: flex;
  gap: 0;
  border-top: 1px solid var(--border);
}

.cert-doc-detail {
  flex: 1;
  padding: 12px 10px;
  text-align: center;
  border-left: 1px solid var(--border);
}

.cert-doc-detail:last-child { border-left: none; }

.cert-doc-detail span {
  display: block;
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cert-doc-detail strong {
  font-size: 11px;
  color: var(--text-primary);
  font-weight: 800;
  direction: ltr;
  display: block;
}

/* ---- Right Side Info ---- */
.cert-right {}

.cert-info-header {
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--border-light);
}

.cert-info-header h3 {
  font-size: clamp(1.2rem, 4vw, 1.6rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 12px;
  line-height: 1.4;
}

.cert-info-header p {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.8;
}

.cert-info-header strong { color: var(--sky-dark); }

/* ---- Data Grid (4 info boxes) ---- */
.cert-data-grid {
  display: grid;
  grid-template-columns: 1fr;   /* 1 col on mobile */
  gap: 10px;
  margin-bottom: 24px;
}

.cert-data-item {
  display: flex;
  flex-direction: row;          /* always row: icon | text */
  align-items: center;
  gap: 12px;
  background: var(--bg-alt);
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  transition: var(--transition);
  min-width: 0;                 /* prevent overflow */
}

.cert-data-item:hover {
  background: rgba(14,165,233,.08);
  border-color: rgba(14,165,233,.3);
}

.cert-data-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
  line-height: 1;
  width: 36px;
  text-align: center;
}

.cert-data-text { min-width: 0; flex: 1; }

.cert-data-label {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-bottom: 2px;
  display: block;
}

.cert-data-val {
  font-size: 0.95rem;
  color: var(--text-primary);
  font-weight: 700;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---- Standards Section ---- */
.standards-heading {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.standards-heading::before {
  content: '';
  display: block;
  width: 4px;
  height: 20px;
  background: linear-gradient(to bottom, var(--sky), var(--sky-dark));
  border-radius: 2px;
  flex-shrink: 0;
}

.standards-grid {
  display: grid;
  grid-template-columns: 1fr;   /* 1 col on mobile */
  gap: 10px;
}

.standard-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  background: var(--bg-alt);
  border-radius: 12px;
  border: 1px solid var(--border);
  transition: var(--transition);
  min-width: 0;
}

.standard-item:hover {
  background: rgba(14,165,233,.05);
  border-color: rgba(14,165,233,.2);
}

.standard-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
  line-height: 1.3;
  margin-top: 1px;
}

.standard-info { min-width: 0; flex: 1; }

.standard-info h4 {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 3px;
  word-break: break-word;
}

.standard-info p {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.6;
  word-break: break-word;
}

/* =====================================================
   CERTIFICATIONS — DESKTOP 2-COLUMN LAYOUT
   ===================================================== */
@media (min-width: 769px) {
  .certifications { padding: 100px 0; }

  .cert-layout {
    display: grid;
    grid-template-columns: 1fr 1.35fr;
    flex-direction: unset;
    gap: 48px;
    align-items: start;
  }

  .cert-left { position: sticky; top: 100px; }

  .cert-info-header { margin-bottom: 28px; padding-bottom: 24px; }

  /* 2 columns on desktop for data grid */
  .cert-data-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 32px;
  }

  .cert-data-item { padding: 14px 16px; }
  .cert-data-icon { font-size: 1.4rem; }
  .cert-data-label { font-size: 11px; }
  .cert-data-val { font-size: 0.95rem; }

  /* 2 columns on desktop for standards */
  .standards-grid { grid-template-columns: 1fr 1fr; }

  .standard-item { padding: 14px; }
  .standard-item:hover { transform: translateX(-3px); }
}


/* ===== CERTIFICATE LIGHTBOX ===== */
.cert-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.cert-lightbox.active {
  opacity: 1;
  pointer-events: all;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5,10,20,.9);
  backdrop-filter: blur(8px);
  cursor: pointer;
}

.lightbox-panel {
  position: relative;
  z-index: 1;
  background: var(--white);
  border-radius: 20px;
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0,0,0,.5);
  transform: scale(0.92) translateY(20px);
  transition: transform 0.4s cubic-bezier(.34,1.56,.64,1);
}

.cert-lightbox.active .lightbox-panel {
  transform: scale(1) translateY(0);
}

.lightbox-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  background: linear-gradient(135deg, var(--navy), #1e3a5f);
  color: var(--white);
  flex-shrink: 0;
}

.lightbox-top h3 {
  font-size: 1rem;
  font-weight: 700;
  margin: 0;
}

.lightbox-close {
  background: rgba(255,255,255,.15);
  border: none;
  color: var(--white);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  flex-shrink: 0;
}

.lightbox-close:hover { background: rgba(255,255,255,.3); }

.lightbox-body {
  overflow-y: auto;
  flex: 1;
  background: #f5f5f0;
}

.lightbox-img {
  width: 100%;
  display: block;
}

.lightbox-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 16px 24px;
  background: var(--white);
  border-top: 1px solid var(--gray-100);
  flex-shrink: 0;
  flex-wrap: wrap;
}

.btn-verify {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gray-600);
  font-size: 13px;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 50px;
  border: 1px solid var(--gray-100);
  transition: var(--transition);
}

.btn-verify:hover {
  color: var(--sky-dark);
  border-color: var(--sky-light);
  background: rgba(14,165,233,.05);
}

/* ===== CONTACT IMPROVEMENTS ===== */
.contact-link-sm {
  font-size: 0.88rem !important;
  direction: ltr;
  display: block;
  margin-bottom: 8px;
  font-weight: 600 !important;
  color: var(--sky-dark) !important;
}

/* ===== MAP OPEN LINK ===== */
.map-open-link {
  text-align: center;
  padding: 16px;
  background: var(--navy);
  border-top: 1px solid rgba(255,255,255,.08);
  border-radius: 0 0 16px 16px;
}

.btn-map-open {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, var(--sky), var(--sky-dark));
  color: var(--white);
  padding: 12px 28px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 700;
  transition: var(--transition);
  box-shadow: 0 4px 16px rgba(14,165,233,.3);
}

.btn-map-open:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(14,165,233,.45);
}


