/* =========================================================
   منصّة+ | Premium Educational Landing Page — Complete
   ========================================================= */

:root {
  --primary: #2563eb;
  --secondary: #7c3aed;
  --accent: #06b6d4;
  --bg: #eef3ff;
  --dark: #0f172a;

  --primary-rgb: 37, 99, 235;
  --secondary-rgb: 124, 58, 237;
  --accent-rgb: 6, 182, 212;

  --surface: #ffffff;
  --surface-rgb: 255, 255, 255;
  --text-main: #0f172a;
  --text-soft: #334155;
  --text-faint: #64748b;
  --border-soft: rgba(37, 99, 235, 0.1);

  --glass-bg: rgba(255, 255, 255, 0.72);
  --glass-border: rgba(37, 99, 235, 0.15);
  --glass-blur: 20px;

  --surface-alt: rgba(37, 99, 235, 0.04);
  --code-bg: #1e1e2e;
  --code-kw: #569cd6;
  --code-fn: #dcdcaa;
  --code-str: #ce9178;
  --code-var: #9cdcfe;

  --nav-h: 78px;
  --gradient-brand: linear-gradient(
    135deg,
    var(--primary) 0%,
    var(--secondary) 55%,
    var(--accent) 100%
  );
  --gradient-brand-rgb: var(--primary-rgb);
  --gradient-soft: linear-gradient(
    135deg,
    rgba(37, 99, 235, 0.12),
    rgba(124, 58, 237, 0.12)
  );

  --shadow-soft: 0 20px 60px -20px rgba(37, 99, 235, 0.18);
  --shadow-strong: 0 30px 80px -25px rgba(37, 99, 235, 0.35);

  --ease: cubic-bezier(0.16, 0.84, 0.44, 1);
  --font-display: "Cairo", sans-serif;
  --font-body: "IBM Plex Sans Arabic", sans-serif;
}

[data-theme="dark"] {
  --bg: #0b1220;
  --surface: #121b2e;
  --surface-rgb: 18, 27, 46;
  --text-main: #f1f5f9;
  --text-soft: #b8c2d6;
  --text-faint: #64748b;
  --border-soft: rgba(255, 255, 255, 0.08);
  --glass-bg: rgba(18, 27, 46, 0.55);
  --glass-border: rgba(255, 255, 255, 0.08);
  --shadow-soft: 0 20px 60px -20px rgba(0, 0, 0, 0.55);
  --shadow-strong: 0 30px 90px -25px rgba(6, 182, 212, 0.25);
  --surface-alt: rgba(0, 0, 0, 0.15);
  --code-bg: #0d1117;
}

/* Light mode backgrounds configuration */
:root {
  --hero-bg: linear-gradient(160deg, #eef3ff 0%, #f0eaff 45%, #e8f9ff 100%);
  --features-bg: linear-gradient(180deg, #e9f0ff 0%, #ede8ff 60%, #e6f8ff 100%);
  --courses-bg: linear-gradient(180deg, #ebe6ff 0%, #e4f0ff 50%, #e2fbf9 100%);
  --testimonials-bg: linear-gradient(
    180deg,
    #dff5fb 0%,
    #e4eaff 55%,
    #ede8ff 100%
  );
  --contact-bg: linear-gradient(180deg, #eae6ff 0%, #e9f1ff 55%, #f0f8ff 100%);
}

:root body {
  background: var(--hero-bg);
}
:root .features-section {
  background: var(--features-bg);
}
:root .courses-section {
  background: var(--courses-bg);
}
:root .testimonials-section {
  background: var(--testimonials-bg);
}
:root .contact-section {
  background: var(--contact-bg);
}

/* Dark mode section backgrounds mapping */
[data-theme="dark"] body {
  background: var(--bg);
}
[data-theme="dark"] .features-section {
  background: linear-gradient(
    180deg,
    rgba(37, 99, 235, 0.06) 0%,
    rgba(124, 58, 237, 0.06) 100%
  );
}
[data-theme="dark"] .testimonials-section {
  background: linear-gradient(
    180deg,
    rgba(6, 182, 212, 0.06) 0%,
    rgba(37, 99, 235, 0.05) 100%
  );
}
[data-theme="dark"] .contact-section {
  background: linear-gradient(
    180deg,
    rgba(124, 58, 237, 0.05) 0%,
    rgba(37, 99, 235, 0.07) 100%
  );
}

* {
  box-sizing: border-box;
}
::selection {
  background: rgba(var(--primary-rgb), 0.25);
  color: var(--text-main);
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text-main);
  font-family: var(--font-body);
  overflow-x: hidden;
  transition:
    background 0.5s var(--ease),
    color 0.5s var(--ease);
  position: relative;
}
h1,
h2,
h3,
h4,
.font-display {
  font-family: var(--font-display);
  margin: 0;
}
p {
  margin: 0;
}
a {
  text-decoration: none;
  color: inherit;
}
ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
button {
  font-family: inherit;
  border: none;
  background: none;
  cursor: pointer;
}
svg {
  display: block;
}

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 48px);
  position: relative;
}

.grad-text {
  font-style: normal;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur)) saturate(160%);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(160%);
  border: 1px solid var(--glass-border);
}

/* =========================================================
   Scroll progress bar
   ========================================================= */
.scroll-progress {
  position: fixed;
  inset-inline: 0;
  top: 0;
  height: 3px;
  width: 100%;
  z-index: 1200;
  background: transparent;
}
.scroll-progress span {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--gradient-brand);
  box-shadow: 0 0 12px rgba(var(--primary-rgb), 0.6);
  transition: width 0.05s linear;
}

.cursor-glow {
  position: fixed;
  top: 0;
  left: 0;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 2;
  background: radial-gradient(
    circle,
    rgba(var(--primary-rgb), 0.1),
    transparent 70%
  );
  transform: translate(-50%, -50%);
  transition: opacity 0.3s ease;
  opacity: 0;
}
@media (hover: hover) and (pointer: fine) {
  .cursor-glow.active {
    opacity: 1;
  }
}

/* =========================================================
   Ambient background
   ========================================================= */
.ambient-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}
.mesh-gradient {
  position: absolute;
  inset: -10%;
  background:
    radial-gradient(
      circle at 15% 20%,
      rgba(var(--primary-rgb), 0.18),
      transparent 45%
    ),
    radial-gradient(
      circle at 85% 15%,
      rgba(var(--secondary-rgb), 0.16),
      transparent 45%
    ),
    radial-gradient(
      circle at 75% 80%,
      rgba(var(--accent-rgb), 0.14),
      transparent 45%
    );
  filter: blur(10px);
}
[data-theme="dark"] .mesh-gradient {
  background:
    radial-gradient(
      circle at 15% 20%,
      rgba(var(--primary-rgb), 0.14),
      transparent 45%
    ),
    radial-gradient(
      circle at 85% 15%,
      rgba(var(--secondary-rgb), 0.14),
      transparent 45%
    ),
    radial-gradient(
      circle at 75% 80%,
      rgba(var(--accent-rgb), 0.12),
      transparent 45%
    );
}
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.5;
  will-change: transform;
  contain: strict;
}
.blob-a {
  width: 480px;
  height: 480px;
  top: -120px;
  left: -140px;
  background: radial-gradient(
    circle,
    rgba(var(--primary-rgb), 0.35),
    transparent 70%
  );
}
.blob-b {
  width: 520px;
  height: 520px;
  top: 10%;
  right: -180px;
  background: radial-gradient(
    circle,
    rgba(var(--secondary-rgb), 0.32),
    transparent 70%
  );
}
.blob-c {
  width: 420px;
  height: 420px;
  bottom: -160px;
  left: 30%;
  background: radial-gradient(
    circle,
    rgba(var(--accent-rgb), 0.28),
    transparent 70%
  );
}
.geo-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image:
    repeating-linear-gradient(
      60deg,
      rgba(var(--primary-rgb), 0.05) 0 1px,
      transparent 1px 90px
    ),
    repeating-linear-gradient(
      -60deg,
      rgba(var(--secondary-rgb), 0.05) 0 1px,
      transparent 1px 90px
    );
  mask-image: radial-gradient(ellipse at 50% 0%, black, transparent 70%);
}
.particles {
  position: absolute;
  inset: 0;
}
.particle {
  position: absolute;
  border-radius: 50%;
  background: rgba(var(--accent-rgb), 0.5);
}

/* =========================================================
   Floating Navbar
   ========================================================= */
