/* Hero-only styles: header/footer aur baaki home sections ko touch nahi karta. */
.learning-hero {
  --hero-navy: #102b55;
  --hero-blue: #1768d6;
  --hero-yellow: #f6c51b;
  position: relative;
  display: grid;
  grid-template-columns: minmax(290px, .85fr) minmax(530px, 1.15fr);
  gap: clamp(30px, 5vw, 80px);
  align-items: center;
  min-height: 610px;
  padding: clamp(62px, 7vw, 96px) max(5vw, 28px) 74px;
  /* Live-search panel next section ke upar float karega; isliye is hero mein clipping allowed nahi hai. */
  overflow: visible;
  isolation: isolate;
  z-index: 5;
  background: #f4f8ff;
  border-bottom: 1px solid #d6e3f7;
}

/* Background image ke bina depth dene ke liye halka blueprint layer. */
.learning-hero::before,
.learning-hero::after { position: absolute; inset: 0; z-index: -2; content: ""; pointer-events: none; }
.learning-hero::before { background: linear-gradient(120deg, rgba(218, 236, 255, .92), rgba(248, 249, 255, .96) 50%, rgba(236, 230, 255, .88)); }
.learning-hero::after { z-index: -1; background-image: linear-gradient(rgba(32, 93, 188, .055) 1px, transparent 1px), linear-gradient(90deg, rgba(32, 93, 188, .055) 1px, transparent 1px); background-size: 28px 28px; mask-image: linear-gradient(to right, transparent, #000 20%, #000 85%, transparent); }

.learning-hero__blueprint { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; fill: none; stroke: rgba(32, 93, 188, .17); stroke-width: 1; pointer-events: none; }
.learning-hero__blueprint circle { stroke: rgba(88, 67, 181, .14); stroke-width: 2; }
.learning-hero__content { position: relative; z-index: 2; max-width: 650px; }
.learning-hero__eyebrow { display: inline-flex; align-items: center; gap: 9px; margin: 0 0 17px; color: var(--hero-navy); font-family: "Afacad", ui-sans-serif, system-ui, sans-serif; font-size: .88rem; font-weight: 700; letter-spacing: .13em; text-transform: uppercase; }
.learning-hero__eyebrow::before { width: 26px; height: 4px; content: ""; background: var(--hero-yellow); border-radius: 99px; }
.learning-hero h1 { max-width: 650px; margin: 0; color: var(--hero-navy); font-family: Sora, ui-sans-serif, system-ui, sans-serif; font-size: clamp(3rem, 5vw, 5.3rem); letter-spacing: -.052em; line-height: .98; }
.learning-hero__intro { max-width: 570px; margin: 20px 0 28px; color: #536987; font-family: "Nunito Sans", ui-sans-serif, system-ui, sans-serif; font-size: clamp(1rem, 1.4vw, 1.12rem); line-height: 1.65; }
.learning-hero__search { max-width: 590px; }
.learning-hero__search button { display: grid; width: 49px; min-width: 49px; min-height: 49px; padding: 0; place-items: center; }
.learning-hero__search button i { pointer-events: none; }

/* Suggestion panel search ke neeche float karega aur popular-search chips ke upar render hoga. */
.learning-hero__search { z-index: 12; }
.learning-hero__search:focus-within { z-index: 14; }
.learning-hero__search .suggestions-list {
  position: absolute;
  left: 0;
  width: 100%;
  top: calc(100% + 10px);
  z-index: 20;
  max-height: min(310px, 46vh);
  overflow-y: auto;
  border-radius: 14px;
  box-shadow: 0 18px 34px rgba(25, 65, 128, .18);
}

/* Chips ko search bar se breathing room milta hai, lekin suggestions open hone par woh overlay ke peeche rehte hain. */
.learning-hero__quick-links { position: relative; z-index: 1; margin-top: 26px; }

/* Next section normal page flow mein rahega, lekin open suggestions uske upar dikhengi. */
.learning-hero + .university-section { position: relative; z-index: 1; }

/* Desktop par route-map, mobile par isi ka vertical version use hoga. */
.learning-map { position: relative; z-index: 2; display: grid; grid-template: 1fr 1fr / 1fr 1fr; gap: clamp(48px, 7vw, 94px) clamp(46px, 8vw, 110px); min-height: 340px; padding: 20px; }
.learning-map__routes { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; overflow: visible; fill: none; }
.learning-map__route-line { stroke: #2871dc; stroke-width: 3; stroke-linecap: round; stroke-dasharray: 11 9; opacity: .84; }
.learning-map__core { position: absolute; z-index: 2; top: 50%; left: 50%; display: grid; width: 82px; height: 82px; color: white; background: var(--hero-navy); border: 5px solid #fff; border-radius: 50%; box-shadow: 0 0 0 6px rgba(246, 197, 27, .78), 0 0 0 17px rgba(246, 197, 27, .13); font-family: "Afacad", ui-sans-serif, system-ui, sans-serif; font-size: 1.1rem; font-weight: 700; line-height: .95; place-items: center; text-align: center; transform: translate(-50%, -50%); }
.learning-route { position: relative; display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 13px; align-items: center; min-width: 0; color: var(--hero-navy); text-decoration: none; transition: transform 200ms ease, color 200ms ease; }
.learning-route:hover, .learning-route:focus-visible { color: var(--hero-blue); outline: none; transform: translateY(-5px); }
.learning-route:focus-visible::after { position: absolute; inset: -10px; content: ""; border: 2px solid var(--hero-blue); border-radius: 10px; }
.learning-route__icon { position: relative; display: grid; width: 52px; height: 52px; color: var(--hero-blue); background: rgba(255,255,255,.74); border: 2px solid currentColor; border-radius: 16px; font-size: 1.36rem; place-items: center; box-shadow: 0 8px 20px rgba(26, 81, 161, .12); }
.learning-route--school { grid-area: 1 / 1; }
.learning-route--university { grid-area: 1 / 2; }
.learning-route--solved { grid-area: 2 / 1; }
.learning-route--tools { grid-area: 2 / 2; }
.learning-route--school { cursor: default; opacity: .88; }
.learning-route--school .learning-route__icon { color: #c38b00; }
.learning-route strong, .learning-route small { display: block; }
.learning-route strong { font-family: Outfit, ui-sans-serif, system-ui, sans-serif; font-size: clamp(1.28rem, 2vw, 1.72rem); letter-spacing: -.035em; line-height: 1; }
.learning-route small { margin-top: 7px; color: #5e7291; font-family: "Nunito Sans", ui-sans-serif, system-ui, sans-serif; font-size: .78rem; font-weight: 700; }
.learning-route em { color: #9a6b00; font-size: .7rem; font-style: normal; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.learning-route__arrow { padding: 10px 0 10px 5px; color: var(--hero-blue); font-size: 1rem; transition: transform 180ms ease; }
.learning-route:hover .learning-route__arrow, .learning-route:focus-visible .learning-route__arrow { transform: translateX(5px); }
.learning-route--solved .learning-route__icon { color: #154aa8; }
.learning-route--solved .learning-route__icon b { position: absolute; right: -20px; bottom: -9px; padding: 3px 6px; color: #173667; background: var(--hero-yellow); border-radius: 4px; box-shadow: 0 2px 0 #ce9600; font-size: .54rem; font-weight: 900; letter-spacing: .04em; text-transform: uppercase; transform: rotate(-9deg); }

/* Flow dots lightweight CSS animation hain; JS har frame par position calculate nahi karta. */
.learning-map__flow { position: absolute; z-index: 1; display: flex; gap: 16px; pointer-events: none; }
.learning-map__flow i { width: 8px; height: 8px; background: var(--hero-yellow); border: 2px solid white; border-radius: 50%; box-shadow: 0 0 0 2px rgba(39,113,220,.22); animation: learning-flow-pulse 2.6s ease-in-out infinite; }
.learning-map__flow i:nth-child(2) { animation-delay: .35s; }.learning-map__flow i:nth-child(3) { animation-delay: .7s; }
.learning-map__flow--school { top: 31%; left: 25%; transform: rotate(31deg); }.learning-map__flow--university { top: 31%; right: 25%; transform: rotate(-31deg); }.learning-map__flow--solved { bottom: 30%; left: 25%; transform: rotate(-31deg); }.learning-map__flow--tools { right: 25%; bottom: 30%; transform: rotate(31deg); }
.learning-hero__scroll-cue { position: absolute; bottom: 24px; left: 50%; z-index: 3; display: grid; width: 38px; height: 38px; color: var(--hero-blue); border: 1px solid #bad2f7; border-radius: 50%; place-items: center; text-decoration: none; transform: translateX(-50%); transition: background 180ms ease, color 180ms ease; animation: scroll-cue-bob 1.8s ease-in-out infinite; }
.learning-hero__scroll-cue:hover, .learning-hero__scroll-cue:focus-visible { color: #fff; background: var(--hero-blue); outline: none; }
.hero-motion-paused .learning-map__flow i,
.hero-motion-paused .learning-hero__scroll-cue { animation-play-state: paused; }

@keyframes learning-flow-pulse { 0%, 100% { opacity: .24; transform: translateX(-11px) scale(.65); } 48% { opacity: 1; transform: translateX(13px) scale(1); } }
@keyframes scroll-cue-bob { 0%, 100% { transform: translateX(-50%) translateY(0); } 50% { transform: translateX(-50%) translateY(6px); } }

@media (max-width: 920px) { .learning-hero { grid-template-columns: 1fr; gap: 42px; min-height: auto; padding-bottom: 85px; }.learning-hero__content { max-width: 720px; }.learning-map { width: min(680px, 100%); min-height: 315px; justify-self: center; }.learning-hero__blueprint { opacity: .72; } }
/* Mobile mein bhi same arrow-map rahega; sirf har element proportional compact hoga. */
@media (max-width: 620px) {
  .learning-hero { padding: 54px 20px 72px; }
  .learning-hero::after { background-size: 22px 22px; }
  .learning-hero h1 { font-size: clamp(2.7rem, 14vw, 4rem); }
  .learning-hero__intro { margin-bottom: 23px; }
  .learning-hero__quick-links { grid-template-columns: 1fr; gap: 7px; }

  /* Timeline/list mode nahi: four routes aur centre hub desktop jaise hi visible rahenge. */
  .learning-map {
    grid-template: repeat(2, minmax(0, 1fr)) / repeat(2, minmax(0, 1fr));
    gap: clamp(25px, 8vw, 48px) clamp(18px, 7vw, 42px);
    min-height: clamp(285px, 82vw, 365px);
    padding: 8px;
  }

  .learning-map__routes { display: block; }
  .learning-map__flow { display: flex; }

  .learning-map__core {
    width: clamp(56px, 18vw, 72px);
    height: clamp(56px, 18vw, 72px);
    border-width: 3px;
    box-shadow: 0 0 0 4px rgba(246, 197, 27, .78), 0 0 0 11px rgba(246, 197, 27, .13);
    font-size: clamp(.78rem, 3.4vw, .98rem);
  }

  .learning-route {
    grid-template-columns: clamp(36px, 12vw, 45px) minmax(0, 1fr) auto;
    gap: 7px;
    align-self: center;
    min-height: 45px;
  }

  .learning-route--school,
  .learning-route--university,
  .learning-route--solved,
  .learning-route--tools { grid-area: auto; }

  .learning-route--school { grid-area: 1 / 1; }
  .learning-route--university { grid-area: 1 / 2; }
  .learning-route--solved { grid-area: 2 / 1; }
  .learning-route--tools { grid-area: 2 / 2; }

  .learning-route__icon {
    width: clamp(36px, 12vw, 45px);
    height: clamp(36px, 12vw, 45px);
    border-radius: 12px;
    font-size: clamp(.92rem, 4vw, 1.12rem);
  }

  .learning-route strong { font-size: clamp(.94rem, 4.3vw, 1.2rem); line-height: 1; }
  .learning-route small { margin-top: 4px; font-size: clamp(.57rem, 2.6vw, .7rem); white-space: nowrap; }
  .learning-route__arrow { padding: 7px 0; font-size: clamp(.68rem, 3vw, .9rem); }
  .learning-route em { position: absolute; right: 0; bottom: -12px; font-size: clamp(.46rem, 2vw, .58rem); }
  .learning-route--solved .learning-route__icon b { right: -16px; bottom: -8px; padding: 2px 4px; font-size: .43rem; }

  /* Dots map ke same curve par compact size mein flow karte rahenge. */
  .learning-map__flow { gap: 8px; }
  .learning-map__flow i { width: 5px; height: 5px; border-width: 1px; }
  .learning-map__flow--school { top: 31%; left: 25%; }
  .learning-map__flow--university { top: 31%; right: 25%; }
  .learning-map__flow--solved { bottom: 30%; left: 25%; }
  .learning-map__flow--tools { right: 25%; bottom: 30%; }

  .learning-hero__scroll-cue { bottom: 16px; }
}
@media (prefers-reduced-motion: reduce) { .learning-route, .learning-route__arrow, .learning-map__flow i, .learning-hero__scroll-cue { transition: none !important; animation: none !important; } }
