/* ============================================================
   ARIO — 04 LEARN
   Learn Hero · Learn Events · Course Grid · Online Note
   Code Card · Guest Lock
   ============================================================ */

/* ============================================================
   Learn Hero
   ============================================================ */
.learn-hero {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 3.5rem;
  align-items: center;
  padding: 4rem 1.5rem 2rem;
  min-height: auto;
  overflow: hidden;
  isolation: isolate;
}
.learn-hero-bg { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.learn-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: .55;
  animation: orbFloat 14s ease-in-out infinite;
}
@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(22px, -18px) scale(1.15); }
}
.learn-blob-1 { top: 5%; left: 5%; width: 320px; height: 320px; background: radial-gradient(circle, rgba(96,165,250,.7), transparent 70%); }
.learn-blob-2 { bottom: 10%; right: 5%; width: 280px; height: 280px; background: radial-gradient(circle, rgba(168,85,247,.6), transparent 70%); animation-delay: -5s; }
.learn-blob-3 { top: 40%; left: 45%; width: 240px; height: 240px; background: radial-gradient(circle, rgba(251,191,36,.45), transparent 70%); animation-delay: -9s; }

.learn-grid-lines {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(59, 130, 246,.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(59, 130, 246,.06) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
}
.learn-hero-content { position: relative; z-index: 2; max-width: 620px; }
.learn-tag {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .45rem 1.1rem;
  border-radius: 100px;
  background: linear-gradient(135deg, rgba(59, 130, 246,.12), rgba(245, 158, 11,.08));
  border: 1px solid rgba(59, 130, 246,.25);
  color: var(--blue-700);
  font-family: var(--font-en);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .18em;
  margin-bottom: 1.4rem;
}
.learn-tag-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #22d3ee;
  box-shadow: 0 0 10px #22d3ee, 0 0 20px rgba(34,211,238,.6);
  animation: pulseDot 1.6s ease-in-out infinite;
}
@keyframes pulseDot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50%      { transform: scale(1.3); opacity: .7; }
}
.learn-hero-title {
  font-family: var(--font-fa);
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 900;
  line-height: 1.4;
  letter-spacing: -.02em;
  margin-bottom: 1.3rem;
  color: var(--ink-900);
}
.learn-hero-sub { color: #475569; font-size: 1.02rem; line-height: 2; margin-bottom: 2rem; max-width: 46ch; }
.learn-hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-bottom: 2.5rem; }
.learn-hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; max-width: 480px; }
.learn-mini-stat {
  padding: 1rem .8rem;
  background: rgba(255,255,255,.7);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(59, 130, 246,.18);
  border-radius: var(--radius);
  text-align: center;
  box-shadow: 0 4px 14px rgba(59, 130, 246,.06);
}
.learn-mini-stat-num {
  font-family: var(--font-fa);
  font-size: 1.5rem;
  font-weight: 900;
  background: linear-gradient(135deg, #3b82f6, #7c3aed 50%, #f59e0b);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.2;
  margin-bottom: .25rem;
}
.learn-mini-stat-lbl { font-size: .76rem; font-weight: 700; color: var(--text-soft); }

/* ============================================================
   Learn Hero Visual — Code Card
   ============================================================ */
.learn-hero-visual {
  position: relative;
  z-index: 2;
  min-height: 520px;
  width: 100%;
}
.learn-code-float {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: min(640px, 100%);
  border-radius: var(--radius-lg);
  padding: 2px;
  background: linear-gradient(135deg,
      #ff6ec4 0%, #ff9a56 14%, #fbbf24 28%, #4ade80 42%,
      #22d3ee 56%, #7873f5 70%, #c084fc 84%, #ff6ec4 100%);
  background-size: 400% 400%;
  animation: codeFloat 6s ease-in-out infinite, borderFlow 7s ease infinite;
  box-shadow: 0 20px 50px rgba(120,115,245,.25), 0 0 60px rgba(255,110,196,.2);
  font-family: var(--font-mono);
  direction: ltr;
  overflow: hidden;
  isolation: isolate;
}
.learn-code-float::before {
  content: '';
  position: absolute;
  inset: 2px;
  border-radius: calc(var(--radius-lg) - 2px);
  background:
    radial-gradient(circle at 15% 0%, rgba(120, 115, 245, .22), transparent 55%),
    radial-gradient(circle at 100% 100%, rgba(6, 182, 212, .12), transparent 55%),
    linear-gradient(160deg, #16122e 0%, #0a0718 50%, #16122e 100%);
  z-index: 0;
  pointer-events: none;
}
.learn-code-float > * { position: relative; z-index: 1; }
@keyframes codeFloat {
  0%, 100% { transform: translateX(-50%) translateY(0)     rotate(-5deg); }
  50%      { transform: translateX(-50%) translateY(-12px) rotate(3deg);  }
}
@keyframes borderFlow {
  0%, 100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}
.learn-code-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .8rem 1.1rem;
  background: linear-gradient(180deg, rgba(38, 26, 68, .95), rgba(20, 14, 42, .95));
  border-bottom: 1px solid rgba(120, 115, 245, .18);
  border-top-left-radius: calc(var(--radius-lg) - 2px);
  border-top-right-radius: calc(var(--radius-lg) - 2px);
}
.learn-code-dots { display: flex; gap: .45rem; }
.learn-code-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.learn-code-dot-red    { background: #ff5f57; }
.learn-code-dot-yellow { background: #febc2e; }
.learn-code-dot-green  { background: #28c840; }
.learn-code-filename {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .04em;
  background: linear-gradient(90deg, #7dd3fc, #a78bfa);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.learn-code-filename svg { color: #7dd3fc; flex-shrink: 0; }
.learn-code-body {
  margin: 0;
  padding: 1.5rem 1.3rem 1.6rem;
  font-size: .92rem;
  line-height: 2.05;
  color: #e8e3ff;
  background: transparent;
  font-family: var(--font-mono);
  tab-size: 4;
  counter-reset: line;
  white-space: pre;
  overflow-x: auto;
  overflow-y: hidden;
  border-bottom-left-radius: calc(var(--radius-lg) - 2px);
  border-bottom-right-radius: calc(var(--radius-lg) - 2px);
  scrollbar-width: thin;
  scrollbar-color: rgba(120,115,245,.4) transparent;
}
.learn-code-body::-webkit-scrollbar { height: 6px; }
.learn-code-body::-webkit-scrollbar-track { background: transparent; }
.learn-code-body::-webkit-scrollbar-thumb {
  background: rgba(120,115,245,.4);
  border-radius: 100px;
}
.learn-code-body::-webkit-scrollbar-thumb:hover { background: rgba(120,115,245,.7); }
.learn-code-body code {
  display: block;
  background: transparent;
  padding: 0;
  margin: 0;
  font-family: inherit;
  color: inherit;
  font-size: inherit;
  line-height: inherit;
  border: none;
}
.learn-code-body .line {
  display: block;
  counter-increment: line;
  position: relative;
  padding-left: 5.2rem;
  white-space: pre;
  min-height: 2em;
  margin: 0;
}
.learn-code-body .line::before {
  content: counter(line);
  position: absolute;
  left: 0;
  top: 0;
  width: 3.4rem;
  text-align: center;
  color: rgba(148, 163, 184, .55);
  font-size: .82rem;
  user-select: none;
  pointer-events: none;
  font-weight: 500;
  font-feature-settings: 'tnum';
}
.learn-code-body .kw    { color: #c084fc; font-weight: 700; }
.learn-code-body .str   { color: #6ee7b7; }
.learn-code-body .fn    { color: #fbbf24; font-weight: 600; }
.learn-code-body .op    { color: #60a5fa; font-weight: 600; }
.learn-code-body .brace { color: #7dd3fc; }
.learn-code-body .cls   { color: #a78bfa; font-weight: 700; }
.learn-code-body .var   { color: #e0e7ff; }

/* ============================================================
   Learn Events — رویدادهای ویژه
   ============================================================ */
.learn-events {
  position: relative;
  margin-bottom: 3rem;
  padding: 1.8rem 1.5rem 2rem;
  border-radius: var(--radius-xl);
  background: linear-gradient(160deg, #f8fbff 0%, #eef5ff 100%);
  border: 1.5px solid rgba(59, 130, 246, .15);
  overflow: hidden;
  isolation: isolate;
  max-width: 1220px;
  margin-inline: auto;
}
.learn-events::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #f59e0b, #ec4899, #8b5cf6, #22d3ee, #f59e0b);
  background-size: 200% 100%;
  animation: borderShine 5s linear infinite;
}
@keyframes borderShine {
  0%   { background-position:   0% 50%; }
  100% { background-position: 300% 50%; }
}
.learn-events-head { text-align: center; margin-bottom: 1.4rem; }
.learn-events-tag {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .45rem 1.1rem;
  border-radius: 100px;
  background: linear-gradient(135deg, rgba(245, 158, 11, .15), rgba(236, 72, 153, .12));
  border: 1.5px solid rgba(245, 158, 11, .45);
  color: #b45309;
  font-family: var(--font-en);
  font-size: .7rem;
  font-weight: 900;
  letter-spacing: .22em;
  text-transform: uppercase;
  box-shadow: 0 8px 22px rgba(245, 158, 11, .12);
  margin-bottom: .8rem;
}
.learn-events-tag-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 10px #f59e0b, 0 0 20px rgba(245, 158, 11, .7);
  animation: pulseDot 1.6s ease-in-out infinite;
  flex-shrink: 0;
}
.learn-events-title {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  font-family: var(--font-fa);
  font-size: clamp(1.35rem, 2.6vw, 1.85rem);
  font-weight: 900;
  margin: 0;
  letter-spacing: -.015em;
  line-height: 1.4;
}
.learn-events-title-emoji {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 1.9em; height: 1.9em;
  border-radius: 50%;
  font-size: .95em;
  background:
    radial-gradient(circle at 30% 25%, rgba(255, 255, 255, .9) 0%, transparent 45%),
    linear-gradient(135deg, #fbbf24 0%, #f59e0b 35%, #ec4899 75%, #a855f7 100%);
  box-shadow:
    0 8px 22px rgba(245, 158, 11, .55),
    0 0 0 3px rgba(255, 255, 255, .9),
    0 0 32px rgba(236, 72, 153, .5);
  filter: drop-shadow(0 4px 12px rgba(245, 158, 11, .6));
  animation: eventEmojiFloat 3.5s ease-in-out infinite;
  overflow: hidden;
  isolation: isolate;
}
.learn-events-title-emoji::before {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 2px dashed rgba(255, 255, 255, .65);
  animation: ringSpin 14s linear infinite;
  pointer-events: none;
}
@keyframes eventEmojiFloat {
  0%, 100% { transform: translateY(0) rotate(-6deg) scale(1); }
  25%      { transform: translateY(-3px) rotate(4deg) scale(1.06); }
  50%      { transform: translateY(-6px) rotate(-3deg) scale(1.1); }
  75%      { transform: translateY(-3px) rotate(5deg) scale(1.05); }
}
@keyframes ringSpin { to { transform: rotate(360deg); } }
.learn-events-title-text {
  display: inline-block;
  background: linear-gradient(135deg, #b45309 0%, #ec4899 45%, #7c3aed 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: statNumShine 5s linear infinite;
  filter: drop-shadow(0 2px 6px rgba(236, 72, 153, .2));
}
@keyframes statNumShine { to { background-position: 200% center; } }

.events-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.6rem;
  max-width: 900px;
  margin-inline: auto;
}
.event-card {
  position: relative;
  padding: 1.8rem 1.5rem 1.5rem;
  border-radius: 24px;
  overflow: hidden;
  isolation: isolate;
  background: linear-gradient(160deg, #0d1424 0%, #05080f 100%);
  color: #fff;
  box-shadow:
    0 20px 50px rgba(0, 0, 0, .4),
    0 0 0 1px rgba(245, 158, 11, .3) inset;
  transition: transform .35s cubic-bezier(.4, 0, .2, 1), box-shadow .35s;
}
.event-card::before {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 27px;
  background: conic-gradient(
    from 0deg,
    #f59e0b 0%, #ec4899 18%, #8b5cf6 36%,
    #22d3ee 54%, #f59e0b 72%, #f59e0b 100%);
  animation: snakeRotate 5s linear infinite;
  z-index: 0;
  pointer-events: none;
}
@keyframes snakeRotate { to { transform: rotate(360deg); } }
.event-card::after {
  content: '';
  position: absolute;
  inset: 3px;
  border-radius: 21px;
  background: linear-gradient(160deg, #0d1424 0%, #05080f 100%);
  z-index: 1;
  pointer-events: none;
}
.event-card > * { position: relative; z-index: 2; }
.event-card:hover {
  transform: translateY(-6px);
  box-shadow:
    0 28px 70px rgba(0, 0, 0, .55),
    0 0 40px rgba(245, 158, 11, .3),
    0 0 0 1px rgba(245, 158, 11, .5) inset;
}
.event-chain {
  position: absolute;
  inset: 10px;
  border-radius: 16px;
  pointer-events: none;
  z-index: 3;
  background-image:
    radial-gradient(circle, rgba(245, 158, 11, .85) 0 1.5px, transparent 1.5px 3.5px),
    radial-gradient(circle, rgba(245, 158, 11, .85) 0 1.5px, transparent 1.5px 3.5px);
  background-size: 10px 10px;
  background-position: 0 0, 5px 5px;
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  padding: 2px;
  animation: chainDots 3s linear infinite;
}
@keyframes chainDots {
  from { background-position: 0 0, 5px 5px; }
  to   { background-position: 10px 10px, 15px 15px; }
}
.event-title {
  font-family: var(--font-fa);
  font-size: 1.12rem;
  font-weight: 900;
  letter-spacing: -.01em;
  margin: 0 0 .5rem;
  line-height: 1.5;
  background: linear-gradient(135deg, #fbbf24, #ec4899 50%, #a78bfa 100%);
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: statNumShine 5s linear infinite;
}
.event-desc {
  font-size: .87rem;
  line-height: 1.85;
  color: #cbd5e1;
  margin: 0 0 1.1rem;
  font-weight: 500;
}
.event-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  padding: .75rem 1rem;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(245, 158, 11, .12), rgba(236, 72, 153, .08));
  border: 1px solid rgba(245, 158, 11, .3);
  margin-bottom: 1rem;
}
.event-price-label {
  font-family: var(--font-fa);
  font-size: .74rem;
  font-weight: 700;
  color: #fbbf24;
  white-space: nowrap;
}
.event-price-values {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.event-price-badge {
  display: inline-flex;
  align-items: center;
  padding: .18rem .55rem;
  border-radius: 100px;
  font-family: var(--font-fa);
  font-size: .65rem;
  font-weight: 900;
  color: #fff;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  box-shadow: 0 2px 8px rgba(239, 68, 68, .5), inset 0 1px 0 rgba(255, 255, 255, .3);
  animation: discountPulse 1.8s ease-in-out infinite;
}
@keyframes discountPulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.06); }
}
.event-price-old {
  font-family: var(--font-fa);
  font-size: .8rem;
  font-weight: 700;
  color: #94a3b8;
  text-decoration: line-through;
  text-decoration-color: rgba(239, 68, 68, .7);
  text-decoration-thickness: 1.5px;
}
.event-price-new {
  font-family: var(--font-fa);
  font-size: 1.05rem;
  font-weight: 900;
  background: linear-gradient(135deg, #fbbf24, #fb923c, #f472b6);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: statNumShine 4s linear infinite;
}
.event-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .85rem 1.2rem;
  border-radius: 12px;
  font-family: var(--font-fa);
  font-size: .85rem;
  font-weight: 900;
  cursor: not-allowed;
  background: linear-gradient(135deg, rgba(30, 41, 59, .9), rgba(15, 23, 42, .95));
  border: 1.5px dashed rgba(245, 158, 11, .5);
  color: #fbbf24;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05);
  transition: all .3s;
}
.event-btn:hover {
  border-color: rgba(245, 158, 11, .85);
  background: linear-gradient(135deg, rgba(30, 41, 59, 1), rgba(15, 23, 42, 1));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .08),
    0 0 20px rgba(245, 158, 11, .25);
}
@media (max-width: 860px) {
  .events-grid { grid-template-columns: 1fr; max-width: 480px; }
}
@media (max-width: 640px) {
  .learn-events { padding: 1.4rem 1rem 1.8rem; }
  .learn-events-title { font-size: 1.2rem; gap: .55rem; }
  .event-card { padding: 1.5rem 1.2rem 1.3rem; }
  .event-title { font-size: .98rem; }
  .event-desc { font-size: .8rem; margin-bottom: .9rem; }
}

/* ============================================================
   Course Grid
   ============================================================ */
.learn-courses {
  padding: 2rem 2rem 2.5rem;
  scroll-margin-top: 100px;
}
.learn-courses .section-head { max-width: 720px; margin-inline: auto; margin-bottom: 3.5rem; }
.course-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.6rem; max-width: 1220px; margin-inline: auto; }

.course-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  overflow: hidden;
  isolation: isolate;
  background: rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(22px) saturate(180%);
  -webkit-backdrop-filter: blur(22px) saturate(180%);
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  box-shadow:
    0 8px 32px rgba(31, 38, 135, 0.10),
    0 2px 8px rgba(15, 23, 42, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: transform .4s cubic-bezier(.4,0,.2,1), box-shadow .4s, border-color .4s;
}
.course-card::after {
  content: '';
  position: absolute;
  top: 0; left: -120%;
  width: 60%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.55), transparent);
  transform: skewX(-20deg);
  transition: left .9s cubic-bezier(.4,0,.2,1);
  pointer-events: none;
  z-index: 5;
}
.course-card:hover::after { left: 140%; }
.course-card:hover {
  transform: translateY(-6px);
  border-color: var(--c1, #3b82f6);
  box-shadow: 0 20px 44px rgba(59, 130, 246, .22), 0 0 0 3px rgba(59, 130, 246, .1), inset 0 1px 0 rgba(255, 255, 255, 1);
}
.course-blue   { --c1: #3b82f6; --c2: #7c3aed; }
.course-indigo { --c1: #6366f1; --c2: #4338ca; }
.course-violet { --c1: #8b5cf6; --c2: #6d28d9; }
.course-pink   { --c1: #ec4899; --c2: #be185d; }
.course-cyan   { --c1: #06b6d4; --c2: #0891b2; }
.course-amber  { --c1: #f59e0b; --c2: #d97706; }
.course-green  { --c1: #10b981; --c2: #059669; }

.course-cover {
  position: relative;
  height: 110px;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  background: linear-gradient(135deg, var(--c1), var(--c2));
}
.cover-shapes {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image:
    radial-gradient(circle at 18% 25%, rgba(255,255,255,.28) 0, transparent 22%),
    radial-gradient(circle at 82% 70%, rgba(255,255,255,.18) 0, transparent 18%),
    radial-gradient(circle at 50% 110%, rgba(0,0,0,.22) 0, transparent 55%);
  animation: orbFloat 9s ease-in-out infinite;
}
.course-cover::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.09) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: radial-gradient(ellipse at center, #000 25%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at center, #000 25%, transparent 80%);
  z-index: 1;
}
.course-cover::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 60%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.35), transparent);
  transform: skewX(-20deg);
  animation: buyChipShine 3.6s ease-in-out infinite;
  z-index: 2;
  pointer-events: none;
}
@keyframes buyChipShine {
  0%        { left: -80%; }
  55%, 100% { left: 140%; }
}
.cover-icon {
  position: relative;
  z-index: 3;
  width: 52px; height: 52px;
  display: grid; place-items: center;
  color: #fff;
  filter: drop-shadow(0 6px 16px rgba(0,0,0,.35)) drop-shadow(0 0 22px rgba(255,255,255,.3));
  animation: topicIconFloat 3.4s ease-in-out infinite;
}
@keyframes topicIconFloat {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50%      { transform: translateY(-4px) rotate(2deg); }
}
.cover-icon svg { width: 100%; height: 100%; }
.cover-badge {
  position: absolute;
  top: .55rem; right: .55rem;
  z-index: 4;
  padding: .22rem .6rem;
  border-radius: 100px;
  font-size: .66rem;
  font-weight: 800;
  color: #fff;
  background: rgba(0, 0, 0, .35);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,.35);
  letter-spacing: 0;
}
.cover-badge-soon { background: rgba(245, 158, 11, .85); color: #1a0d2e; border-color: rgba(255,255,255,.6); }

.course-body { display: flex; flex-direction: column; gap: .55rem; padding: 1.1rem 1.1rem 1.2rem; }
.course-title {
  font-family: var(--font-fa);
  font-size: 1.02rem;
  font-weight: 900;
  letter-spacing: -.01em;
  margin: 0;
  background: linear-gradient(135deg, var(--c1), var(--c2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.course-desc { font-size: .8rem; line-height: 1.85; color: var(--text-soft); flex-grow: 1; margin: 0; }
.course-meta { display: flex; flex-wrap: wrap; gap: .35rem; padding-top: .5rem; border-top: 1px dashed rgba(59, 130, 246, .15); }
.course-sessions,
.course-mode {
  display: inline-flex;
  align-items: center;
  gap: .28rem;
  padding: .25rem .6rem;
  border-radius: 100px;
  font-size: .7rem;
  font-weight: 800;
  background: rgba(59, 130, 246, .08);
  border: 1px solid rgba(59, 130, 246, .18);
  color: var(--blue-700);
  font-family: var(--font-fa);
}
.course-sessions svg,
.course-mode svg { width: 11px; height: 11px; flex-shrink: 0; }
.course-mode { background: rgba(16, 185, 129, .08); border-color: rgba(16, 185, 129, .22); color: #047857; }

.course-price {
  display: flex;
  flex-direction: column;
  gap: .2rem;
  padding: .75rem .9rem;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(59,130,246,.10), rgba(245,158,11,.08));
  border: 1px solid rgba(59, 130, 246, .2);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.course-price::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 55%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.6), transparent);
  transform: skewX(-20deg);
  animation: buyChipShine 3.8s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}
.course-price > * { position: relative; z-index: 1; }
.course-price-label { font-family: var(--font-fa); font-size: .68rem; font-weight: 700; color: var(--text-soft); letter-spacing: .02em; line-height: 1; }
.course-price-num {
  font-family: var(--font-fa);
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: -.01em;
  background: linear-gradient(135deg, #1d4ed8, #7c3aed 50%, #ec4899);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: statNumShine 5s linear infinite;
  line-height: 1.25;
}
.course-price-soon { align-items: center; text-align: center; background: linear-gradient(135deg, rgba(245, 158, 11, .12), rgba(245, 158, 11, .06)); border-color: rgba(245, 158, 11, .35); }
.course-price-num-soon { font-size: .9rem; background: linear-gradient(135deg, #b45309, #f59e0b); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; animation: none; }
.course-buy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: .7rem 1rem;
  border-radius: 11px;
  font-family: var(--font-fa);
  font-weight: 900;
  font-size: .84rem;
  color: #fff;
  background: linear-gradient(135deg, var(--c1, #3b82f6), var(--c2, #7c3aed));
  background-size: 200% 200%;
  box-shadow: 0 10px 22px rgba(59, 130, 246, .3), inset 0 1px 0 rgba(255, 255, 255, .25);
  position: relative;
  overflow: hidden;
  transition: transform .3s cubic-bezier(.4,0,.2,1), box-shadow .3s;
}
.course-buy::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 55%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.6), transparent);
  transform: skewX(-20deg);
  animation: buyChipShine 3.2s ease-in-out infinite;
}
.course-buy svg { width: 13px; height: 13px; transition: transform .3s; }
.course-buy:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 16px 34px rgba(59, 130, 246, .45), inset 0 1px 0 rgba(255, 255, 255, .35); }
.course-buy:hover svg { transform: translateX(-3px); }
.course-buy-soon { background: linear-gradient(135deg, #f59e0b, #d97706); box-shadow: 0 10px 22px rgba(245, 158, 11, .3); }
.course-buy-soon:hover { box-shadow: 0 16px 34px rgba(245, 158, 11, .45); }
.course-soon { opacity: .96; }

.course-add {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  width: 100%;
  padding: .6rem 1rem;
  margin-top: .1rem;
  border-radius: 11px;
  border: 1.5px dashed rgba(59, 130, 246, .45);
  background: rgba(59, 130, 246, .06);
  color: var(--blue-700);
  font-family: var(--font-fa);
  font-size: .78rem;
  font-weight: 800;
  cursor: pointer;
  transition: all .28s cubic-bezier(.4,0,.2,1);
  position: relative;
  overflow: hidden;
}
.course-add svg { width: 14px; height: 14px; flex-shrink: 0; transition: transform .3s; }
.course-add:hover {
  background: rgba(59, 130, 246, .12);
  border-color: rgba(59, 130, 246, .85);
  border-style: solid;
  color: #1d4ed8;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(59, 130, 246, .18);
}
.course-add:hover svg { transform: scale(1.15) rotate(-8deg); }
.course-add:active { transform: translateY(0) scale(.98); }

/* ============================================================
   Online Note
   ============================================================ */
.learn-online-note {
  padding: 1.5rem 2rem 3.5rem;
}
.online-note-card {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 1.8rem 2rem;
  border-radius: 24px;
  overflow: hidden;
  isolation: isolate;
  max-width: 1220px;
  margin-inline: auto;
  background:
    radial-gradient(ellipse 60% 120% at 5% 50%,  rgba(16, 185, 129, .28), transparent 65%),
    radial-gradient(ellipse 60% 120% at 95% 50%, rgba(6, 182, 212, .22), transparent 65%),
    linear-gradient(135deg, #0a1a2e 0%, #06101f 55%, #0a1a2e 100%);
  border: 1.5px solid rgba(52, 211, 153, .4);
  box-shadow: 0 20px 55px rgba(0, 0, 0, .4), 0 0 60px rgba(16, 185, 129, .12), inset 0 1px 0 rgba(255, 255, 255, .06);
  color: #fff;
}
.online-note-card::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 26px;
  padding: 2px;
  background: linear-gradient(120deg, #10b981, #06b6d4, #3b82f6, #8b5cf6, #ec4899, #10b981);
  background-size: 300% 100%;
  animation: onlineNoteBorderFlow 6s linear infinite;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  z-index: 0;
}
@keyframes onlineNoteBorderFlow {
  0%   { background-position: 0% 50%; }
  100% { background-position: 300% 50%; }
}
.online-note-card::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 60%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .18) 50%, transparent);
  transform: skewX(-20deg);
  animation: onlineNoteShine 4.5s ease-in-out infinite;
  pointer-events: none;
  z-index: 2;
}
@keyframes onlineNoteShine {
  0%   { left: -100%; }
  55%, 100% { left: 160%; }
}
.online-note-card > * { position: relative; z-index: 3; }
.online-note-particles { position: absolute; inset: 0; pointer-events: none; z-index: 1; overflow: hidden; }
.online-note-particles span {
  position: absolute;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 10px #10b981, 0 0 20px rgba(16, 185, 129, .5);
  opacity: .55;
  animation: onlineNoteParticleFloat 9s ease-in-out infinite;
}
.online-note-particles span:nth-child(1)  { top: 15%; left: 8%;  animation-delay: 0s;    background: #06b6d4; box-shadow: 0 0 10px #06b6d4; }
.online-note-particles span:nth-child(2)  { top: 75%; left: 12%; animation-delay: -1.2s; }
.online-note-particles span:nth-child(3)  { top: 30%; left: 25%; animation-delay: -2.4s; background: #3b82f6; box-shadow: 0 0 10px #3b82f6; }
.online-note-particles span:nth-child(4)  { top: 80%; left: 38%; animation-delay: -3.6s; }
.online-note-particles span:nth-child(5)  { top: 20%; left: 55%; animation-delay: -4.8s; background: #8b5cf6; box-shadow: 0 0 10px #8b5cf6; }
.online-note-particles span:nth-child(6)  { top: 65%; left: 68%; animation-delay: -6s;   }
.online-note-particles span:nth-child(7)  { top: 40%; left: 80%; animation-delay: -1.8s; background: #ec4899; box-shadow: 0 0 10px #ec4899; }
.online-note-particles span:nth-child(8)  { top: 10%; left: 90%; animation-delay: -3s;   }
.online-note-particles span:nth-child(9)  { top: 85%; left: 92%; animation-delay: -4.2s; background: #06b6d4; box-shadow: 0 0 10px #06b6d4; }
.online-note-particles span:nth-child(10) { top: 50%; left: 45%; animation-delay: -5.4s; }
.online-note-particles span:nth-child(11) { top: 5%;  left: 35%; animation-delay: -.6s;  background: #3b82f6; box-shadow: 0 0 10px #3b82f6; }
.online-note-particles span:nth-child(12) { top: 92%; left: 60%; animation-delay: -7.2s; }
@keyframes onlineNoteParticleFloat {
  0%, 100% { transform: translateY(0) scale(1);   opacity: .45; }
  50%      { transform: translateY(-14px) scale(1.4); opacity: .95; }
}
.online-note-scanline {
  position: absolute;
  left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, rgba(16, 185, 129, .2) 20%, rgba(16, 185, 129, 1) 50%, rgba(16, 185, 129, .2) 80%, transparent 100%);
  filter: blur(1px);
  box-shadow: 0 0 14px rgba(16, 185, 129, .8), 0 0 28px rgba(16, 185, 129, .5);
  pointer-events: none;
  z-index: 2;
  animation: onlineNoteScan 5s linear infinite;
  opacity: .7;
}
@keyframes onlineNoteScan {
  0%   { top: 0%;   opacity: 0; }
  10%, 90% { opacity: .8; }
  100% { top: 100%; opacity: 0; }
}
.online-note-icon {
  position: relative;
  flex-shrink: 0;
  width: 72px; height: 72px;
  border-radius: 22px;
  display: grid; place-items: center;
  font-size: 2rem;
  background: linear-gradient(135deg, #10b981, #06b6d4);
  box-shadow: 0 14px 32px rgba(16, 185, 129, .45), 0 0 32px rgba(16, 185, 129, .25), inset 0 1px 0 rgba(255, 255, 255, .4);
  animation: onlineNoteIconPulse 3s ease-in-out infinite;
  isolation: isolate;
  z-index: 4;
}
.online-note-icon-emoji {
  display: inline-block;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .25));
  animation: onlineNoteEmojiSpin 6s ease-in-out infinite;
}
@keyframes onlineNoteEmojiSpin {
  0%, 100% { transform: rotate(-6deg) scale(1); }
  50%      { transform: rotate(8deg) scale(1.1); }
}
@keyframes onlineNoteIconPulse {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50%      { transform: translateY(-5px) rotate(-3deg); }
}
.online-note-icon-ring {
  position: absolute;
  inset: -6px;
  border-radius: 28px;
  border: 2px solid rgba(16, 185, 129, .65);
  animation: onlineNoteIconRing 2.6s ease-out infinite;
  pointer-events: none;
  box-shadow: 0 0 16px rgba(16, 185, 129, .6);
}
.online-note-icon-ring-2 { animation-delay: -1.3s; border-color: rgba(6, 182, 212, .65); box-shadow: 0 0 16px rgba(6, 182, 212, .6); }
@keyframes onlineNoteIconRing {
  0%   { opacity: .85; transform: scale(.9); }
  100% { opacity: 0;  transform: scale(1.5); }
}
.online-note-body { flex: 1; min-width: 0; max-width: 900px; }
.online-note-badge {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  padding: .35rem .95rem;
  margin-bottom: .75rem;
  border-radius: 100px;
  background: linear-gradient(135deg, rgba(16, 185, 129, .22), rgba(6, 182, 212, .15));
  border: 1px solid rgba(52, 211, 153, .55);
  box-shadow: 0 0 16px rgba(16, 185, 129, .3), inset 0 0 12px rgba(52, 211, 153, .1);
  font-family: var(--font-en);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .18em;
  position: relative;
  overflow: hidden;
}
.online-note-badge::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 45%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(110, 231, 183, .55) 50%, transparent);
  transform: skewX(-20deg);
  animation: onlineNoteShine 3.2s ease-in-out infinite;
  pointer-events: none;
}
.online-note-badge-text {
  position: relative;
  display: inline-block;
  background: linear-gradient(90deg, #6ee7b7 0%, #22d3ee 30%, #6ee7b7 60%, #34d399 100%);
  background-size: 250% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: liveBadgeShine 3s linear infinite;
  filter: drop-shadow(0 0 6px rgba(52, 211, 153, .55));
  z-index: 1;
}
@keyframes liveBadgeShine {
  0%   { background-position:   0% center; }
  100% { background-position: 250% center; }
}
.online-note-live-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 8px #ef4444, 0 0 16px rgba(239, 68, 68, .85), 0 0 28px rgba(239, 68, 68, .5);
  animation: onlineNoteDotPulse 1.4s ease-in-out infinite;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}
@keyframes onlineNoteDotPulse {
  0%, 100% { transform: scale(1);   opacity: 1; }
  50%      { transform: scale(1.5); opacity: .55; }
}
.online-note-body h3 {
  font-family: var(--font-fa);
  font-size: 1.2rem;
  font-weight: 900;
  margin-bottom: .5rem;
  background: linear-gradient(135deg, #6ee7b7 0%, #22d3ee 60%, #a5f3fc 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 10px rgba(52, 211, 153, .35));
  letter-spacing: -.01em;
  line-height: 1.4;
}
.online-note-body p { font-size: .92rem; line-height: 1.95; color: #e2e8f0; margin-bottom: .9rem; font-weight: 500; }
.online-note-body b {
  font-weight: 900;
  background: linear-gradient(135deg, #6ee7b7, #34d399);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 6px rgba(52, 211, 153, .4));
}
.online-note-features { display: flex; flex-wrap: wrap; gap: .5rem; }
.online-note-feature {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .38rem .85rem;
  border-radius: 100px;
  font-family: var(--font-fa);
  font-size: .76rem;
  font-weight: 800;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .22);
  color: #ffffff;
  backdrop-filter: blur(8px);
  transition: transform .25s, box-shadow .25s, background .25s, border-color .25s;
}
.online-note-feature svg { color: #6ee7b7; flex-shrink: 0; filter: drop-shadow(0 0 4px rgba(52, 211, 153, .6)); }
.online-note-feature:hover {
  transform: translateY(-2px);
  background: rgba(52, 211, 153, .18);
  border-color: rgba(52, 211, 153, .45);
  box-shadow: 0 8px 18px rgba(52, 211, 153, .3);
}
@media (max-width: 640px) {
  .online-note-card { flex-direction: column; text-align: center; padding: 1.6rem 1.2rem; gap: 1rem; }
  .online-note-body { text-align: center; max-width: 100%; }
  .online-note-features { justify-content: center; }
  .online-note-icon { width: 64px; height: 64px; font-size: 1.75rem; }
}

/* ============================================================
   Guest Lock — قفل شیشه‌ای
   ============================================================ */
body.guest-mode .course-add {
  position: relative;
  overflow: visible !important;
  cursor: pointer;
  background: linear-gradient(135deg, rgba(30, 41, 59, .85), rgba(15, 23, 42, .9)) !important;
  border: 1.5px dashed rgba(96, 165, 250, .55) !important;
  color: #cbd5e1 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .18), inset 0 1px 0 rgba(255, 255, 255, .04);
}
body.guest-mode .course-add svg { color: #94a3b8 !important; opacity: .9; }
body.guest-mode .course-add::before {
  content: '';
  position: absolute;
  inset: -1.5px;
  border-radius: inherit;
  border: 1.5px dashed rgba(96, 165, 250, .35);
  pointer-events: none;
  animation: chainDash 14s linear infinite;
}
@keyframes chainDash {
  to { background-position: 200px 0; }
}
body.guest-mode .course-add::after {
  content: '🔒';
  position: absolute;
  top: -16px;
  left: -16px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  font-size: 1.35rem;
  background: transparent;
  border: none;
  box-shadow: none;
  filter:
    drop-shadow(0 0 6px rgba(251, 191, 36, .9))
    drop-shadow(0 0 16px rgba(251, 146, 60, .65))
    drop-shadow(0 0 28px rgba(251, 146, 60, .35));
  z-index: 5;
  pointer-events: none;
  animation: lockFloat 2.6s ease-in-out infinite;
  transform-origin: 65% 60%;
}
@keyframes lockFloat {
  0%, 100% { transform: translateY(0) rotate(-8deg) scale(1); }
  25%      { transform: translateY(-3px) rotate(6deg) scale(1.08); }
  50%      { transform: translateY(-6px) rotate(-4deg) scale(1.12); }
  75%      { transform: translateY(-3px) rotate(4deg) scale(1.06); }
}
body.guest-mode .course-add:hover {
  background: linear-gradient(135deg, rgba(30, 41, 59, .95), rgba(15, 23, 42, 1)) !important;
  border-color: rgba(147, 197, 253, .85) !important;
  color: #e2e8f0 !important;
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(59, 130, 246, .35), 0 0 22px rgba(96, 165, 250, .22);
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1024px) {
  .learn-hero { grid-template-columns: 1fr; gap: 3rem; text-align: center; }
  .learn-hero-content { margin-inline: auto; }
  .learn-hero-sub { margin-inline: auto; }
  .learn-hero-actions { justify-content: center; }
  .learn-hero-stats { margin-inline: auto; }
  .learn-hero-visual { min-height: 480px; max-width: 500px; margin-inline: auto; width: 100%; }
  .course-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 860px) {
  .course-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .learn-hero { padding: 2rem 1rem 3rem; }
  .learn-hero-title { font-size: 1.6rem; }
  .learn-hero-sub { font-size: .94rem; }
  .learn-hero-stats { grid-template-columns: 1fr; gap: .65rem; }
  .learn-code-float { font-size: .72rem; }
  .learn-courses { padding: 4rem 1rem 2rem; }
  .course-grid { grid-template-columns: 1fr; gap: 1.2rem; }
  .course-cover { height: 100px; }
  .course-price-num { font-size: 1.05rem; }
}
/* ============================================================
   COVER BADGE POPULAR — «پرطرفدار» مثل «سطح X · Y» ولی سمت چپ
   ============================================================ */
.cover-badge-popular {
  position: absolute;
  top: .55rem;
  left: .55rem;
  right: auto;
  z-index: 4;
  padding: .22rem .6rem;
  border-radius: 100px;
  font-family: var(--font-fa);
  font-size: .66rem;
  font-weight: 800;
  color: #fff;
  background: rgba(0, 0, 0, .35);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, .35);
  letter-spacing: 0;
  line-height: 1.4;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
/* ============================================================
   ✅ CLICKABLE COURSE CARDS
   ============================================================ */
.course-card {
  position: relative;
}

.course-title-link {
  color: inherit;
  text-decoration: none;
  display: inline;
}

.course-title-link::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
  cursor: pointer;
}

.course-card .course-add,
.course-card .buy-chip,
.course-card .status-chip {
  position: relative;
  z-index: 2;
}

.course-card:hover .course-title-link {
  filter: brightness(1.15);
}