.floating-nav-wrap {
  position: fixed;
  top: 20px;
  inset-inline: 0;
  display: flex;
  justify-content: center;
  z-index: 1000;
  padding: 0 16px;
}
.floating-nav {
  width: min(1160px, 100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px 10px 10px;
  border-radius: 999px;
  background: rgba(var(--surface-rgb), 0.55);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-soft);
  transition:
    background 0.4s var(--ease),
    box-shadow 0.4s var(--ease),
    padding 0.4s var(--ease);
}
.floating-nav.scrolled {
  padding-block: 7px;
  background: rgba(var(--surface-rgb), 0.85);
  box-shadow: 0 15px 45px -15px rgba(15, 23, 42, 0.25);
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-inline-start: 6px;
  flex-shrink: 0;
}
.logo-mark {
  width: 36px;
  height: 36px;
  display: block;
}
.logo-mark svg {
  width: 100%;
  height: 100%;
}
.logo-text {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--text-main);
  letter-spacing: -0.02em;
}
.logo-text em {
  font-style: normal;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-link {
  position: relative;
  padding: 10px 14px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-soft);
  border-radius: 999px;
  transition: color 0.3s ease;
  white-space: nowrap;
}
.nav-link::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: rgba(var(--primary-rgb), 0.08);
  opacity: 0;
  transform: scale(0.85);
  transition:
    opacity 0.3s var(--ease),
    transform 0.3s var(--ease);
  z-index: -1;
}
.nav-link:hover {
  color: var(--primary);
}
.nav-link:hover::before {
  opacity: 1;
  transform: scale(1);
}
.nav-link.active {
  color: var(--primary);
}
.nav-link.active::before {
  opacity: 1;
  transform: scale(1);
  background: rgba(var(--primary-rgb), 0.12);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.theme-toggle {
  display: flex;
  align-items: center;
}
.toggle-track {
  width: 52px;
  height: 28px;
  border-radius: 999px;
  background: rgba(var(--primary-rgb), 0.12);
  display: flex;
  align-items: center;
  padding: 3px;
  position: relative;
  transition: background 0.3s ease;
}
.toggle-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--gradient-brand);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transform: translateX(0);
  transition: transform 0.4s var(--ease);
  position: relative;
}
[data-theme="dark"] .toggle-thumb {
  transform: translateX(-24px);
}
.toggle-thumb svg {
  width: 14px;
  height: 14px;
  position: absolute;
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
}
.icon-moon {
  opacity: 0;
  transform: rotate(-40deg) scale(0.6);
}
.icon-sun {
  opacity: 1;
  transform: rotate(0) scale(1);
}
[data-theme="dark"] .icon-sun {
  opacity: 0;
  transform: rotate(40deg) scale(0.6);
}
[data-theme="dark"] .icon-moon {
  opacity: 1;
  transform: rotate(0) scale(1);
}

.btn-nav-login {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text-main);
  border: 1.5px solid var(--border-soft);
  background: rgba(var(--surface-rgb), 0.4);
  transition:
    border-color 0.3s ease,
    color 0.3s ease,
    background 0.3s ease,
    transform 0.3s var(--ease);
  white-space: nowrap;
}
.btn-nav-login:hover {
  border-color: rgba(var(--primary-rgb), 0.5);
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.06);
  transform: translateY(-2px);
}
.btn-nav-signup {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.88rem;
  color: #fff;
  background: var(--gradient-brand);
  background-size: 180% 180%;
  box-shadow: 0 8px 24px -6px rgba(var(--primary-rgb), 0.45);
  transition:
    box-shadow 0.35s ease,
    background-position 0.6s ease,
    transform 0.3s var(--ease);
  white-space: nowrap;
}
.btn-nav-signup:hover {
  box-shadow: 0 12px 32px -6px rgba(var(--secondary-rgb), 0.55);
  background-position: 100% 100%;
  transform: translateY(-2px);
}

.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
}
.nav-burger span {
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--text-main);
  transition:
    transform 0.35s var(--ease),
    opacity 0.3s ease;
}
.nav-burger.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-burger.active span:nth-child(2) {
  opacity: 0;
}
.nav-burger.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  background: rgba(var(--surface-rgb), 0.97);
  backdrop-filter: blur(30px);
  transform: translateY(-100%);
  opacity: 0;
  visibility: hidden;
  transition:
    transform 0.5s var(--ease),
    opacity 0.5s var(--ease),
    visibility 0.5s;
}
.mobile-menu.open {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
}
.mobile-menu ul {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
}
.mobile-menu a {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
}
.mobile-menu-btns {
  display: flex;
  gap: 12px;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 260px;
}
.mobile-menu-btns .btn-nav-login,
.mobile-menu-btns .btn-nav-signup {
  width: 100%;
  text-align: center;
  font-size: 1rem;
  padding: 14px 24px;
}

/* =========================================================
   CTA Buttons
   ========================================================= */
.btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 22px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.9rem;
  color: #fff;
  background: var(--gradient-brand);
  background-size: 180% 180%;
  box-shadow: 0 12px 30px -8px rgba(var(--primary-rgb), 0.55);
  transition:
    box-shadow 0.35s ease,
    background-position 0.6s ease,
    transform 0.3s var(--ease);
}
.btn-cta:hover {
  box-shadow: 0 16px 38px -8px rgba(var(--secondary-rgb), 0.55);
  background-position: 100% 100%;
}
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  border-radius: 999px;
  background: var(--gradient-brand);
  color: #fff;
  font-weight: 700;
  font-size: 0.98rem;
  box-shadow: var(--shadow-strong);
  transition:
    transform 0.35s var(--ease),
    box-shadow 0.35s ease;
}
.btn-primary svg {
  width: 18px;
  height: 18px;
  transition: transform 0.3s var(--ease);
}
.btn-primary:hover {
  transform: translateY(-3px);
}
.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 26px 14px 14px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--text-main);
  border: 1px solid var(--border-soft);
  background: rgba(var(--surface-rgb), 0.5);
  transition:
    border-color 0.3s ease,
    transform 0.35s var(--ease);
}
.btn-ghost:hover {
  transform: translateY(-3px);
  border-color: rgba(var(--primary-rgb), 0.4);
}
.play-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-brand);
  color: #fff;
  flex-shrink: 0;
}
.play-circle svg {
  width: 15px;
  height: 15px;
}
.magnetic {
  position: relative;
}
.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  transform: scale(0);
  animation: rippleAnim 0.6s ease-out forwards;
  pointer-events: none;
  overflow: hidden;
}
[data-theme="dark"] .ripple {
  background: rgba(255, 255, 255, 0.25);
}
@keyframes rippleAnim {
  to {
    transform: scale(3);
    opacity: 0;
  }
}

/* =========================================================
   Hero Section
   ========================================================= */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: calc(var(--nav-h) + 40px);
  padding-bottom: 40px;
  z-index: 1;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: clamp(30px, 5vw, 80px);
  align-items: center;
}
.hero-content {
  position: relative;
  z-index: 2;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.08);
  border: 1px solid rgba(var(--primary-rgb), 0.15);
  margin-bottom: 22px;
}
.eyebrow-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gradient-brand);
  box-shadow: 0 0 0 4px rgba(var(--primary-rgb), 0.15);
}
.hero-title {
  font-size: clamp(2.3rem, 4.6vw, 3.9rem);
  font-weight: 800;
  line-height: 1.28;
  letter-spacing: -0.01em;
  margin-bottom: 26px;
  color: var(--text-main);
}
.hero-title .line {
  display: block;
  overflow: hidden;
}
.hero-title .reveal-line {
  display: inline-block;
  will-change: transform;
}
.hero-desc {
  font-size: clamp(1rem, 1.1vw, 1.15rem);
  line-height: 1.9;
  color: var(--text-soft);
  max-width: 560px;
  margin-bottom: 36px;
  font-weight: 400;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  margin-bottom: 52px;
}
.hero-stats {
  display: flex;
  align-items: center;
  gap: 26px;
  padding-top: 36px;
  border-top: 1px solid var(--border-soft);
  max-width: 560px;
}
.stat-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat-num {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2vw, 1.9rem);
  font-weight: 800;
  color: var(--text-main);
}
.stat-label {
  font-size: 0.82rem;
  color: var(--text-faint);
  font-weight: 500;
}
.stat-divider {
  width: 1px;
  height: 34px;
  background: var(--border-soft);
}

/* =========================================================
   Hero Visual
   ========================================================= */
.hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 540px;
  opacity: 0;
}
.visual-stage {
  position: relative;
  width: 100%;
  max-width: 520px;
  aspect-ratio: 1/1;
  --card-px: 0px;
  --card-py: 0px;
  --badge-px: 0px;
  --badge-py: 0px;
}
.emblem {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.emblem-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  will-change: transform;
}

/* =========================================================
   Teacher Photo
   ========================================================= */
