/*
  Site styles shared by every page (ae- prefix). Brand colours come from the logo:
  navy #14477C, blue #2D81AE, tint #e8f3fa. Page-specific styles stay in each page's <style> block.
*/

/* Layout and type */
.ae-wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.ae-narrow { max-width: 820px; }
.ae-eyebrow { margin: 0 0 10px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #2D81AE; }
.ae-h2 { margin: 0; font-size: clamp(26px, 3vw, 36px); line-height: 1.2; font-weight: 700; color: #14477C; letter-spacing: -.01em; }
.ae-h3 { margin: 0 0 8px; font-size: 20px; font-weight: 700; color: #14477C; }
.ae-lead { max-width: 640px; margin: 14px 0 0; font-size: 17px; line-height: 1.6; color: #4a5a6b; }
.ae-center { text-align: center; margin-top: 40px; }
.ae-center-text { text-align: center; }
.ae-center-text .ae-lead { margin-left: auto; margin-right: auto; }
.ae-section { padding: 72px 0; background: #fff; }
.ae-section--tint { background: #f6f9fc; }
.ae-muted { color: #5b6b7c; }
.ae-link { color: #2D81AE; font-weight: 600; text-decoration: none; }
.ae-link:hover { color: #14477C; text-decoration: underline; }

/* Buttons */
.ae-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 24px; font-size: 16px; font-weight: 600; border-radius: 8px; border: 0; cursor: pointer; text-decoration: none; transition: background-color .15s, color .15s, border-color .15s, transform .15s; }
.ae-btn:hover { transform: translateY(-1px); }
.ae-btn--primary { color: #fff !important; background: #14477C; }
.ae-btn--primary:hover { background: #2D81AE; }
.ae-btn--ghost { color: #14477C !important; background: #fff; border: 1px solid #cfdcea; }
.ae-btn--ghost:hover { border-color: #2D81AE; color: #2D81AE !important; }
.ae-btn--light { color: #14477C !important; background: #fff; }
.ae-btn--light:hover { background: #e8f3fa; }

/* Inner page header (partial pagehero) */
.ae-pagehero { padding: 56px 0 52px; background: radial-gradient(900px 380px at 90% 0%, #e2f0fa 0%, rgba(226,240,250,0) 60%), linear-gradient(180deg, #f5f9fd 0%, #fff 100%); border-bottom: 1px solid #edf2f7; }
.ae-pagehero__crumbs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; font-size: 13px; color: #6b7b8c; }
.ae-pagehero__crumbs a { color: #2D81AE; text-decoration: none; }
.ae-pagehero__crumbs a:hover { text-decoration: underline; }
.ae-pagehero__title { margin: 0; font-size: clamp(30px, 4vw, 44px); line-height: 1.12; font-weight: 800; letter-spacing: -.02em; color: #14477C; }
.ae-pagehero__lead { max-width: 640px; margin: 14px 0 0; font-size: 18px; line-height: 1.6; color: #4a5a6b; }
.ae-pagehero--compact { padding: 36px 0 32px; }
.ae-pagehero--compact .ae-pagehero__title { font-size: clamp(26px, 3vw, 34px); }

/* Cards and feature grids */
.ae-card { padding: 28px; background: #fff; border: 1px solid #e3ebf3; border-radius: 12px; box-shadow: 0 1px 2px rgba(20,71,124,.04); }
.ae-card--tint { background: #f6f9fc; }
.ae-features { padding: 88px 0; background: #fff; }
.ae-features__grid { display: grid; gap: 20px; margin-top: 48px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .ae-features__grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .ae-features__grid { grid-template-columns: repeat(4, 1fr); } }
.ae-feature { padding: 26px 24px; border: 1px solid #e3ebf3; border-radius: 12px; background: #fff; }
.ae-feature__icon { display: inline-flex; width: 44px; height: 44px; align-items: center; justify-content: center; margin-bottom: 16px; color: #14477C; background: #e8f3fa; border-radius: 10px; }
.ae-feature h3 { margin: 0 0 8px; font-size: 17px; font-weight: 700; color: #14477C; }
.ae-feature p { margin: 0; font-size: 15px; line-height: 1.6; color: #4a5a6b; }

/* Numbered steps */
.ae-steps { display: grid; gap: 20px; margin-top: 44px; grid-template-columns: 1fr; counter-reset: step; }
@media (min-width: 768px) { .ae-steps { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .ae-steps--4 { grid-template-columns: repeat(4, 1fr); } .ae-steps--3 { grid-template-columns: repeat(3, 1fr); } }
.ae-step { position: relative; padding: 26px 24px; background: #fff; border: 1px solid #e3ebf3; border-radius: 12px; }
.ae-step::before { counter-increment: step; content: counter(step); display: inline-flex; width: 34px; height: 34px; align-items: center; justify-content: center; margin-bottom: 14px; font-size: 15px; font-weight: 700; color: #fff; background: #14477C; border-radius: 50%; }
.ae-step h3 { margin: 0 0 8px; font-size: 17px; font-weight: 700; color: #14477C; }
.ae-step p { margin: 0; font-size: 15px; line-height: 1.6; color: #4a5a6b; }

/* Call-to-action band */
.ae-band { padding: 56px 0; background: linear-gradient(120deg, #14477C 0%, #1d5f96 60%, #2D81AE 100%); color: #fff; }
.ae-band__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.ae-band h2 { margin: 0; font-size: clamp(22px, 2.6vw, 30px); font-weight: 700; color: #fff; }
.ae-band p { margin: 8px 0 0; font-size: 16px; color: rgba(255,255,255,.85); }

/* FAQ accordion (partial faqs) */
.ae-acc { margin: 0; padding: 0; list-style: none; border-top: 1px solid #e3ebf3; }
.ae-acc__item { border-bottom: 1px solid #e3ebf3; }
.ae-acc__q { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 4px; font-size: 17px; font-weight: 600; line-height: 1.4; color: #14477C; text-align: left; background: none; border: 0; cursor: pointer; }
.ae-acc__q:hover { color: #2D81AE; }
.ae-acc__icon { flex-shrink: 0; display: inline-flex; width: 28px; height: 28px; align-items: center; justify-content: center; color: #2D81AE; background: #e8f3fa; border-radius: 50%; transition: transform .25s; }
.ae-acc__item.is-open .ae-acc__icon { transform: rotate(45deg); }
.ae-acc__a { overflow: hidden; max-height: 0; transition: max-height .3s ease; }
.ae-acc__body { padding: 0 4px 22px; font-size: 16px; line-height: 1.7; color: #4a5a6b; }
.ae-acc__body p { margin: 0 0 10px; }
.ae-acc__body ul { margin: 8px 0 0; padding-left: 20px; list-style: disc; }
.ae-acc__body li { margin: 4px 0; }
.ae-acc__body a { color: #2D81AE; font-weight: 600; }

/* Forms (Mall, RainLab User and our own) */
.mall-form-control label { font-size: 14px !important; font-weight: 600 !important; letter-spacing: 0 !important; text-transform: none !important; color: #1f2d3d !important; margin-bottom: 6px !important; }
.mall-form-control input, .mall-form-control textarea, .mall-form-control select { background: #fff !important; border: 1px solid #cfdcea !important; border-radius: 8px !important; padding: 12px 14px !important; font-size: 16px !important; color: #1f2d3d !important; box-shadow: none !important; transition: border-color .15s, box-shadow .15s; }
.mall-form-control input:focus, .mall-form-control textarea:focus, .mall-form-control select:focus { outline: none; border-color: #2D81AE !important; box-shadow: 0 0 0 3px rgba(45,129,174,.18) !important; }
.mall-form-control input::placeholder, .mall-form-control textarea::placeholder { color: #9aa8b6; }
.mall-btn--primary { background: #14477C !important; border-color: #14477C !important; color: #fff !important; border-radius: 8px !important; padding: 12px 22px !important; font-size: 15px !important; font-weight: 600 !important; box-shadow: none !important; transition: background-color .15s; }
.mall-btn--primary:hover { background: #2D81AE !important; border-color: #2D81AE !important; }
.mall-signup__heading, .mall-signup h3 { margin: 0 0 20px; font-size: 22px; font-weight: 700; color: #14477C; }
[data-validate-for] { font-size: 14px; color: #c0392b; }

/* Log in / sign up: two cards */
.ae-auth .grid { gap: 24px !important; align-items: start; }
.ae-auth .grid > div { padding: 28px; background: #fff; border: 1px solid #e3ebf3; border-radius: 12px; box-shadow: 0 1px 2px rgba(20,71,124,.04); }
.ae-auth h3 { margin: 22px 0 14px; font-size: 18px; font-weight: 700; color: #14477C; }
.ae-auth h3.mall-signup__heading { margin-top: 0; font-size: 22px; }
.ae-auth .mall-form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.ae-auth .mall-form-actions a { margin: 0 !important; color: #2D81AE; font-weight: 600; }

/* Account, cart and checkout pages (layout's cartpage placeholder) */
.ae-app { padding: 40px 0 72px; }
.ae-app .ae-wrap > nav a { font-weight: 600; color: #3b4a5c; }
.ae-app .ae-wrap > nav a.bg-gray-100, .ae-app .ae-wrap > nav a:hover { color: #14477C; background: #e8f3fa !important; }

/* Footer */
.ae-footer { color: #c9d8e6; background: #0f355d; }
.ae-footer a { color: #e3edf6; text-decoration: none; }
.ae-footer a:hover { color: #fff; text-decoration: underline; }
.ae-footer__top { display: grid; gap: 40px; padding: 64px 0 48px; grid-template-columns: 1fr; }
@media (min-width: 768px) { .ae-footer__top { grid-template-columns: 1.6fr 1fr 1fr; gap: 48px; } }
.ae-footer__logo img { height: 44px; width: auto; filter: brightness(0) invert(1); }
.ae-footer__about { max-width: 380px; margin: 18px 0 0; font-size: 15px; line-height: 1.65; }
.ae-footer h4 { margin: 0 0 14px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #fff; }
.ae-footer ul { margin: 0; padding: 0; list-style: none; }
.ae-footer li { margin: 0 0 10px; font-size: 15px; }
.ae-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding: 22px 0 28px; font-size: 14px; border-top: 1px solid rgba(255,255,255,.12); }
.ae-footer__legal { display: flex; flex-wrap: wrap; gap: 6px 20px; }

/* 404 */
.ae-notfound { padding: 96px 0 104px; text-align: center; }
.ae-notfound__code { margin: 0 0 8px; font-size: 64px; font-weight: 800; letter-spacing: -.03em; color: #cfe2f1; }
.ae-notfound .ae-hero__actions, .ae-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 28px; }
.ae-account__head { margin-bottom: 32px; padding-bottom: 24px; border-bottom: 1px solid #edf2f7; }
.ae-account__head .ae-pagehero__title { font-size: clamp(26px, 3vw, 34px); }
.ae-empty { max-width: 640px; margin: 0 auto; text-align: center; }
.ae-empty p { margin: 0; }
.mall-signup-terms { padding: 14px 16px !important; background: #f6f9fc !important; border: 1px solid #e3ebf3 !important; border-radius: 8px !important; }
.mall-signup-terms a { color: #2D81AE; font-weight: 600; }
.mall-btn--primary:disabled, .mall-btn--primary[disabled] { background: #9fb3c8 !important; border-color: #9fb3c8 !important; cursor: not-allowed; }

/* Phones: tighter vertical rhythm */
@media (max-width: 639px) {
    .ae-pagehero { padding: 36px 0 32px; }
    .ae-pagehero__lead { font-size: 16px; }
    .ae-section, .ae-features, .ae-courses, .ae-faq { padding: 48px 0 !important; }
    .ae-features__grid, .ae-steps, .ae-courses__grid { margin-top: 32px; }
    .ae-card, .ae-auth .grid > div { padding: 20px; }
    .ae-acc__q { font-size: 16px; padding: 18px 2px; }
    .ae-band { padding: 44px 0; }
    .ae-band .ae-btn { width: 100%; }
    .ae-footer__top { padding: 48px 0 32px; gap: 32px; grid-template-columns: 1fr 1fr; }
    .ae-footer__top > div:first-child { grid-column: 1 / -1; }
    .ae-app { padding: 28px 0 48px; }
    .ae-notfound { padding: 64px 0 72px; }
    .ae-actions .ae-btn { width: 100%; }
}
@media (max-width: 767px) {
    .ae-account__nav { flex-wrap: wrap; gap: 8px; margin: 0 0 24px !important; }
    .ae-account__nav > div { flex: 1 1 auto; }
    .ae-account__nav a { white-space: nowrap; border: 1px solid #e3ebf3; border-radius: 999px !important; font-size: 14px; }
}
@media (max-width: 639px) {
    .ae-transcript thead { display: none; }
    .ae-transcript, .ae-transcript tbody, .ae-transcript tr, .ae-transcript td { display: block; width: 100%; }
    .ae-transcript tr { margin-bottom: 12px; padding: 14px 16px; border: 1px solid #e3ebf3 !important; border-radius: 10px; }
    .ae-transcript td { display: flex; justify-content: space-between; gap: 16px; padding: 4px 0 !important; text-align: right !important; }
    .ae-transcript td::before { content: attr(data-label); font-weight: 600; color: #5b6b7c; text-align: left; }
    .ae-transcript td:not([data-label]) { justify-content: flex-start; align-items: center; padding-top: 10px !important; }
    .ae-transcript td:not([data-label])::before { display: none; }
    .ae-transcript__module { font-weight: 600; color: #14477C; }
}

/* ------------------------------------------------------------------ */
/* Cart page: table, totals, discount code, checkout button            */
/* ------------------------------------------------------------------ */
.mall-cart { max-width: none; margin: 0; } /* full width, lined up with the page heading */
.mall-cart__wrapper { background: #fff; border: 1px solid #e3eaf1; border-radius: 14px; overflow: hidden; box-shadow: 0 18px 40px -30px rgba(16, 40, 60, .45); }
.mall-cart__table { width: 100%; border-collapse: collapse; }
.mall-cart__table td:last-child, .mall-cart__table th:last-child { white-space: nowrap; } /* amounts never wrap */
.mall-cart__table th, .mall-cart__table td { padding: 16px 20px !important; border: 0 !important; }
.mall-cart__header th { background: #f6f9fc !important; color: #5b6b7c; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; border-bottom: 1px solid #e3eaf1 !important; }
.mall-cart__header th:first-child, .mall-cart__product td:first-child { width: 60%; }
.mall-cart__product td { border-bottom: 1px solid #e3eaf1 !important; color: #1f2d3a; font-size: 16px; vertical-align: top; }
.mall-cart__product a:not(.js-mall-remove-product) { color: #14477C !important; font-weight: 600; text-decoration: none; }
.mall-cart__product a:not(.js-mall-remove-product):hover { text-decoration: underline; }
.mall-cart__product .js-mall-remove-product { display: inline-block; margin-top: 6px; color: #5b6b7c !important; font-size: 13px; text-decoration: none; }
.mall-cart__product .js-mall-remove-product:hover { color: #14477C !important; text-decoration: underline; }
.mall-cart__table tfoot td { background: #fff !important; color: #5b6b7c; font-size: 15px; padding-top: 10px !important; padding-bottom: 10px !important; }
.mall-cart__total td { padding-top: 18px !important; }
.mall-cart__grand-total td { background: #f6f9fc !important; border-top: 1px solid #e3eaf1 !important; color: #14477C !important; font-size: 20px !important; font-weight: 800; padding-top: 16px !important; padding-bottom: 16px !important; }

.mall-discount-applier { display: block !important; width: 100%; }
.cart-discount { display: flex; justify-content: flex-end; width: 100%; margin-top: 24px; }
.cart-discount__form { display: block !important; flex: 0 1 460px; width: 100%; max-width: 460px; padding: 18px 20px; background: #f6f9fc; border: 1px solid #e3eaf1; border-radius: 12px; }
.cart-discount__label { display: block; margin: 0 0 10px; color: #14477C !important; font-size: 14px !important; font-weight: 600; letter-spacing: 0 !important; text-transform: none !important; }
.cart-discount__row { display: flex; gap: 10px; }
.cart-discount__input { flex: 1 1 auto; min-width: 0; height: 46px; padding: 0 14px !important; background: #fff !important; border: 1px solid #cfdbe3 !important; border-radius: 8px !important; font-size: 15px; color: #1f2d3a; }
.cart-discount__input:focus { outline: none; border-color: #2D81AE !important; box-shadow: 0 0 0 3px rgba(23, 145, 191, .18); }
.cart-discount__btn { flex: 0 0 auto; height: 46px; padding: 0 20px !important; margin: 0 !important; border-radius: 8px !important; background: #fff !important; color: #14477C !important; border: 1.5px solid #14477C !important; font-weight: 600; white-space: nowrap; transition: background-color .15s ease, color .15s ease; }
.cart-discount__btn:hover { background: #14477C !important; color: #fff !important; }
.cart-discount__error:not(:empty) { margin-top: 8px; color: #14477C; font-size: 13px; }

.mall-cart-actions { display: flex; justify-content: flex-end; margin-top: 20px; padding-top: 0 !important; border-top: 0 !important; }
.mall-cart-actions .mall-btn--primary { min-width: 220px; padding: 16px 28px !important; border-radius: 10px !important; background: #14477C !important; border-color: #14477C !important; color: #fff !important; font-size: 17px; font-weight: 700; box-shadow: 0 12px 24px -14px rgba(0, 0, 0, .45); transition: background-color .15s ease, transform .15s ease; }
.mall-cart-actions .mall-btn--primary:hover { background: #2D81AE !important; transform: translateY(-1px); }

@media (max-width: 640px) {
    .mall-cart__table th, .mall-cart__table td { padding: 12px 14px !important; }
    /* Phones: drop the Price column (Total shows the same amount) and the empty first cell of the totals rows */
    .mall-cart__header th:nth-child(2), .mall-cart__product td:nth-child(2), .mall-cart__table tfoot td:first-child { display: none; }
    .mall-cart__header th:first-child, .mall-cart__product td:first-child { width: auto; }
    .mall-cart__table tfoot td { font-size: 14px; }
    .mall-cart__grand-total td { font-size: 18px !important; }
    .cart-discount__form { max-width: none; }
    .cart-discount__row { flex-direction: column; }
    .cart-discount__btn { width: 100%; }
    .mall-cart-actions .mall-btn--primary { width: 100%; }
}

/* ------------------------------------------------------------------ */
/* Checkout: payment step (method card, name fields, Stripe card box)  */
/* ------------------------------------------------------------------ */
.mall-payment-method { background: #fff; border: 1px solid #e3eaf1 !important; border-radius: 14px; box-shadow: 0 18px 40px -30px rgba(16, 40, 60, .45); overflow: hidden; }
.mall-payment-method > .js-mall-select-payment-method { margin: 0 !important; padding: 24px 28px !important; border: 0 !important; }
.mall-payment-method > .js-mall-select-payment-method + .js-mall-select-payment-method { border-top: 1px solid #e3eaf1 !important; }
.mall-payment-method__name { color: #14477C; font-size: 18px; font-weight: 700; margin-bottom: 14px; }
.mall-payment-method label, .mall-payment-method .mall-label { display: block; margin-bottom: 6px; color: #5b6b7c !important; font-size: 13px !important; font-weight: 600; letter-spacing: 0 !important; text-transform: none !important; }
.mall-payment-method input[type="text"] { height: 46px; padding: 0 14px !important; font-size: 15px; }
.mall-payment-method .mall-form-control { max-width: 520px !important; margin-bottom: 16px; }
#card-element { max-width: 520px; min-height: 46px; padding: 13px 14px !important; background: #fff !important; border: 1px solid #cfdbe3 !important; border-radius: 8px !important; color: #5b6b7c; transition: border-color .15s ease, box-shadow .15s ease; }
#card-element.StripeElement--focus { border-color: #2D81AE !important; box-shadow: 0 0 0 3px rgba(23, 145, 191, .18); }
#card-element.StripeElement--invalid { border-color: #14477C !important; }
#card-errors:not(:empty) { margin-top: 8px; color: #14477C; font-size: 13px; }
.mall-payment-method__submit { margin-top: 8px; }
.mall-payment-method__submit .mall-btn--primary { min-width: 240px; padding: 15px 28px !important; border-radius: 10px !important; background: #14477C !important; border-color: #14477C !important; color: #fff !important; font-size: 16px; font-weight: 700; box-shadow: 0 12px 24px -14px rgba(0, 0, 0, .45); transition: background-color .15s ease, transform .15s ease; }
.mall-payment-method__submit .mall-btn--primary:hover { background: #2D81AE !important; transform: translateY(-1px); }
@media (max-width: 640px) {
    .mall-payment-method > .js-mall-select-payment-method { padding: 18px !important; }
    .mall-payment-method__submit .mall-btn--primary { width: 100%; }
}

/* ------------------------------------------------------------------ */
/* Checkout: confirm step (fits one desktop screen)                    */
/* ------------------------------------------------------------------ */
.checkout-review { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 32px; align-items: start; max-width: 1120px; margin: 0 auto; }
.checkout-title { margin: 0 0 16px !important; padding: 0 !important; color: #14477C; font-size: 26px; font-weight: 800; letter-spacing: -.01em; }
.checkout-box { position: relative; margin-bottom: 14px; padding: 16px 20px; background: #fff; border: 1px solid #e3eaf1; border-radius: 12px; font-size: 15px; line-height: 1.5; color: #1f2d3a; }
.checkout-box__title { margin: 0 0 6px !important; padding: 0 !important; color: #5b6b7c; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.checkout-box .mall-address-selector { font-size: 15px; }
.checkout-box .mall-address-selector, .checkout-box .mall-address, .checkout-box .mall-address__actions + * { position: static !important; }
.checkout-box .mall-address p { margin: 0 !important; }
.checkout-box .mall-address__actions { position: absolute; top: 14px; right: 18px; }
.checkout-box a, .checkout-box__change { color: #14477C !important; font-size: 14px; font-weight: 600; }
.checkout-box__change { position: absolute; top: 14px; right: 18px; }
.checkout-pay { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }
.checkout-pay__method { font-weight: 600; }
.checkout-pay__card { color: #5b6b7c; }
.checkout-review__order { position: sticky; top: 100px; padding: 20px; background: #f6f9fc; border: 1px solid #e3eaf1; border-radius: 14px; }
.checkout-review__order > .checkout-box__title { margin-bottom: 12px !important; }
.checkout-review__order .mall-cart { max-width: none; margin: 0; }
.checkout-review__order .mall-cart__table th, .checkout-review__order .mall-cart__table td { padding: 11px 16px !important; }
.checkout-review__order .mall-cart__total td { padding-top: 12px !important; }
.checkout-review__order .js-mall-remove-product { display: none !important; }
.checkout-consent { display: flex; gap: 10px; align-items: flex-start; margin: 16px 0 0; color: #5b6b7c; font-size: 13px; line-height: 1.45; cursor: pointer; }
.checkout-consent input { margin-top: 3px; flex: 0 0 auto; }
.checkout-review__order .mall-cart-actions { margin-top: 16px; }
.checkout-review__order .mall-btn-checkout { width: 100%; padding: 16px 28px !important; border-radius: 10px !important; background: #14477C !important; border: 0 !important; color: #fff !important; font-size: 17px; font-weight: 700; box-shadow: 0 12px 24px -14px rgba(0, 0, 0, .45); transition: background-color .15s ease, transform .15s ease; }
.checkout-review__order .mall-btn-checkout:hover { background: #2D81AE !important; transform: translateY(-1px); }
@media (max-width: 900px) {
    .checkout-review { grid-template-columns: 1fr; gap: 20px; }
    .checkout-review__order { position: static; }
}

/* ------------------------------------------------------------------ */
/* Failed payment: result page, retry notice, orders list badge        */
/* ------------------------------------------------------------------ */
.checkout-result { max-width: 620px; margin: 48px auto 64px; padding: 32px 32px 28px; background: #fff; border: 1px solid #f1c4bf; border-top: 5px solid #c0392b; border-radius: 14px; box-shadow: 0 22px 44px -30px rgba(120, 30, 20, .45); text-align: center; }
.checkout-result__icon { width: 52px; height: 52px; margin: 0 auto 14px; border-radius: 50%; background: #fdecea; color: #c0392b; font-size: 28px; font-weight: 800; line-height: 52px; }
.checkout-result__title { margin: 0 0 10px !important; padding: 0 !important; color: #1f2d3a; font-size: 26px; font-weight: 800; letter-spacing: -.01em; }
.checkout-result__reason { display: inline-block; margin: 0 0 14px; padding: 8px 14px; background: #fdecea; border-radius: 8px; color: #a5281b; font-weight: 600; }
.checkout-result__text { margin: 0 auto 22px; max-width: 460px; color: #5b6b7c; font-size: 16px; line-height: 1.55; }
.checkout-result--success { border-color: #cde7d6; border-top-color: #2e8b57; box-shadow: 0 22px 44px -30px rgba(20, 90, 50, .45); }
.checkout-result--success .checkout-result__icon { background: #e6f4ec; color: #2e8b57; }
.checkout-result--neutral { border-color: #e3eaf1; border-top-color: #14477C; box-shadow: 0 22px 44px -30px rgba(20, 71, 124, .35); }
.checkout-result__actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.checkout-result__primary { display: inline-block; padding: 14px 26px; border-radius: 10px; background: #14477C; color: #fff !important; font-weight: 700; text-decoration: none !important; box-shadow: 0 12px 24px -14px rgba(0, 0, 0, .45); transition: background-color .15s ease, transform .15s ease; }
.checkout-result__primary:hover { background: #2D81AE; transform: translateY(-1px); }
.checkout-result__secondary { display: inline-block; padding: 14px 22px; border-radius: 10px; color: #14477C !important; font-weight: 600; text-decoration: none !important; box-shadow: inset 0 0 0 1.5px #e3eaf1; }
.checkout-result__secondary:hover { box-shadow: inset 0 0 0 1.5px #14477C; }
.pay-amount { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin: 0 0 18px; padding: 14px 18px; background: #f6f9fc; border: 1px solid #e3eaf1; border-radius: 10px; color: #3b4a5c; font-weight: 600; }
.pay-amount strong { color: #14477C; font-size: 24px; font-weight: 800; }
.pay-retry-note { max-width: 720px; margin: 0 0 18px; padding: 14px 18px; background: #fdecea; border: 1px solid #f1c4bf; border-left: 4px solid #c0392b; border-radius: 10px; color: #7a2016; font-size: 15px; line-height: 1.5; }
.pay-retry-note strong { display: block; color: #a5281b; }
.order-pay-state { display: inline-block; padding: 3px 10px; border-radius: 999px; background: #fdecea; color: #a5281b; font-size: 13px; font-weight: 700; white-space: nowrap; }
.order-paid-state { display: inline-block; padding: 3px 10px; border-radius: 999px; background: #e6f4ec; color: #14663a; font-size: 13px; font-weight: 700; white-space: nowrap; }
.order-refunded-state { display: inline-block; padding: 3px 10px; border-radius: 999px; background: #eef1f4; color: #4a5563; font-size: 13px; font-weight: 700; white-space: nowrap; }
.order-pay-now { display: inline-block; margin-left: 8px; padding: 4px 12px; border-radius: 8px; background: #14477C; color: #fff !important; font-size: 13px; font-weight: 700; text-decoration: none !important; white-space: nowrap; }
.order-pay-now:hover { background: #2D81AE; }
@media (max-width: 640px) {
    .checkout-result { margin: 32px 16px 48px; padding: 24px 18px; }
    .checkout-result__actions a { width: 100%; }
    .order-pay-now { margin: 6px 0 0; }
}
.checkout-error { margin: 12px 0 0; padding: 12px 14px; background: #fdecea; border: 1px solid #f1c4bf; border-left: 4px solid #c0392b; border-radius: 8px; color: #a5281b; font-size: 14px; font-weight: 600; }

/* ------------------------------------------------------------------ */
/* Receipt (/account/receipt)                                          */
/* ------------------------------------------------------------------ */
.ae-receipt { max-width: 720px; padding: 28px; background: #fff; border: 1px solid #e3ebf3; border-radius: 14px; }
.ae-receipt__head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 20px; padding: 0; }
.ae-receipt__brand { margin: 0 !important; padding: 0 !important; color: #14477C; font-size: 22px; font-weight: 800; }
.ae-receipt__facts { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); margin: 0 0 24px; }
.ae-receipt__facts dt { font-size: 13px; font-weight: 700; color: #5b6b7c; }
.ae-receipt__facts dd { margin: 2px 0 0; }
.ae-receipt__items { width: 100%; border-collapse: collapse; }
.ae-receipt__items th, .ae-receipt__items td { padding: 10px 0; border-top: 1px solid #e3ebf3; text-align: left; }
.ae-receipt__items th:last-child, .ae-receipt__items td:last-child { text-align: right; white-space: nowrap; }
.ae-receipt__items tfoot th { font-size: 18px; color: #14477C; }
.ae-receipt__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
@media print {
    .ae-header, .ae-footer, .ae-noprint { display: none !important; }
    .ae-app { padding: 0; }
    .ae-receipt { padding: 0; border: 0; }
}

/* ------------------------------------------------------------------ */
/* Student dashboard, section page and exam                            */
/* ------------------------------------------------------------------ */
.ae-sections { margin: 0; padding: 0; list-style: none; }
.ae-sections__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin: 0 0 10px; padding: 14px 20px; background: #fff; border: 1px solid #e3ebf3; border-radius: 10px; }
.ae-sections__head { display: flex; flex: 1 1 280px; flex-wrap: wrap; align-items: center; gap: 4px 12px; min-width: 0; }
.ae-courseicon { display: block; flex: none; width: 40px; height: 40px; }
.ae-sections__name { display: flex; align-items: center; gap: 12px; min-width: 0; }
.ae-sections__title { min-width: 0; font-weight: 600; color: #14477C; overflow-wrap: anywhere; }
.ae-sections__status { flex: none; font-size: 14px; font-weight: 700; color: #14663a; }
.ae-sections__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ae-sections__actions .ae-btn { padding: 8px 14px; font-size: 14px; }
.ae-sections__soon { font-size: 14px; font-weight: 600; color: #5b6b7c; }
.ae-sections__row--passed { background: #e6f6ec; border-color: #a9dfbf; }
.ae-sections__row--passed .ae-sections__title { color: #14663a; }
.ae-notice { margin: 0 0 20px; padding: 14px 16px; color: #14477C; background: #e8f3fa; border-radius: 8px; }
.ae-material { display: block; width: 100%; height: 72vh; margin: 0 0 20px; background: #f6f9fc; border: 1px solid #e3ebf3; border-radius: 10px; }

.ae-course { max-width: 820px; margin: 0 auto; }
.ae-crumbs { display: flex; flex-wrap: wrap; gap: 4px 8px; margin-bottom: 20px; font-size: 14px; color: #5b6b7c; overflow-wrap: anywhere; }
.ae-crumbs a { color: #2D81AE; font-weight: 600; text-decoration: none; }
.ae-crumbs a:hover { text-decoration: underline; }
.ae-course__title { margin: 0 0 24px; font-size: clamp(24px, 3vw, 32px); line-height: 1.25; font-weight: 700; color: #14477C; overflow-wrap: anywhere; }
.ae-choices { display: flex; flex-wrap: wrap; gap: 12px; }
.ae-badge-passed { display: inline-block; margin: 0 0 16px; padding: 4px 12px; font-size: 14px; font-weight: 700; color: #14663a; background: #e6f6ec; border: 1px solid #a9dfbf; border-radius: 999px; }

.ae-exam [hidden] { display: none; } /* .ae-btn sets display, which would otherwise win */
.ae-exam__fields { margin: 0; padding: 0; border: 0; min-width: 0; }
.ae-exam__list { margin: 0 0 20px; padding: 0; list-style: none; counter-reset: ae-q; }
.ae-exam__q { counter-increment: ae-q; margin: 0 0 16px; padding: 20px; background: #fff; border: 1px solid #e3ebf3; border-radius: 10px; }
.ae-exam__q--right { background: #e6f6ec; border-color: #7ccf9e; }
.ae-exam__q--wrong { background: #fdecec; border-color: #eda5a5; }
.ae-exam__q--right .ae-exam__option input:checked + span { font-weight: 700; color: #14663a; }
.ae-exam__q--wrong .ae-exam__option input:checked + span { font-weight: 700; color: #a11d1d; }
.ae-exam__result { margin: 8px 0 0; font-weight: 700; }
.ae-exam__q--right .ae-exam__result { color: #14663a; }
.ae-exam__q--wrong .ae-exam__result { color: #a11d1d; }
.ae-exam__intro { margin: 0 0 16px; padding: 14px 16px; color: #1f2d3d; background: #f6f9fc; border: 1px solid #e3ebf3; border-radius: 10px; }
.ae-exam__intro p { margin: 0; }
.ae-exam__score { margin: 0 0 16px; font-size: 18px; font-weight: 700; color: #14477C; outline: none; }
.ae-exam__text { margin: 0 0 12px; font-weight: 600; color: #1f2d3d; overflow-wrap: anywhere; }
.ae-exam__text::before { content: counter(ae-q) ". "; color: #14477C; }
.ae-exam__option { display: flex; align-items: flex-start; gap: 10px; padding: 7px 0; cursor: pointer; overflow-wrap: anywhere; }
.ae-exam__option input { flex: none; margin-top: 4px; }
.ae-exam__option span { min-width: 0; }
.ae-exam__message { margin: 0 0 16px; padding: 12px 14px; font-weight: 600; color: #14477C; background: #e8f3fa; border-radius: 8px; }
.ae-exam__answer, .ae-exam__rationale { margin: 8px 0 0; overflow-wrap: anywhere; }
.ae-exam-passed { margin-bottom: 24px; }
@media (max-width: 639px) {
    .ae-exam__q { padding: 16px; }
    .ae-choices .ae-btn, .ae-exam .ae-btn { width: 100%; }
    .ae-sections__row { padding: 14px 16px; }
    .ae-sections__actions { width: 100%; }
    .ae-sections__actions .ae-btn { flex: 1 1 auto; }
    .ae-material { display: none; } /* phones show one page of an embedded PDF: View PDF opens all of it */
}

/* Hero and homepage FAQ */
.ae-hero { padding: 72px 0 80px; background: radial-gradient(1200px 500px at 85% 0%, #e6f2fa 0%, rgba(230,242,250,0) 60%), linear-gradient(180deg, #f7fbfe 0%, #fff 100%); }
.ae-hero__grid { display: grid; gap: 48px; align-items: center; grid-template-columns: 1fr; }
@media (min-width: 1024px) { .ae-hero__grid { grid-template-columns: 1.05fr .95fr; gap: 64px; } }
.ae-hero__title { margin: 0; font-size: clamp(34px, 4.6vw, 54px); line-height: 1.08; font-weight: 800; letter-spacing: -.02em; color: #14477C; }
.ae-hero__lead { max-width: 560px; margin: 20px 0 0; font-size: 18px; line-height: 1.65; color: #4a5a6b; }
.ae-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.ae-hero__points { display: flex; flex-wrap: wrap; gap: 10px 22px; margin: 28px 0 0; padding: 0; list-style: none; font-size: 14px; font-weight: 600; color: #3b4a5c; }
.ae-hero__points li { display: inline-flex; align-items: center; gap: 8px; }
.ae-hero__points li::before { content: ""; width: 18px; height: 18px; border-radius: 50%; background: #e8f3fa url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232D81AE' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center/12px no-repeat; }
.ae-hero__media img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 16px; box-shadow: 0 24px 48px -16px rgba(20,71,124,.28); }
.ae-faq { padding: 88px 0; background: #fff; }
.ae-faq__inner { max-width: 820px; }
.ae-faq__list { margin-top: 36px; }

/* FAQs page */
.ae-faqpage { display: grid; gap: 40px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 1024px) { .ae-faqpage { grid-template-columns: 1fr 320px; gap: 56px; } .ae-faqpage__aside { position: sticky; top: 112px; } }
.ae-faqpage__aside p { margin: 0 0 20px; font-size: 15px; line-height: 1.6; }

/* Contact */
.ae-contact { display: grid; gap: 40px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 1024px) { .ae-contact { grid-template-columns: 1fr 340px; gap: 56px; } }
.ae-contact__two { display: grid; gap: 0 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .ae-contact__two { grid-template-columns: 1fr 1fr; } }
.ae-contact__aside p { margin: 16px 0 0; font-size: 15px; line-height: 1.6; }
.ae-checklist { margin: 0; padding: 0; list-style: none; }
.ae-checklist li { position: relative; margin: 0 0 12px; padding-left: 30px; font-size: 15px; line-height: 1.5; color: #3b4a5c; }
.ae-checklist li::before { content: ""; position: absolute; left: 0; top: 1px; width: 20px; height: 20px; border-radius: 50%; background: #e8f3fa url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232D81AE' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center/12px no-repeat; }

/* Course bundle */
.ae-courses { padding: 88px 0; background: #f6f9fc; }
.ae-courses .ae-h2, .ae-courses .ae-eyebrow { text-align: center; }
.ae-courses .ae-lead { margin-left: auto; margin-right: auto; text-align: center; }
.ae-courses__grid { display: grid; gap: 10px; margin: 40px 0 0; padding: 0; list-style: none; grid-template-columns: 1fr; }
@media (min-width: 768px) { .ae-courses__grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .ae-courses__grid { grid-template-columns: repeat(3, 1fr); } }
.ae-coursename { display: flex; align-items: center; gap: 12px; padding: 6px 16px 6px 12px; font-size: 15px; font-weight: 600; color: #14477C; background: #fff; border: 1px solid #e3ebf3; border-radius: 10px; overflow-wrap: anywhere; }
.ae-coursename span { min-width: 0; }

/* Page text: headings, paragraphs, images and buttons from Website, Pages */
.ae-prose { max-width: 760px; }
.ae-prose > * + * { margin-top: 24px; }
.ae-prose__text { font-size: 17px; line-height: 1.7; color: #3b4a5c; }
.ae-prose__text > * + * { margin-top: 14px; }
.ae-prose__text h2, .ae-prose__text h3, .ae-prose__text h4 { font-weight: 700; line-height: 1.3; color: #14477C; }
.ae-prose__text h2 { font-size: 24px; }
.ae-prose__text h3 { font-size: 20px; }
.ae-prose__text h4 { font-size: 17px; }
.ae-prose__text ul, .ae-prose__text ol { margin-left: 0; padding-left: 22px; }
.ae-prose__text ul { list-style: disc; }
.ae-prose__text ol { list-style: decimal; }
.ae-prose__text li + li { margin-top: 6px; }
.ae-prose__text a { color: #2D81AE; font-weight: 600; text-decoration: none; }
.ae-prose__text a:hover { color: #14477C; text-decoration: underline; }
.ae-prose__text blockquote { padding-left: 16px; border-left: 3px solid #cfdcea; color: #4a5a6b; }
.ae-prose__figure { margin-left: 0; margin-right: 0; }
.ae-prose__figure img { display: block; max-width: 100%; height: auto; border-radius: 12px; }
.ae-prose__figure figcaption { margin-top: 8px; font-size: 14px; color: #5b6b7c; }

/* Student QA: account headings match, and long values stay readable on a phone. */
.ae-account__title { font-size: 20px; font-weight: 700; color: #14477C; }
.ae-auth .mall-form-actions a { padding-left: 0; padding-right: 0; }
.ae-crumbs { display: block; }
.ae-crumbs > * { display: inline; margin-right: 6px; }
@media (max-width: 639px) {
    .mall-two-fields:has(input[type="email"]) { flex-direction: column; gap: 16px; }
    .mall-two-fields:has(input[type="email"]) > * { flex: none; width: 100%; margin-left: 0; margin-right: 0; }
    .ae-receipt__actions .ae-btn { width: 100%; }
}
.checkout-review { padding-top: 32px; padding-bottom: 32px; }
