:root,
html[data-theme="zain"] {
  --bg: #e0f2fe;
  --bg-mid: #f0f9ff;
  --bg-end: #f8fbff;
  --glow: rgba(14, 165, 233, 0.28);
  --panel: #ffffff;
  --panel-soft: #e0f2fe;
  --panel-grad: #eef8ff;
  --text: #0c4a6e;
  --muted: #475569;
  --primary: #0284c7;
  --primary-dark: #0369a1;
  --primary-deep: #0c4a6e;
  --accent: #38bdf8;
  --lime: #7dd3fc;
  --banner-bg: #e0f2fe;
  --banner-text: #075985;
  --chip-bg: #0c4a6e;
  --chip-text: #7dd3fc;
  --cta-start: #0369a1;
  --cta-end: #0ea5e9;
  --float-text: #0c4a6e;
  --overlay: rgba(12, 74, 110, 0.55);
  --border: rgba(2, 132, 199, 0.16);
  --shadow: 0 24px 70px rgba(2, 132, 199, 0.2);
  --theme-rgb: 2, 132, 199;
}

html[data-theme="stc"] {
  --bg: #f3e8ff;
  --bg-mid: #faf5ff;
  --bg-end: #fcfaff;
  --glow: rgba(139, 92, 246, 0.3);
  --panel: #ffffff;
  --panel-soft: #f3e8ff;
  --panel-grad: #f5f0ff;
  --text: #4c1d95;
  --muted: #6b7280;
  --primary: #7c3aed;
  --primary-dark: #6d28d9;
  --primary-deep: #5b21b6;
  --accent: #a78bfa;
  --lime: #c4b5fd;
  --banner-bg: #f3e8ff;
  --banner-text: #5b21b6;
  --chip-bg: #4c1d95;
  --chip-text: #e9d5ff;
  --cta-start: #6d28d9;
  --cta-end: #a78bfa;
  --float-text: #4c1d95;
  --overlay: rgba(76, 29, 149, 0.55);
  --border: rgba(124, 58, 237, 0.16);
  --shadow: 0 24px 70px rgba(109, 40, 217, 0.22);
  --theme-rgb: 124, 58, 237;
}

html[data-theme="mobily"] {
  --bg: #ecfeff;
  --bg-mid: #f0fdff;
  --bg-end: #f8feff;
  --glow: rgba(6, 182, 212, 0.3);
  --panel: #ffffff;
  --panel-soft: #cffafe;
  --panel-grad: #eefcff;
  --text: #155e75;
  --muted: #54758a;
  --primary: #06b6d4;
  --primary-dark: #0891b2;
  --primary-deep: #0e7490;
  --accent: #22d3ee;
  --lime: #67e8f9;
  --banner-bg: #ecfeff;
  --banner-text: #0e7490;
  --chip-bg: #155e75;
  --chip-text: #a5f3fc;
  --cta-start: #0891b2;
  --cta-end: #22d3ee;
  --float-text: #155e75;
  --overlay: rgba(21, 94, 117, 0.55);
  --border: rgba(6, 182, 212, 0.18);
  --shadow: 0 24px 70px rgba(8, 145, 178, 0.22);
  --theme-rgb: 6, 182, 212;
}

html[data-theme="salam"] {
  --bg: #ecfccb;
  --bg-mid: #f7fee7;
  --bg-end: #fcfff5;
  --glow: rgba(132, 204, 22, 0.32);
  --panel: #ffffff;
  --panel-soft: #ecfccb;
  --panel-grad: #f4fce8;
  --text: #3f6212;
  --muted: #5b6b4a;
  --primary: #65a30d;
  --primary-dark: #4d7c0f;
  --primary-deep: #3f6212;
  --accent: #84cc16;
  --lime: #a3e635;
  --banner-bg: #ecfccb;
  --banner-text: #3f6212;
  --chip-bg: #3f6212;
  --chip-text: #d9f99d;
  --cta-start: #4d7c0f;
  --cta-end: #a3e635;
  --float-text: #3f6212;
  --overlay: rgba(63, 98, 18, 0.55);
  --border: rgba(101, 163, 13, 0.18);
  --shadow: 0 24px 70px rgba(77, 124, 15, 0.2);
  --theme-rgb: 101, 163, 13;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 24px 12px;
  background:
    radial-gradient(circle at top, var(--glow), transparent 42%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-mid) 45%, var(--bg-end) 100%);
  color: var(--text);
  font-family: "Cairo", "Segoe UI", Tahoma, sans-serif;
  transition: background 0.7s ease, color 0.45s ease;
}

.disclosure-banner {
  margin: 0;
  padding: 10px 18px;
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  background: var(--banner-bg);
  color: var(--banner-text);
  font-size: 12px;
  line-height: 1.65;
  text-align: center;
  transition: background 0.45s ease, color 0.45s ease, border-color 0.45s ease;
}