.teacher-photo-wrap {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.teacher-photo {
  width: 65%;
  aspect-ratio: 3/4;
  border-radius: 32px;
  overflow: hidden;
  box-shadow:
    var(--shadow-strong),
    0 0 0 4px rgba(37, 99, 235, 0.15);
  position: relative;
  background: var(--gradient-soft);
  transition: transform 0.4s var(--ease);
  will-change: transform;
  z-index: 2;
}
.teacher-photo:hover {
  transform: translateY(-6px) scale(1.01);
}

.teacher-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}
.teacher-photo-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--primary);
  opacity: 0.5;
  text-align: center;
  padding: 20px;
}
.teacher-photo-placeholder span {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-faint);
  font-family: var(--font-body);
}

/* Code card — FIXED: visibility configuration prevents layout painting shifts before timeline start */
.code-card {
  position: absolute;
  bottom: 8%;
  left: 0%;
  border-radius: 16px;
  padding: 0;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  min-width: 170px;
  max-width: 205px;
  will-change: transform;
  animation: floatY 4s ease-in-out infinite;
  animation-play-state: paused;
  opacity: 0;
  visibility: hidden; /* Added to resolve the structural paint shift gap */
  z-index: 4;
}
.code-card.float-active {
  animation-play-state: running;
}
@keyframes floatY {
  0%,
  100% {
    transform: translate3d(
      var(--card-px, 0px),
      calc(0px + var(--card-py, 0px)),
      0
    );
  }
  50% {
    transform: translate3d(
      var(--card-px, 0px),
      calc(-10px + var(--card-py, 0px)),
      0
    );
  }
}
.code-card-header {
  background: #2d2d3f;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.code-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.code-dot.red {
  background: #ff5f57;
}
.code-dot.yellow {
  background: #febc2e;
}
.code-dot.green {
  background: #28c840;
}
.code-filename {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.5);
  margin-right: auto;
  font-family: "Courier New", monospace;
  font-weight: 500;
}
/* =========================================================
   Code Card Body — FIXED: Set dimensions to prevent vertical stretching
   ========================================================= */
.code-body {
  background: var(--code-bg, #1e1e2e); /* From source[cite: 2] */
  padding: 12px 16px; /* From source[cite: 2] */
  display: flex; /* From source[cite: 2] */
  flex-direction: column; /* From source[cite: 2] */
  gap: 4px; /* From source[cite: 2] */

  /* FIX: Force a structural height ceiling to prevent the typing script from stretching the container */
  height: 140px;
  max-height: 140px;

  /* FIX: Enable automatic scroll containment for injected typing elements */
  overflow-y: auto;
  overflow-x: hidden;

  /* Smooth scrolling internal behavior */
  scroll-behavior: smooth;
}
.code-line {
  display: block;
  font-family: "Courier New", Courier, monospace;
  font-size: 0.76rem;
  line-height: 1.6;
  color: #abb2bf;
  white-space: pre;
  direction: ltr;
  text-align: left;
}
.ck-kw {
  color: #c678dd;
  font-weight: 600;
}
.ck-fn {
  color: #61afef;
}
.ck-str {
  color: #98c379;
}
.ck-var {
  color: #e06c75;
}
.code-cursor {
  display: inline-block;
  color: #61afef;
  font-family: "Courier New", monospace;
  font-size: 0.76rem;
  animation: blink 1.1s step-end infinite;
}
@keyframes blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0;
  }
}

/* Students badge — FIXED: alignment configuration matching visibility rules setup */
.students-badge {
  position: absolute;
  top: 6%;
  right: 0%;
  border-radius: 20px;
  padding: 14px 20px;
  text-align: center;
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  gap: 4px;
  will-change: transform;
  animation: floatY2 3.8s ease-in-out infinite;
  animation-play-state: paused;
  opacity: 0;
  visibility: hidden; /* Added to mirror code-card flash protection */
  z-index: 3;
}
.students-badge.float-active {
  animation-play-state: running;
}
@keyframes floatY2 {
  0%,
  100% {
    transform: translate3d(
      var(--badge-px, 0px),
      calc(0px + var(--badge-py, 0px)),
      0
    );
  }
  50% {
    transform: translate3d(
      var(--badge-px, 0px),
      calc(-8px + var(--badge-py, 0px)),
      0
    );
  }
}
.students-num {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 900;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.1;
}
.students-label {
  font-size: 0.75rem;
  color: var(--text-faint);
  font-weight: 600;
  white-space: nowrap;
}
.pulse-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.2);
  align-self: center;
}

.scroll-hint {
  position: absolute;
  bottom: 26px;
  inset-inline: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-faint);
  font-size: 0.78rem;
  font-weight: 600;
  z-index: 2;
}
.scroll-hint-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(var(--text-faint), transparent);
  position: relative;
  overflow: hidden;
}
.scroll-hint-line::after {
  content: "";
  position: absolute;
  top: -40px;
  right: 0;
  width: 100%;
  height: 40px;
  background: linear-gradient(var(--primary), transparent);
  animation: scrollLine 2.2s ease-in-out infinite;
}
@keyframes scrollLine {
  0% {
    top: -40px;
  }
  100% {
    top: 40px;
  }
}

/* =========================================================
   Section shared
   ========================================================= */
.section-header {
  text-align: center;
  margin-bottom: clamp(32px, 4vw, 56px);
}
.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.08);
  border: 1px solid rgba(var(--primary-rgb), 0.15);
  margin-bottom: 20px;
}
.section-title {
  font-size: clamp(1.9rem, 3.8vw, 3.2rem);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--text-main);
  margin-bottom: 16px;
}
.section-desc {
  font-size: clamp(0.97rem, 1.1vw, 1.1rem);
  color: var(--text-soft);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.8;
}

/* =========================================================
   Features Section — Bento Grid
   ========================================================= */
.features-section {
  position: relative;
  z-index: 1;
  padding: clamp(50px, 6vw, 90px) 0;
}
.feat-bento {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.feat-card--wide {
  grid-column: 1 / -1;
}
.feat-card {
  border-radius: 28px;
  padding: clamp(24px, 3vw, 36px);
  display: flex;
  flex-direction: row;
  gap: 24px;
  align-items: flex-start;
  border: 1px solid var(--glass-border);
  transition:
    transform 0.35s var(--ease),
    box-shadow 0.35s ease;
  position: relative;
  overflow: hidden;
}
.feat-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: var(--gradient-brand);
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 0;
}
.feat-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-strong);
}
.feat-card:hover::before {
  opacity: 0.03;
}
.feat-card--wide {
  align-items: center;
}
.feat-card--wide .feat-card-body {
  flex: 1;
}
.feat-card--accent {
  background:
    linear-gradient(
      135deg,
      rgba(124, 58, 237, 0.06) 0%,
      rgba(var(--glass-bg)) 100%
    ),
    var(--glass-bg);
}
.feat-card-icon-wrap {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  border: 1px solid rgba(var(--primary-rgb), 0.1);
}
.feat-card--wide .feat-card-icon-wrap {
  width: 88px;
  height: 88px;
  border-radius: 24px;
}
.feat-card-body {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.feat-card-num {
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--primary);
  letter-spacing: 0.05em;
  opacity: 0.6;
}
.feat-card-title {
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 1.8vw, 1.4rem);
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.3;
  margin: 0;
}
.feat-card--wide .feat-card-title {
  font-size: clamp(1.25rem, 2vw, 1.65rem);
}
.feat-card-desc {
  font-size: clamp(0.88rem, 1vw, 0.97rem);
  color: var(--text-soft);
  line-height: 1.75;
  margin: 0;
}
.feat-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.feat-card-tags span {
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.08);
  border: 1px solid rgba(var(--primary-rgb), 0.15);
}

