/* page-learning.css — styles for page-learning.hbs
   Extracted from the page's inline <style> block. The .slider-badges rules that came with
   it are gone: the testimonial markup now matches learning-checkout.hbs, which puts the
   portrait in .auth-img with no .slider-badges wrapper, and style.css already sizes that.

   certifications.css already carries this page's responsive grid work and already uses
   the 1024/600 breakpoints for .box-container, so none of that is repeated here. The one
   grid still on the old 768px tablet breakpoint is .level-selector-list; it is moved onto
   1024 below so tablet is consistent across the page — two cards per row down to 600,
   one below that (the 600px rule in certifications.css already handles the mobile case). */

.slider-section .slider-content .slider-wrapper {
  width: 100%;
}

/* The ROA periodic table is a 3000px PNG (sec-design's was an SVG, which scaled on its
   own), and nothing in certifications.css constrains it — so it rendered at full
   intrinsic width and pushed the whole document into horizontal scroll. */
.table-of-elements-section .table-of-elements-image img {
  display: block;
  width: 100%;
  height: auto;
}

/* The IQ graphic column, desktop only - tablet and below stack (see the 1024px block).
   That row is align-items: flex-start, so the right column only ever matched the lottie's
   own square height - taller than the copy beside it, with the art sitting low because the
   1400x1400 artboard carries ~41% dead space above and below the chart. Stretch the row so
   both columns share a height, then take the player out of flow so it fills that height
   instead of dictating it. The player keeps its square aspect and is centred with a
   transform rather than fitted to the box: letting preserveAspectRatio shrink it to the
   shorter side would scale the chart down by a third. The overhang is clipped instead. */
@media only screen and (min-width: 1033px) {
  .benchmark-skill-section .content-wrap {
    align-items: stretch;
  }

  .benchmark-skill-section .right-contents {
    position: relative;
    overflow: hidden;
  }

  .benchmark-skill-section .right-contents lottie-player {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: auto;
  }
}

/* Testimonial slides stay a non-wrapping flex row at every width (style.css sets
   .slide-item to display:flex with an 80px gap), and the portrait has no width rule of its
   own, so it renders at its intrinsic 323px. Below ~430px of container the image plus the
   gap already exceed the row, which pushed .slide-content outside the box - and
   .slider-content clips with overflow:hidden, so the quote simply vanished. Stack the slide
   once the section goes single-column. */
@media only screen and (max-width: 1032px) {
  .slider-section .slider-controller {
    justify-content: flex-start;
  }

  .slider-section .slide-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 32px;
  }

  .slider-section .slide-item .auth-img {
    width: 100%;
    max-width: 323px;
    height: auto;
  }

  /* The arrows are absolutely pinned right/centre by style.css, which at this width
     floats them over the bottom-right of the quote. Put them back in flow so they sit
     below the slide - .slider-content is already a column here - and at its left edge. */
  .slider-section .slider-controller {
    position: static;
    justify-content: flex-start;
    gap: 45px;
  }
}

/* testimonial-slider.js marks the unavailable arrow with inline visibility:hidden, which
   made it vanish while still holding its slot. Show it instead, dimmed and inert, so the
   pair stays put and it reads as disabled rather than missing. The attribute selector
   matches the inline style the script writes. */
.slider-section .slider-controller a[style*="visibility: hidden"] {
  visibility: visible !important;
  opacity: 0.3;
  pointer-events: none;
  cursor: default;
}

/* The pen-scratch decal is an inline SVG carrying hardcoded width="598" height="43"
   attributes, and nothing constrains it - Tailwind's preflight caps img and video at
   max-width:100% but not svg, so it kept rendering at 598px however narrow the column got
   (536px at 600px viewport, 326px at 390px) and dragged the page into horizontal scroll.
   Let it scale with the column, capped at its natural width. */
.benchmark-skill-section .decal-1 svg {
  width: 100%;
  max-width: 598px;
  height: auto;
}

