/* ==========================================================================
   Forge Academy — Layout
   Containers, header, section scaffolding, grids
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-3);
}

@media (max-width: 480px) {
  .container {
    padding-inline: var(--space-2);
  }
}

.section {
  padding-block: var(--space-6);
}

.section--tint {
  background: var(--color-teal-tint);
}

.section-head {
  max-width: 620px;
  margin-inline: auto;
  text-align: center;
  margin-bottom: var(--space-5);
}

.section-head p {
  margin-top: var(--space-2);
  font-size: var(--fs-lead);
  color: var(--color-muted);
}

/* ---- Header ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  padding-top: 1rem;
}

.site-header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 1.5rem;
  background: var(--color-teal-100);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-card);
}

.site-nav {
  display: flex;
  gap: var(--space-4);
}

.site-nav a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--color-ink);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  padding: 0.4rem;
  font-size: 1.4rem;
  line-height: 1;
  color: var(--color-ink);
}

@media (max-width: 860px) {
  .site-nav {
    display: none;
  }

  .nav-toggle {
    display: block;
  }
}
@media (max-width: 860px) {
  .site-nav.site-nav--open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: #fff;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-card);
    padding: var(--space-2);
    gap: var(--space-1);
    z-index: 50;
  }

  .site-header__bar {
    position: relative;
  }
}

@media (max-width: 600px) {
  .site-header {
    padding-top: 0.6rem;
  }

  .site-header__bar {
    padding: 0.5rem 0.9rem;
    gap: var(--space-1);
  }

  .header-actions {
    gap: 0.5rem;
  }

  .header-actions .btn {
    padding: 0.6rem 1rem;
    font-size: 0.85rem;
  }
}

@media (max-width: 380px) {
  .header-actions .btn {
    padding: 0.5rem 0.85rem;
    font-size: 0.8rem;
  }
}

/* ---- Hero ---- */
.hero {
  position: relative;
  overflow: hidden;
  padding-top: var(--space-5);
  padding-bottom: var(--space-5);
}

.hero__rays {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    repeating-conic-gradient(from 0deg at 50% 8%,
      rgba(10, 126, 120, 0.05) 0deg 4deg,
      transparent 4deg 12deg);
  mask-image: radial-gradient(circle at 50% 8%, black 0%, transparent 65%);
}

.hero__intro {
  max-width: 640px;
  margin-inline: auto;
  text-align: center;
}

.hero__intro p {
  margin-top: var(--space-2);
  font-size: var(--fs-lead);
  color: var(--color-muted);
}

.hero__actions {
  margin-top: var(--space-3);
  display: flex;
  gap: var(--space-2);
  justify-content: center;
  flex-wrap: wrap;
}

/* ---- Hero image stage — matches Figma coordinates ---- */
/* Reference frame: box 870.44 x 425.11 */
.hero__stage {
  position: relative;
  max-width: 870px;
  width: 100%;
  aspect-ratio: 870.44 / 425.11;
  margin: var(--space-5) auto var(--space-4);
}

.hero__collage img {
  position: absolute;
  object-fit: cover;
  border: 4px solid var(--color-teal-100);
  border-radius: 32px;
}

/* Left image: 300 x 387, top 4.27%, left 0%, rotate 4deg */
.hero__collage li:nth-child(1) img {
  width: 34.47%;
  height: 91.06%;
  top: 4.27%;
  left: 0%;
  transform: rotate(-8deg);
  object-position: center 75%;
}

/* Middle image: 300 x 400, top 0, left 32.89% */
.hero__collage li:nth-child(2) img {
  width: 34.47%;
  height: 94.1%;
  top: 0%;
  left: 32.89%;
  transform: none;
  z-index: 2;
}

/* Right image: 300 x 387, top 4.24%, left 62.55%, rotate -4deg */
.hero__collage li:nth-child(3) img {
  width: 34.47%;
  height: 91.06%;
  top: 4.24%;
  left: 62.55%;
  transform: rotate(8deg);
}
/* On phones the wide absolute-positioned collage collapses. Instead of
   stacking the three photos in a tall vertical column, fan them into a
   single overlapping row that fits the screen, then let the two badges
   flow underneath as a centered pair. */
@media (max-width: 640px) {
  .hero__stage {
    aspect-ratio: auto;
    height: auto;
    max-width: 460px;
    margin-block: var(--space-4) var(--space-3);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-2);
  }

  .hero__collage {
    flex: 1 1 100%;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .hero__collage li {
    flex: 1 1 0;
    min-width: 0;
  }

  .hero__collage li:nth-child(1) img,
  .hero__collage li:nth-child(2) img,
  .hero__collage li:nth-child(3) img {
    position: static;
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-width: 3px;
    border-radius: 18px;
  }

  .hero__collage li:nth-child(1) img {
    transform: rotate(-6deg);
    object-position: center 75%;
  }

  .hero__collage li:nth-child(2) img {
    position: relative;
    z-index: 2;
    transform: scale(1.09);
  }

  .hero__collage li:nth-child(3) img {
    transform: rotate(6deg);
  }

  .hero__collage li:nth-child(1) {
    margin-right: -5%;
  }

  .hero__collage li:nth-child(3) {
    margin-left: -5%;
  }

  .floating-badge {
    position: static;
    flex: 0 1 auto;
    margin-top: 0;
  }
}