@media (max-width: 640px) {
  .feat-bento {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .feat-card--wide {
    grid-column: auto;
  }
  .feat-card {
    flex-direction: column;
    gap: 16px;
  }
  .feat-card-icon-wrap,
  .feat-card--wide .feat-card-icon-wrap {
    width: 60px;
    height: 60px;
    border-radius: 16px;
  }
}

/* =========================================================
   Interactive Video Section — Luxury Architecture Block
   ========================================================= */
.video-section {
  position: relative;
  z-index: 1;
}
.custom-video-frame {
  border: 1px solid var(--glass-border);
  transition:
    transform 0.4s var(--ease),
    box-shadow 0.4s ease;
}
.custom-video-frame:hover {
  transform: translateY(-4px);
  box-shadow: 0 40px 90px -15px rgba(var(--primary-rgb), 0.3) !important;
}

/* =========================================================
   Courses Section — Swiper
   ========================================================= */
.courses-section {
  position: relative;
  z-index: 1;
  padding: clamp(50px, 6vw, 90px) 0;
}
[data-theme="dark"] .courses-section {
  background: rgba(0, 0, 0, 0.15);
}
:root .course-card {
  border-top: 3px solid transparent;
  border-image: var(--gradient-brand) 1;
}
.courses-swiper {
  position: relative;
  padding-bottom: 60px !important;
}
.courses-nav {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 24px;
}
.course-card {
  border-radius: 28px;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  position: relative;
  transition:
    transform 0.4s var(--ease),
    box-shadow 0.4s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.course-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 40px 80px -20px rgba(var(--primary-rgb), 0.22);
}
.course-featured-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 10;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 800;
  background: var(--gradient-brand);
  color: #fff;
  box-shadow: 0 6px 20px -4px rgba(var(--primary-rgb), 0.5);
}
/* .course-img-wrap {
  position: relative;
  overflow: hidden;
}
.course-img img {
  object-fit: contain;
} */
/* .course-img {
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  transition: transform 0.5s var(--ease);
} */
.course-card:hover .course-img {
  transform: scale(1.04);
}
.course-bg-icon {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.6;
}
.course-level-badge {
  position: absolute;
  bottom: 12px;
  left: 12px;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(8px);
}
.level-mid {
  background: rgba(6, 182, 212, 0.25);
  border-color: rgba(6, 182, 212, 0.4);
}
.level-adv {
  background: rgba(190, 24, 93, 0.25);
  border-color: rgba(190, 24, 93, 0.4);
}
.course-img-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.35s ease;
  backdrop-filter: blur(4px);
}
.course-card:hover .course-img-overlay {
  opacity: 1;
}
.course-preview-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  font-weight: 600;
  font-size: 0.85rem;
  backdrop-filter: blur(8px);
  transition: background 0.25s ease;
}
.course-preview-btn:hover {
  background: rgba(255, 255, 255, 0.28);
}
.course-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}
.course-meta-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.course-subject {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--primary);
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(var(--primary-rgb), 0.08);
  border: 1px solid rgba(var(--primary-rgb), 0.15);
}
.course-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.82rem;
}
.stars {
  color: #f59e0b;
  letter-spacing: -1px;
}
.course-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.35;
}
.course-desc {
  font-size: 0.88rem;
  color: var(--text-soft);
  line-height: 1.7;
  flex: 1;
}
.course-stats {
  display: flex;
  gap: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--border-soft);
}
.course-stats span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: var(--text-faint);
  font-weight: 600;
}
.course-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px solid var(--border-soft);
  margin-top: auto;
}
.course-price {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.price-old {
  font-size: 0.78rem;
  color: var(--text-faint);
  text-decoration: line-through;
}
.price-new {
  font-size: 1.1rem;
  font-weight: 800;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.course-cta {
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--gradient-brand);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  box-shadow: 0 8px 20px -6px rgba(var(--primary-rgb), 0.45);
  transition:
    transform 0.3s var(--ease),
    box-shadow 0.3s ease;
}
.course-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px -6px rgba(var(--secondary-rgb), 0.5);
}

.swiper-button-custom {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  color: var(--text-main);
  backdrop-filter: blur(12px);
  transition:
    background 0.3s ease,
    color 0.3s ease,
    transform 0.3s var(--ease);
}
.swiper-button-custom:hover {
  background: var(--gradient-brand);
  color: #fff;
  transform: scale(1.08);
  border-color: transparent;
}

/* =========================================================
   Testimonials Section
   ========================================================= */
.testimonials-section {
  position: relative;
  z-index: 1;
  padding: clamp(50px, 6vw, 90px) 0;
  overflow: hidden;
}
.testimonials-bg-shape {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(
      ellipse at 0% 50%,
      rgba(var(--secondary-rgb), 0.08),
      transparent 60%
    ),
    radial-gradient(
      ellipse at 100% 50%,
      rgba(var(--accent-rgb), 0.08),
      transparent 60%
    );
  pointer-events: none;
}
.testimonials-swiper {
  position: relative;
  z-index: 1;
  padding-bottom: 60px !important;
}
.testi-card {
  border-radius: 28px;
  padding: clamp(24px, 3vw, 40px);
  position: relative;
  transition:
    transform 0.4s var(--ease),
    box-shadow 0.4s ease;
  height: 100%;
  box-sizing: border-box;
}
.testi-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-strong);
}
.testi-quote-icon {
  font-size: 4rem;
  line-height: 1;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 8px;
  display: block;
  opacity: 0.6;
  font-family: Georgia, serif;
}
.testi-stars {
  color: #f59e0b;
  font-size: 1.1rem;
  letter-spacing: 2px;
  margin-bottom: 16px;
}
.testi-text {
  font-size: clamp(0.95rem, 1.05vw, 1.05rem);
  line-height: 1.9;
  color: var(--text-soft);
  margin-bottom: 28px;
  flex: 1;
}
.testi-author {
  display: flex;
  align-items: center;
  gap: 14px;
}
.testi-avatar {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.1rem;
  color: #fff;
}
.testi-author strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
}
.testi-author span {
  display: block;
  font-size: 0.78rem;
  color: var(--text-faint);
  margin-top: 2px;
}
.testi-nav {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 32px;
}
.testi-pagination .swiper-pagination-bullet,
.courses-pagination .swiper-pagination-bullet {
  width: 8px;
  height: 8px;
  background: var(--text-faint);
  opacity: 1;
  transition:
    width 0.3s ease,
    background 0.3s ease;
  border-radius: 999px;
}
.testi-pagination .swiper-pagination-bullet-active,
.courses-pagination .swiper-pagination-bullet-active {
  width: 28px;
  background: var(--gradient-brand);
}

/* =========================================================
   Contact Section — with Teacher Profile Card
   ========================================================= */
.contact-section {
  position: relative;
  z-index: 1;
  padding: clamp(50px, 6vw, 90px) 0;
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
}
.teacher-profile-card {
  border-radius: 28px;
  padding: 28px;
  margin-bottom: 32px;
  display: flex;
  gap: 22px;
  align-items: flex-start;
  box-shadow: var(--shadow-soft);
  transition:
    transform 0.3s var(--ease),
    box-shadow 0.3s ease;
}
.teacher-profile-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-strong);
}
.teacher-profile-img-wrap {
  position: relative;
  flex-shrink: 0;
}
.teacher-profile-img {
  width: 100px;
  height: 120px;
  border-radius: 20px;
  overflow: hidden;
  background: var(--gradient-soft);
  border: 2px solid rgba(var(--primary-rgb), 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}
.teacher-profile-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.teacher-profile-placeholder {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: var(--primary);
  opacity: 0.6;
}
.teacher-profile-badge {
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  background: #22c55e;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  gap: 5px;
  box-shadow: 0 4px 12px -2px rgba(34, 197, 94, 0.45);
}
.online-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fff;
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.6;
    transform: scale(1.3);
  }
}
.teacher-profile-info {
  flex: 1;
  min-width: 0;
}
.teacher-profile-name {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 6px;
  line-height: 1.3;
}
.teacher-profile-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 14px;
}
.teacher-profile-stats {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  padding: 10px 14px;
  border-radius: 14px;
  background: rgba(var(--primary-rgb), 0.05);
  border: 1px solid rgba(var(--primary-rgb), 0.08);
}
.tps-item {
  text-align: center;
  flex: 1;
}
.tps-item strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 800;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.tps-item span {
  font-size: 0.7rem;
  color: var(--text-faint);
  font-weight: 600;
}
.tps-divider {
  width: 1px;
  height: 28px;
  background: var(--border-soft);
}
.teacher-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.teacher-skills span {
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.08);
  border: 1px solid rgba(var(--primary-rgb), 0.15);
  font-family: "Courier New", monospace;
}

.contact-info-title {
  font-size: clamp(1.4rem, 2vw, 1.8rem);
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 12px;
}
.contact-info-desc {
  font-size: 0.97rem;
  color: var(--text-soft);
  line-height: 1.8;
  margin-bottom: 28px;
}
.contact-cards {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 32px;
}
.contact-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 22px;
  border-radius: 18px;
  transition:
    transform 0.3s var(--ease),
    box-shadow 0.3s ease;
}
.contact-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-soft);
}
.contact-card-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(var(--primary-rgb), 0.1);
  color: var(--primary);
}
.contact-card-label {
  display: block;
  font-size: 0.76rem;
  color: var(--text-faint);
  font-weight: 600;
  margin-bottom: 4px;
}
.contact-card-val {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
}
.social-links {
  display: flex;
  align-items: center;
  gap: 14px;
}
.social-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-faint);
}
.social-icons {
  display: flex;
  gap: 10px;
}
.social-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-soft);
  transition:
    color 0.3s ease,
    transform 0.3s var(--ease),
    background 0.3s ease;
}
.social-icon:hover {
  color: var(--primary);
  transform: translateY(-3px);
  background: rgba(var(--primary-rgb), 0.12);
}

