/* ============================================================
   PathtoAI Academy — Landing Page
   Cosmic dark theme · Bricolage Grotesque + DM Sans
   ============================================================ */

:root {
  --bg:     #06090f;
  --bg-1:   #0a101c;
  --bg-2:   #0f1729;
  --card:   rgba(14, 22, 40, 0.7);
  --line:   rgba(100, 160, 255, 0.16);
  --text:   #e4edff;
  --text-2: #94a8cc;
  --a1:     #4ecdc4;
  --a2:     #ffd166;
  --a3:     #6e8efb;
  --a4:     #ff6b6b;
  --a5:     #a78bfa;
  --grad:   linear-gradient(135deg, var(--a1), var(--a3), var(--a5));
  --display: "Bricolage Grotesque", sans-serif;
  --body:    "DM Sans", sans-serif;
  --ease:    cubic-bezier(.22, 1, .36, 1);
}

/* ─── Light Theme ─── */
[data-theme="light"] {
  --bg:     #f5f7fb;
  --bg-1:   #edf0f7;
  --bg-2:   #e4e8f2;
  --card:   rgba(255, 255, 255, 0.82);
  --line:   rgba(60, 80, 130, 0.14);
  --text:   #1a1e2e;
  --text-2: #555e75;
  --a1:     #1ba69c;
  --a2:     #d4930a;
  --a3:     #4a6cf7;
  --a4:     #e04545;
  --a5:     #7c5ccf;
  --grad:   linear-gradient(135deg, var(--a1), var(--a3), var(--a5));
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--body);
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  transition: background 0.5s, color 0.5s;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -48px;
  z-index: 300;
  background: #ffffff;
  color: #111827;
  padding: 0.55rem 0.8rem;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}
.skip-link:focus {
  top: 1rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ─── Utility ─── */
.wrap {
  width: min(1180px, calc(100% - 2.5rem));
  margin-inline: auto;
}

.gradient-text {
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-label {
  font-family: var(--display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--a1);
  margin-bottom: 1rem;
}

/* ─── Scroll Reveal ─── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}
.reveal:nth-child(2) { transition-delay: 0.08s; }
.reveal:nth-child(3) { transition-delay: 0.16s; }
.reveal:nth-child(4) { transition-delay: 0.24s; }
.reveal:nth-child(5) { transition-delay: 0.32s; }
.reveal:nth-child(6) { transition-delay: 0.40s; }

/* ─── Ambient Background ─── */
.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(100px);
  z-index: -2;
  pointer-events: none;
  animation: drift 14s ease-in-out infinite alternate;
  transition: opacity 0.5s;
}
.bg-glow--1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(78, 205, 196, 0.18), transparent 70%);
  top: -180px; left: -120px;
}
.bg-glow--2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(110, 142, 251, 0.16), transparent 70%);
  top: 35%; right: -160px;
  animation-delay: -5s;
}
.bg-glow--3 {
  width: 550px; height: 550px;
  background: radial-gradient(circle, rgba(167, 139, 250, 0.14), transparent 70%);
  bottom: -100px; left: 30%;
  animation-delay: -9s;
}

[data-theme="light"] .bg-glow { opacity: 0.35; }
[data-theme="light"] #starfield { opacity: 0; }

@keyframes drift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(30px, -20px) scale(1.08); }
}

#starfield {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

