/*
 * ROW Academy (Batch F): states that live's scripts and Webflow interactions set on
 * the Account Security hub, its static pages and the Gold / Security item templates
 * (components/frontend/academy-embed-behaviours.ts), and the inline icons that replace
 * live's icon font (also on the ebooks and gold listings). Hand-written; the rest of
 * the looks are ported from live (security-pages.css, item-templates.css, listings.css,
 * generated). Academy-only (ACADEMY_STYLESHEETS); every rule is scoped under a block
 * root (.raven-academy-sec, .raven-academy-item, .raven-academy-list).
 */

/* Live's icon font glyphs, drawn as inline SVG at the glyph's size (all Batch F blocks). */
.raven-academy-sec .academy-icon, .raven-academy-item .academy-icon,
.raven-academy-list .academy-icon {
  display: inline-block;
  width: 1em;
  height: 1em;
  vertical-align: -0.125em;
}
/* Font Awesome's chevron-right is 0.625em wide (10px at 16px): the breadcrumb separators sit where live's do (QA-F-3). */
.raven-academy-sec .academy-icon-chevron, .raven-academy-item .academy-icon-chevron,
.raven-academy-list .academy-icon-chevron {
  width: 0.625em;
}
/* Font Awesome's arrow-up-right is 0.75em wide and arrow-right 0.875em: chips and links as wide as live's (QA-F-6). */
.raven-academy-sec .academy-icon-out, .raven-academy-item .academy-icon-out,
.raven-academy-list .academy-icon-out {
  width: 0.75em;
}
.raven-academy-sec .academy-icon-arrow, .raven-academy-item .academy-icon-arrow,
.raven-academy-list .academy-icon-arrow {
  width: 0.875em;
}
/* Live's button icon is a text glyph, so the button's letter-spacing (.035rem) follows it; the SVG gets that space too. */
.raven-academy-sec .ds-button_right-icon .academy-icon-out, .raven-academy-item .ds-button_right-icon .academy-icon-out {
  margin-right: 0.035rem;
}

/* FAQ accordion (live's inline style block): closed at load, height animation, arrow turns. */
.raven-academy-sec .course-faqs_accordion-wrap [data-academy-accordion="content"], .raven-academy-item .course-faqs_accordion-wrap [data-academy-accordion="content"] {
  max-height: 0;
  overflow: hidden;
  /* A closed answer is out of the tab order and hidden from screen readers (R826-11), once it has finished closing. */
  visibility: hidden;
  transition: max-height 0.24s cubic-bezier(0.65, 0, 0.35, 1), visibility 0s linear 0.24s;
}
.raven-academy-sec .course-faqs_accordion-wrap .sec-open [data-academy-accordion="content"], .raven-academy-item .course-faqs_accordion-wrap .sec-open [data-academy-accordion="content"] {
  visibility: visible;
  transition: max-height 0.24s cubic-bezier(0.65, 0, 0.35, 1), visibility 0s;
}
.raven-academy-sec .course-faqs_accordion-wrap [data-academy-accordion="trigger"], .raven-academy-item .course-faqs_accordion-wrap [data-academy-accordion="trigger"] { cursor: pointer; }
.raven-academy-sec .course-faqs_accordion-wrap [data-academy-accordion="arrow"], .raven-academy-item .course-faqs_accordion-wrap [data-academy-accordion="arrow"] { transition: transform 0.24s cubic-bezier(0.65, 0, 0.35, 1); }
.raven-academy-sec .course-faqs_accordion-wrap .sec-open [data-academy-accordion="arrow"], .raven-academy-item .course-faqs_accordion-wrap .sec-open [data-academy-accordion="arrow"] { transform: rotate(180deg); }
/*
 * Reduced motion: the hub's floating art stops (R826-1). Live's own rule names `.sec-hl-art`, but
 * its markup uses `.sec-hl-art-2`, so on live the tag keeps floating (checked 2026-11-13). The
 * rule is applied to the class the markup uses: accessibility is not copied from live's bug.
 */
@media (prefers-reduced-motion: reduce) {
  .raven-academy-sec .sec-hl-art *, .raven-academy-sec .sec-hl-art-2 * { animation: none !important; translate: none !important; }
}
@media (prefers-reduced-motion: reduce) {
  .raven-academy-sec .course-faqs_accordion-wrap [data-academy-accordion="content"], .raven-academy-item .course-faqs_accordion-wrap [data-academy-accordion="content"],
  .raven-academy-sec .course-faqs_accordion-wrap [data-academy-accordion="arrow"], .raven-academy-item .course-faqs_accordion-wrap [data-academy-accordion="arrow"] { transition: none; }
}