.contact-form-wrap {
  border-radius: 32px;
  padding: clamp(28px, 4vw, 48px);
  box-shadow: var(--shadow-soft);
}
.form-title {
  font-size: clamp(1.3rem, 1.8vw, 1.6rem);
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 28px;
}
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.form-group {
  position: relative;
}
.form-input {
  width: 100%;
  padding: 18px 20px 10px;
  border-radius: 16px;
  background: rgba(var(--primary-rgb), 0.04);
  border: 1.5px solid var(--border-soft);
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 0.97rem;
  outline: none;
  transition:
    border-color 0.3s ease,
    background 0.3s ease,
    box-shadow 0.3s ease;
  display: block;
  resize: none;
  appearance: none;
  -webkit-appearance: none;
}
.form-input:focus {
  border-color: rgba(var(--primary-rgb), 0.5);
  background: rgba(var(--primary-rgb), 0.06);
  box-shadow: 0 0 0 4px rgba(var(--primary-rgb), 0.1);
}
.form-label {
  position: absolute;
  right: 20px;
  top: 18px;
  font-size: 0.92rem;
  color: var(--text-faint);
  font-weight: 600;
  pointer-events: none;
  transition:
    top 0.25s ease,
    font-size 0.25s ease,
    color 0.25s ease;
  transform-origin: right;
}
.form-input:focus ~ .form-label,
.form-input:not(:placeholder-shown) ~ .form-label {
  top: 6px;
  font-size: 0.72rem;
  color: var(--primary);
}
.form-select {
  padding-top: 20px;
}
.form-textarea {
  min-height: 120px;
  padding-top: 20px;
}
.form-submit {
  align-self: flex-start;
  gap: 12px;
}
.form-submit svg {
  transform: none !important;
}

/* =========================================================
   Footer
   ========================================================= */
.site-footer {
  position: relative;
  z-index: 1;
  padding: clamp(40px, 5vw, 70px) 0 0;
  border-top: 1px solid var(--border-soft);
  overflow: hidden;
}
.footer-glow {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(
    ellipse,
    rgba(var(--primary-rgb), 0.08),
    transparent 70%
  );
  pointer-events: none;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.4fr;
  gap: clamp(24px, 4vw, 48px);
  margin-bottom: 60px;
}
.footer-brand-desc {
  font-size: 0.92rem;
  color: var(--text-soft);
  line-height: 1.8;
  margin: 16px 0 24px;
  max-width: 280px;
}
.footer-social {
  display: flex;
  gap: 10px;
}
.footer-logo {
  margin-bottom: 4px;
}
.footer-col-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 18px;
  letter-spacing: -0.01em;
}
.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-links a {
  font-size: 0.9rem;
  color: var(--text-soft);
  font-weight: 500;
  transition:
    color 0.25s ease,
    padding-right 0.25s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.footer-links a::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--gradient-brand);
  flex-shrink: 0;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.footer-links a:hover {
  color: var(--primary);
}
.footer-links a:hover::before {
  opacity: 1;
}
.footer-newsletter p {
  font-size: 0.9rem;
  color: var(--text-soft);
  line-height: 1.7;
  margin-bottom: 16px;
}
.newsletter-form {
  display: flex;
  gap: 8px;
  background: rgba(var(--primary-rgb), 0.05);
  border: 1.5px solid var(--border-soft);
  border-radius: 16px;
  padding: 6px 6px 6px 12px;
  transition: border-color 0.3s ease;
}
.newsletter-form:focus-within {
  border-color: rgba(var(--primary-rgb), 0.4);
}
.newsletter-input {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 0.9rem;
  outline: none;
  min-width: 0;
}
.newsletter-btn {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  flex-shrink: 0;
  background: var(--gradient-brand);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    transform 0.3s var(--ease),
    box-shadow 0.3s ease;
}
.newsletter-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 20px -6px rgba(var(--primary-rgb), 0.5);
}
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 0;
  border-top: 1px solid var(--border-soft);
  font-size: 0.85rem;
  color: var(--text-faint);
  flex-wrap: wrap;
  gap: 12px;
}
.footer-bottom-links {
  display: flex;
  gap: 24px;
}
.footer-bottom-links a {
  color: var(--text-faint);
  transition: color 0.25s ease;
}
.footer-bottom-links a:hover {
  color: var(--primary);
}

/* =========================================================
   Floating Utility Buttons
   ========================================================= */
.fab {
  position: fixed;
  bottom: 26px;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-soft);
  z-index: 900;
  transition:
    transform 0.3s var(--ease),
    opacity 0.3s ease,
    box-shadow 0.3s ease;
}
.fab-whatsapp {
  inset-inline-start: 26px;
  background: #25d366;
  color: #fff;
}
.fab-whatsapp svg {
  width: 28px;
  height: 28px;
}
.fab-whatsapp:hover {
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 16px 40px -8px rgba(37, 211, 102, 0.5);
}
.fab-top {
  inset-inline-end: 26px;
  bottom: 26px;
  background: rgba(var(--surface-rgb), 0.8);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-soft);
  color: var(--text-main);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
}
.fab-top svg {
  width: 20px;
  height: 20px;
}
.fab-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.fab-top:hover {
  color: var(--primary);
  transform: translateY(-4px);
}

/* =========================================================
   Gallery Page — Simple Top Bar (gallery.css)
   ========================================================= */
.top-bar {
  position: fixed;
  top: 16px;
  inset-inline: 0;
  display: flex;
  justify-content: center;
  z-index: 1000;
  padding: 0 16px;
}
.top-bar-inner {
  width: min(1160px, 100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  border-radius: 999px;
  background: rgba(var(--surface-rgb), 0.75);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-soft);
}
.top-bar-logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  gap: 8px;
}
.top-bar-logo em {
  font-style: normal;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text-main);
  border: 1.5px solid var(--border-soft);
  background: rgba(var(--surface-rgb), 0.4);
  transition:
    border-color 0.3s,
    color 0.3s,
    transform 0.3s var(--ease);
}
.back-btn:hover {
  border-color: rgba(var(--primary-rgb), 0.5);
  color: var(--primary);
  transform: translateY(-2px);
}
.back-btn svg {
  width: 16px;
  height: 16px;
}

/* Hero area */
.page-hero {
  position: relative;
  z-index: 1;
  padding: clamp(110px, 14vw, 160px) 0 clamp(60px, 8vw, 100px);
  text-align: center;
}
.page-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.08);
  border: 1px solid rgba(var(--primary-rgb), 0.15);
  margin-bottom: 20px;
}
.page-title {
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
  color: var(--text-main);
}
.page-desc {
  font-size: clamp(0.97rem, 1.1vw, 1.1rem);
  color: var(--text-soft);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.8;
}

/* Filter tabs */
.filter-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: clamp(36px, 5vw, 60px);
}
.filter-btn {
  padding: 9px 20px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-soft);
  background: rgba(var(--surface-rgb), 0.6);
  border: 1.5px solid var(--border-soft);
  transition: all 0.3s var(--ease);
  cursor: pointer;
}
.filter-btn:hover,
.filter-btn.active {
  color: #fff;
  background: var(--gradient-brand);
  border-color: transparent;
  box-shadow: 0 8px 24px -6px rgba(var(--primary-rgb), 0.45);
}

/* Masonry gallery */
.gallery-grid {
  columns: 3;
  column-gap: 16px;
  position: relative;
  z-index: 1;
}
@media (max-width: 900px) {
  .gallery-grid {
    columns: 2;
  }
}
@media (max-width: 576px) {
  .gallery-grid {
    columns: 1;
  }
}

.gallery-item {
  break-inside: avoid;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  margin-bottom: 16px;
  cursor: zoom-in;
  background: var(--surface);
  transition:
    transform 0.4s var(--ease),
    box-shadow 0.4s ease;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards;
}
.gallery-item:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-strong);
}
.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.gallery-img {
  width: 100%;
  display: block;
  transition: transform 0.5s var(--ease);
}
.gallery-item:hover .gallery-img {
  transform: scale(1.05);
}