/* ─── Navigation ─── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  transition: background 0.4s, box-shadow 0.4s, min-height 0.4s;
  background: transparent;
}
.nav--scrolled {
  background: rgba(6, 9, 15, 0.85);
  backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 var(--line);
}
[data-theme="light"] .nav--scrolled {
  background: rgba(245, 247, 251, 0.88);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  gap: 1rem;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.nav__logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: 10px;
  background: var(--grad);
  color: #06090f;
  font-weight: 800;
  font-size: 1rem;
  flex-shrink: 0;
}

.nav__links {
  display: flex;
  gap: 2rem;
}
.nav__links a {
  color: var(--text-2);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.25s;
  position: relative;
}
.nav__links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 2px;
  background: var(--a1);
  transition: width 0.3s var(--ease);
}
.nav__links a:hover { color: var(--text); }
.nav__links a:hover::after { width: 100%; }

.nav__cta {
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  background: var(--grad);
  padding: 0.55rem 1.2rem;
  border-radius: 999px;
  text-decoration: none;
  transition: transform 0.25s, box-shadow 0.25s;
}
.nav__cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(78, 205, 196, 0.3);
}

/* ─── Theme Toggle ─── */
.theme-toggle {
  width: 42px; height: 42px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  transition: border-color 0.3s, transform 0.25s, background 0.3s;
  flex-shrink: 0;
}
.theme-toggle:hover {
  border-color: var(--a1);
  transform: scale(1.08);
}
.theme-toggle .icon-sun,
.theme-toggle .icon-moon { pointer-events: none; }
[data-theme="light"] .theme-toggle .icon-sun  { display: none; }
[data-theme="light"] .theme-toggle .icon-moon { display: inline; }
:root .theme-toggle .icon-sun  { display: inline; }
:root .theme-toggle .icon-moon { display: none; }
[data-theme="light"] .theme-toggle .icon-sun  { display: none; }
[data-theme="light"] .theme-toggle .icon-moon { display: inline; }

.nav__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav__burger span {
  width: 24px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: 0.3s;
}

/* ─── HERO ─── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  padding: 7rem 0 4rem;
}
.hero__inner {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
}

.hero__tag {
  font-family: var(--display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--a2);
  padding: 0.4rem 0.9rem;
  border: 1px solid rgba(255, 209, 102, 0.3);
  border-radius: 999px;
  width: fit-content;
}

.hero__title {
  font-family: var(--display);
  font-size: clamp(2.6rem, 6vw, 4.8rem);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.02em;
  max-width: 18ch;
}
.hero__title em {
  font-style: italic;
  color: var(--a2);
  -webkit-text-fill-color: var(--a2);
}

[data-theme="light"] .hero__tag {
  border-color: rgba(212, 147, 10, 0.35);
}

.hero__sub {
  font-size: 1.12rem;
  color: var(--text-2);
  max-width: 58ch;
  line-height: 1.7;
}

.hero__actions {
  display: flex;
  gap: 0.9rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.8rem 1.6rem;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.25s var(--ease), box-shadow 0.25s;
  cursor: pointer;
  border: none;
  font-family: var(--body);
}
.btn--primary {
  background: var(--grad);
  color: var(--bg);
}
.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(78, 205, 196, 0.3);
}
.btn--outline {
  border: 1px solid var(--line);
  color: var(--text);
  background: transparent;
}
.btn--outline:hover {
  border-color: var(--a1);
  transform: translateY(-2px);
}

/* Stats */
.hero__stats {
  display: flex;
  gap: 2.4rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}
.stat {
  display: flex;
  flex-direction: column;
}
.stat__num {
  font-family: var(--display);
  font-size: 2.2rem;
  font-weight: 800;
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.stat span {
  font-size: 0.82rem;
  color: var(--text-2);
  margin-top: 0.15rem;
}

/* Scroll indicator */
.hero__scroll {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
}
.hero__scroll span {
  display: block;
  width: 22px; height: 36px;
  border: 2px solid var(--line);
  border-radius: 999px;
  position: relative;
}
.hero__scroll span::after {
  content: '';
  width: 3px; height: 8px;
  background: var(--a1);
  border-radius: 999px;
  position: absolute;
  top: 6px; left: 50%;
  transform: translateX(-50%);
  animation: scrollDot 1.8s ease-in-out infinite;
}
@keyframes scrollDot {
  0%, 100% { opacity: 1; transform: translateX(-50%) translateY(0); }
  60%      { opacity: 0; transform: translateX(-50%) translateY(14px); }
}

/* ─── ABOUT ─── */
.about {
  padding: 6rem 0;
  position: relative;
}
.about::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}

.about__grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 4rem;
  align-items: start;
}

