/*
  Reading Card Skin — approved visual layer only.
  Scope: /appendix/ipa/ and /appendix/combinations/
  Do not move course data, card DOM, audio bindings, search logic, or grid logic.
*/

/* ---------- Header decorative layer ---------- */
.reading-page .reading-header {
  position: relative;
}

.reading-page .reading-header__copy {
  position: relative;
  z-index: 1;
}

.reading-page .reading-header__mascot {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 105px !important;
  pointer-events: none !important;
  z-index: 0 !important;
  background-repeat: no-repeat !important;
  background-position: right top !important;
  background-size: auto 105px !important;
}

.reading-page--vowel .reading-header__mascot {
  background-image: url("./ipa-header-decor.svg") !important;
}

.reading-page--consonant .reading-header__mascot {
  background-image: url("./combo-header-decor.svg") !important;
}

/* ---------- Section-bar decorative skins ---------- */
/* Do not change the existing 42px bar height, text, badge DOM, or spacing. */
.reading-page .section-titlebar {
  background-repeat: no-repeat !important;
  background-position: right center !important;
  background-size: auto 42px !important;
}

/* IPA: vowels */
.reading-page--vowel .ipa-cat:nth-of-type(1) .ipa-group:nth-of-type(1) > .section-titlebar {
  background-image: url("./ipa-bar-01.svg") !important;
}
.reading-page--vowel .ipa-cat:nth-of-type(1) .ipa-group:nth-of-type(2) > .section-titlebar {
  background-image: url("./ipa-bar-02.svg") !important;
}
.reading-page--vowel .ipa-cat:nth-of-type(1) .ipa-group:nth-of-type(3) > .section-titlebar {
  background-image: url("./ipa-bar-03.svg") !important;
}

/* IPA: consonants */
.reading-page--vowel .ipa-cat:nth-of-type(2) .ipa-group:nth-of-type(1) > .section-titlebar {
  background-image: url("./ipa-bar-04.svg") !important;
}
.reading-page--vowel .ipa-cat:nth-of-type(2) .ipa-group:nth-of-type(2) > .section-titlebar {
  background-image: url("./ipa-bar-05.svg") !important;
}
.reading-page--vowel .ipa-cat:nth-of-type(2) .ipa-group:nth-of-type(3) > .section-titlebar {
  background-image: url("./ipa-bar-06.svg") !important;
}
.reading-page--vowel .ipa-cat:nth-of-type(2) .ipa-group:nth-of-type(4) > .section-titlebar {
  background-image: url("./ipa-bar-07.svg") !important;
}
.reading-page--vowel .ipa-cat:nth-of-type(2) .ipa-group:nth-of-type(5) > .section-titlebar {
  background-image: url("./ipa-bar-08.svg") !important;
}

/* Letter-combination stations */
.reading-page--consonant .lc-station[data-station="1"] > .section-titlebar {
  background-image: url("./combo-bar-01.svg") !important;
}
.reading-page--consonant .lc-station[data-station="2"] > .section-titlebar {
  background-image: url("./combo-bar-02.svg") !important;
}
.reading-page--consonant .lc-station[data-station="3"] > .section-titlebar {
  background-image: url("./combo-bar-03.svg") !important;
}
.reading-page--consonant .lc-station[data-station="4"] > .section-titlebar {
  background-image: url("./combo-bar-04.svg") !important;
}
.reading-page--consonant .lc-station[data-station="5"] > .section-titlebar {
  background-image: url("./combo-bar-05.svg") !important;
}
.reading-page--consonant .lc-station[data-station="6"] > .section-titlebar {
  background-image: url("./combo-bar-06.svg") !important;
}

/* Keep the approved course color logic. */
.reading-page--vowel .ipa-group.is-vowel .section-titlebar__num,
.reading-page--consonant .lc-station .section-titlebar.is-vowel .section-titlebar__num {
  background: #F65D91 !important;
}

.reading-page--vowel .ipa-group.is-consonant .section-titlebar__num,
.reading-page--consonant .lc-station .section-titlebar.is-consonant .section-titlebar__num {
  background: #61B3F9 !important;
}

/* === MASCOT-ASPECT-LOCK START === */

/*
  Header artwork is a fixed 520 × 105 SVG composition.
  Never stretch width and height independently.
*/
.reading-page .reading-header__mascot {
  width: 100% !important;
  height: 105px !important;
  background-repeat: no-repeat !important;
  background-position: right top !important;
  background-size: auto 105px !important;
  transform: none !important;
  scale: none !important;
  pointer-events: none !important;
}

/* Do not use img/object-fit stretching on this decorative layer. */
.reading-page--vowel .reading-header__mascot {
  background-image: url("./ipa-header-decor.svg") !important;
}

.reading-page--consonant .reading-header__mascot {
  background-image: url("./combo-header-decor.svg") !important;
}

/* === MASCOT-ASPECT-LOCK END === */

/* === NEW-HEADER-HERO START === */

/*
  Each PNG below is the complete header illustration.
  Do not layer the former SVG artwork, pseudo-elements, or separate props.
*/

.reading-page .reading-header {
  position: relative !important;
}

.reading-page .reading-header__copy {
  position: relative !important;
  z-index: 2 !important;
}

.reading-page .reading-header__mascot {
  position: absolute !important;
  top: 0 !important;
  right: 0 !important;
  bottom: auto !important;
  left: auto !important;
  pointer-events: none !important;
  z-index: 1 !important;
  background-repeat: no-repeat !important;
}

/* Complete bunny + headphones + heart/sparkles illustration. */
.reading-page--vowel .reading-header__mascot {
  width: 126px !important;
  height: 100px !important;
  background-image: url("./ipa-header-hero.png") !important;
  background-size: contain !important;
  background-position: right center !important;
  transform: none !important;
  scale: none !important;
}

/* Complete puppy + open book + stars illustration. */
.reading-page--consonant .reading-header__mascot {
  width: 136px !important;
  height: 98px !important;
  background-image: url("./combo-header-hero.png") !important;
  background-size: contain !important;
  background-position: right center !important;
  transform: none !important;
  scale: none !important;
}

.reading-page--vowel .reading-header__mascot::before,
.reading-page--vowel .reading-header__mascot::after,
.reading-page--consonant .reading-header__mascot::before,
.reading-page--consonant .reading-header__mascot::after {
  content: none !important;
  display: none !important;
  background: none !important;
}

.reading-page--vowel .reading-header__copy,
.reading-page--consonant .reading-header__copy {
  max-width: calc(100% - 142px) !important;
}

@media (max-width: 430px) {
  .reading-page--vowel .reading-header__mascot {
    width: 120px !important;
    height: 96px !important;
    right: 0 !important;
    top: 2px !important;
  }

  .reading-page--consonant .reading-header__mascot {
    width: 130px !important;
    height: 94px !important;
    right: 0 !important;
    top: 4px !important;
  }

  .reading-page--vowel .reading-header__copy,
  .reading-page--consonant .reading-header__copy {
    max-width: calc(100% - 134px) !important;
  }
}

/* === NEW-HEADER-HERO END === */