.gallery-img-placeholder {
  width: 100%;
  display: block;
  position: relative;
  overflow: hidden;
}
.gallery-img-placeholder svg {
  display: block;
  width: 100%;
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(15, 23, 42, 0.75) 0%,
    transparent 55%
  );
  display: flex;
  align-items: flex-end;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.4s ease;
}
.gallery-overlay-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}
.gallery-caption {
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  font-family: var(--font-display);
}
.gallery-zoom-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
  backdrop-filter: blur(8px);
}
.gallery-zoom-icon svg {
  width: 16px;
  height: 16px;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.35s ease,
    visibility 0.35s;
  padding: 20px;
}
.lightbox.open {
  opacity: 1;
  visibility: visible;
}
.lightbox-img-wrap {
  position: relative;
  max-width: 900px;
  width: 100%;
  max-height: 90vh;
  border-radius: 20px;
  overflow: hidden;
  transform: scale(0.9);
  transition: transform 0.35s var(--ease);
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox.open .lightbox-img-wrap {
  transform: scale(1);
}
.lightbox-img-wrap svg,
.lightbox-img-wrap img {
  width: 100%;
  height: auto;
  display: block;
}
.lightbox-close {
  position: fixed;
  top: 24px;
  right: 24px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    background 0.3s,
    transform 0.3s;
  backdrop-filter: blur(12px);
  z-index: 2001;
}
.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: rotate(90deg);
}
.lightbox-close svg {
  width: 20px;
  height: 20px;
}
.lightbox-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
  padding: 24px 24px 20px;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
}
.lightbox-nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2001;
  display: flex;
  gap: 0;
}
.lightbox-nav-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s;
  backdrop-filter: blur(12px);
}
.lightbox-nav-btn:hover {
  background: rgba(255, 255, 255, 0.28);
}
.lightbox-nav-btn svg {
  width: 22px;
  height: 22px;
}
.lb-prev {
  left: 20px;
  position: fixed;
}
.lb-next {
  right: 20px;
  position: fixed;
}

/* Gallery footer */
.gallery-footer {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 40px 0;
  border-top: 1px solid var(--border-soft);
  margin-top: clamp(60px, 8vw, 100px);
  font-size: 0.85rem;
  color: var(--text-faint);
}
.gallery-footer a {
  color: var(--primary);
  font-weight: 600;
}
.gallery-footer a:hover {
  text-decoration: underline;
}

/* Entrance animation for gallery items */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* =========================================================
   Course Details Page (course-details.css)
   ========================================================= */
/* =========================================================
   مِنَصّة+ | course-details.css — Custom Detail Page Styles
   ========================================================= */

.cd-page-spacer {
  height: calc(var(--nav-h) + 40px);
}

.cd-breadcrumb {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-faint);
  margin-bottom: 24px;
  font-weight: 600;
  z-index: 2;
  position: relative;
}

.cd-breadcrumb a {
  color: var(--text-soft);
  transition: color 0.3s ease;
}

.cd-breadcrumb a:hover {
  color: var(--primary);
}

.cd-breadcrumb svg {
  width: 12px;
  height: 12px;
  transform: scaleX(-1);
}

.cd-hero {
  position: relative;
  padding-bottom: 40px;
  z-index: 2;
}

.cd-hero-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.08);
  border: 1px solid rgba(var(--primary-rgb), 0.15);
  margin-bottom: 16px;
}

.cd-hero-title {
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 16px;
  line-height: 1.3;
}

.cd-hero-desc {
  font-size: 1.05rem;
  color: var(--text-soft);
  max-width: 700px;
  line-height: 1.8;
  margin-bottom: 24px;
}

.cd-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
}

.cd-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  color: var(--text-soft);
  font-weight: 600;
}

.cd-meta-item svg {
  width: 16px;
  height: 16px;
  color: var(--primary);
}

.cd-rating-stars {
  color: #f59e0b;
}

.cd-content-section {
  position: relative;
  z-index: 2;
  padding-bottom: 80px;
}

.cd-thumb {
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  margin-bottom: 32px;
  border: 1px solid var(--glass-border);
  aspect-ratio: 16/9;
  background: var(--gradient-soft);
}

.cd-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.cd-card {
  border-radius: 24px;
  padding: 28px;
  margin-bottom: 24px;
  border: 1px solid var(--glass-border);
}

.cd-card h2 {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.cd-card h2::before {
  content: "";
  width: 4px;
  height: 20px;
  background: var(--gradient-brand);
  border-radius: 99px;
  display: inline-block;
}

.cd-card p {
  color: var(--text-soft);
  line-height: 1.8;
  font-size: 0.95rem;
}

.cd-curriculum-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cd-curriculum-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-radius: 14px;
  background: rgba(var(--primary-rgb), 0.03);
  border: 1px solid var(--border-soft);
  transition:
    transform 0.3s var(--ease),
    border-color 0.3s ease;
}

.cd-curriculum-item:hover {
  transform: translateX(-4px);
  border-color: rgba(var(--primary-rgb), 0.25);
}

.cd-curr-left {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.92rem;
}

.cd-curr-left svg {
  width: 18px;
  height: 18px;
  color: var(--primary);
}

.cd-curr-time {
  font-size: 0.8rem;
  color: var(--text-faint);
  font-weight: 500;
  direction: ltr;
}

.cd-instructor {
  display: flex;
  gap: 20px;
  align-items: center;
}

.cd-instructor img {
  width: 80px;
  height: 100px;
  border-radius: 16px;
  object-fit: cover;
  border: 2px solid rgba(var(--primary-rgb), 0.15);
}

.cd-instructor h4 {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 6px;
}

.cd-sidebar {
  position: sticky;
  top: calc(var(--nav-h) + 40px);
  z-index: 10;
}

.cd-price-card {
  border-radius: 28px;
  padding: 32px;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-soft);
  text-align: center;
}

.cd-price-value {
  font-size: 2.2rem;
  font-weight: 900;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  /* line-height: 1; */
  margin-bottom: 20px;
  font-family: var(--font-display);
}

.cd-price-note {
  font-size: 0.82rem;
  color: var(--text-faint);
  font-weight: 600;
  margin-bottom: 24px;
}

.cd-sidebar-btn {
  width: 100%;
  justify-content: center;
  padding: 15px;
  font-size: 1rem;
  margin-bottom: 24px;
}

.cd-sidebar-btn svg {
  width: 18px;
  height: 18px;
  transform: scaleX(-1);
}

.cd-includes-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: right;
  margin-bottom: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--border-soft);
}

.cd-include-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text-soft);
  font-weight: 600;
}

.cd-include-item svg {
  width: 16px;
  height: 16px;
  color: #22c55e;
}

.cd-share-row {
  display: flex;
  justify-content: center;
  gap: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--border-soft);
}

.cd-share-btn {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-soft);
  transition:
    color 0.3s ease,
    background 0.3s ease,
    transform 0.3s var(--ease);
}

.cd-share-btn:hover {
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.08);
  transform: translateY(-2px);
}

.cd-share-btn svg {
  width: 16px;
  height: 16px;
}

/* =========================================================
   Login Page (login.css)
   ========================================================= */
/* =========================================================
   مِنَصّة+ | login.css — Luxury Modern Card Layout
   ========================================================= */

.login-main-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: calc(var(--nav-h) + 20px);
  padding-bottom: 60px;
  position: relative;
  z-index: 2;
}

.login-card-box {
  width: 100%;
  max-width: 480px;
  border-radius: 32px;
  padding: 40px;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-strong);
  backdrop-filter: blur(24px) saturate(170%);
  -webkit-backdrop-filter: blur(24px) saturate(170%);
  transform: translateY(0);
}

.login-header-zone {
  margin-bottom: 32px;
}

.login-header-zone h2 {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.login-header-zone p {
  font-size: 0.9rem;
  color: var(--text-soft);
  line-height: 1.6;
}

.login-form-element {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.input-icon-left {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-faint);
  pointer-events: none;
  transition: color 0.3s ease;
}

.input-icon-left svg {
  width: 18px;
  height: 18px;
}

.form-input:focus ~ .input-icon-left {
  color: var(--primary);
}

.password-toggle-btn {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-faint);
  border: none;
  background: none;
  padding: 0;
  cursor: pointer;
  transition: color 0.3s ease;
}

.password-toggle-btn:hover {
  color: var(--primary);
}

.password-toggle-btn svg {
  width: 18px;
  height: 18px;
}

/* Setup adjust for labels on icons mapping */
.form-input:focus ~ .form-label,
.form-input:not(:placeholder-shown) ~ .form-label {
  color: var(--primary);
}

.form-actions-row {
  margin-top: -4px;
}

.remember-me-checkbox {
  cursor: pointer;
  position: relative;
  user-select: none;
}

.remember-me-checkbox input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.custom-checkmark {
  width: 18px;
  height: 18px;
  background: rgba(var(--primary-rgb), 0.05);
  border: 1.5px solid var(--border-soft);
  border-radius: 6px;
  display: inline-block;
  position: relative;
  transition:
    background 0.25s ease,
    border-color 0.25s ease;
}