.about__text h2 {
  font-family: var(--display);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  line-height: 1.18;
  margin-bottom: 1.2rem;
}
.about__text p {
  color: var(--text-2);
  line-height: 1.75;
  margin-bottom: 1rem;
  font-size: 0.98rem;
}

.about__highlights {
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
}
.highlight {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1.1rem 1.2rem;
  border-radius: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  transition: border-color 0.3s, transform 0.3s var(--ease);
}
.highlight:hover {
  border-color: var(--a1);
  transform: translateX(6px);
}
.highlight__icon {
  font-size: 1.3rem;
  line-height: 1;
  flex-shrink: 0;
  width: 40px; height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(78, 205, 196, 0.12);
  color: var(--a1);
}
.highlight strong {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 0.2rem;
}
.highlight span {
  font-size: 0.84rem;
  color: var(--text-2);
}

/* ─── MODULES ─── */
.modules {
  padding: 6rem 0;
  position: relative;
}
.modules::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}

.modules__heading {
  font-family: var(--display);
  font-size: clamp(1.6rem, 3.5vw, 2.6rem);
  font-weight: 800;
  margin-bottom: 3rem;
}

.modules__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.8rem;
}

.mod-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 2rem 1.8rem;
  border-radius: 20px;
  background: var(--card);
  border: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  transition: border-color 0.4s, transform 0.4s var(--ease), box-shadow 0.4s;
}
.mod-card:hover {
  border-color: rgba(78, 205, 196, 0.5);
  transform: translateY(-6px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}
[data-theme="light"] .mod-card:hover {
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}

/* Glow blob inside cards */
.mod-card__glow {
  position: absolute;
  width: 200px; height: 200px;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.25;
  pointer-events: none;
  transition: opacity 0.4s;
}
.mod-card:hover .mod-card__glow { opacity: 0.5; }
.mod-card__glow--1 {
  background: var(--a1);
  top: -80px; right: -60px;
}
.mod-card__glow--2 {
  background: var(--a3);
  top: -80px; right: -60px;
}
.mod-card__glow--3 {
  background: var(--a5);
  top: -80px; right: -60px;
}
.mod-card__glow--4 {
  background: var(--a2);
  top: -80px; right: -60px;
}

.mod-card__num {
  font-family: var(--display);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0.3;
}

.mod-card h3 {
  font-family: var(--display);
  font-size: 1.35rem;
  font-weight: 700;
}
.mod-card p {
  font-size: 0.92rem;
  color: var(--text-2);
  line-height: 1.65;
  flex-grow: 1;
}

.mod-card__tags {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.mod-card__tags li {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text-2);
  letter-spacing: 0.03em;
}

.mod-card__cta {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--a1);
  margin-top: 0.5rem;
  transition: letter-spacing 0.3s;
}
.mod-card:hover .mod-card__cta {
  letter-spacing: 0.04em;
}

/* ─── FEATURES ─── */
.features {
  padding: 6rem 0;
  position: relative;
}
.features::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}

.features__heading {
  font-family: var(--display);
  font-size: clamp(1.6rem, 3.5vw, 2.6rem);
  font-weight: 800;
  margin-bottom: 3rem;
  line-height: 1.2;
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.feat {
  padding: 1.6rem;
  border-radius: 16px;
  background: var(--card);
  border: 1px solid var(--line);
  transition: border-color 0.3s, transform 0.3s var(--ease);
  position: relative;
  overflow: hidden;
}
.feat:hover {
  border-color: var(--a1);
  transform: translateY(-4px);
}
.feat__bar {
  width: 36px; height: 4px;
  border-radius: 999px;
  background: var(--bar);
  margin-bottom: 1.2rem;
}
.feat h3 {
  font-family: var(--display);
  font-size: 1.08rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
}
.feat p {
  font-size: 0.9rem;
  color: var(--text-2);
  line-height: 1.6;
}

/* ─── CONTACT ─── */
.contact {
  padding: 6rem 0;
  position: relative;
}
.contact::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}