/* "On this page": below 992px live's interaction shows it as a bar fixed under the navbar. */
@media screen and (max-width: 991px) {
  .raven-academy-sec .guide-content_toc-wrap, .raven-academy-item .guide-content_toc-wrap {
    display: block;
    top: 4rem;
  }
  .raven-academy-sec .guide-content_toc-wrap.sec-toc-open .guide-content_toc-icon, .raven-academy-item .guide-content_toc-wrap.sec-toc-open .guide-content_toc-icon { transform: rotate(180deg); }
  /*
   * The item templates' bar starts closed and opens with the heading, as the security pages'
   * (their rule is ported from live, security-pages.css): the list shows only while the
   * heading says it is open (team review on #826).
   */
  .raven-academy-item .guide-content_toc-wrap:not(.sec-toc-open) .fs-toc_link-content { display: none; }
  .raven-academy-item .guide-content_toc-wrap .guide-content_toc-heading-wrap { cursor: pointer; }
  .raven-academy-item .guide-content_toc-wrap .guide-content_toc-icon { transition: transform 0.2s ease; }
}
@media screen and (max-width: 991px) and (prefers-reduced-motion: reduce) {
  .raven-academy-item .guide-content_toc-wrap .guide-content_toc-icon { transition: none; }
}

/* Mobile breadcrumb "…": live's "Articles in this section" sheet (opened with live's `show` class, security-pages.css). */
.raven-academy-sec .bread-crumb_ellipsis, .raven-academy-item .bread-crumb_ellipsis { cursor: pointer; }

/*
 * Live's hero backgrounds sit at z-index -1 inside the page body. In Raven the
 * block root is a stacking context of its own, so they stay above the page
 * background instead of falling behind it.
 */
.raven-academy-sec, .raven-academy-item,
.raven-academy-list { isolation: isolate; }

/*
 * Lists in live's rich text use the browser's own markers; Raven's base CSS
 * removes them site-wide, so they are put back inside the Academy blocks.
 */
.raven-academy-sec .w-richtext ul, .raven-academy-item .w-richtext ul { list-style: disc; }
.raven-academy-sec .w-richtext ol, .raven-academy-item .w-richtext ol { list-style: decimal; }

/*
 * Gold Masterclass cards: Batch D's copy button sits next to the card link, not inside it
 * (R818-20). A same-size stand-in holds its place in the info row (live's look); the button
 * is placed over it from the card's width: the 4:3 image (75cqw) plus its bottom margin
 * (1.5rem; 1.25rem at 767px and below, as listings.css). Same rule as guide-cards.css.
 */
.raven-academy-list .academy-card_component { position: relative; container-type: inline-size; }
.raven-academy-list .share-block_button.is-card.is-placeholder { visibility: hidden; pointer-events: none; }
.raven-academy-list .share-block_button.is-card.is-overlay {
  position: absolute;
  top: calc(75cqw + 1.5rem);
  inset-inline-end: 0;
  margin: 0;
  padding: 0;
  border: 0;
  background-color: transparent;
}
.raven-academy-list .share-block_button.is-card.is-overlay:hover { background-color: #00000014; }
.raven-academy-list .share-block_button.is-card.is-overlay:active { background-color: #0000003d; }
@media screen and (max-width: 767px) {
  .raven-academy-list .share-block_button.is-card.is-overlay { top: calc(75cqw + 1.25rem); }
}
/* D's hidden "Copied" status next to the copy button (guide-base.css rule, for F's own root). */
.raven-academy-list .academy-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/*
 * The hub's card arrows are F's inline SVG (decisions-and-facts §22: icon glyphs become inline SVGs). The ported
 * rules size the box to 0 and draw live's Font Awesome glyph in ::before, which needs
 * Webflow's icon font (R826-10): the box gets the glyph's 16px back and the ::before goes.
 */
.raven-academy-sec .sec-tt-arrow { font-size: 16px; line-height: 1; }
.raven-academy-sec .sec-tt-arrow::before { content: none; }

/* Words for screen readers only (the copy status the share script adds on item pages; the listings' new-tab notes). */
.raven-academy-item .academy-sr-only, .raven-academy-list .academy-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/*
 * Ebook card hover (/trading-ebooks; 2026-11-15 preview review): live's Webflow interaction grows
 * the cover to 1.07 over 0.5 s (outQuart) and back, as on the home's ebook cards
 * (home-behaviour.css) and every guide and course card (guide-cards.css). Pure :hover for mouse
 * devices; nothing for visitors who ask for reduced motion.
 */
.raven-academy-list .academy-ebook_image { transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1); }
@media (hover: hover) {
  .raven-academy-list .academy-card_link:hover .academy-ebook_image { transform: scale(1.07); }
}
@media (prefers-reduced-motion: reduce) {
  .raven-academy-list .academy-ebook_image { transition: none; }
  .raven-academy-list .academy-card_link:hover .academy-ebook_image { transform: perspective(50px); }
}