.remember-me-checkbox:hover input ~ .custom-checkmark {
  border-color: rgba(var(--primary-rgb), 0.4);
}

.remember-me-checkbox input:checked ~ .custom-checkmark {
  background: var(--gradient-brand);
  border-color: transparent;
}

.custom-checkmark::after {
  content: "";
  position: absolute;
  display: none;
  left: 5px;
  top: 2px;
  width: 5px;
  height: 9px;
  border: stroke #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.remember-me-checkbox input:checked ~ .custom-checkmark::after {
  display: block;
  border: solid #fff;
  border-width: 0 2px 2px 0;
}

.checkbox-text {
  font-size: 0.88rem;
  color: var(--text-soft);
  font-weight: 600;
}

.forgot-password-link {
  font-size: 0.88rem;
  color: var(--primary);
  font-weight: 700;
  transition: color 0.3s ease;
}

.forgot-password-link:hover {
  color: var(--secondary);
}

.form-submit-btn {
  padding: 15px;
  font-size: 1rem;
  font-weight: 700;
  border-radius: 16px;
  margin-top: 8px;
}

.login-footer-redirect {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border-soft);
  font-size: 0.9rem;
  color: var(--text-soft);
  display: flex;
  justify-content: center;
  gap: 6px;
}

.login-error-alert {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #ef4444;
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.5;
  text-align: right;
}

/* Responsiveness adjustments */
@media (max-width: 576px) {
  .login-card-box {
    padding: 30px 20px;
    border-radius: 24px;
  }
  .login-header-zone h2 {
    font-size: 1.5rem;
  }
}

/* =========================================================
   Register Page (register.css)
   ========================================================= */
/* =========================================================
   مِنَصّة+ | register.css — Multi-Step Layout System
   ========================================================= */

.reg-main-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: calc(var(--nav-h) + 20px);
  padding-bottom: 60px;
  position: relative;
  z-index: 2;
}

.reg-side-panel {
  border-radius: 32px;
  border: 1px solid var(--glass-border);
}

.reg-side-eyebrow {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: block;
  margin-bottom: 12px;
}

.reg-side-title {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.35;
  margin-bottom: 16px;
}

.reg-side-desc {
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.7;
}

.reg-side-features {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-top: 32px;
}

.reg-feat-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  color: var(--text-soft);
  font-weight: 600;
}

.reg-feat-icon {
  width: 24px;
  height: 24px;
  color: var(--primary);
  flex-shrink: 0;
}

.reg-feat-icon svg {
  width: 100%;
  height: 100%;
}

.reg-stat-item strong {
  display: block;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1;
}

.reg-stat-item span {
  font-size: 0.8rem;
  color: var(--text-faint);
  font-weight: 600;
}

.reg-stat-divider {
  width: 1px;
  height: 32px;
  background: var(--border-soft);
}

.reg-form-card {
  border-radius: 32px;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-soft);
}

.reg-header h2 {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 8px;
}

.reg-header p {
  font-size: 0.9rem;
  color: var(--text-soft);
}

/* Steps Progress Nav Design Mapping */
.reg-steps-indicator {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.reg-step-node {
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0.4;
  transition: opacity 0.3s ease;
}

.reg-step-node.active {
  opacity: 1;
}

.step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(var(--primary-rgb), 0.1);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 800;
  border: 1px solid var(--border-soft);
  transition:
    background 0.3s ease,
    color 0.3s ease;
}

.reg-step-node.active .step-num {
  background: var(--gradient-brand);
  color: #fff;
  border-color: transparent;
}

.step-text {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
}

.reg-step-connector {
  flex: 1;
  height: 2px;
  background: var(--border-soft);
  margin-inline: 12px;
}

.review-data-wrapper {
  background: rgba(var(--primary-rgb), 0.02);
  border: 1px solid var(--border-soft);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.review-row-node {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  padding-bottom: 8px;
  border-bottom: 1px dashed var(--border-soft);
}

.review-row-node:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.rev-label {
  color: var(--text-faint);
  font-weight: 600;
}

.rev-val {
  color: var(--text-main);
  font-weight: 700;
}

/* Breakpoint Fixes */
@media (max-width: 768px) {
  .reg-steps-indicator {
    gap: 4px;
  }
  .step-text {
    display: none;
  }
  .reg-step-connector {
    margin-inline: 4px;
  }
}

/* =========================================================
   enroll.css 
   ========================================================= */

.enroll-main-wrapper {
  min-height: 100vh;
  padding-top: calc(var(--nav-h) + 20px);
  padding-bottom: 60px;
  position: relative;
  z-index: 2;
}

.en-breadcrumb {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-faint);
  font-weight: 600;
}

.en-breadcrumb a {
  color: var(--text-soft);
  transition: color 0.3s ease;
}

.en-breadcrumb a:hover {
  color: var(--primary);
}

.en-breadcrumb svg {
  width: 12px;
  height: 12px;
  transform: scaleX(-1);
}

.en-card {
  border-radius: 24px;
  border: 1px solid var(--glass-border);
}

.en-course-card {
  background: rgba(var(--surface-rgb), 0.4);
}

.en-course-thumb {
  width: 100px;
  height: 60px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--glass-border);
}

.en-course-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.badge-subject {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary);
  padding: 3px 10px;
  border-radius: 99px;
  background: rgba(var(--primary-rgb), 0.08);
}

.en-course-instructor {
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.en-course-instructor svg {
  width: 14px;
  height: 14px;
  color: var(--primary);
}

/* Payment Gateway Grid Options Selector Layout */
.en-payment-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.en-payment-option {
  padding: 16px 20px;
  border-radius: 14px;
  background: rgba(var(--primary-rgb), 0.02);
  border: 1.5px solid var(--border-soft);
  cursor: pointer;
  transition: all 0.25s var(--ease);
}

.en-payment-option:hover {
  border-color: rgba(var(--primary-rgb), 0.3);
}

.en-payment-option.active {
  background: rgba(var(--primary-rgb), 0.05);
  border-color: var(--primary);
}

.en-option-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.en-radio-circle {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--text-faint);
  position: relative;
  display: inline-block;
  transition: border-color 0.25s;
}

.en-payment-option input {
  position: absolute;
  opacity: 0;
  visibility: hidden;
}

.en-payment-option input:checked ~ .en-option-content .en-radio-circle {
  border-color: var(--primary);
}

.en-payment-option input:checked ~ .en-option-content .en-radio-circle::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  background: var(--gradient-brand);
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.en-payment-label {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-main);
}

.form-label.style-small {
  top: 10px;
  font-size: 0.85rem;
}

.form-input:focus ~ .form-label.style-small,
.form-input:not(:placeholder-shown) ~ .form-label.style-small {
  top: 4px;
  font-size: 0.7rem;
}

.en-sidebar {
  position: sticky;
  top: calc(var(--nav-h) + 40px);
}

.en-summary-card {
  box-shadow: var(--shadow-strong);
}

@media (max-width: 991px) {
  .en-sidebar {
    position: static;
    margin-top: 24px;
  }
}

/* =========================================================
   Responsive Rules (responsive.css)
   ========================================================= */
/* =========================================================
   Responsive rules — complete (updated)
   ========================================================= */

/* Laptop viewport configuration */
@media (max-width: 1200px) {
  .nav-link {
    padding: 10px 12px;
    font-size: 0.88rem;
  }
  .btn-nav-login,
  .btn-nav-signup {
    padding: 9px 14px;
    font-size: 0.84rem;
  }
  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
  }
  .footer-newsletter {
    grid-column: 1 / -1;
    max-width: 480px;
  }
  /* Hero visual: keep reasonable size */
  .hero-grid {
    grid-template-columns: 1.1fr 1fr;
  }
}