.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.contact__info h2 {
  font-family: var(--display);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  margin-bottom: 0.8rem;
}
.contact__info > p {
  color: var(--text-2);
  margin-bottom: 2rem;
  line-height: 1.7;
}

.contact__channels {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
.channel {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.channel strong {
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--a1);
}
.channel span {
  color: var(--text-2);
  font-size: 0.95rem;
}

.contact__form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.contact__form input,
.contact__form textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text);
  font-family: var(--body);
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.3s;
}
.contact__form input:focus,
.contact__form textarea:focus {
  border-color: var(--a1);
}
.contact__form textarea {
  resize: vertical;
  min-height: 100px;
}
.contact__form button {
  align-self: flex-start;
}
.form-ok {
  color: var(--a1);
  font-size: 0.88rem;
}

/* ─── FOOTER ─── */
.footer {
  border-top: 1px solid var(--line);
  background: rgba(6, 9, 15, 0.9);
  padding: 4rem 0 0;
}
[data-theme="light"] .footer {
  background: rgba(230, 234, 244, 0.95);
}

.footer__top {
  display: grid;
  grid-template-columns: 1.4fr 1.2fr 0.8fr;
  gap: 3rem;
  padding-bottom: 3rem;
}

.footer__brand .nav__brand {
  margin-bottom: 1rem;
}
.footer__brand p {
  color: var(--text-2);
  font-size: 0.9rem;
  max-width: 32ch;
  line-height: 1.6;
  margin-top: 0.8rem;
}

.footer__subscribe h3,
.footer__links h3 {
  font-family: var(--display);
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
}
.footer__subscribe p {
  color: var(--text-2);
  font-size: 0.88rem;
  margin-bottom: 1rem;
  line-height: 1.5;
}

.subscribe-form {
  display: flex;
  gap: 0;
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--card);
  transition: border-color 0.3s;
}
.subscribe-form:focus-within {
  border-color: var(--a1);
}
.subscribe-form input {
  flex: 1;
  padding: 0.7rem 1rem;
  border: none;
  background: transparent;
  color: var(--text);
  font-family: var(--body);
  font-size: 0.88rem;
  outline: none;
  min-width: 0;
}
.subscribe-form button {
  padding: 0.7rem 1.3rem;
  border: none;
  background: var(--grad);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  white-space: nowrap;
  font-family: var(--body);
  transition: opacity 0.25s;
}
.subscribe-form button:hover { opacity: 0.85; }

.sub-ok {
  color: var(--a1);
  font-size: 0.84rem;
  margin-top: 0.5rem;
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.footer__links a {
  color: var(--text-2);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color 0.25s;
}
.footer__links a:hover { color: var(--text); }

.footer__bottom {
  border-top: 1px solid var(--line);
  padding: 1.5rem 0;
  display: flex;
  justify-content: space-between;
  color: var(--text-2);
  font-size: 0.8rem;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 900px) {
  .nav__links { display: none; }
  .nav__links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: rgba(6, 9, 15, 0.97);
    backdrop-filter: blur(16px);
    padding: 1.5rem;
    gap: 1.2rem;
    border-bottom: 1px solid var(--line);
  }
  .nav__cta { display: none; }
  .nav__burger { display: flex; }
  .theme-toggle { width: 38px; height: 38px; font-size: 1rem; }

  .about__grid { grid-template-columns: 1fr; gap: 2rem; }
  .modules__grid { grid-template-columns: 1fr; }
  .features__grid { grid-template-columns: 1fr; }
  .contact__grid { grid-template-columns: 1fr; }
  .footer__top { grid-template-columns: 1fr; gap: 2rem; }
  .hero__stats { gap: 1.5rem; }
  .footer__bottom { flex-direction: column; gap: 0.5rem; }
}

@media (max-width: 600px) {
  .hero { min-height: auto; padding: 8rem 0 3rem; }
  .hero__title { font-size: 2rem; }
  .hero__scroll { display: none; }
  .stat__num { font-size: 1.6rem; }
}