.site-footer {
  margin: 0;
  padding: 16px 18px 20px;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

.site-footer p {
  margin: 0 0 8px;
}

.site-footer nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.site-footer a {
  color: var(--primary-deep);
  text-decoration: none;
  font-weight: 700;
}

.site-footer a:hover {
  text-decoration: underline;
}

.legal-page {
  width: min(100%, 680px);
  margin: 0 auto;
  padding: 24px 20px 40px;
}

.legal-page h1 {
  margin-bottom: 8px;
  font-size: clamp(24px, 5vw, 32px);
}

.legal-page h2 {
  margin: 24px 0 8px;
  font-size: 18px;
}

.legal-page p,
.legal-page li {
  color: var(--muted);
  line-height: 1.8;
}

.updated {
  color: var(--muted);
  font-size: 14px;
}

.back-link {
  display: inline-block;
  margin-bottom: 20px;
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
}

.back-link:hover {
  text-decoration: underline;
}

.notice-body a {
  color: var(--primary-dark);
  font-weight: 700;
}

a,
button {
  font: inherit;
}

.phone-frame {
  width: min(100%, 430px);
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 34px;
  background: linear-gradient(180deg, #ffffff 0%, var(--panel-grad) 100%);
  box-shadow: var(--shadow);
  margin-bottom: 88px;
  transition: border-color 0.45s ease, box-shadow 0.45s ease, background 0.45s ease;
}

.hero {
  position: relative;
  padding: 26px 22px 20px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

.hero::before {
  content: "";
  position: absolute;
  inset: -120px 40px auto;
  height: 240px;
  border-radius: 999px;
  background: var(--glow);
  filter: blur(48px);
  pointer-events: none;
  transition: background 0.7s ease;
}

.top-badge {
  position: relative;
  width: fit-content;
  margin: 0 auto 18px;
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--primary-dark);
  background: rgba(var(--theme-rgb), 0.12);
  font-size: 13px;
  font-weight: 700;
  transition: all 0.45s ease;
}

.product-visual {
  position: relative;
  width: min(100%, 270px);
  margin: 0 auto 18px;
  padding: 18px 14px 42px;
  border-radius: 28px;
  background:
    radial-gradient(circle at 50% 30%, rgba(var(--theme-rgb), 0.35), transparent 55%),
    linear-gradient(160deg, var(--banner-bg), var(--panel-soft));
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
  perspective: 900px;
  transition: background 0.7s ease, border-color 0.45s ease;
}

.router-stage {
  width: 180px;
  height: 180px;
  margin: 0 auto;
  perspective: 1000px;
  animation: cubeIdle 5.5s ease-in-out infinite;
}

.router-cube {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.85s cubic-bezier(0.4, 0.2, 0.2, 1);
}

.cube-face {
  position: absolute;
  inset: 0;
  border-radius: 22px;
  overflow: hidden;
  background: #fff;
  border: 2px solid rgba(255, 255, 255, 0.85);
  box-shadow: 0 10px 28px rgba(var(--theme-rgb), 0.2);
  backface-visibility: hidden;
}

.cube-face img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 20px;
}

.face-front {
  transform: rotateY(0deg) translateZ(90px);
}

.face-right {
  transform: rotateY(90deg) translateZ(90px);
}

.face-back {
  transform: rotateY(180deg) translateZ(90px);
}

.face-left {
  transform: rotateY(-90deg) translateZ(90px);
}

.product-chip {
  position: absolute;
  left: 50%;
  bottom: 34px;
  transform: translateX(-50%);
  padding: 5px 14px;
  border-radius: 999px;
  background: var(--chip-bg);
  color: var(--chip-text);
  font-size: 12px;
  font-weight: 900;
  border: 1px solid rgba(var(--theme-rgb), 0.4);
  white-space: nowrap;
  z-index: 2;
  transition: background 0.45s ease, color 0.45s ease, border-color 0.45s ease;
}

.brand-dots {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 2;
}

.brand-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(var(--theme-rgb), 0.25);
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
}

.brand-dot.active {
  background: var(--primary);
  transform: scale(1.2);
}

@keyframes cubeIdle {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--primary);
  font-weight: 800;
  transition: color 0.45s ease;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 10px;
  font-size: clamp(28px, 7vw, 36px);
  line-height: 1.15;
  font-weight: 900;
  color: var(--primary-deep);
  transition: color 0.45s ease;
}

.lead,
.content-card p,
.info-box p,
.features p,
.notice-body p {
  color: var(--muted);
  line-height: 1.75;
}

.lead {
  max-width: 340px;
  margin: 0 auto 20px;
  font-size: 15px;
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 8px;
  border-radius: 22px;
  background: var(--panel-soft);
  border: 1px solid var(--border);
  transition: background 0.45s ease, border-color 0.45s ease;
}

