:root {
  --bg: #eaf4ff;
  --bg-soft: #f5fbff;
  --text: #0f2540;
  --muted: #43617f;
  --line: #c7daea;
  --primary: #0b63c5;
  --primary-strong: #08498f;
  --secondary: #14956b;
  --secondary-soft: #dcf5ea;
  --ok: #148f65;
  --danger: #cc3d4f;
  --card-shadow: 0 16px 38px rgba(14, 52, 92, 0.12);
  --radius-xl: 24px;
  --radius-lg: 16px;
  --radius-sm: 10px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: radial-gradient(circle at 18% 10%, #d9ebff 0%, transparent 30%),
    radial-gradient(circle at 80% 8%, #d8f5eb 0%, transparent 34%),
    var(--bg);
  font-family: "Work Sans", "Trebuchet MS", sans-serif;
  min-height: 100vh;
}

body.lang-ar {
  font-family: "Cairo", "Segoe UI", sans-serif;
}

h1,
h2,
h3,
h4 {
  font-family: "Sora", "Segoe UI", sans-serif;
  margin: 0;
}

body.lang-ar h1,
body.lang-ar h2,
body.lang-ar h3,
body.lang-ar h4 {
  font-family: "Cairo", "Segoe UI", sans-serif;
}

p {
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(12, 25, 42, 0.06) 0.5px, transparent 0.5px);
  background-size: 2px 2px;
  opacity: 0.2;
  z-index: 0;
}

.shape {
  position: fixed;
  border-radius: 999px;
  filter: blur(48px);
  z-index: 0;
  pointer-events: none;
}

.shape-a {
  width: 280px;
  height: 280px;
  background: rgba(11, 99, 197, 0.24);
  top: 220px;
  left: -80px;
}

.shape-b {
  width: 320px;
  height: 320px;
  background: rgba(20, 149, 107, 0.25);
  right: -120px;
  top: 48%;
}

.site-header,
main,
.cart-drawer,
.checkout-modal {
  position: relative;
  z-index: 1;
}

.site-header {
  position: sticky;
  top: 0;
  margin: 18px auto 0;
  width: min(1120px, calc(100% - 24px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 16px;
  background: rgba(245, 251, 255, 0.88);
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px rgba(18, 52, 83, 0.1);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: "Sora", "Segoe UI", sans-serif;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-size: 0.86rem;
}

.top-nav {
  display: flex;
  gap: 20px;
}

.top-nav a {
  color: #1f4468;
  font-weight: 600;
  font-size: 0.94rem;
}

.top-nav a:hover {
  color: var(--primary);
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
  background: #fff;
}

.lang-switch button {
  border: 0;
  background: transparent;
  color: #356183;
  font-weight: 700;
  font-size: 0.78rem;
  padding: 8px 10px;
  cursor: pointer;
}

.lang-switch button.is-active {
  background: linear-gradient(135deg, var(--primary), #1f8acc);
  color: #fff;
}

.cart-toggle {
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  background: linear-gradient(135deg, #0a4f99, #0b63c5);
  color: #fff;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
}

.cart-toggle span:last-child {
  min-width: 22px;
  height: 22px;
  border-radius: 99px;
  display: grid;
  place-items: center;
  background: var(--secondary);
  color: #fff;
  font-size: 0.82rem;
}

main {
  width: min(1120px, calc(100% - 24px));
  margin: 24px auto 48px;
}

.section {
  margin: 22px 0;
  background: var(--bg-soft);
  border: 1px solid #d4e3f0;
  border-radius: var(--radius-xl);
  padding: 30px;
  box-shadow: var(--card-shadow);
}

.eyebrow {
  display: inline-block;
  margin-bottom: 10px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 700;
}

.section-head h2 {
  font-size: clamp(1.5rem, 2vw, 2.1rem);
  margin-bottom: 18px;
}

.section-head > p:not(.eyebrow) {
  color: var(--muted);
  max-width: 68ch;
  margin-bottom: 16px;
  line-height: 1.5;
}

.hero {
  display: grid;
  gap: 24px;
  grid-template-columns: 1.25fr 0.95fr;
  align-items: stretch;
}

.hero-copy h1 {
  font-size: clamp(1.9rem, 4vw, 3rem);
  line-height: 1.05;
  margin-bottom: 14px;
}

.hero-copy p {
  color: var(--muted);
  line-height: 1.6;
  max-width: 62ch;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0 18px;
}

.btn {
  border: 0;
  border-radius: 999px;
  padding: 12px 20px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #1b87c8);
  box-shadow: 0 10px 22px rgba(11, 99, 197, 0.26);
}

.btn-secondary {
  color: #0f3653;
  background: var(--secondary-soft);
  border: 1px solid #b7ead5;
}

.hero-points {
  margin: 0;
  padding-left: 19px;
  color: #235b67;
  display: grid;
  gap: 6px;
}

html[dir="rtl"] .hero-points {
  padding-left: 0;
  padding-right: 19px;
}

.hero-card {
  background: linear-gradient(160deg, #0a4f99, #12986d);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 22px;
  display: grid;
  gap: 16px;
}

.flash-label {
  display: inline-flex;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-card h2 {
  font-size: 1.45rem;
}

.timer-line {
  color: #d7f6ee;
}

.timer-line strong {
  color: #ffffff;
}

.hero-stats {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.hero-stats article {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.15);
  padding: 10px;
}

.stat-value {
  font-family: "Sora", "Segoe UI", sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
}

body.lang-ar .stat-value {
  font-family: "Cairo", "Segoe UI", sans-serif;
}

.stat-label {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.93);
}

.trust-strip {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  text-align: center;
  font-weight: 600;
  color: #245b7a;
  padding-top: 18px;
  padding-bottom: 18px;
}

.trust-strip p {
  border: 1px dashed var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 11px;
}

.filters {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.filters button {
  border: 1px solid var(--line);
  background: #fff;
  color: #275579;
  border-radius: 999px;
  padding: 8px 12px;
  font-weight: 600;
  cursor: pointer;
}

.filters button.is-active {
  border-color: transparent;
  background: linear-gradient(135deg, #0a4f99, #0b63c5);
  color: #fff;
}

.product-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.product-card {
  border: 1px solid #dce8f3;
  background: #fff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.media {
  min-height: 190px;
  position: relative;
  padding: 14px;
  color: #fff;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  overflow: hidden;
}

.product-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.media::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to top, rgba(8, 27, 47, 0.68), rgba(8, 27, 47, 0.18) 44%, rgba(255, 255, 255, 0.08));
}

.media.is-fallback::before {
  background: radial-gradient(circle at 72% 20%, rgba(255, 255, 255, 0.44), transparent 45%);
}

.media span,
.media small {
  position: relative;
  z-index: 2;
}

.media-a {
  background: linear-gradient(135deg, #0b63c5, #169ec4);
}

.media-b {
  background: linear-gradient(135deg, #14956b, #0b63c5);
}

.media-c {
  background: linear-gradient(135deg, #1a83b1, #1ca57f);
}

.media-d {
  background: linear-gradient(135deg, #0f4f95, #2176ba);
}

.media-e {
  background: linear-gradient(135deg, #15785f, #1788a8);
}

.media-f {
  background: linear-gradient(135deg, #1d6ea8, #27a27d);
}

.media-g {
  background: linear-gradient(135deg, #0d5db5, #20a18f);
}

.media-h {
  background: linear-gradient(135deg, #146b9a, #27a264);
}

.media-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 8px;
  font-size: 0.71rem;
  background: rgba(4, 19, 34, 0.28);
}

.product-body {
  padding: 14px;
  display: grid;
  gap: 10px;
}

.product-title {
  font-size: 1.02rem;
  line-height: 1.2;
}

.product-sub {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.supplier-line {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.supplier-chip,
.fit-chip {
  font-size: 0.74rem;
  border-radius: 999px;
  padding: 4px 8px;
  font-weight: 600;
}

.supplier-chip {
  background: #e7f1ff;
  color: #0d4a87;
}

.fit-chip {
  background: #e5f7ef;
  color: #0f7251;
}

.price-line {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.price {
  font-size: 1.15rem;
  font-weight: 700;
}

.compare {
  color: #7d95aa;
  font-size: 0.9rem;
  text-decoration: line-through;
}

.product-actions {
  display: grid;
  gap: 8px;
  grid-template-columns: 1fr;
}

.product-actions .btn {
  border-radius: 999px;
  padding: 10px 13px;
  font-size: 0.86rem;
  width: 100%;
}

.bundles .bundle-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.bundle-grid article {
  border: 1px solid #d8e8f4;
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, #ffffff, #f2fbff);
  padding: 20px;
  display: grid;
  gap: 10px;
}

.bundle-tag {
  width: fit-content;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 0.74rem;
  color: #0b5f98;
  background: #deecff;
}

.bundle-price {
  font-family: "Sora", "Segoe UI", sans-serif;
  font-size: 1.24rem;
  font-weight: 700;
  color: var(--primary);
  display: grid;
  gap: 2px;
}

body.lang-ar .bundle-price {
  font-family: "Cairo", "Segoe UI", sans-serif;
}

.bundle-price span:last-child {
  color: #5f7e97;
  font-weight: 600;
  font-size: 0.82rem;
}

.proof .review-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.review-grid article {
  border-radius: 14px;
  border: 1px solid #d8e6f0;
  background: linear-gradient(180deg, #fff, #f7fcff);
  padding: 16px;
  display: grid;
  gap: 12px;
}

.review-grid p {
  color: #2f5675;
  line-height: 1.5;
}

.review-grid strong {
  color: #123f69;
}

.faq details {
  border: 1px solid #dbe7f0;
  border-radius: 14px;
  padding: 14px;
  background: #fff;
  margin-top: 10px;
}

.faq summary {
  cursor: pointer;
  font-family: "Sora", "Segoe UI", sans-serif;
  font-weight: 600;
}

body.lang-ar .faq summary {
  font-family: "Cairo", "Segoe UI", sans-serif;
}

.faq p {
  margin-top: 8px;
  color: var(--muted);
}

.final-cta {
  text-align: center;
  background: linear-gradient(145deg, #0a4f99, #14956b);
  color: #fff;
  display: grid;
  gap: 12px;
}

.final-cta p {
  color: #d8f3ed;
}

.final-cta .btn {
  justify-self: center;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: min(420px, 100%);
  height: 100dvh;
  background: #f4fbff;
  border-left: 1px solid #d4e3ef;
  box-shadow: -16px 0 40px rgba(14, 52, 92, 0.2);
  padding: 18px;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  gap: 14px;
  transform: translateX(100%);
  transition: transform 0.25s ease;
}

.cart-drawer.is-open {
  transform: translateX(0);
}

html[dir="rtl"] .cart-drawer {
  right: auto;
  left: 0;
  border-left: 0;
  border-right: 1px solid #d4e3ef;
  box-shadow: 16px 0 40px rgba(14, 52, 92, 0.2);
  transform: translateX(-100%);
}

html[dir="rtl"] .cart-drawer.is-open {
  transform: translateX(0);
}

.cart-drawer header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ghost-btn {
  border: 1px solid #c6d8e7;
  background: #fff;
  color: #335a7b;
  border-radius: 999px;
  padding: 8px 11px;
  font-weight: 700;
  cursor: pointer;
}

.cart-items {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  align-content: start;
  overflow: auto;
}

.cart-item {
  border: 1px solid #d9e7f2;
  border-radius: 12px;
  padding: 11px;
  background: #fff;
  display: grid;
  gap: 10px;
}

.cart-item-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.cart-item h4 {
  font-size: 0.95rem;
}

.cart-item p {
  color: #52718a;
  font-size: 0.83rem;
}

.qty-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.qty-controls button {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  border: 1px solid #c8d9e6;
  background: #fff;
  cursor: pointer;
  font-weight: 700;
}

.qty-controls span {
  min-width: 20px;
  text-align: center;
  font-weight: 700;
}

.line-delete {
  border: 0;
  background: transparent;
  color: var(--danger);
  font-weight: 700;
  cursor: pointer;
  padding: 0;
}

.cart-summary {
  border-top: 1px solid #d6e4ee;
  padding-top: 12px;
  display: grid;
  gap: 8px;
}

.cart-summary p {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.cart-total {
  font-size: 1.1rem;
}

.shipping-hint {
  color: #18795b;
  font-size: 0.84rem;
}

.checkout-btn {
  width: 100%;
}

.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 28, 47, 0.48);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 10;
}

.drawer-backdrop.is-open {
  opacity: 1;
  pointer-events: all;
}

.checkout-modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(11, 30, 50, 0.7);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 20;
}

.checkout-modal.is-open {
  opacity: 1;
  pointer-events: all;
}

.checkout-card {
  width: min(520px, calc(100% - 24px));
  border-radius: 18px;
  border: 1px solid #d7e5f1;
  background: #fbfeff;
  padding: 20px;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  border: 0;
  background: #ddeafb;
  color: #1e4c73;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.1rem;
}

html[dir="rtl"] .modal-close {
  right: auto;
  left: 10px;
}

.checkout-form {
  margin-top: 14px;
  display: grid;
  gap: 12px;
}

.checkout-form label {
  display: grid;
  gap: 6px;
  font-size: 0.9rem;
  color: #2f5a7d;
  font-weight: 600;
}

.checkout-form input {
  border: 1px solid #ccdeeb;
  border-radius: 10px;
  padding: 10px;
  font: inherit;
  background: #fff;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 20px);
  background: #114f8a;
  color: #fff;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 0.86rem;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 30;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.empty-cart {
  border: 1px dashed #bfd6e8;
  border-radius: 14px;
  padding: 16px;
  text-align: center;
  color: #4f708a;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1040px) {
  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .top-nav {
    display: none;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .hero-stats,
  .trust-strip {
    grid-template-columns: 1fr 1fr;
  }

  .proof .review-grid {
    grid-template-columns: 1fr;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .bundles .bundle-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .site-header {
    gap: 8px;
    padding: 10px;
  }

  .brand-text {
    display: none;
  }

  .header-tools {
    gap: 6px;
  }

  .section {
    padding: 20px;
    border-radius: 18px;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .hero-stats,
  .trust-strip {
    grid-template-columns: 1fr;
  }

  .cart-drawer {
    width: 100%;
  }
}