@media (max-width: 480px) {
  .hero {
    padding-top: var(--space-4);
    padding-bottom: var(--space-4);
  }

  .hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero__actions .btn--hero {
    width: 100%;
  }
}
/* ---- Skills grid ---- */
.skills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3);
}

@media (max-width: 720px) {
  .skills-grid {
    grid-template-columns: 1fr;
  }
}

/* ---- Why bento ---- */

.bento-grid {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
}

.bento-col {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  flex: 1;
  min-width: 0;
}

@media (max-width: 720px) {
  .bento-grid {
    flex-direction: column;
  }
}

/* ---- How it works ---- */
.process {
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-2);
  padding-top: 1rem;
}

.process__curve {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.process__step {
  position: relative;
  z-index: 1;
  flex: 1;
  text-align: center;
}

.process__step:nth-child(1) {
  margin-top: 1.25rem;
}

.process__step:nth-child(2) {
  margin-top: 5.5rem;
}

.process__step:nth-child(3) {
  margin-top: 0;
}

.process__step:nth-child(4) {
  margin-top: 3.25rem;
}

/* Tablet: tighten the zigzag so the staggered steps don't sprawl, and drop
   the oversized finale badge down to match the rest. */
@media (max-width: 960px) and (min-width: 781px) {
  .process {
    gap: var(--space-1);
  }

  .process__step:nth-child(1) { margin-top: 0.75rem; }
  .process__step:nth-child(2) { margin-top: 3.5rem; }
  .process__step:nth-child(4) { margin-top: 2rem; }

  .process__step p {
    max-width: 180px;
  }

  .process__step .process-badge--filled {
    width: 88px;
    height: 88px;
    font-size: 1.6rem;
  }
}

/* Phone: the diagonal collapses into a left-aligned vertical timeline —
   numbered badges on a connector line, step text beside each. */
@media (max-width: 780px) {
  .process {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-top: 0;
  }

  .process__curve {
    display: none;
  }

  .process__step {
    display: grid;
    grid-template-columns: 52px 1fr;
    grid-template-rows: minmax(52px, auto) auto;
    column-gap: var(--space-3);
    row-gap: 0.3rem;
    flex: none;
    text-align: left;
    padding-bottom: var(--space-4);
  }

  .process__step:nth-child(1),
  .process__step:nth-child(2),
  .process__step:nth-child(3),
  .process__step:nth-child(4) {
    margin-top: 0;
  }

  .process__step:last-child {
    padding-bottom: 0;
  }

  /* connector line — dead-centre of the 52px badge column (26px), and the
     2px stroke is pulled back half its width so it's centred on that point */
  .process__step::before {
    content: "";
    position: absolute;
    left: 26px;
    transform: translateX(-50%);
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--color-line);
    z-index: 0;
  }

  .process__step:first-child::before {
    top: 26px;
  }

  .process__step:last-child::before {
    display: none;
  }

  /* higher specificity so it beats components.css .process-badge--filled */
  .process__step .process-badge,
  .process__step .process-badge--filled {
    grid-column: 1;
    grid-row: 1;
    align-self: center;
    justify-self: center;
    width: 52px;
    height: 52px;
    font-size: 1.15rem;
    margin: 0;
    position: relative;
    z-index: 1;
  }

  /* title shares row 1 with the badge and centres against it */
  .process__step h3 {
    grid-column: 2;
    grid-row: 1;
    align-self: center;
    margin: 0;
  }

  .process__step p {
    grid-column: 2;
    grid-row: 2;
    max-width: none;
    margin: 0;
  }
}

/* ---- Community banner ---- */
/* ============================================================
   COMMUNITY BANNER — Image 1 layout
   ============================================================ */

.community {
  position: relative;
  background: var(--color-teal-700);
  padding-top: 0;
  overflow: hidden;
}