/* Tablet viewport configuration */
@media (max-width: 991px) {
  .nav-links {
    display: none;
  }
  .btn-nav-login,
  .btn-nav-signup {
    display: none;
  }
  .nav-burger {
    display: flex;
  }
  .floating-nav {
    padding: 8px 10px 8px 8px;
  }

  /* Hero — stack visual on top, content below */
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 60px;
  }
  .hero-content {
    order: 2;
    text-align: center;
  }
  .hero-visual {
    order: 1;
    min-height: 420px;
  }
  .hero-desc {
    margin-inline: auto;
  }
  .hero-actions {
    justify-content: center;
  }
  .hero-stats {
    margin-inline: auto;
    justify-content: center;
  }
  .eyebrow {
    margin-inline: auto;
  }
  .visual-stage {
    max-width: 420px;
  }
  .teacher-photo {
    width: 62%;
  }
  .code-card {
    left: 1%;
    /* Proportional to the reduced base sizes (170/205px) */
    min-width: 158px;
    max-width: 188px;
  }
  .students-badge {
    right: 1%;
  }

  /* Features layout adjustments */
  .fz-row {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .fz-row.fz-reverse {
    grid-template-columns: 1fr;
  }
  .fz-row.fz-reverse .fz-visual {
    order: 0;
  }
  .fz-row.fz-reverse .fz-content {
    order: 0;
  }
  .fz-visual {
    max-width: 200px;
  }
  .fz-content {
    text-align: center;
  }
  .fz-tags {
    justify-content: center;
  }

  /* Contact section stack */
  .contact-grid {
    grid-template-columns: 1fr;
  }
  .contact-info {
    order: 2;
  }
  .contact-form-wrap {
    order: 1;
  }
  .teacher-profile-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .teacher-profile-title {
    justify-content: center;
  }
  .teacher-profile-stats {
    width: 100%;
  }
  .teacher-skills {
    justify-content: center;
  }

  /* Footer grid reconfiguration */
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer-brand {
    grid-column: 1 / -1;
  }
  .footer-newsletter {
    grid-column: 1 / -1;
    max-width: 100%;
  }
}

/* Mobile viewport configuration */
@media (max-width: 576px) {
  .floating-nav-wrap {
    top: 12px;
    padding: 0 10px;
  }
  .logo-text {
    font-size: 1rem;
  }
  .toggle-track {
    width: 44px;
    height: 24px;
  }
  .toggle-thumb {
    width: 18px;
    height: 18px;
  }
  [data-theme="dark"] .toggle-thumb {
    transform: translateX(-20px);
  }

  /* Hero interface reduction */
  .hero {
    padding-top: calc(var(--nav-h) + 30px);
  }
  .hero-title {
    font-size: 2rem;
  }
  .hero-desc {
    font-size: 0.95rem;
  }
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .btn-primary,
  .btn-ghost {
    justify-content: center;
    width: 100%;
  }
  .hero-stats {
    flex-wrap: wrap;
    gap: 18px;
    justify-content: center;
  }
  .stat-divider {
    display: none;
  }

  .visual-stage {
    max-width: 340px;
  }
  .teacher-photo {
    width: 80%;
    border-radius: 24px;
  }
  .code-card {
    left: 0%;
    /* Proportional reduction */
    min-width: 136px;
    max-width: 164px;
  }
  .code-line {
    font-size: 0.65rem;
  }
  .students-badge {
    right: 0%;
    padding: 10px 12px;
  }
  .students-num {
    font-size: 1.2rem;
  }

  /* Teacher details block */
  .teacher-profile-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px;
  }
  .teacher-profile-img {
    width: 90px;
    height: 108px;
  }

  /* Contact wrappers */
  .social-links {
    flex-wrap: wrap;
  }

  /* Footer layout */
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .footer-brand {
    grid-column: auto;
  }
  .footer-bottom {
    flex-direction: column;
    align-items: center !important; /* FIXED: Changed from flex-start to center for mobile screens */
    justify-content: center !important;
    text-align: center !important;
    gap: 8px;
  }

  /* Action control units */
  .fab-whatsapp {
    inset-inline-start: 16px;
    bottom: 16px;
    width: 48px;
    height: 48px;
  }
  .fab-top {
    inset-inline-end: 16px;
    bottom: 16px;
    width: 48px;
    height: 48px;
  }

  .mobile-menu a {
    font-size: 1.3rem;
  }
  .section-title {
    font-size: 1.7rem;
  }
  .fz-content h3 {
    font-size: 1.3rem;
  }
}

/* Small screens configuration */
@media (max-width: 380px) {
  .hero-title {
    font-size: 1.7rem;
  }
  .visual-stage {
    max-width: 300px;
  }
  .code-card {
    left: 0%;
    /* Proportional reduction for very small screens */
    min-width: 120px;
    max-width: 142px;
  }
  .code-line {
    font-size: 0.6rem;
  }
  .students-badge {
    right: 0%;
    padding: 8px 10px;
  }
  .students-num {
    font-size: 1rem;
  }
}

/* Operational utility for motion restriction systems */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  html {
    scroll-behavior: auto;
  }
}
/* =========================================================
   Promo Video Player — custom overlay
   ========================================================= */
.promo-video-wrap {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow-strong);
  aspect-ratio: 16 / 9;
  background: #0b1220;
  cursor: pointer;
}
.promo-video-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 28px;
  transition:
    transform 0.5s var(--ease),
    filter 0.4s ease;
}
.promo-video-wrap:hover .promo-video-poster {
  transform: scale(1.03);
  filter: brightness(0.75);
}
.promo-video-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  background: linear-gradient(
    to bottom,
    rgba(11, 18, 32, 0.25) 0%,
    rgba(11, 18, 32, 0.55) 100%
  );
  border-radius: 28px;
  transition: background 0.35s ease;
  z-index: 2;
}
.promo-video-wrap:hover .promo-video-overlay {
  background: linear-gradient(
    to bottom,
    rgba(11, 18, 32, 0.35) 0%,
    rgba(11, 18, 32, 0.68) 100%
  );
}
.promo-play-btn {
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 84px;
  height: 84px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.35s var(--ease);
  filter: drop-shadow(0 8px 24px rgba(37, 99, 235, 0.55));
}
.promo-play-btn:hover {
  transform: scale(1.15);
}
.promo-play-ripple {
  position: absolute;
  inset: -12px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.35);
  animation: videoRipple 2.4s ease-out infinite;
}
@keyframes videoRipple {
  0% {
    transform: scale(0.85);
    opacity: 0.7;
  }
  100% {
    transform: scale(1.55);
    opacity: 0;
  }
}
.promo-play-label {
  color: rgba(255, 255, 255, 0.9);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin: 0;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}
/* hide overlay once video is playing */
.promo-video-wrap.playing .promo-video-overlay,
.promo-video-wrap.playing .promo-video-poster {
  display: none;
}

/* =========================================================
   3. APPENDED COMPONENT: Dynamic Checkout & Enrollment Page Styles
   ========================================================= */

.enroll-main-wrapper {
  min-height: 100vh;
  padding-top: calc(var(--nav-h) + 20px);
  padding-bottom: 60px;
  position: relative;
  z-index: 2;
}

.en-breadcrumb {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-faint);
  font-weight: 600;
}

.en-breadcrumb a {
  color: var(--text-soft);
  transition: color 0.3s ease;
}

.en-breadcrumb a:hover {
  color: var(--primary);
}

.en-breadcrumb svg {
  width: 12px;
  height: 12px;
  transform: scaleX(-1);
}

.en-card {
  border-radius: 24px;
  border: 1px solid var(--glass-border);
}

.en-course-card {
  background: rgba(var(--surface-rgb), 0.4);
}

.en-course-thumb {
  width: 100px;
  height: 60px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--glass-border);
}

.en-course-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.badge-subject {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary);
  padding: 3px 10px;
  border-radius: 99px;
  background: rgba(var(--primary-rgb), 0.08);
}

.en-course-info {
  flex: 1;
}

.en-course-instructor {
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.en-course-instructor svg {
  width: 14px;
  height: 14px;
  color: var(--primary);
}

/* Payment Gateway Grid Options Selector Layout */
.en-payment-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.en-payment-option {
  padding: 16px 20px;
  border-radius: 14px;
  background: rgba(var(--primary-rgb), 0.02);
  border: 1.5px solid var(--border-soft);
  cursor: pointer;
  transition: all 0.25s var(--ease);
}

.en-payment-option:hover {
  border-color: rgba(var(--primary-rgb), 0.3);
}

.en-payment-option.active {
  background: rgba(var(--primary-rgb), 0.05);
  border-color: var(--primary);
}

.en-option-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.en-radio-circle {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--text-faint);
  position: relative;
  display: inline-block;
  transition: border-color 0.25s;
}

.en-payment-option input {
  position: absolute;
  opacity: 0;
  visibility: hidden;
}

.en-payment-option input:checked ~ .en-option-content .en-radio-circle {
  border-color: var(--primary);
}

.en-payment-option input:checked ~ .en-option-content .en-radio-circle::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  background: var(--gradient-brand);
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.en-payment-label {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-main);
}

.form-label.style-small {
  top: 10px;
  font-size: 0.85rem;
}

.form-input:focus ~ .form-label.style-small,
.form-input:not(:placeholder-shown) ~ .form-label.style-small {
  top: 4px;
  font-size: 0.7rem;
}

.en-sidebar {
  position: sticky;
  top: calc(var(--nav-h) + 40px);
}

.en-summary-card {
  box-shadow: var(--shadow-strong);
}

@media (max-width: 991px) {
  .en-sidebar {
    position: static;
    margin-top: 24px;
  }
}
