/* =============================================================
   HOMEPAGE COMPONENTS
   Paste into main.css, replacing the existing blocks for:
   .quotes / .quote-slider, video section, .resources,
   .about-image, .about, .mobile-wrapper, .btn-orange / .btn-blue

   Sections in order of appearance on the page:
     1. Video hero
     2. Testimonial slider (Splide)
     3. Resources for Teachers
     4. About image band
     5. About cards
     6. Buttons
============================================================= */
/* =============================================================
   1. VIDEO HERO
============================================================= */
#video-section {
  position: relative;
  z-index: 1;
  background-color: var(--color-navy-900); /* shows while video loads */
}
.video-wrapper {
  position: relative;
}
/* Dark gradient vignette: top and bottom edges fade to black,
   which makes the white title text readable at any frame. */
.video-wrapper .overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background-image: linear-gradient(180deg, rgba(0, 0, 0, .80) 0%, rgba(0, 0, 0, .30) 30%, rgba(0, 0, 0, 0) 70%, rgba(0, 0, 0, .80) 100%);
  pointer-events: none;
}
.main-video {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}
/* Pause / play toggle — top-right corner */
.btn-video-controls {
  position: absolute;
  top: 0.25rem;
  right: 0.25rem;
  z-index: 12;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem 0.5rem;
  background: none;
  border: 0;
  color: var(--color-white);
  font-size: 1.3rem;
  opacity: 0.5;
  cursor: pointer;
  transition: opacity 0.2s ease;
}
.btn-video-controls:hover, .btn-video-controls:focus-visible {
  opacity: 1;
}
.btn-video-controls:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 var(--focus-ring-offset) var(--focus-ring-inner), 0 0 0 calc(var(--focus-ring-offset) + var(--focus-ring-width)) var(--color-white);
}
/* Title block sits over the overlay at the bottom of the frame */
.video-messaging {
  position: absolute;
  z-index: 10;
  left: 0;
  right: 0;
  bottom: clamp(3rem, 12vw, 8rem);
  text-align: center;
}
.video-title {
  margin: 0;
  font-family: var(--font-kanit);
  font-size: 2.5rem;
  line-height: 1;
  color: var(--color-white);
  text-shadow: var(--text-shadow-hero);
  text-transform: uppercase;
  text-align: center;
  font-weight: 600;
}
.video-text {
  margin-bottom: 0;
  font-size: 1.5rem;
  color: var(--color-white);
  text-shadow: var(--text-shadow-hero);
  font-weight: 600;
  line-height: 1.3;
}
/* Mobile static image (shown when video is hidden at < 576px) */
#video-section .img-fluid {
  display: block;
  width: 100%;
  height: auto;
}
/* -- Responsive --------------------------------------------- */
@media (min-width: 576px) {
  .main-video {
    width: 100%;
    height: auto;
  }
  .video-title {
    font-size: 4rem;
  }
  .video-text {
    font-size: 1.2rem;
  }
}
@media (min-width: 768px) {
  .video-title {
    font-size: 5rem;
    letter-spacing: 6px;
  }
  .video-text {
    font-size: 1.5rem;
  }
  .btn-video-controls {
    top: auto;
    right: 1rem;
    bottom: 0.25rem;
    font-size: 2rem;
  }
}
@media (min-width: 992px) {
  .main-video {
    max-height: 550px;
  }
  .video-title {
    font-size: 6rem;
  }
  .video-text {
    font-size: 1.75rem;
    line-height: 1;
  }
}
@media (min-width: 1200px) {
  .main-video {
    max-height: 600px;
  }
}
@media (min-width: 1400px) {
  .video-title {
    font-size: 7.5rem;
  }
  .video-text {
    font-size: 2.2rem;
  }
}
@media (min-width: 1600px) {
  .video-title {
    font-size: 7rem;
  }
  .video-text {
    font-size: 2rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  .btn-video-controls {
    transition: none;
  }
}
/* =============================================================
   2. TESTIMONIAL SLIDER (Splide)
   The PHP shuffles the quotes array on load, so order varies.
   The .testimonial block styles the open/close quote marks via
   FA pseudo-elements (same as the current inline <style>).
============================================================= */
.quote-slider {
  padding: .5rem 0;
  max-width: 900px;
  margin: 0 auto;
}
.quote-slider .splide__arrows {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
}
.quote-slider .splide__arrow svg {
  fill: var(--color-navy-500);
}
.quote-slider .splide__arrow {
  height: 2.5em;
  width: 2.5em;
}
.quotes {
  background-color: var(--color-navy-500);
  color: var(--text-on-dark);
  padding: 0;
  margin-bottom: 1.25rem;
}
/* Splide overrides — keeps the slider text on-brand */
.quotes .splide__slide {
  display: flex;
  align-items: center;
}
.quotes .splide__pagination__page {
  background: rgba(255, 255, 255, 0.4);
}
.quotes .splide__pagination__page.is-active {
  background: var(--color-white);
}
.quotes .splide__arrow {
  background: rgba(255, 255, 255, 0.75);
  color: var(--color-white);
  top: auto;
  bottom: 0;
}
.quotes .splide__arrow:hover {
  background: rgba(255, 255, 255, 1);
}
/* Individual testimonial block */
.testimonial {
  padding: 0.75rem 2rem 0.75rem 3rem;
  position: relative;
  font-style: italic;
  font-size: 1.25rem;
  line-height: 1.6;
  margin-bottom: 3.5rem;
}
/* Open quote — top-left */
.testimonial::before {
  content: "“";
  font-family: var(--font-noto-serif);
  font-weight: 900;
  font-size: 70px;
  color: var(--color-white);
  opacity: 0.3;
  position: absolute;
  left: 0;
  top: 0;
}
/* Close quote — bottom-right */
.testimonial::after {
  content: "”";
  font-family: var(--font-noto-serif);
  font-weight: 900;
  font-size: 70px;
  color: var(--color-white);
  opacity: 0.3;
  position: absolute;
  bottom: 0;
  right: 16px;
}
.testimonial p {
  font-family: var(--font-noto-serif);
  margin-bottom: 0;
  color: var(--color-white);
  font-size: 1.25rem;
}
@media (min-width: 768px) {
  .quote-slider .splide__arrows {
    position: initial;
  }
  .testimonial {
    margin-bottom: 0;
    padding: 2rem 8rem;
  }
  .testimonial::before {
    left: 70px;
    top: 0;
  }
  .testimonial::after {
    right: 90px;
    bottom: 0;
  }
  .quote-slider .splide__arrow--prev {
    left: .5em;
    top: 50%;
  }
  .quote-slider .splide__arrow--next {
    right: .5em;
    top: 50%;
  }
}
@media (min-width: 992px) {
  .quotes {
    line-height: 1.8;
  }
  .testimonial::before {
    top: 0;
  }
  .testimonial::after {
    bottom: 0;
  }
}
/* =============================================================
   3. RESOURCES FOR TEACHERS
============================================================= */
.resources {
  padding: 2rem 0 3rem;
  color: var(--brand-primary);
  background-image: url("data:image/svg+xml,%3Csvg width='100' height='20' viewBox='0 0 100 20' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M21.184 20c.357-.13.72-.264 1.088-.402l1.768-.661C33.64 15.347 39.647 14 50 14c10.271 0 15.362 1.222 24.629 4.928.955.383 1.869.74 2.75 1.072h6.225c-2.51-.73-5.139-1.691-8.233-2.928C65.888 13.278 60.562 12 50 12c-10.626 0-16.855 1.397-26.66 5.063l-1.767.662c-2.475.923-4.66 1.674-6.724 2.275h6.335zm0-20C13.258 2.892 8.077 4 0 4V2c5.744 0 9.951-.574 14.85-2h6.334zM77.38 0C85.239 2.966 90.502 4 100 4V2c-6.842 0-11.386-.542-16.396-2h-6.225zM0 14c8.44 0 13.718-1.21 22.272-4.402l1.768-.661C33.64 5.347 39.647 4 50 4c10.271 0 15.362 1.222 24.629 4.928C84.112 12.722 89.438 14 100 14v-2c-10.271 0-15.362-1.222-24.629-4.928C65.888 3.278 60.562 2 50 2 39.374 2 33.145 3.397 23.34 7.063l-1.767.662C13.223 10.84 8.163 12 0 12v2z' fill='%23abdae7' fill-opacity='0.1' fill-rule='evenodd'/%3E%3C/svg%3E");
}
.resources .container {
  max-width: 1400px;
}
/* Heading with green accent rule beneath */
.resources h2 {
  position: relative;
  display: block; /* shrinks to text width so ::after centres under it */
  margin: 1rem auto 3rem;
  font-size: 1.8rem;
  color: var(--brand-primary);
}
/* Because h2 is inline-block, .text-center on the parent col
   centres the whole heading. The rule then centres under it. */
.resources h2::after {
  content: "";
  display: block;
  width: 3rem;
  height: 3px;
  margin: 0.5rem auto 0;
  background-color: var(--brand-accent);
  border-radius: 2px;
}
/* Resource card grid — equal-height columns, no gutters fuss */
.resources .row {
  row-gap: 1.5rem;
}
.card--resource {
  height: 100%;
  padding: .5rem .5rem 1rem;
  background-color: var(--surface-page);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transform: translateY(0);
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}
.card--resource:hover {
  box-shadow: var(--shadow-card);
  transform: translateY(-5px);
}
.card--resource:hover h3 {
  color: var(--color-green-500);
}
.card--resource a {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: var(--brand-primary);
  border-bottom: 0;
}
.card--resource img {
  display: block;
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.card--resource h3 {
  flex: 1;
  display: flex;
  margin: 0;
  padding: 1.25rem 1rem .5rem 0;
  font-size: 1.2rem;
  font-family: var(--font-oswald);
  font-weight: 700;
  color: var(--brand-primary);
  flex-direction: column;
}
.card--resource h3 span {
  font-size: .7em;
}
.card--resource p {
  font-size: 1rem;
  line-height: 1.6;
}
@media (min-width: 768px) {
  .resources h2 {
    font-size: 2.5rem;
  }
  .card--resource img {
    height: 220px;
  }
  .card--resource h3 {
    font-size: 1.4rem;
  }
}
@media (min-width: 992px) {
  .card--resource img {
    height: 180px;
  }
  .card--resource h3 {
    font-size: 1.2rem;
  }
}
@media (min-width: 1200px) {
  .card--resource img {
    height: 220px;
  }
  .card--resource h3 {
    font-size: 1.35rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  .card--resource {
    transition: box-shadow 0.25s ease;
    transform: none !important;
  }
}
/* =============================================================
   4. ABOUT IMAGE BAND
   Overlaps with the resources section above via negative top
   margin, and acts as a backdrop for the about cards below.
============================================================= */
.about-image {
  background-color: var(--color-navy-700);
  background-image: linear-gradient(0deg, var(--color-navy-700) 0%, var(--color-navy-400) 50%, var(--color-navy-700) 100%);
  margin-top: -165px;
  padding-top: 165px;
  padding-bottom: 150px;
}
.about-image img {
  display: block;
  width: 100%;
  height: auto;
  box-shadow: rgba(0, 0, 0, 0.5) 0px 5px 15px;
  max-width: 1280px;
  margin: 0 auto;
}
/* =============================================================
   5. ABOUT CARDS
   Sits over the bottom of .about-image via negative top margin.
   .mobile-wrapper provides the white card surface.
============================================================= */
.about {
  background-color: var(--surface-page);
  background-image: url("data:image/svg+xml,%3Csvg width='100' height='20' viewBox='0 0 100 20' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M21.184 20c.357-.13.72-.264 1.088-.402l1.768-.661C33.64 15.347 39.647 14 50 14c10.271 0 15.362 1.222 24.629 4.928.955.383 1.869.74 2.75 1.072h6.225c-2.51-.73-5.139-1.691-8.233-2.928C65.888 13.278 60.562 12 50 12c-10.626 0-16.855 1.397-26.66 5.063l-1.767.662c-2.475.923-4.66 1.674-6.724 2.275h6.335zm0-20C13.258 2.892 8.077 4 0 4V2c5.744 0 9.951-.574 14.85-2h6.334zM77.38 0C85.239 2.966 90.502 4 100 4V2c-6.842 0-11.386-.542-16.396-2h-6.225zM0 14c8.44 0 13.718-1.21 22.272-4.402l1.768-.661C33.64 5.347 39.647 4 50 4c10.271 0 15.362 1.222 24.629 4.928C84.112 12.722 89.438 14 100 14v-2c-10.271 0-15.362-1.222-24.629-4.928C65.888 3.278 60.562 2 50 2 39.374 2 33.145 3.397 23.34 7.063l-1.767.662C13.223 10.84 8.163 12 0 12v2z' fill='%23abdae7' fill-opacity='0.1' fill-rule='evenodd'/%3E%3C/svg%3E");
  margin-top: -100px;
  padding: 3rem 0;
  color: var(--brand-primary);
}
.about h2 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
  color: var(--brand-primary);
  font-family: var(--font-oswald);
  font-weight: 700;
}
.card--about {
  display: flex;
  flex-direction: column;
  height: 100%;
  margin-bottom: 2rem;
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.55s ease, transform 0.55s ease;
  box-shadow: rgba(0, 0, 0, 0.1) 0px 2px 15px 0px;
  padding: 1rem 1.5rem;
  background-color: var(--color-white);
  border-radius: 10px;
}
.card--about .card-body .btn-green {
  margin-top: 1rem;
  align-self: flex-start; /* Keeps the button from stretching horizontally */
}
.card--about .card-body {
  display: flex;
  flex-direction: column;
  flex: 1; /* Fills remaining height */
}
.card--about.is-visible {
  opacity: 1;
  transform: translateY(0);
}
/* Stagger the second card slightly */
.col-lg-6:nth-child(2) .card--about {
  transition-delay: 0.15s;
}
@media (min-width: 992px) {
  .card--about .card-body .btn-green {
    margin-top: auto;
    width: initial;
  }
}
@media (prefers-reduced-motion: reduce) {
  .card--about {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .btn-green, .btn-blue, .btn-primary {
    transition: none;
  }
}