/* E-planet 2026 theme — dropdowns, content pages, news & blog. Loaded after eplanet.css. */

/* Dropdown menus */
.dropdown { position: absolute; top: calc(100% + 14px); left: 50%; min-width: 290px; transform: translate(-50%, 10px); opacity: 0; visibility: hidden; background: #fff; border-radius: 20px; box-shadow: var(--shadow-lg); padding: 12px; transition: opacity .25s, transform .3s var(--ease), visibility .25s; }
.dropdown::before { content: ""; position: absolute; left: 0; right: 0; top: -20px; height: 20px; }
.nav-item:hover .dropdown, .nav-item:focus-within .dropdown { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.dropdown a { display: flex; flex-direction: column; padding: 11px 14px; border-radius: 12px; transition: background .2s; }
.dropdown a:hover { background: var(--bg-soft); }
.dropdown a b { color: var(--ink); font-size: 14.5px; font-weight: 600; }
.dropdown a small { color: var(--muted); font-size: 12.5px; line-height: 1.4; }
.dropdown a.all { margin-top: 6px; border-top: 1px solid var(--line); border-radius: 0 0 12px 12px; padding-top: 14px; }
.dropdown a.all b { color: var(--blue); }

/* Section sub-navigation */
.subnav { position: sticky; top: var(--header-h); z-index: 20; background: rgba(255, 255, 255, .94); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.subnav .container { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-top: 12px; padding-bottom: 12px; }
.subnav .container::-webkit-scrollbar { display: none; }
.subnav a { white-space: nowrap; padding: 9px 16px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--text); transition: background .2s, color .2s; }
.subnav a:hover { color: var(--blue); background: var(--sky-50); }
.subnav a.active { background: var(--blue); color: #fff; }

/* Content pages */
.content-block + .content-block { margin-top: 110px; }
.content-block .media-frame { aspect-ratio: auto; }
.content-block .media-frame img { height: auto; }
.prose { font-size: 17px; line-height: 1.8; color: var(--text); }
.prose > * + * { margin-top: 1.1em; }
.prose p { margin: 0; }
.prose h2 { font-size: clamp(26px, 2.4vw, 34px); margin-top: 1.8em; }
.prose h3 { font-size: clamp(21px, 1.8vw, 25px); margin-top: 1.6em; }
.prose h4 { font-size: 19px; margin-top: 1.4em; }
.prose a { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.prose strong { color: var(--ink); }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .45em; }
.prose ul li::marker { color: var(--sky); }
.prose blockquote { margin: 1.6em 0; padding: 22px 28px; border-left: 4px solid var(--sky); background: var(--sky-50); border-radius: 0 16px 16px 0; color: var(--ink); font-size: 19px; }
.prose img { border-radius: var(--radius); margin: 1.6em auto; box-shadow: var(--shadow-sm); height: auto; }
.prose figure { margin: 1.6em 0; }
.prose figcaption { font-size: 14px; color: var(--muted); text-align: center; margin-top: -1em; }
.prose .yt, .yt { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; }
.yt iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.card-link { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .3s; height: 100%; }
.card-link:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.card-link .thumb { aspect-ratio: 16 / 10; overflow: hidden; background: var(--sky-50); }
.card-link .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.card-link:hover .thumb img { transform: scale(1.05); }
.card-link .body { padding: 26px 28px 30px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-link h3 { font-size: 21px; margin: 0; }
.card-link p { font-size: 15px; margin: 0; }
.card-link .link-arrow { margin-top: auto; padding-top: 10px; }
.card-link .num { width: 46px; height: 46px; border-radius: 14px; background: var(--sky-50); color: var(--blue); display: grid; place-items: center; font-weight: 800; }

/* News & blog */
.post-featured { display: grid; grid-template-columns: 1.25fr 1fr; background: #fff; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); margin-bottom: 60px; transition: transform .45s var(--ease), box-shadow .45s var(--ease); }
.post-featured:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.post-featured .thumb { min-height: 420px; position: relative; overflow: hidden; background: var(--sky-50); }
.post-featured .thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.post-featured:hover .thumb img { transform: scale(1.04); }
.post-featured .body { padding: 50px; display: flex; flex-direction: column; justify-content: center; gap: 16px; }
.post-featured h2 { font-size: clamp(26px, 2.6vw, 38px); margin: 0; }
.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; font-size: 13.5px; color: var(--muted); font-weight: 500; }
.post-meta .dotsep { width: 4px; height: 4px; border-radius: 50%; background: currentColor; opacity: .5; }
.post-card { display: flex; flex-direction: column; gap: 18px; }
.post-card .thumb { aspect-ratio: 16 / 10; border-radius: var(--radius); overflow: hidden; background: var(--sky-50); }
.post-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.post-card:hover .thumb img { transform: scale(1.06); }
.post-card h3 { font-size: 21px; margin: 0; line-height: 1.3; transition: color .2s; }
.post-card:hover h3 { color: var(--blue); }
.post-card p { font-size: 15px; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.article-hero { padding: 70px 0 0; background: var(--bg-soft); }
.article-hero h1 { font-size: clamp(34px, 4.4vw, 60px); max-width: 980px; }
.article-cover { margin-top: 44px; border-radius: var(--radius-lg) var(--radius-lg) 0 0; overflow: hidden; aspect-ratio: 21 / 9; background: var(--navy); }
.article-cover img { width: 100%; height: 100%; object-fit: cover; }
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 70px; align-items: start; }
.article-aside { position: sticky; top: calc(var(--header-h) + 30px); display: grid; gap: 20px; }
.aside-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; background: #fff; }
.aside-card h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 14px; }
.share { display: flex; gap: 10px; }
.share a, .share button { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: #fff; display: grid; place-items: center; color: var(--ink); transition: all .2s; padding: 0; }
.share a:hover, .share button:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.share svg { width: 16px; height: 16px; fill: currentColor; }
.aside-post { display: flex; gap: 14px; align-items: center; padding: 8px 0; }
.aside-post img { width: 74px; height: 56px; border-radius: 10px; object-fit: cover; flex: none; }
.aside-post b { font-size: 14px; color: var(--ink); line-height: 1.35; display: block; font-weight: 600; }
.aside-post:hover b { color: var(--blue); }
.progress-bar { position: fixed; top: 0; left: 0; height: 3px; width: 0; background: linear-gradient(90deg, var(--blue), var(--sky)); z-index: 70; }

@media (max-width: 1240px) {
    .nav > a, .nav-item > a { padding: 10px 11px; font-size: 14.5px; }
}
@media (max-width: 1100px) {
    .article-layout { grid-template-columns: 1fr; }
    .article-aside { position: static; }
}
@media (max-width: 900px) {
    .post-featured { grid-template-columns: 1fr; }
    .post-featured .thumb { min-height: 260px; }
    .post-featured .body { padding: 30px; }
    .content-block + .content-block { margin-top: 70px; }
    .article-cover { aspect-ratio: 16 / 10; border-radius: var(--radius) var(--radius) 0 0; }
}

/* Login */
.login-roots { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.login-root { text-align: left; border: 1px solid var(--line); background: #fff; border-radius: var(--radius-lg); padding: 28px; display: flex; flex-direction: column; gap: 6px; transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .3s; }
.login-root:hover { transform: translateY(-5px); box-shadow: var(--shadow); border-color: transparent; }
.login-root.active { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0, 80, 160, .15), var(--shadow); }
.login-root .ic { width: 54px; height: 54px; border-radius: 16px; background: var(--sky-50); color: var(--blue); display: grid; place-items: center; margin-bottom: 12px; transition: background .3s, color .3s; }
.login-root .ic svg { width: 24px; height: 24px; }
.login-root:hover .ic, .login-root.active .ic { background: var(--blue); color: #fff; }
.login-root b { font-size: 18px; color: var(--ink); }
.login-root small { color: var(--muted); font-size: 13.5px; }
.login-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.login-step, .login-link { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: 16px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-weight: 600; font-size: 15px; text-align: left; transition: all .25s var(--ease); }
.login-step:hover, .login-link:hover { border-color: var(--blue); color: var(--blue); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.login-step span, .login-link span { flex: 1; }
.login-step svg, .login-link svg { width: 18px; height: 18px; color: var(--blue); flex: none; transition: transform .25s var(--ease); }
.login-step:hover svg, .login-link:hover svg { transform: translateX(4px); }
.login-step img, .login-link img { width: 42px; height: 42px; object-fit: cover; border-radius: 10px; flex: none; }
.login-step.flag img { width: 44px; height: 30px; border-radius: 5px; box-shadow: 0 2px 6px rgba(0, 0, 0, .15); }
.login-groups { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.login-group { background: var(--bg-soft); border-radius: var(--radius); padding: 22px; display: grid; gap: 10px; align-content: start; }
.login-group h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .12em; color: var(--blue); margin-bottom: 6px; }
.toc { display: grid; gap: 4px; max-height: 60vh; overflow: auto; }
.toc a { font-size: 14px; padding: 6px 10px; border-radius: 8px; color: var(--text); }
.toc a:hover { background: var(--sky-50); color: var(--blue); }
@media (max-width: 900px) { .login-groups { grid-template-columns: 1fr; } }

/* E-planet System collage (home) */
.system { overflow: hidden; }
.system-head { max-width: 860px; margin: 0 auto 70px; text-align: center; }
.system-head .h2 { font-weight: 500; }
.system-head .hl { color: var(--blue); font-weight: 700; }
.system-head .lead { margin: 22px auto 0; }
.system-collage { display: grid; grid-template-columns: 1fr 1.05fr 1fr; align-items: center; gap: 40px; max-width: 1120px; margin: 0 auto 50px; }
.shape { position: relative; margin: 0; }
.shape img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 1.2s var(--ease); }
.shape:hover img { transform: scale(1.06); }
.shape-circle { aspect-ratio: 1; border-radius: 50%; overflow: visible; }
.shape-circle img { border-radius: 50%; box-shadow: var(--shadow); }
.shape-tilt { aspect-ratio: 4 / 5; transform: rotate(-7deg); }
.shape-tilt img { border-radius: 30px; box-shadow: var(--shadow-lg); }
.shape-tri { aspect-ratio: 1; }
.shape-tri img { clip-path: polygon(0 0, 100% 50%, 0 100%); border-radius: 18px; }
.shape-tilt.in { transform: rotate(-7deg); }
.shape-badge { position: absolute; display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 15px; line-height: 1.25; color: var(--ink); }
.shape-badge i { width: 50px; height: 50px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; flex: none; box-shadow: 0 10px 24px rgba(11, 33, 80, .3); }
.shape-badge i svg { width: 22px; height: 22px; }
.shape-badge.top-left { top: -6px; left: -10px; flex-direction: column; align-items: flex-start; }
.shape-badge.top-left span { order: -1; }
.shape-badge.bottom { bottom: -70px; left: 40%; transform: rotate(7deg); }
.shape-badge.top-right { top: 4%; left: 42%; }
@media (max-width: 900px) {
    .system-collage { grid-template-columns: 1fr 1fr; gap: 50px 30px; }
    .shape-tri { grid-column: 1 / -1; width: 60%; justify-self: center; }
    .shape-badge.bottom { bottom: -56px; }
}
@media (max-width: 600px) {
    .system-collage { grid-template-columns: 1fr; gap: 80px; }
    .shape-circle, .shape-tilt, .shape-tri { width: 78%; justify-self: center; }
    .shape-badge { font-size: 14px; }
}

/* Header fit with the full menu */
.header .container { gap: 22px; }
.brand { flex: none; }
.nav > a, .nav-item > a { white-space: nowrap; }
.drawer { visibility: hidden; transition: transform .45s var(--ease), visibility 0s .45s; }
.menu-open .drawer { visibility: visible; transition: transform .45s var(--ease); }
.system-collage { margin-bottom: 120px; }
@media (max-width: 1380px) { .header-cta { display: none; } }
@media (max-width: 1180px) { .nav { display: none; } .menu-toggle { display: block; } }

/* Books mega menu: centre it on the header, not on the "Books" link, so it never leaves the screen */
.header .container { position: relative; }
.nav-item.has-mega { position: static; }
.nav-item.has-mega .mega { top: calc(100% - 6px); left: 50%; width: min(980px, calc(100vw - 40px)); }

/* Explorer: bigger series cards (step 2) and books (step 3) */
.series-pick { grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 22px; }
.series-pick button { padding: 22px; gap: 22px; border-radius: 22px; }
.series-pick img, .series-pick .ph { width: 104px; height: 144px; border-radius: 8px; }
.series-pick b { font-size: 21px; margin-bottom: 6px; }
.series-pick small { display: block; font-size: 14.5px; line-height: 1.5; }
.series-pick small.lv { color: var(--blue); font-weight: 600; font-size: 13px; margin-top: 2px; }
.series-pick .arrow svg { width: 24px; height: 24px; }
.explorer .grid-books { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 36px 28px; }
.explorer .book-card h3 { font-size: 19px; }
@media (max-width: 600px) {
    .series-pick { grid-template-columns: 1fr; }
    .series-pick img, .series-pick .ph { width: 84px; height: 116px; }
    .series-pick b { font-size: 18px; }
    .explorer .grid-books { grid-template-columns: repeat(2, 1fr); gap: 22px 14px; }
}

/* PIN login */
.pin-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px; margin-top: 30px; padding: 26px; border-radius: var(--radius); background: var(--bg-soft); }
.pin-form .field { flex: 1 1 240px; }
.pin-form .field input { background: #fff; }
.pin-msg { flex-basis: 100%; margin: 0; padding: 12px 16px; border-radius: 12px; background: #fdecec; color: #b42318; font-weight: 600; }

/* Home: statement instead of counters */
.manifesto { padding: 130px 0 120px; text-align: center; background: radial-gradient(ellipse at 50% 0%, var(--sky-50), #fff 70%); }
.manifesto .eyebrow { justify-content: center; }
.manifesto .eyebrow::after { content: ""; width: 26px; height: 2px; background: currentColor; border-radius: 2px; }
.manifesto-text { font-size: clamp(40px, 6.2vw, 92px); line-height: 1.05; letter-spacing: -.04em; font-weight: 600; color: var(--ink); max-width: 1100px; margin: 0 auto; }
.manifesto-text em { font-style: normal; background: linear-gradient(100deg, var(--blue), var(--sky)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.manifesto-text .dot-sky { color: var(--sky); }
.manifesto-sub { font-size: clamp(17px, 1.5vw, 21px); line-height: 1.7; max-width: 760px; margin: 34px auto 0; color: var(--text); }
.manifesto .btn-row { justify-content: center; }
@media (max-width: 600px) { .manifesto { padding: 80px 0 70px; } }

/* Footer bento (inspired by infolex) */
.footer { padding-top: 70px; }
.fbento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 22px; }
.fcard { position: relative; grid-column: span 2; border-radius: 26px; border: 1px solid rgba(255, 255, 255, .1); background: rgba(255, 255, 255, .03); padding: 34px; color: #b8c6e0; overflow: hidden; isolation: isolate; }
.fcard h3 { color: #fff; font-size: clamp(24px, 2vw, 30px); margin: 0 0 16px; }
.fcard p { font-size: 14.5px; line-height: 1.7; }
.fkicker { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: #dbe7fa; margin-bottom: 10px; }
.fkicker svg { width: 16px; height: 16px; color: var(--sky); }
.fcard-photo { grid-column: span 3; min-height: 340px; display: flex; flex-direction: column; justify-content: space-between; color: #dbe7fa; }
.fcard-photo > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 1s var(--ease); }
.fcard-photo::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(6, 20, 47, .92) 10%, rgba(6, 20, 47, .55)); }
.fcard-photo:hover > img { transform: scale(1.05); }
.fcard-photo p { max-width: 560px; color: #dbe7fa; }
.fmore { align-self: flex-end; display: inline-flex; align-items: center; gap: 10px; padding: 8px 8px 8px 18px; border-radius: 999px; background: var(--navy-900); color: #fff; font-weight: 600; font-size: 14px; }
.fmore svg { width: 30px; height: 30px; padding: 7px; border-radius: 50%; background: #fff; color: var(--navy); transition: transform .3s var(--ease); }
.fcard-photo:hover .fmore svg { transform: rotate(-45deg); }
.fcard-map { grid-column: span 3; display: grid; grid-template-columns: 1fr 1.25fr; gap: 10px; align-items: center; padding-right: 10px; }
.fchips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.fchips a { font-size: 12.5px; font-weight: 600; color: #fff; padding: 7px 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .22); transition: background .2s, border-color .2s; }
.fchips a:hover { background: var(--blue); border-color: var(--blue); }
.fmap { position: relative; width: 140%; margin-left: -10%; }
.fmap img { width: 100%; height: auto; }
.pin { position: absolute; width: 9px; height: 9px; margin: -4.5px 0 0 -4.5px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 0 rgba(79, 183, 238, .7); animation: pinPulse 2.6s infinite; cursor: default; }
.pin b { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); white-space: nowrap; font-size: 11px; font-weight: 700; color: var(--navy); background: #fff; padding: 3px 8px; border-radius: 6px; opacity: 0; pointer-events: none; transition: opacity .2s; }
.pin:hover b { opacity: 1; }
.pin:hover { z-index: 2; background: var(--sky); }
@keyframes pinPulse { 0% { box-shadow: 0 0 0 0 rgba(79, 183, 238, .75); } 70% { box-shadow: 0 0 0 12px rgba(79, 183, 238, 0); } 100% { box-shadow: 0 0 0 0 rgba(79, 183, 238, 0); } }
.fcard-banner { grid-column: span 6; height: 200px; display: grid; place-items: center; padding: 0; }
.fcard-banner > img:first-child { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.fcard-banner::after { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(6, 20, 47, .72); }
.fbanner-logo { height: 84px; width: auto; background: #fff; padding: 10px 22px; border-radius: 18px; box-shadow: 0 20px 50px rgba(0, 0, 0, .35); }
.flist { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 16px; }
.flist li { display: flex; gap: 12px; color: #fff; font-weight: 600; font-size: 14.5px; line-height: 1.5; }
.flist svg { width: 18px; height: 18px; color: var(--sky); flex: none; margin-top: 20px; }
.flist small { display: block; color: #8ea2c6; font-weight: 500; font-size: 12px; }
.fsocial { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 12px; }
.fsocial a { display: inline-flex; align-items: center; gap: 12px; color: #fff; font-weight: 600; }
.fsocial a:hover { color: var(--sky); }
.fsocial i { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; }
.fsocial svg { width: 15px; height: 15px; fill: #fff; }
.fnews { display: grid; gap: 12px; margin-top: 6px; }
.fnews input { border: 1px solid rgba(255, 255, 255, .2); background: transparent; color: #fff; border-radius: 999px; padding: 14px 20px; font: inherit; }
.fnews input::placeholder { color: #8ea2c6; }
.fnews input:focus { outline: 0; border-color: var(--sky); }
.fnews .btn { justify-self: start; }
.footer .footer-cols { border-top: 0; padding-top: 60px; }
.map-credit { opacity: .5; font-size: 12px; }
@media (max-width: 1100px) {
    .fcard-photo, .fcard-map { grid-column: span 6; }
    .fcard { grid-column: span 3; }
    .fcard:last-child { grid-column: span 6; }
}
@media (max-width: 700px) {
    .fbento { grid-template-columns: 1fr; }
    .fcard, .fcard-photo, .fcard-map, .fcard-banner, .fcard:last-child { grid-column: 1 / -1; }
    .fcard-map { grid-template-columns: 1fr; padding-right: 34px; }
    .fmap { width: 100%; margin: 10px 0 0; }
    .fcard-banner { height: 150px; }
    .fbanner-logo { height: 64px; }
}
.footer .footer-cols { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 600px) { .footer .footer-cols { grid-template-columns: 1fr; } }
.fcard-map { grid-template-columns: .85fr 1.3fr; gap: 6px; padding-right: 22px; }
.fmap { width: 112%; margin-left: -4%; }

/* Home: catalogue + e-learning demo cards under the hero */
.quick-cta { position: relative; z-index: 3; margin-top: -90px; }
.qc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.qc-card { position: relative; display: flex; align-items: stretch; min-height: 260px; border-radius: 30px; overflow: hidden; color: #fff; box-shadow: var(--shadow-lg); isolation: isolate; transition: transform .45s var(--ease), box-shadow .45s var(--ease); }
.qc-card:hover { transform: translateY(-6px); }
.qc-catalogue { background: linear-gradient(130deg, var(--blue) 0%, #0a7fd0 100%); }
.qc-demo { background: linear-gradient(130deg, var(--navy) 0%, #12306f 100%); }
.qc-card::before { content: ""; position: absolute; width: 380px; height: 380px; right: -120px; top: -160px; border-radius: 50%; background: radial-gradient(circle, rgba(255, 255, 255, .16), transparent 65%); z-index: -1; }
.qc-body { position: relative; z-index: 1; padding: 36px 38px; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; max-width: 62%; }
.qc-tag { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #cfe6fb; }
.qc-tag svg { width: 16px; height: 16px; }
.qc-card h2 { color: #fff; font-size: clamp(24px, 2.3vw, 34px); line-height: 1.12; margin: 0; }
.qc-card .dot-sky { color: var(--sky-200); }
.qc-card p { margin: 0 0 8px; color: #dbe9fb; font-size: 15px; }
.qc-card .btn-white { color: var(--blue); margin-top: auto; }
.qc-card:hover .btn-white svg { transform: translateX(4px); }
.qc-books { position: absolute; right: 18px; bottom: -24px; display: flex; align-items: flex-end; }
.qc-books img { width: 118px; border-radius: 8px; box-shadow: 0 20px 40px rgba(0, 0, 0, .35); margin-left: -54px; transition: transform .6s var(--ease); }
.qc-books img:nth-child(1) { transform: rotate(-10deg) translateY(10px); }
.qc-books img:nth-child(2) { transform: rotate(-1deg) translateY(-14px); width: 132px; z-index: 1; }
.qc-books img:nth-child(3) { transform: rotate(9deg) translateY(12px); }
.qc-catalogue:hover .qc-books img:nth-child(1) { transform: rotate(-14deg) translate(-12px, 4px); }
.qc-catalogue:hover .qc-books img:nth-child(3) { transform: rotate(13deg) translate(12px, 6px); }
.qc-device { position: absolute; right: -40px; bottom: -30px; width: 46%; aspect-ratio: 4 / 3; border-radius: 22px; overflow: hidden; border: 8px solid #0b1734; box-shadow: 0 24px 50px rgba(0, 0, 0, .45); transform: rotate(-6deg); transition: transform .6s var(--ease); }
.qc-device img { width: 100%; height: 100%; object-fit: cover; }
.qc-demo:hover .qc-device { transform: rotate(-3deg) translateY(-6px); }
.hero .container { padding-bottom: 170px; }
@media (max-width: 1000px) { .qc-grid { grid-template-columns: 1fr; } }
@media (max-width: 600px) {
    .quick-cta { margin-top: -60px; }
    .qc-body { max-width: 100%; padding: 28px 24px 150px; }
    .qc-books { right: 50%; transform: translateX(50%); bottom: -30px; }
    .qc-device { width: 64%; right: 50%; transform: translateX(50%) rotate(-5deg); bottom: -40px; }
    .qc-demo:hover .qc-device { transform: translateX(50%) rotate(-3deg); }
}
.hero-books, .hero .scroll-cue { display: none; }
.qc-body { max-width: 58%; }
.qc-books { right: 4px; }
.qc-books img { width: 104px; margin-left: -58px; }
.qc-books img:nth-child(2) { width: 118px; }

/* Footer: one horizontal menu with the small logo, before the copyright */
.footer-nav { display: flex; align-items: center; gap: 28px 40px; flex-wrap: wrap; padding: 34px 0; margin-top: 50px; border-top: 1px solid rgba(255, 255, 255, .08); }
.footer-logo { flex: none; background: #fff; border-radius: 12px; padding: 6px 12px; }
.footer-logo img { height: 40px; width: auto; display: block; }
.footer-nav nav { display: flex; flex-wrap: wrap; gap: 10px 28px; flex: 1; justify-content: flex-end; }
.footer-nav nav a { color: #c9d6ee; font-weight: 500; font-size: 15px; transition: color .2s; }
.footer-nav nav a:hover { color: #fff; }
@media (max-width: 900px) { .footer-nav { flex-direction: column; align-items: flex-start; } .footer-nav nav { justify-content: flex-start; } }

/* Header: big logo at the top, shrinks smoothly on scroll */
:root { --header-h: 104px; }
body.header-compact { --header-h: 70px; }
.header { transition: background .35s, box-shadow .35s, border-color .35s; }
.header .container { height: var(--header-h); transition: height .45s var(--ease); }
.brand img { height: 78px; transition: height .45s var(--ease), transform .45s var(--ease); transform-origin: left center; }
.brand:hover img { transform: scale(1.03); }
.header-compact .header { box-shadow: 0 10px 30px rgba(11, 33, 80, .10); background: rgba(255, 255, 255, .96); }
.header-compact .brand img { height: 48px; }
.header-compact .nav > a, .header-compact .nav-item > a { padding-top: 8px; padding-bottom: 8px; }
.header-compact .header-cta { padding: 10px 20px; }
.header-cta { transition: padding .45s var(--ease), transform .25s var(--ease), box-shadow .25s; }
@media (max-width: 900px) {
    :root { --header-h: 78px; }
    body.header-compact { --header-h: 62px; }
    .brand img { height: 54px; }
    .header-compact .brand img { height: 40px; }
}

/* Quick CTA cards: full-width text when the cards stack (tablet / mobile) */
@media (max-width: 1000px) {
    .qc-card { min-height: 0; }
    .qc-body { max-width: 100%; padding: 32px 30px 200px; }
    .qc-card h2 { font-size: clamp(26px, 6vw, 34px); }
    .qc-tag { white-space: nowrap; }
    .qc-books { right: 50%; transform: translateX(50%); bottom: -26px; }
    .qc-device { width: min(62%, 360px); right: 50%; transform: translateX(50%) rotate(-5deg); bottom: -36px; }
    .qc-demo:hover .qc-device { transform: translateX(50%) rotate(-3deg); }
}
@media (max-width: 600px) {
    .qc-body { padding: 28px 24px 175px; }
    .qc-tag { font-size: 11.5px; }
}

/* Map card: text + buttons left, map right; on phones text, then map, then buttons */
.fcard-map { grid-template-columns: .85fr 1.3fr; grid-template-areas: "text map" "chips map"; align-items: center; }
.fcard-map .fmap-text { grid-area: text; align-self: end; }
.fcard-map .fmap { grid-area: map; }
.fcard-map .fchips { grid-area: chips; align-self: start; }
@media (max-width: 700px) {
    .fcard-map { grid-template-columns: 1fr; grid-template-areas: "text" "map" "chips"; padding-right: 30px; }
    .fcard-map .fmap { width: 100%; margin: 6px 0; }
    .fchips a { font-size: 13px; }
}

/* Footer bottom: copyright on two lines, legal links on one line */
.footer-bottom { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 10px 30px; }
.footer-bottom .copy { margin: 0; line-height: 1.6; }
.footer-bottom .legal { display: flex; flex-wrap: nowrap; gap: 24px; white-space: nowrap; }
.footer-bottom .map-credit { grid-column: 1 / -1; font-size: 11.5px; opacity: .45; }
@media (max-width: 600px) {
    .footer-bottom { grid-template-columns: 1fr; }
    .footer-bottom .legal { gap: 18px; font-size: 14px; }
}

/* Top bar on phones: only the social icons, so nothing overflows */
@media (max-width: 600px) {
    .topbar .container { justify-content: center; }
    .topbar-links { display: none; }
    .topbar .social { gap: 20px; }
}

/* Newsletter card on phones */
@media (max-width: 700px) {
    .fnews .btn { justify-self: stretch; justify-content: center; }
    .fcard .apps { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
    .fcard .apps a { padding: 9px 12px; }
}

/* Never let grid/flex children force the page wider than the screen */
.split > *, .grid > *, .contact-grid > *, .form-grid > *, .fbento > *, .article-layout > *, .book-hero > *, .qc-grid > * { min-width: 0; }
.contact-card b, .flist a, .prose a, .footer-contact a { overflow-wrap: anywhere; }
.prose table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; }
.prose td, .prose th { border: 1px solid var(--line); padding: 8px 12px; }
.prose img, .prose iframe, .prose video { max-width: 100%; height: auto; }
.prose pre { max-width: 100%; overflow-x: auto; }
.prose { overflow-wrap: break-word; }

/* Login: country detection + searchable flag list */
.cp-detect { display: grid; place-items: center; gap: 22px; padding: 50px 0 40px; text-align: center; }
.cp-detect p { font-weight: 600; color: var(--ink); font-size: 18px; margin: 0; }
.cp-radar { position: relative; width: 120px; height: 120px; display: grid; place-items: center; color: var(--blue); }
.cp-radar svg { width: 56px; height: 56px; animation: cpSpin 3s linear infinite; position: relative; z-index: 1; }
.cp-radar span { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--sky); opacity: 0; animation: cpPing 2.1s ease-out infinite; }
.cp-radar span:nth-child(2) { animation-delay: .7s; }
.cp-radar span:nth-child(3) { animation-delay: 1.4s; }
@keyframes cpSpin { to { transform: rotate(360deg); } }
@keyframes cpPing { 0% { transform: scale(.35); opacity: .9; } 100% { transform: scale(1.25); opacity: 0; } }
.cp-found { display: grid; justify-items: center; text-align: center; padding: 30px 0 20px; }
.cp-flag { width: 180px; height: auto; border-radius: 14px; box-shadow: 0 24px 50px rgba(11, 33, 80, .25); animation: cpPop .8s var(--ease) both; }
.cp-kicker { margin: 26px 0 4px; color: var(--muted); font-weight: 600; letter-spacing: .14em; text-transform: uppercase; font-size: 13px; animation: cpUp .6s .25s var(--ease) both; }
.cp-country { margin: 0; font-size: clamp(40px, 6vw, 72px); font-weight: 800; letter-spacing: -.03em; color: var(--ink); text-transform: uppercase; animation: cpUp .7s .35s var(--ease) both; }
.cp-found .btn-row { animation: cpUp .7s .5s var(--ease) both; }
@keyframes cpPop { 0% { transform: scale(.4) rotate(-12deg); opacity: 0; } 60% { transform: scale(1.08) rotate(3deg); opacity: 1; } 100% { transform: none; } }
@keyframes cpUp { from { transform: translateY(18px); opacity: 0; } to { transform: none; opacity: 1; } }
.cp-note { color: var(--muted); margin: 0 0 10px; }
.cp-search { position: relative; margin: 18px 0 24px; }
.cp-search svg { position: absolute; left: 20px; top: 50%; width: 22px; height: 22px; margin-top: -11px; color: var(--muted); }
.cp-search input { width: 100%; font: inherit; font-size: 18px; padding: 18px 22px 18px 56px; border-radius: 999px; border: 2px solid var(--line); background: var(--bg-soft); color: var(--ink); transition: border-color .2s, background .2s, box-shadow .2s; }
.cp-search input:focus { outline: 0; border-color: var(--blue); background: #fff; box-shadow: 0 0 0 5px rgba(0, 80, 160, .1); }
.cp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.cp-item { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 20px 12px 16px; border-radius: 18px; border: 1px solid var(--line); background: #fff; font-weight: 700; color: var(--ink); text-align: center; animation: cpUp .5s var(--ease) both; transition: transform .25s var(--ease), box-shadow .25s, border-color .2s; }
.cp-item img { width: 96px; height: 64px; object-fit: cover; border-radius: 8px; box-shadow: 0 6px 16px rgba(11, 33, 80, .18); transition: transform .3s var(--ease); }
.cp-item:hover { transform: translateY(-4px); border-color: var(--blue); box-shadow: var(--shadow-sm); color: var(--blue); }
.cp-item:hover img { transform: scale(1.06); }
.cp-item[hidden] { display: none; }
.cp-empty { text-align: center; color: var(--muted); padding: 30px 0; }
@media (max-width: 600px) { .cp-grid { grid-template-columns: repeat(2, 1fr); } .cp-item img { width: 80px; height: 54px; } .cp-flag { width: 140px; } }

/* Login: picture cards (online courses, corporate training) */
.lcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px; }
.lcard { display: flex; flex-direction: column; border-radius: 22px; overflow: hidden; border: 1px solid var(--line); background: #fff; transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .3s; }
.lcard:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.lcard-media { aspect-ratio: 16 / 9; background: linear-gradient(140deg, var(--blue), var(--navy)); display: grid; place-items: center; overflow: hidden; }
.lcard-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.lcard:hover .lcard-media img { transform: scale(1.06); }
.lcard-media .mono { font-size: 54px; font-weight: 800; color: #fff; letter-spacing: -.04em; opacity: .95; }
.lcard-body { padding: 22px 24px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.lcard-body h4 { margin: 0; font-size: 20px; color: var(--ink); }
.lcard-body p { margin: 0; font-size: 14.5px; color: var(--text); }
.lcard-body .link-arrow { margin-top: auto; padding-top: 6px; }

/* Country login: picture cards with buttons (Juniors / Children / Adults) */
.login-group { background: transparent; padding: 0; gap: 20px; }
.login-group h4 { font-size: 14px; margin: 0 0 2px; padding-left: 4px; }
.lg-card { background: #fff; border: 1px solid var(--line); border-radius: 22px; overflow: hidden; box-shadow: var(--shadow-sm); transition: box-shadow .35s var(--ease), transform .35s var(--ease); }
.lg-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.lg-media { aspect-ratio: 16 / 10; overflow: hidden; background: var(--sky-50); }
.lg-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.lg-card:hover .lg-media img { transform: scale(1.04); }
.lg-btns { display: grid; gap: 10px; padding: 18px; }
.lg-btn { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 18px; border-radius: 14px; background: var(--sky-50); color: var(--blue); font-weight: 700; font-size: 15px; transition: background .25s, color .25s, transform .25s var(--ease), box-shadow .25s; }
.lg-btn svg { width: 18px; height: 18px; flex: none; transition: transform .25s var(--ease); }
.lg-btn:hover { background: var(--blue); color: #fff; box-shadow: 0 10px 22px rgba(0, 80, 160, .25); transform: translateY(-1px); }
.lg-btn:hover svg { transform: translateX(4px); }

/* Keep menus open while the pointer travels from the link down to the panel */
.nav-item.has-mega .mega::before { top: -48px; height: 48px; }
.nav-item > a { position: relative; }
.nav-item.is-open > a::after { content: ""; position: absolute; left: -10px; right: -10px; top: 100%; height: 40px; }

/* Mobile / tablet header: hamburger left, logo centred, Login button right */
@media (max-width: 1180px) {
    .header .container { gap: 12px; position: relative; }
    .menu-toggle { order: -1; margin-left: -8px; margin-right: 0; flex: none; }
    .brand { position: absolute; left: 50%; transform: translateX(-50%); }
    .header-cta { display: inline-flex !important; margin-left: auto; padding: 10px 16px; font-size: 14px; gap: 7px; box-shadow: 0 6px 16px rgba(0, 80, 160, .28); }
    .header-cta svg { width: 16px !important; height: 16px !important; }
    .header-compact .header-cta { padding: 8px 14px; }
    .drawer .btn-primary[href$="/login/"], .drawer .btn-primary[href$="login/index.html"] { display: none; }
}
@media (max-width: 380px) {
    .header-cta { padding: 9px 12px; font-size: 13px; }
    .brand img { height: 46px; }
}
@media (max-width: 1180px) {
    .brand { position: static; transform: none; margin-right: auto; }
}

/* ===== Full-width menu panels (inspired by viva.com) ===== */
@media (min-width: 1181px) {
    .header .container { position: static; }
    .nav-item, .nav-item.has-mega { position: static; }
}
.mpanel { position: absolute; left: 0; right: 0; top: 100%; z-index: 60; background: rgba(255, 255, 255, .97); backdrop-filter: saturate(170%) blur(18px); -webkit-backdrop-filter: saturate(170%) blur(18px);
    border-top: 1px solid var(--line); box-shadow: 0 30px 60px rgba(11, 33, 80, .14); opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .25s, transform .35s var(--ease), visibility .25s; }
/* No invisible bridge above the panel: it starts right under the header, and a bridge would cover the
   other menu links once the header shrinks (the pointer then sticks to the open menu and it flickers). */
.mpanel::before { content: none; }
/* Panels open with the .is-open class (set by eplanet.js with a short hover delay), not :hover,
   so they don't flicker while the header shrinks on scroll and they close reliably after a click. */
.nav-item.is-open > .mpanel { opacity: 1; visibility: visible; transform: none; }
.nav-item.is-open > a, .nav-item > a:hover { background: var(--sky-50); color: var(--blue); }
.mpanel-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) minmax(300px, 1.15fr); gap: 34px; padding-top: 34px; padding-bottom: 38px; }
.mpanel-grid:has(> .mcol:nth-of-type(2):last-of-type), .mpanel-grid:has(> .mcol:only-of-type) { grid-template-columns: repeat(2, minmax(0, 1fr)) minmax(320px, 1.15fr); }
.mpanel-grid:has(> .mcol:only-of-type) { grid-template-columns: minmax(0, 1.4fr) minmax(320px, 1fr); }
.mcol { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.mhead { display: block; font-size: 12.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px 12px; }
.mitem { display: flex; align-items: center; gap: 14px; padding: 11px 12px; border-radius: 14px; transition: background .2s; }
.mitem:hover { background: var(--bg-soft); }
.mitem img { width: 52px; height: 52px; border-radius: 12px; object-fit: cover; flex: none; box-shadow: 0 4px 12px rgba(11, 33, 80, .12); }
.mitem b { display: block; color: var(--ink); font-size: 15.5px; font-weight: 700; line-height: 1.3; transition: color .2s; }
.mitem:hover b { color: var(--blue); }
.mitem small { display: block; color: var(--muted); font-size: 13.5px; line-height: 1.45; margin-top: 2px; }
.mfeature { display: flex; flex-direction: column; border-radius: 22px; overflow: hidden; background: var(--navy); color: #fff; box-shadow: var(--shadow); align-self: start; transition: transform .35s var(--ease), box-shadow .35s; }
.mfeature:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.mfeature-media { aspect-ratio: 16 / 8.5; overflow: hidden; background: #000; }
.mfeature-media img, .mfeature-media video { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.mfeature:hover .mfeature-media img { transform: scale(1.05); }
.mfeature-body { padding: 20px 22px 22px; }
.mfeature-body .mhead { color: var(--sky-200); margin: 0 0 8px; }
.mfeature-body b { display: block; font-size: 19px; line-height: 1.3; margin-bottom: 6px; }
.mfeature-body p { font-size: 14px; color: #c9d6ee; margin: 0 0 14px; }
.mpill { display: inline-flex; align-items: center; gap: 8px; background: #fff; color: var(--blue); font-weight: 700; font-size: 13.5px; padding: 8px 16px; border-radius: 999px; }
.mpill svg { width: 15px; height: 15px; transition: transform .25s var(--ease); }
.mfeature:hover .mpill svg { transform: translateX(4px); }
@media (max-width: 1180px) { .mpanel { display: none; } }
/* The panel's inner container must not inherit the header bar's flex/height rules */
.header .mpanel .mpanel-grid { display: grid; height: auto; align-items: start; gap: 34px; transition: none; }
.mpanel { background: #fff; backdrop-filter: none; -webkit-backdrop-filter: none; }

/* ===== Franchise: interactive map hero ===== */
.fr-hero { position: relative; min-height: 760px; background: radial-gradient(ellipse at 70% 40%, #0f2a66 0%, #081634 55%, #050d22 100%); color: #fff; overflow: hidden; display: flex; align-items: center; }
.fr-map { position: absolute; inset: 0 0 0 30%; }
.fr-map canvas { width: 100%; height: 100%; display: block; }
.fr-hero::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(90deg, #050d22 0%, rgba(5, 13, 34, .92) 28%, rgba(5, 13, 34, .2) 55%, transparent 70%); }
.fr-hero-inner { position: relative; z-index: 2; padding-top: 80px; padding-bottom: 80px; pointer-events: none; }
.fr-hero-inner > * { pointer-events: auto; max-width: 620px; }
.fr-hero h1 { color: #fff; font-size: clamp(38px, 4.6vw, 66px); }
.fr-hero .lead { color: #c9d6ee; }
.fr-hero .breadcrumb, .fr-hero .breadcrumb a { color: #9fb0cf; }
.fr-hero .breadcrumb span:last-child { color: #fff; }
.fr-regions { margin-top: 44px; display: grid; gap: 16px; }
.fr-count { display: flex; align-items: center; gap: 14px; }
.fr-count b { font-size: 56px; font-weight: 800; letter-spacing: -.04em; line-height: 1; background: linear-gradient(120deg, #fff, var(--sky)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.fr-count span { color: #9fb0cf; font-size: 14px; font-weight: 600; line-height: 1.3; }
.fr-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.fr-chip { border: 1px solid rgba(255, 255, 255, .22); background: rgba(255, 255, 255, .05); color: #dbe7fa; padding: 9px 16px; border-radius: 999px; font-weight: 600; font-size: 14px; transition: all .25s var(--ease); }
.fr-chip:hover { border-color: var(--sky); color: #fff; }
.fr-chip.active { background: var(--sky); border-color: var(--sky); color: var(--navy-900); }
.fr-names { margin: 0; color: #8ea2c6; font-size: 13.5px; line-height: 1.7; min-height: 2.4em; }
.wm-tip { position: absolute; left: 0; top: 0; z-index: 3; pointer-events: none; display: flex; align-items: center; gap: 10px; padding: 8px 14px 8px 8px; border-radius: 14px; background: #fff; color: var(--ink); box-shadow: 0 16px 40px rgba(0, 0, 0, .35); white-space: nowrap; margin: -64px 0 0 -40px; }
.wm-tip img { width: 40px; height: 27px; object-fit: cover; border-radius: 5px; }
.wm-tip b { display: block; font-size: 14.5px; }
.wm-tip small { display: block; color: var(--muted); font-size: 12px; }
@media (max-width: 900px) {
    .fr-hero { min-height: 0; flex-direction: column; align-items: stretch; }
    .fr-map { position: relative; inset: auto; order: 2; height: 360px; margin-top: -40px; }
    .fr-hero::before { background: linear-gradient(180deg, #050d22 0%, rgba(5, 13, 34, .6) 60%, transparent 100%); height: 70%; }
    .fr-hero-inner { padding-top: 50px; padding-bottom: 20px; }
}

/* Franchise: tabbed benefits */
.fr-tabs { display: grid; grid-template-columns: 340px 1fr; gap: 30px; align-items: start; }
.fr-tablist { display: grid; gap: 6px; position: sticky; top: calc(var(--header-h) + 20px); }
.fr-tab { display: flex; align-items: center; gap: 14px; text-align: left; border: 0; background: transparent; padding: 14px 16px; border-radius: 14px; font-weight: 600; font-size: 15.5px; color: var(--text); transition: background .2s, color .2s; }
.fr-tab span { font-size: 12.5px; font-weight: 800; color: var(--muted); width: 26px; flex: none; }
.fr-tab:hover { background: #fff; color: var(--ink); }
.fr-tab.active { background: #fff; color: var(--blue); box-shadow: var(--shadow-sm); }
.fr-tab.active span { color: var(--sky); }
.fr-panel { background: #fff; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); animation: fadeSwap .45s var(--ease); }
.fr-panel-media { aspect-ratio: 16 / 7; overflow: hidden; background: var(--sky-50); }
.fr-panel-media img { width: 100%; height: 100%; object-fit: cover; }
.fr-panel-body { padding: 36px 40px 40px; }
@media (max-width: 900px) {
    .fr-tabs { grid-template-columns: 1fr; }
    .fr-tablist { position: static; display: flex; overflow-x: auto; gap: 8px; scrollbar-width: none; margin: 0 -20px; padding: 0 20px 6px; }
    .fr-tablist::-webkit-scrollbar { display: none; }
    .fr-tab { white-space: nowrap; background: #fff; border: 1px solid var(--line); }
    .fr-panel-body { padding: 26px 22px 28px; }
}
.fr-map { inset: 0 0 0 24%; }
.fr-hero::before { background: linear-gradient(90deg, #050d22 0%, rgba(5, 13, 34, .9) 26%, rgba(5, 13, 34, .25) 48%, transparent 62%); }
@media (max-width: 900px) { .fr-map { inset: auto; } }

/* Phones: no top bar with social icons (they remain in the footer) */
@media (max-width: 600px) { .topbar { display: none; } }

/* Safety net: the page itself never scrolls sideways */
html, body { overflow-x: clip; }
@supports not (overflow: clip) { html, body { overflow-x: hidden; } }

/* Scrolling closes open menu panels until the pointer goes back onto a menu link */
.menus-off .nav-item > .mpanel { opacity: 0 !important; visibility: hidden !important; transform: translateY(-8px) !important; pointer-events: none; }
.menus-off .nav-item:hover > a { background: transparent; color: inherit; }

/* Laptops 1181–1440px (e.g. MacBook 1280): keep the Login button, tighten the menu */
@media (max-width: 1380px) { .header-cta { display: inline-flex; } }
@media (min-width: 1181px) and (max-width: 1440px) {
    .header .container { gap: 14px; }
    .brand img { height: 62px; }
    .header-compact .brand img { height: 44px; }
    .nav { gap: 0; }
    .nav > a, .nav-item > a { padding: 9px 10px; font-size: 14.5px; }
    .nav-item > a svg { width: 12px; height: 12px; }
    .header-cta { padding: 11px 18px; font-size: 14.5px; }
}
@media (min-width: 1181px) and (max-width: 1300px) {
    .nav > a, .nav-item > a { padding: 8px 8px; font-size: 14px; }
    .brand img { height: 56px; }
}

/* ===== Login hub: compact intro + photo cards ===== */
.login-intro { padding: 36px 0 6px; background: linear-gradient(180deg, var(--sky-50), #fff); }
.login-intro .breadcrumb { margin-bottom: 14px; }
.login-intro h1 { margin: 0 0 6px; }
.login-intro p { margin: 0; font-size: 17px; color: var(--text); max-width: 680px; }
.login-cards-section { padding-top: 34px; }
.lc-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.lc { display: flex; flex-direction: column; text-align: left; padding: 0; border: 1px solid var(--line); border-radius: 26px; background: #fff; overflow: hidden; color: inherit; box-shadow: var(--shadow-sm); transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .3s; }
.lc:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.lc.active { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0, 80, 160, .18), var(--shadow); }
.lc-media { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--navy); }
.lc-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.lc:hover .lc-media img { transform: scale(1.06); }
.lc-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(6, 20, 47, .5)); }
.lc-ic { position: absolute; left: 18px; bottom: 16px; z-index: 1; width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; color: #fff; background: rgba(255, 255, 255, .2); border: 1px solid rgba(255, 255, 255, .35); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.lc-ic svg { width: 22px; height: 22px; }
.lc-body { display: flex; flex-direction: column; gap: 8px; padding: 22px 24px 24px; flex: 1; }
.lc-for { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); }
.lc-body b { font-size: 21px; color: var(--ink); line-height: 1.25; }
.lc-desc { font-size: 15px; line-height: 1.55; color: var(--text); }
.lc-cta { margin-top: auto; padding-top: 10px; display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 15px; color: var(--blue); }
.lc-cta svg { width: 18px; height: 18px; transition: transform .25s var(--ease); }
.lc:hover .lc-cta svg { transform: translateX(5px); }
/* Featured first card: wide, image beside the text */
.lc-featured { grid-column: span 2; grid-row: span 1; flex-direction: row; background: linear-gradient(130deg, var(--navy), #12306f); border-color: transparent; }
.lc-featured .lc-media { flex: 1.15; aspect-ratio: auto; min-height: 280px; }
.lc-featured .lc-media::after { background: linear-gradient(90deg, transparent 60%, rgba(11, 33, 80, .9)); }
.lc-featured .lc-body { flex: 1; justify-content: center; padding: 34px 34px 34px 28px; }
.lc-featured .lc-for { color: var(--sky-200); }
.lc-featured b { color: #fff; font-size: 28px; }
.lc-featured .lc-desc { color: #c9d6ee; font-size: 16px; }
.lc-featured .lc-cta { align-self: flex-start; margin-top: 14px; background: #fff; color: var(--blue); padding: 12px 22px; border-radius: 999px; }
@media (max-width: 1000px) {
    .lc-grid { grid-template-columns: 1fr 1fr; }
    .lc-featured { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
    .lc-grid { grid-template-columns: 1fr; gap: 16px; }
    .lc-featured { flex-direction: column; }
    .lc-featured .lc-media { min-height: 0; aspect-ratio: 16 / 9; flex: none; }
    .lc-featured .lc-media::after { background: linear-gradient(180deg, transparent 50%, rgba(11, 33, 80, .7)); }
    .lc-featured .lc-body { padding: 24px; }
    .lc-featured b { font-size: 23px; }
    .lc { flex-direction: row; align-items: stretch; }
    .lc:not(.lc-featured) .lc-media { width: 112px; flex: none; aspect-ratio: auto; }
    .lc:not(.lc-featured) .lc-body { padding: 16px 18px; gap: 4px; }
    .lc:not(.lc-featured) .lc-body b { font-size: 17px; }
    .lc:not(.lc-featured) .lc-desc { font-size: 13.5px; }
    .lc:not(.lc-featured) .lc-ic { display: none; }
}
.lc-featured .lc-media { min-height: 220px; max-height: 260px; }
.lc-featured .lc-body { padding: 26px 30px; }
.login-cards-section { padding-top: 26px; }
@media (max-width: 640px) {
    .lc.lc-featured { flex-direction: column; }
    .lc.lc-featured .lc-media { width: 100%; height: 170px; min-height: 0; max-height: none; aspect-ratio: auto; flex: none; }
}
@media (min-width: 641px) {
    .lc-featured .lc-media { max-height: none; min-height: 240px; align-self: stretch; }
    .lc-featured .lc-media img { position: absolute; inset: 0; }
}
.login-intro p { max-width: none; }

/* Embedded video inside an article (16:9, full width) */
.prose .video-embed { position: relative; aspect-ratio: 16 / 9; margin: 24px 0; border-radius: 16px; overflow: hidden; background: #0b1b33; }
.prose .video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* "Try the e-learning demo." always on one line: the font scales with the card width (container units) */
.qc-demo { container-type: inline-size; }
.qc-demo h2 { white-space: nowrap; font-size: min(34px, calc((100cqi - 76px) / 13)); }