.quick-actions button {
  border: 0;
  cursor: pointer;
  display: grid;
  gap: 3px;
  padding: 11px 8px;
  border-radius: 16px;
  color: var(--muted);
  background: transparent;
  font-weight: 800;
  transition: 0.2s ease;
}

.quick-actions button.active,
.quick-actions button:hover {
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.content-card,
.info-box,
.features,
.notice {
  margin: 16px;
}

.content-card,
.info-box,
.notice {
  border: 1px solid var(--border);
  border-radius: 24px;
  background: var(--panel);
  transition: border-color 0.45s ease;
}

.content-card {
  padding: 22px;
  text-align: center;
}

.content-card h2 {
  margin-bottom: 8px;
  font-size: 24px;
  color: var(--primary-deep);
  transition: color 0.45s ease;
}

.cta-group {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  padding: 12px 18px;
  border-radius: 18px;
  color: #fff;
  text-decoration: none;
  font-weight: 800;
  transition: background 0.45s ease, box-shadow 0.45s ease;
}

.cta strong {
  font-size: 14px;
  opacity: 0.9;
}

.cta.primary {
  background: linear-gradient(135deg, var(--cta-start), var(--primary));
}

.cta.whatsapp {
  background: linear-gradient(135deg, #128c7e, #25d366);
}

.cta.order {
  background: linear-gradient(135deg, var(--cta-start), var(--cta-end));
  box-shadow: 0 10px 28px rgba(var(--theme-rgb), 0.35);
}

.info-box {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px;
}

.info-box h2,
.features h3 {
  margin-bottom: 6px;
  font-size: 18px;
  color: var(--primary-deep);
  transition: color 0.45s ease;
}

.info-box p,
.features p {
  margin-bottom: 0;
  font-size: 14px;
}

.shield {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--lime));
  font-weight: 900;
  transition: background 0.45s ease;
}

.features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.features article {
  min-height: 148px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff, var(--panel-grad));
  transition: border-color 0.45s ease, background 0.45s ease;
}

.feature-icon {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin-bottom: 12px;
  border-radius: 14px;
  background: var(--panel-soft);
  transition: background 0.45s ease;
}

.notice {
  margin-bottom: 0;
}

.notice-toggle {
  width: 100%;
  border: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  color: var(--text);
  background: transparent;
  font-weight: 800;
}

.chevron {
  transition: transform 0.2s ease;
}

.notice.open .chevron {
  transform: rotate(180deg);
}

.notice-body {
  padding: 0 18px 18px;
}

.notice-body p {
  margin-bottom: 0;
  font-size: 13px;
}

.notice-body p + p {
  margin-top: 12px;
}

.float-actions {
  position: fixed;
  z-index: 1000;
  left: 16px;
  right: 16px;
  bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  pointer-events: none;
}

.float-btn {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #fff;
  box-shadow: 0 12px 28px rgba(var(--theme-rgb), 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.45s ease;
}

.float-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(var(--theme-rgb), 0.34);
}

.float-call,
.float-whatsapp {
  width: 56px;
  height: 56px;
  border-radius: 50%;
}

.float-call {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-deep));
}

.float-whatsapp {
  background: linear-gradient(135deg, #16a34a, #128c7e);
}

.float-order {
  min-height: 56px;
  padding: 0 22px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), var(--lime));
  font-weight: 900;
  font-size: 15px;
  white-space: nowrap;
  color: var(--float-text);
}

.float-btn svg {
  width: 26px;
  height: 26px;
}

.admin-gate {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  background: var(--overlay);
  padding: 16px;
}

.admin-gate.open {
  display: flex;
}

.admin-gate-card {
  width: min(100%, 360px);
  background: #fff;
  border-radius: 20px;
  padding: 22px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
  text-align: center;
}

.admin-gate-card h3 {
  margin: 0 0 8px;
  color: var(--primary-deep);
}

.admin-gate-card p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14px;
}

.admin-gate-card input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  font: inherit;
  margin-bottom: 12px;
  text-align: center;
}

.admin-gate-card .actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.admin-gate-card button {
  border: 0;
  border-radius: 12px;
  padding: 12px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.admin-gate-card .submit {
  background: var(--primary);
  color: #fff;
}

.admin-gate-card .cancel {
  background: var(--panel-soft);
  color: var(--primary-deep);
}

.admin-gate-error {
  color: #b91c1c !important;
  font-size: 13px !important;
  display: none;
}

.admin-gate-hint {
  margin-top: 12px !important;
}

.admin-gate-hint button {
  background: none;
  border: 0;
  color: var(--primary-dark);
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
  padding: 0;
}

@media (max-width: 380px) {
  body {
    padding: 0;
  }

  .phone-frame {
    min-height: 100vh;
    border-radius: 0;
    margin-bottom: 88px;
  }

  .features {
    grid-template-columns: 1fr;
  }

  .float-actions {
    left: 12px;
    right: 12px;
    bottom: 14px;
  }

  .float-order {
    padding: 0 16px;
    font-size: 14px;
  }
}