.community--bg {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -3rem;
  /* pulls it up into the "How it works" section's bottom padding */
  position: relative;
  z-index: 1;
}
.community--bg .container {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.community__text {
  max-width: 640px;
  margin-inline: auto;
  text-align: center;
  color: #fff;
}

.community__text h2 {
  color: #fff;
  font-size: clamp(2.4rem, 4.2vw, 3.4rem);
  line-height: 1.1;
}

.community__text p {
  max-width: 620px;
  margin: 14px auto 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.2rem;
  line-height: 1.55;
}

.community__actions {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.community__actions .btn {
  height: 52px;
  padding: 0 32px;
  font-size: 0.9rem;
  border-radius: 50px;
}

@media (max-width: 600px) {
  .community--bg {
    min-height: 0;
    margin-top: -1.5rem;
    padding-block: var(--space-5);
  }

  .community__text h2 {
    font-size: 1.9rem;
  }

  .community__text p {
    font-size: 1rem;
  }

  .community__actions {
    width: 100%;
    flex-direction: column;
  }

  .community__actions .btn {
    width: 100%;
  }
}

/* ------------------------------------------------------------
   PEOPLE
   ------------------------------------------------------------ */

.community__photos {
  position: relative;
  width: 100%;
  height: 320px;
  margin-top: 40px;
  padding: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;

  overflow: visible;
}

.community__photos li {
  display: flex;
  align-items: flex-end;
}

.community__photos img {
  display: block;
  width: auto;
  height: 280px;
  max-width: none;
  object-fit: contain;
  flex-shrink: 0;
  filter: drop-shadow(0 18px 14px rgba(0, 0, 0, 0.25));
}

/* PERSON 1 & 2 — grouped tight, standard scale */
.community__photos__item--1 {
  position: relative;
  z-index: 2;
  margin-right: -22px;
}

.community__photos__item--2 {
  position: relative;
  z-index: 3;
  margin-right: 34px;
}

/* PERSON 3 — set apart, slightly smaller for depth */
.community__photos__item--3 {
  position: relative;
  z-index: 2;
  margin: 0;
}

.community__photos__item--3 img {
  height: 290px;
}

/* TWO GIRLS (item 4) — hero figure, largest, floated near the text */
.community__photos__item--4 {
  position: absolute;
  z-index: 4;
  top: -40px;
  right: 24px;
  margin: 0;
}

.community__photos__item--4 img {
  height: 430px;
}

/* ------------------------------------------------------------
   MOBILE
   ------------------------------------------------------------ */

@media (max-width: 780px) {
  .community__photos {
    height: 240px;
    margin-top: 24px;
  }

  .community__photos img {
    height: 200px;
  }

  .community__photos__item--1 {
    margin-right: -14px;
  }

  .community__photos__item--2 {
    margin-right: 20px;
  }

  .community__photos__item--3 img {
    height: 180px;
  }

  .community__photos__item--4 {
    top: -15px;
    right: 10px;
  }

  .community__photos__item--4 img {
    height: 220px;
  }
}

/* ---- Testimonials ---- */
.testimonial-track {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  transition: opacity 0.22s var(--ease), transform 0.22s var(--ease);
}

.testimonial-track.is-transitioning {
  opacity: 0;
  transform: translateY(6px) scale(0.99);
}

.testimonial-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  margin-top: var(--space-3);
}

.testimonial-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}

@media (max-width: 780px) {
  .testimonial-track .testimonial-card--side {
    display: none;
  }

  .testimonial-track .testimonial-card--active {
    transform: none;
    width: min(360px, 100%);
    height: auto;
    min-height: 220px;
  }

  .testimonial-nav {
    gap: var(--space-2);
  }
}

/* ---- FAQ ---- */
.faq-list {
  max-width: 700px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

/* ---- Footer block (CTA + links share one teal surface) ---- */
.footer-block {
  position: relative;
  background: var(--color-teal-700);
  overflow: hidden;
  padding-top: var(--space-6);
}

.final-cta {
  position: relative;
  z-index: 2;
  background: #d0f0eed2;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius-lg);
  padding: var(--space-5) var(--space-3);
  text-align: center;
  color: #fff;
}

.final-cta p {
  color: rgba(0, 0, 0, 0.75);
  margin-top: var(--space-2);
}

.final-cta__actions {
  display: flex;
  gap: var(--space-2);
  justify-content: center;
  margin-top: var(--space-3);
  flex-wrap: wrap;
}

.footer-block__ghost {
  position: absolute;
  bottom: -0.28em;
  left: 50%;
  transform: translateX(-50%);
  font-size: clamp(4rem, 15vw, 11rem);
  font-weight: 800;
  color: rgba(255, 255, 255, 0.06);
  white-space: nowrap;
  z-index: 0;
  letter-spacing: 0.02em;
  pointer-events: none;
}

.footer-links {
  position: relative;
  z-index: 2;
  padding-top: var(--space-5);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: var(--space-3);
}

.footer-grid h4 {
  color: #fff;
  font-size: 0.95rem;
  margin-bottom: var(--space-2);
}

.footer-grid ul li {
  margin-bottom: 0.6rem;
}

.footer-grid a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
}

.footer-brand p {
  color: rgba(255, 255, 255, 0.7);
  margin-top: var(--space-1);
  max-width: 320px;
  font-size: 0.9rem;
}

.footer-bottom-bar {
  position: relative;
  z-index: 2;
  background: var(--color-orange-600);
  margin-top: 0;
  padding: var(--space-2) 0;
}
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2);
  color: #fff;
  font-size: 0.9rem;
}

.social-links {
  display: flex;
  gap: 0.9rem;
}

.social-links svg {
  width: 18px;
  height: 18px;
  fill: #fff;
}

@media (max-width: 780px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 600px) {
  .footer-block {
    padding-top: var(--space-5);
  }

  .final-cta {
    padding: var(--space-4) var(--space-3);
  }

  .final-cta__actions {
    flex-direction: column;
  }

  .final-cta__actions .btn {
    width: 100%;
  }

  .footer-links {
    padding-top: var(--space-4);
  }
}

@media (max-width: 480px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 380px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    justify-content: center;
    text-align: center;
  }
}