/* certifications.css only turns these two sections into columns at 600px, so at tablet they
   were still side-by-side rows. Bring the switch forward to 1024 so tablet matches the mobile
   layout. Padding is left to .page-section-padding / p-0!, both of which are !important. */
@media only screen and (max-width: 1032px) {
  .get-certified-section .content-wrap,
  .benchmark-skill-section .content-wrap {
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
  }
}

/* ── Tablet ─────────────────────────────────────────────────────────────── */
@media only screen and (max-width: 1032px) {
  .level-selector-list {
    grid-template-columns: 1fr 1fr;
  }
}

/* ── Mobile ─────────────────────────────────────────────────────────────────
   certifications.css already drops .level-selector-list to one column here, but this
   sheet loads after it and the tablet rule above matches too — so restate it. */
@media only screen and (max-width: 600px) {
  .level-selector-list {
    grid-template-columns: 1fr;
  }
}

/* Banner star ratings, matched to the live PMA learning page. What came across from
   partials/star-ratings.hbs could not do the job: its `.rating-stars .star-svg` only tied
   the 24px base on specificity (so mobile stars came out 25px - larger than desktop), and
   its `.logo-image img` was outranked by `.star-ratings-container .logo-image img`, leaving
   the logos at 40px. Live scopes both under .banner, which outranks the base rules. */
@media only screen and (max-width: 600px) {
  .banner .star-ratings-container .star-svg {
    width: 16px;
    height: 16px;
  }

  .banner .star-ratings-container .logo-image img {
    height: 28px;
    max-width: 100%;
    object-fit: contain;
  }
}

/* Tablets up to 1032px use the 768px (iPad mini) layout. The breakpoints in this file and
   in certification-microsite/css/certifications.css (only this page uses either) run to
   1032/1033px. The framework chart slider is styled by partials/framework-section-dark.hbs,
   which other templates share and which switches to its tablet layout at 1024px; its tablet
   rules are repeated here for 1025-1032px. #site-main because the partial's <style> comes
   later in the page. */
@media only screen and (min-width: 1025px) and (max-width: 1032px) {
   #site-main .pmm-chart-container .chart-slide-item {
      flex-direction: column;
      gap: 40px;
      align-items: center;
   }

   #site-main .pmm-chart-container .chart-slide-item img {
      width: 75%;
   }

   #site-main .pmm-chart-container .chart-slide-item .chart {
      width: 100%;
      display: flex;
      justify-content: center;
   }

   #site-main .chart-slide-controller {
      display: none;
   }

   #site-main .chart-slide-controller-mobile {
      display: flex;
      gap: 16px;
   }

   #site-main .pmm-chart-container h2 {
      font-family: Poppins, sans-serif;
      font-size: 42px;
      font-weight: 400;
      line-height: 40px;
      letter-spacing: -0.02em;
   }

   #site-main .pmm-chart-container h2 span {
      font-size: 42px;
   }
}

/* Framework chart slider, tablet: the text block spans the column, so the heading, copy and
   button line up with the pagination dots above them instead of shrinking to their content
   and centring (which showed from ~1000px up, where the copy no longer fills the line). */
@media only screen and (max-width: 1032px) {
   #site-main .pmm-chart-container .chart-slide-item .chart-content {
      width: 100%;
   }
}

/* Framework chart slides, tablets (up to 1032px): the text column spans the slide. The
   slide is a centred flex column there, so the column shrank to its widest child - on a
   slide with a short heading, the paragraph, which lg:w-143! fixes at 572px from 1024px -
   and sat centred with a wide gap on the left. The paragraph's width comes from Tailwind
   (!important in @layer utilities); an earlier layer wins for !important, hence base. */
@media only screen and (max-width: 1032px) {
   #site-main .pmm-chart-container .chart-slide-item .chart-content {
      width: 100%;
      align-self: stretch;
   }
}

@layer base {
   @media only screen and (max-width: 1032px) {
      #site-main .pmm-chart-container .chart-slide-item .chart-content p {
         width: 100% !important;
      }
   }
}
