/* Course map (apa-map.js): the lessons of a module drawn as a journey.
 * Node selectors are doubled on purpose: they must outrank the site's `.apa-main a:not(...)` link color. */
.apa-map__switch { display: inline-flex; gap: 2px; padding: 3px; margin: 4px 0 12px; border-radius: 10px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.08); }
.apa-map__switch button { border: 0; background: none; color: #98a7b6; font: inherit; font-size: 13px; font-weight: 700; padding: 6px 14px; border-radius: 8px; cursor: pointer; }
.apa-map__switch button[aria-pressed="true"] { background: rgba(45,212,191,.16); color: #5eead4; }
.apa-module__body.is-list .apa-map { display: none; }
.apa-module__body:not(.is-list) .apa-chapter { display: none; }
.ap-curriculum-expandable.is-list .apa-map { display: none; }
.ap-curriculum-expandable:not(.is-list) .ap-curriculum-list { display: none; }
.ap-curriculum-expandable .apa-map__switch { margin-top: 0; }

.apa-map { position: relative; margin: 0 0 6px; border-radius: 18px; overflow: hidden; background-color: #0f1d31; }
/* Small waves on the water between the islands, drifting slowly. */
.apa-map::before { content: ""; position: absolute; inset: -44px 0 0 -88px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='44' height='44'%3E%3Cpath d='M6 24q5-5 10 0t10 0' fill='none' stroke='%231c3352' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E"); background-size: 44px 44px; pointer-events: none; }
@keyframes apa-map-waves { to { transform: translate(44px, 0); } }
.apa-map.is-trail { background-color: #0d1724; }
.apa-map__svg { position: absolute; inset: 0; display: block; }
.apa-map__shore { fill: #3a2a1a; opacity: .55; }
.apa-map__isle { fill: #17222f; stroke: #243244; stroke-width: 3; }
.apa-map__isle.is-reached { fill: #16362f; stroke: #1f5a4c; }
.apa-map__bush { fill: #1c2a39; }
.apa-map__bush.is-reached { fill: #1f4d40; }
.apa-map__road { fill: none; stroke: #c9b48a; stroke-opacity: .28; stroke-width: 9; stroke-linecap: round; }
.apa-map__road-dash { fill: none; stroke: #e8d7b0; stroke-opacity: .45; stroke-width: 3; stroke-dasharray: 2 10; stroke-linecap: round; }
.apa-map__road-done { fill: none; stroke: #2dd4bf; stroke-width: 6; stroke-linecap: round; }
.apa-map__trail { fill: none; stroke: #1f2b3c; stroke-width: 8; stroke-linejoin: round; stroke-linecap: round; }

.apa-map__zone { position: absolute; transform: translate(-50%, -50%); white-space: nowrap; max-width: 92%; overflow: hidden; text-overflow: ellipsis; padding: 4px 14px; border-radius: 99px; background: #0b121c; border: 2px solid var(--c); color: var(--c); font-size: 12px; font-weight: 800; }
.apa-map__band { position: absolute; left: 12px; right: 12px; transform: translateY(-50%); padding: 10px 14px; border-radius: 12px; background: color-mix(in srgb, var(--c) 14%, transparent); border: 1px solid color-mix(in srgb, var(--c) 40%, transparent); color: #e6edf5; font-size: 14px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.apa-map__band b { color: var(--c); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; margin-right: 6px; }

.apa-map.apa-map .apa-map__node[class][class] { position: absolute; z-index: 1; display: grid; place-items: center; width: 36px; height: 36px; margin: -18px 0 0 -18px; border-radius: 50%; font-size: 13px; font-weight: 800; text-decoration: none; background: #1b2635; color: #5b6b80; border: 2px solid #2a3647; box-shadow: 0 4px 0 #111a26; transition: transform .15s; }
.apa-map.apa-map a.apa-map__node[class][class]:hover { transform: translateY(-2px); }
.apa-map.apa-map .apa-map__node[class][class].is-done { background: var(--c); color: #052420; border-color: transparent; box-shadow: 0 4px 0 rgba(0,0,0,.35); }
.apa-map.apa-map .apa-map__node[class][class].is-open { background: #22344a; color: #c5d0dc; border-color: color-mix(in srgb, var(--c) 55%, transparent); }
.apa-map.apa-map .apa-map__node[class][class].is-cur { z-index: 2; width: 44px; height: 44px; margin: -22px 0 0 -22px; background: #fff; color: #0b121c; font-size: 16px; border: 0; box-shadow: 0 4px 0 #c9d4df, 0 0 0 7px color-mix(in srgb, var(--c) 30%, transparent), 0 0 0 14px color-mix(in srgb, var(--c) 10%, transparent); }

/* Milestones and certificates: a castle instead of a circle. */
.apa-map.apa-map .apa-map__node[class][class].is-castle { width: 64px; height: 64px; margin: -38px 0 0 -32px; border: 0; border-radius: 0; background: none; box-shadow: none; filter: drop-shadow(0 6px 0 rgba(0,0,0,.35)); --wall: #3a4b62; --shade: rgba(0,0,0,.22); --door: #131c2a; --win: #131c2a; --flag: #64748b; }
.apa-map.apa-map .apa-map__node[class][class].is-castle .apa-map__castle { width: 64px; height: 64px; }
.apa-map__castle { display: block; overflow: visible; }
.apa-map__castle .cs-wall { fill: var(--wall); }
.apa-map__castle .cs-shade { fill: var(--shade); }
.apa-map__castle .cs-door { fill: var(--door); }
.apa-map__castle .cs-win { fill: var(--win); }
.apa-map__castle .cs-flag { fill: var(--flag); }
/* What the castle stands for (APA_CASTLE_FX): the flag waves; the diploma floats among sparks. */
.apa-map .apa-map__castle .cs-flag, .lv-map .apa-map__castle .cs-flag { transform-box: fill-box; transform-origin: 0 50%; animation: cs-wave 1.4s ease-in-out infinite alternate; }
.apa-map__castle .cs-scroll { animation: cs-bob 2.2s ease-in-out infinite alternate; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .35)); }
.apa-map__castle .cs-spark { fill: #fde68a; transform-box: fill-box; transform-origin: center; animation: cs-twinkle 1.8s ease-in-out infinite; }
.apa-map .is-castle.is-diploma .apa-map__castle { animation: cs-aura 1.8s ease-in-out infinite alternate; }
.lv .lv-map .apa-map__castle { animation: cs-aura-lv 1.8s ease-in-out infinite alternate; }
.apa-map .is-castle.is-lock .cs-fx, .apa-map .is-castle.is-open .cs-fx { opacity: .75; }
/* The next module's magic portal: the vortex turns, the runes and the keystone glow, light rises out of it. */
.apa-map__portal .pt-stone { fill: #64748b; }
.apa-map__portal .pt-stone-d { fill: rgba(0, 0, 0, .22); }
.apa-map__portal .pt-joint { fill: none; stroke: rgba(15, 23, 42, .45); stroke-width: 1; }
.apa-map__portal .pt-swirl { transform-box: view-box; transform-origin: 24px 31px; animation: pt-spin 4s linear infinite; }
.apa-map__portal .pt-swirl path { fill: none; stroke: rgba(255, 255, 255, .75); stroke-width: 1.6; stroke-linecap: round; }
.apa-map__portal .pt-swirl .pt-swirl2 { stroke: #5eead4; stroke-width: 1.2; opacity: .8; }
.apa-map__portal .pt-glow { fill: #8b5cf6; opacity: .35; animation: pt-pulse 1.6s ease-in-out infinite alternate; }
.apa-map__portal .pt-rune { fill: #5eead4; animation: pt-rune 2s ease-in-out infinite; }
.apa-map__portal .pt-gem { fill: #c4b5fd; stroke: #7c3aed; stroke-width: .8; animation: pt-rune 1.6s ease-in-out infinite; }
.apa-map__portal .pt-mote { fill: #ddd6fe; opacity: 0; transform-box: fill-box; transform-origin: center; animation: cs-mote 2s ease-out infinite; }
.apa-map .is-castle.is-milestone .apa-map__portal { animation: pt-aura 1.8s ease-in-out infinite alternate; }
.apa-map .is-castle.is-milestone.is-lock .apa-map__portal { opacity: .85; }
@keyframes pt-spin { to { transform: rotate(360deg); } }
@keyframes pt-pulse { from { opacity: .2; } to { opacity: .55; } }
@keyframes pt-rune { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }
@keyframes pt-aura { from { filter: drop-shadow(0 0 2px rgba(139, 92, 246, .2)); } to { filter: drop-shadow(0 0 10px rgba(139, 92, 246, .75)); } }
@media (prefers-reduced-motion: reduce) { .apa-map__portal *, .apa-map__portal { animation: none !important; } .apa-map__portal .pt-mote { opacity: 0; } }
@keyframes cs-wave { from { transform: skewY(0) scaleX(1); } to { transform: skewY(-10deg) scaleX(.82); } }
@keyframes cs-bob { from { transform: translateY(0) rotate(-3deg); } to { transform: translateY(-3px) rotate(3deg); } }
@keyframes cs-twinkle { 0%, 100% { transform: scale(0); opacity: 0; } 50% { transform: scale(1); opacity: 1; } }
@keyframes cs-mote { 0% { opacity: 0; transform: translateY(0) scale(.6); } 25% { opacity: .9; } 100% { opacity: 0; transform: translateY(-16px) scale(1.2); } }
@keyframes cs-aura-lv { from { filter: drop-shadow(0 6px 0 rgba(0, 0, 0, .35)) drop-shadow(0 0 2px rgba(250, 204, 21, .15)); } to { filter: drop-shadow(0 6px 0 rgba(0, 0, 0, .35)) drop-shadow(0 0 12px rgba(250, 204, 21, .6)); } }
@keyframes cs-aura { from { filter: drop-shadow(0 0 2px rgba(250, 204, 21, .15)); } to { filter: drop-shadow(0 0 10px rgba(250, 204, 21, .6)); } }
@media (prefers-reduced-motion: reduce) { .apa-map__castle .cs-flag, .apa-map__castle .cs-scroll, .apa-map__castle .cs-spark, .apa-map__castle { animation: none !important; } .apa-map__castle .cs-spark { opacity: 1; transform: none; } }
.apa-map__castle .cs-pole { stroke: #8796a8; stroke-width: 1.6; stroke-linecap: round; }
.apa-map.apa-map .apa-map__node[class][class].is-castle.is-open { --wall: #31445c; --flag: var(--c); --win: color-mix(in srgb, var(--c) 60%, #101824); }
.apa-map.apa-map .apa-map__node[class][class].is-castle.is-done { --wall: var(--c); --shade: rgba(0,0,0,.16); --door: #0b121c; --win: rgba(255,255,255,.75); --flag: #fbbf24; }
.apa-map.apa-map .apa-map__node[class][class].is-castle.is-cur { width: 72px; height: 72px; margin: -42px 0 0 -36px; --wall: #f4f7fb; --shade: rgba(15,30,50,.12); --door: var(--c); --win: var(--c); --flag: #ec4899; filter: drop-shadow(0 0 12px color-mix(in srgb, var(--c) 55%, transparent)) drop-shadow(0 5px 0 rgba(0,0,0,.3)); }
.apa-map.apa-map .apa-map__node[class][class].is-castle.is-diploma { --flag: #fbbf24; }
.apa-map.apa-map .apa-map__node[class][class].is-castle.is-diploma.is-done { --wall: #fbbf24; }
.apa-map.apa-map .apa-map__node[class][class].is-castle.is-cur .apa-map__castle { width: 72px; height: 72px; }

/* Lesson name on hover / keyboard focus. */
.apa-map__pop { position: absolute; left: 50%; bottom: calc(100% + 10px); transform: translateX(-50%) translateY(4px); width: max-content; max-width: 220px; padding: 7px 11px; border-radius: 9px; background: #0b121c; border: 1px solid rgba(255,255,255,.14); box-shadow: 0 8px 20px rgba(0,0,0,.45); color: #e6edf5; font-size: 12.5px; font-weight: 700; line-height: 1.3; text-align: center; white-space: normal; opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .12s, transform .12s; }
.apa-map__pop small { display: block; margin-bottom: 2px; color: #98a7b6; font-size: 10.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.apa-map__pop::after { content: ""; position: absolute; left: 50%; top: 100%; margin-left: -6px; border: 6px solid transparent; border-top-color: #0b121c; }
.apa-map.apa-map .apa-map__node[class][class]:hover, .apa-map.apa-map .apa-map__node[class][class]:focus-visible { z-index: 5; }
.apa-map__node:hover .apa-map__pop, .apa-map__node:focus-visible .apa-map__pop { opacity: 1; visibility: visible; transform: translateX(-50%); }
.apa-map__node.pop-l .apa-map__pop { left: -8px; transform: translateY(4px); }
.apa-map__node.pop-l .apa-map__pop::after { left: 26px; }
.apa-map__node.pop-r .apa-map__pop { left: auto; right: -8px; transform: translateY(4px); }
.apa-map__node.pop-r .apa-map__pop::after { left: auto; right: 20px; }
.apa-map__node.pop-l:hover .apa-map__pop, .apa-map__node.pop-l:focus-visible .apa-map__pop, .apa-map__node.pop-r:hover .apa-map__pop, .apa-map__node.pop-r:focus-visible .apa-map__pop { transform: none; }
.apa-map__node.pop-b .apa-map__pop { bottom: auto; top: calc(100% + 10px); }
.apa-map__node.pop-b .apa-map__pop::after { top: auto; bottom: 100%; border-top-color: transparent; border-bottom-color: #0b121c; }

/* Empty spaces: small editor cards with code from the course, and the module's destination. */
.apa-map__deco { position: absolute; transform: translateY(-50%) rotate(var(--r)); padding: 10px 14px 12px; border-radius: 14px; background: linear-gradient(160deg, rgba(23,34,47,.92), rgba(12,25,40,.85)); border: 1px solid rgba(255,255,255,.07); box-shadow: 0 18px 40px rgba(0,0,0,.35); opacity: .78; pointer-events: none; }
.apa-map__deco b { display: flex; align-items: center; gap: 5px; margin-bottom: 8px; }
.apa-map__deco b i { width: 8px; height: 8px; border-radius: 50%; background: #3a4a5e; }
.apa-map__deco b i:first-child { background: #f87171; } .apa-map__deco b i:nth-child(2) { background: #fbbf24; } .apa-map__deco b i:nth-child(3) { background: #34d399; }
.apa-map__deco b img { width: 18px; height: 18px; margin-left: auto; opacity: .85; }
.apa-map__deco code { display: block; padding: 0; background: none; color: #c5d0dc; font: 12.5px/1.65 ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre; overflow: hidden; text-overflow: ellipsis; }
.apa-map__deco code i { font-style: normal; }
.apa-map__deco .k { color: #c084fc; } .apa-map__deco .s { color: #86efac; } .apa-map__deco .n { color: #fbbf24; }
.apa-map__goal { position: absolute; transform: translate(-50%, -50%); box-sizing: border-box; display: grid; grid-template-columns: 64px minmax(0, 1fr); align-items: center; column-gap: 16px; padding: 16px 22px 16px 16px; border-radius: 18px; background: linear-gradient(135deg, rgba(45,212,191,.12), rgba(167,139,250,.10)); border: 1px solid rgba(45,212,191,.28); box-shadow: 0 18px 40px rgba(0,0,0,.3); }
.apa-map__goal svg { grid-row: 1; grid-column: 1; transform: rotate(-90deg); }
.apa-map__goal circle { fill: none; stroke: rgba(255,255,255,.08); stroke-width: 6; }
.apa-map__goal circle.is-on { stroke: #2dd4bf; stroke-linecap: round; }
.apa-map__goal strong { grid-row: 1; grid-column: 1; text-align: center; color: #e6edf5; font-size: 15px; }
.apa-map__goal div { grid-row: 1; grid-column: 2; display: grid; gap: 2px; min-width: 0; }
.apa-map__goal small { color: #5eead4; font-size: 10.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.apa-map__goal b { color: #fff; font-size: 16px; line-height: 1.25; }
.apa-map__goal span { color: #98a7b6; font-size: 13px; }

.apa-map__me { position: absolute; z-index: 3; pointer-events: none; transform: translate(-50%, -100%); margin-top: -26px; display: flex; align-items: center; gap: 6px; }
.apa-map__me-pin { position: relative; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: #f9d0e3; border: 3px solid #ec4899; color: #9d2a62; font-weight: 900; font-size: 15px; box-shadow: 0 4px 10px rgba(0,0,0,.35); }
.apa-map__me-pin img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
.apa-map__me-pin::after { content: ""; position: absolute; left: 50%; bottom: -10px; margin-left: -6px; border: 6px solid transparent; border-top-color: #ec4899; border-bottom: 0; }
.apa-map__me.is-below { transform: translate(-50%, 0); margin-top: 30px; }
.apa-map__me.is-below .apa-map__me-pin::after { bottom: auto; top: -10px; border-top: 0; border-bottom: 6px solid #ec4899; }
.apa-map__me.is-below .apa-map__me-tag { top: 8px; }
.apa-map__me-tag { position: absolute; left: 40px; top: 6px; white-space: nowrap; padding: 3px 10px; border-radius: 99px; background: #ec4899; color: #fff; font-size: 12px; font-weight: 800; }
.apa-map__me.is-flip .apa-map__me-tag { left: auto; right: 40px; } /* near the right edge: the tag goes on the left */

.apa-map__tip { display: grid; grid-template-columns: 1fr auto; align-items: center; column-gap: 14px; margin: 0 0 10px; padding: 12px 16px; border-radius: 14px; background: #0b121c; border: 1px solid rgba(236,72,153,.45); }
.apa-map__tip small { grid-column: 1; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.apa-map__tip strong { grid-column: 1; color: #e6edf5; font-size: 15px; }
.apa-map__tip .apa-btn { grid-column: 2; grid-row: 1 / span 2; }
.apa-module__body.is-list .apa-map__tip { display: none; }

.apa-map__label { position: absolute; transform: translateY(-50%); max-width: 42%; color: #c5d0dc; font-size: 13px; line-height: 1.25; }
.apa-map__label.is-left { text-align: right; }
.apa-map__label.is-lock { color: #5b6b80; }
.apa-map__label.is-cur { color: #fff; font-weight: 800; }
/* Dashboard: the current module's map in a dropdown under the "Continuă" card. */
.apa-continue-card { margin-bottom: 34px; padding: 0; overflow: hidden; border-color: rgba(32, 199, 183, 0.3); }
.apa-dash__main .apa-continue-card { margin: 0; }
.apa-continue-card .apa-continue { margin: 0; padding: 26px; }
.apa-continue-card .apa-dash-map { margin: 0; border: 0; border-top: 1px solid var(--apa-border); border-radius: 0; background: rgba(0, 0, 0, 0.12); box-shadow: none; }
.apa-dash-map .apa-module__title strong { font-size: 15px; }
/* Career path: the courses as an archipelago (same Hartă / Listă switch as the course pages). */
.apa-path-mapbox:not(.is-list) .apa-path-steps { display: none; }
.apa-path-mapbox.is-list .apa-map { display: none; }
.apa-path-mapbox .apa-map { margin-bottom: 18px; }
.apa-map a.apa-path-isle { position: absolute; z-index: 1; display: grid; place-items: center; width: 60px; height: 60px; margin: -30px 0 0 -30px; border-radius: 15px; background: #fff; box-shadow: 0 5px 0 rgba(0, 0, 0, .3); transition: transform .15s; }
.apa-map a.apa-path-isle:hover { transform: translateY(-3px); }
.apa-path-isle img { width: 38px; height: 38px; object-fit: contain; }
.apa-path-isle.is-done { box-shadow: 0 0 0 4px #13261f, 0 0 0 7px #2dd4bf, 0 5px 0 rgba(0, 0, 0, .3); }
.apa-path-isle.is-cur { box-shadow: 0 0 0 4px #13261f, 0 0 0 7px #fff, 0 0 34px 10px rgba(45, 212, 191, .45); }
.apa-path-isle.is-fog { opacity: .8; filter: grayscale(.6); }
.apa-path-isle__bar { position: absolute; width: 110px; height: 7px; margin-left: -55px; border-radius: 4px; background: #0b121c; overflow: hidden; }
.apa-path-isle__bar i { display: block; height: 100%; background: #2dd4bf; border-radius: 4px; }
.apa-path-isle__bar.is-cur i { background: #fff; }
.apa-path-isle__n { position: absolute; transform: translateX(-50%); white-space: nowrap; color: #e6edf5; font-size: 12.5px; font-weight: 700; text-shadow: 0 1px 2px rgba(0, 0, 0, .7); }
.apa-path-isle__n.is-fog { color: #8a97a8; }
.apa-path-goal { position: absolute; transform: translateX(-50%); white-space: nowrap; color: #fbbf24; font-size: 15px; font-weight: 800; text-shadow: 0 1px 3px rgba(0, 0, 0, .7); }
/* Career page hero, "Insula de start": the sea behind, the stats as islets and the side card as an island with mountains. */
.apa-career-hero--isle { background: radial-gradient(70% 90% at 74% 40%, #14304c, #0e1f34 60%, #0b111a) !important; }
.apa-career-hero--isle::before { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='44' height='44'%3E%3Cpath d='M6 24q5-5 10 0t10 0' fill='none' stroke='%231a2f4c' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") 0 0 / 44px 44px !important; -webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, .25), #000 55%) !important; mask-image: linear-gradient(90deg, rgba(0, 0, 0, .25), #000 55%) !important; }
.apa-career-hero--isle .apa-stats { margin-bottom: 22px; gap: 14px; }
.apa-career-hero--isle .apa-stats li { background: linear-gradient(135deg, #2f6b4f, #1d4a39) !important; border: 4px solid #c9b48a !important; border-radius: 20px !important; box-shadow: 0 9px 0 #4a321d, 0 20px 24px rgba(0, 0, 0, .45) !important; }
.apa-career-hero--isle .apa-stats li:nth-child(even) { transform: translateY(8px); }
.apa-career-hero--isle .apa-stats span { color: #d6e6dc; font-weight: 600; }
.apa-career-hero--isle .apa-stats__sal strong { color: #86efac; }
.apa-career-hero--isle .apa-isle-card { position: relative; padding-top: 0 !important; background: linear-gradient(135deg, #2f6b4f, #1d4a39) !important; border: 6px solid #c9b48a !important; border-radius: 34px !important; box-shadow: 0 16px 0 #4a321d, 0 17px 0 #2c1d12, 0 34px 40px rgba(0, 0, 0, .5) !important; margin-bottom: 18px !important; }
.apa-isle-card__top { position: relative; height: 104px; margin: 0 -6px 4px; }
.apa-isle-card__top svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.apa-isle-card__logo { position: absolute; left: 50%; top: 22px; display: grid; place-items: center; width: 58px; height: 58px; margin-left: -29px; border-radius: 15px; overflow: hidden; box-shadow: 0 0 0 4px #13261f, 0 0 0 7px #2dd4bf, 0 6px 0 7px rgba(0, 0, 0, .25); }
.apa-isle-card__logo img { width: 58px; height: 58px; object-fit: cover; }
.apa-career-hero--isle .apa-isle-card .apa-muted { color: #cfe3d6; }
.apa-career-hero--isle .apa-isle-card .apa-hero-bundle { background: rgba(0, 0, 0, .22); border-color: rgba(252, 211, 77, .4); }
.apa-career-hero--isle .apa-isle-card .apa-progress { background: rgba(0, 0, 0, .3); }
.apa-career-hero__boat { position: absolute; right: 3%; bottom: 0; width: 220px; height: 110px; pointer-events: none; }
@media (max-width: 960px) { .apa-career-hero__boat { display: none; } .apa-career-hero--isle .apa-stats li:nth-child(even) { transform: none; } }
/* Course hero as an island, like the career pages: the card is the start island (START flag), every stat a small islet. */
.apa-course-hero--isle .apa-isle-card__top { height: 104px; }
.apa-course-hero--isle .apa-stats2 { gap: 26px 22px !important; margin-top: 30px !important; }
.apa-course-hero--isle .apa-stats2 li { position: relative; overflow: visible; padding: 14px 16px; border-radius: 26px 26px 34px 34px !important; transform: none; }
.apa-course-hero--isle .apa-stats2 li:nth-child(even) { transform: translateY(14px); }
.apa-course-hero--isle .apa-stats2 li::after { content: ""; position: absolute; right: 14px; top: -22px; width: 60px; height: 26px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 26'%3E%3Cpath d='M8 26L16 12L22 20L30 4L40 20L46 14L54 26Z' fill='%23297d55'/%3E%3C/svg%3E") center / contain no-repeat; pointer-events: none; }
.apa-course-hero--isle .apa-stats2 li:nth-child(odd)::after { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 26'%3E%3Cpath d='M8 26L16 12L22 20L30 4L40 20L46 14L54 26Z' fill='%23246c49'/%3E%3C/svg%3E"); }
.apa-course-hero--isle .apa-stats2 em { color: #d6e6dc; }
.apa-course-hero--isle .apa-ccard2__top { align-items: center; text-align: center; margin-top: -4px; border-bottom: 2px dashed rgba(201, 180, 138, .4); }
.apa-course-hero--isle .apa-ccard2__badge { align-self: center; background: #c9b48a; color: #2c1d12; box-shadow: 0 3px 0 #4a321d; }
.apa-course-hero--isle .apa-ccard2__headline { color: #fff7e0; }
.apa-course-hero--isle .apa-ccard2__sub { color: #cfe3d6; }
.apa-course-hero--isle .apa-ccard2__list li, .apa-course-hero--isle .apa-hero-meta a { color: #e6f2ea; }
.apa-course-hero--isle .apa-ccard2__ic { background: rgba(0, 0, 0, .25); color: #86efac; }
.apa-course-hero--isle .apa-next-price { color: #cfe3d6; }
@media (max-width: 960px) { .apa-course-hero--isle .apa-stats2 li:nth-child(even) { transform: none; } .apa-course-hero--isle .apa-stats2 { gap: 22px 12px !important; } .apa-course-hero--isle .apa-stats2 li::after { right: 10px; top: -18px; width: 46px; height: 20px; } }
/* Moving sea behind the island heroes: two wave layers drift the same way at different speeds (the near, sparse one faster) and swell slightly. */
.apa-career-hero--isle.has-sea::before { background: none !important; }
.apa-sea { position: absolute; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; -webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, .25), #000 55%); mask-image: linear-gradient(90deg, rgba(0, 0, 0, .25), #000 55%); }
.apa-sea i { position: absolute; top: 0; bottom: 0; left: -176px; right: -176px; will-change: transform; }
.apa-sea i:first-child { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='44' height='44'%3E%3Cpath d='M6 24q5-5 10 0t10 0' fill='none' stroke='%23284a74' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") 0 0 / 44px 44px; animation: apa-sea-a 6s linear infinite, apa-sea-swell 4s ease-in-out infinite alternate; }
.apa-sea i:last-child { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='88' height='88'%3E%3Cpath d='M30 66q6-6 12 0t12 0' fill='none' stroke='%23356196' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") 0 0 / 88px 88px; animation: apa-sea-b 7s linear infinite, apa-sea-swell 5s ease-in-out -2s infinite alternate; }
@keyframes apa-sea-a { to { transform: translateX(44px); } }
@keyframes apa-sea-b { to { transform: translateX(88px); } }
@keyframes apa-sea-swell { from { translate: 0 -2px; } to { translate: 0 3px; } }
@media (prefers-reduced-motion: reduce) { .apa-sea i { animation: none; } }
/* The sea on the course and career maps moves like the hero sea: the same two wave layers, drifting the same way, with the swell.
   Pseudo-elements, because the map redraws its contents; isolation keeps them under the islands. */
.apa-map { isolation: isolate; }
.apa-map::before, .apa-map::after { content: ""; position: absolute; inset: -44px 0 -44px -176px; z-index: -1; pointer-events: none; }
.apa-map::before { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='44' height='44'%3E%3Cpath d='M6 24q5-5 10 0t10 0' fill='none' stroke='%23284a74' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") 0 0 / 44px 44px; }
.apa-map::after { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='88' height='88'%3E%3Cpath d='M30 66q6-6 12 0t12 0' fill='none' stroke='%23356196' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") 0 0 / 88px 88px; }
/* Only while the map is on screen (apa-map.js sets is-live). */
.apa-map.is-live::before { animation: apa-sea-a 6s linear infinite, apa-sea-swell 4s ease-in-out infinite alternate; }
.apa-map.is-live::after { animation: apa-sea-b 7s linear infinite, apa-sea-swell 5s ease-in-out -2s infinite alternate; }
@media (prefers-reduced-motion: reduce) { .apa-map.is-live::before, .apa-map.is-live::after { animation: none; } }

/* Lesson island (apa-map.js adds .lv to the body of a lesson page): the current zone as an island walked on foot, the lesson column restyled to match. */
.lv .lv-strip { position: relative; isolation: isolate; aspect-ratio: 860 / 300; margin: 4px 0 26px; border-radius: 22px; overflow: hidden; border: 1px solid rgba(94, 234, 212, .22); background: radial-gradient(120% 140% at 80% 0, #17406a 0, #0f2c4c 45%, #0a1b30 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 24px 50px -30px rgba(14, 165, 233, .5); }
.lv .lv-map { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.lv .lv-zone { position: absolute; top: 17.3%; transform: translate(-50%, -50%); z-index: 2; white-space: nowrap; padding: 4px 12px; border-radius: 99px; background: #0b121c; border: 2px solid var(--c); color: var(--c); font-size: 12px; font-weight: 800; }
.lv .lv-zone--next { top: 20.6%; left: auto !important; right: 10px; transform: translateY(-50%); max-width: 26%; overflow: hidden; text-overflow: ellipsis; opacity: .9; }
.lv .lv-count { position: absolute; left: 14px; top: 12px; z-index: 2; padding: 5px 11px; border-radius: 999px; background: rgba(10, 20, 36, .6); border: 1px solid rgba(255, 255, 255, .14); color: #cbd5e1; font-size: 12px; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.lv .lv-count b { color: #fff; }
.lv .lv-road { fill: none; stroke: #6b5a40; stroke-width: 15; stroke-linecap: round; stroke-linejoin: round; opacity: .85; }
.lv .lv-road-dash { fill: none; stroke: #e8d7b0; stroke-width: 2.5; stroke-dasharray: 2 9; stroke-linecap: round; opacity: .7; }
.lv .lv-road-done { fill: none; stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 10 7; }
.lv .lv-stop circle { fill: #1b2838; stroke: var(--c); stroke-width: 3; }
.lv .lv-stop text { fill: #e2e8f0; font: 800 13px var(--f-sans, sans-serif); }
.lv .lv-stop.is-done circle { fill: var(--c); }
.lv .lv-stop.is-done text { fill: #06231f; }
.lv .lv-stop.is-todo { opacity: .7; }
.lv .lv-stop.is-todo circle { stroke: #64748b; }
.lv .lv-stop .lv-ring { fill: none; stroke: var(--c); stroke-width: 2; transform-origin: 0 0; animation: lv-ring 2.2s ease-out infinite; }
.lv .lv-stop.is-new circle { animation: lv-pop .5s cubic-bezier(.3, 1.6, .5, 1); transform-origin: 0 0; }
@keyframes lv-ring { from { transform: scale(.8); opacity: .9; } to { transform: scale(1.5); opacity: 0; } }
@keyframes lv-pop { from { transform: scale(.4); } to { transform: scale(1); } }
.lv .lv-man { transform-box: view-box; }
.lv .lv-man-in { animation: lv-idle 2.4s ease-in-out infinite alternate; }
.lv .lv-man.is-walking .lv-man-in { animation: lv-step .32s ease-in-out infinite alternate; }
.lv .lv-man.is-walking .lv-leg { transform-box: fill-box; transform-origin: 50% 0; animation: lv-swing .32s ease-in-out infinite alternate; }
.lv .lv-man.is-walking .lv-leg--b { transform-box: fill-box; transform-origin: 50% 0; animation: lv-swing .32s ease-in-out infinite alternate-reverse; }
@keyframes lv-idle { from { transform: translateY(0); } to { transform: translateY(-1.5px); } }
@keyframes lv-step { from { transform: translateY(0); } to { transform: translateY(-2.5px); } }
@keyframes lv-swing { from { transform: rotate(-22deg); } to { transform: rotate(22deg); } }
.lv .lv-toast { position: absolute; left: 50%; bottom: 10px; transform: translate(-50%, 20px); opacity: 0; padding: 8px 14px; border-radius: 999px; background: linear-gradient(135deg, #2dd4bf, #22c55e); color: #052e2b; font-size: 13px; white-space: nowrap; box-shadow: 0 10px 24px -8px rgba(45, 212, 191, .8); transition: .45s cubic-bezier(.3, 1.4, .5, 1); z-index: 3; }
.lv .lv-toast.show { opacity: 1; transform: translate(-50%, 0); }
.lv .lv-burst { position: absolute; width: 0; height: 0; z-index: 2; }
.lv .lv-burst i { position: absolute; left: -3px; top: -3px; width: 6px; height: 6px; border-radius: 2px; background: #facc15; animation: lv-burst .9s ease-out forwards; }
.lv .lv-burst i:nth-child(3n) { background: #5eead4; } .lv .lv-burst i:nth-child(3n+1) { background: #f472b6; }
@keyframes lv-burst { from { transform: rotate(var(--a)) translateY(0); opacity: 1; } to { transform: rotate(var(--a)) translateY(calc(-1 * var(--d))); opacity: 0; } }

/* The lesson column */
.lv .ap-lesson-eyebrow { display: inline-flex !important; align-items: center; gap: 7px; }
.lv .ap-lesson-title .ap-highlight { background: linear-gradient(90deg, #5eead4, #38bdf8 60%, #a78bfa); -webkit-background-clip: text; background-clip: text; color: transparent !important; }
.lv .ap-lesson-divider { height: 2px !important; background: linear-gradient(90deg, rgba(232, 215, 176, .5) 0 4px, transparent 4px 12px) 0 0 / 12px 2px repeat-x !important; opacity: .7; border: 0 !important; }
.lv .ap-lesson-section.lv-wp { position: relative; padding-left: 40px; }
.lv .ap-lesson-section.lv-wp::before { content: ""; position: absolute; left: 13px; top: 34px; bottom: -14px; border-left: 2px dashed rgba(232, 215, 176, .28); }
.lv .ap-lesson-section.lv-wp > h2 { position: relative; }
.lv .ap-lesson-section.lv-wp > h2::before { content: var(--n); position: absolute; left: -40px; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font: 800 12px var(--f-sans, sans-serif); color: #052e2b; background: radial-gradient(circle at 35% 30%, #99f6e4, #2dd4bf); box-shadow: 0 0 0 4px rgba(45, 212, 191, .15), 0 6px 14px -4px rgba(45, 212, 191, .7); }
.lv .ap-lesson-section .ap-code-example, .lv .ap-lesson-section pre { border-radius: 14px !important; border: 1px solid rgba(94, 234, 212, .18) !important; box-shadow: inset 3px 0 0 #2dd4bf; }

.lv .ap-exercise-card { position: relative; overflow: hidden; border-radius: 20px !important; border: 1px solid rgba(250, 204, 21, .35) !important; background: radial-gradient(rgba(232, 215, 176, .09) 1px, transparent 1.4px) 0 0 / 14px 14px, linear-gradient(150deg, rgba(250, 204, 21, .1), rgba(244, 114, 182, .07) 60%, rgba(10, 20, 36, .3)) !important; box-shadow: 0 20px 44px -28px rgba(250, 204, 21, .45); }
.lv .lv-mission { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 10px; padding: 5px 10px; border-radius: 999px; background: rgba(250, 204, 21, .14); border: 1px solid rgba(250, 204, 21, .35); color: #fde68a; font: 800 10.5px/1 var(--f-mono, monospace); letter-spacing: .1em; text-transform: uppercase; }
.lv .ap-next-lesson.show { background: linear-gradient(135deg, #2dd4bf, #0ea5e9) !important; border-radius: 14px !important; box-shadow: 0 16px 34px -12px rgba(14, 165, 233, .7) !important; }

/* Editor and console: a ship's cockpit */
.lv .ap-editor-panel { background: linear-gradient(180deg, #0b1626, #070d16) !important; }
.lv .ap-editor-panel-header { background: linear-gradient(90deg, rgba(45, 212, 191, .1), transparent 60%) !important; border-bottom: 1px solid rgba(94, 234, 212, .16) !important; }
.lv .ap-python-run { border-radius: 12px !important; background: linear-gradient(135deg, #2dd4bf, #0ea5e9) !important; color: #052e2b !important; border: 0 !important; box-shadow: 0 10px 24px -10px rgba(45, 212, 191, .8) !important; }
.lv .ap-python-run:disabled { background: linear-gradient(135deg, #334155, #1e293b) !important; color: #94a3b8 !important; box-shadow: none !important; }
.lv .ap-python-console-header { position: relative; padding-left: 30px !important; }
.lv .ap-python-console-header::before { content: ""; position: absolute; left: 14px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: #2dd4bf; box-shadow: 0 0 0 0 rgba(45, 212, 191, .6); animation: lv-ping 2s infinite; }
@keyframes lv-ping { to { box-shadow: 0 0 0 8px rgba(45, 212, 191, 0); } }

/* Bottom progress: the boat at the end of the sailed stretch */
.lv .lv-track { position: relative; overflow: visible !important; }
.lv .lv-minib { position: absolute; top: -21px; width: 26px; height: 29px; margin-left: -13px; pointer-events: none; transition: left .6s ease; }
.lv .lv-minib svg { width: 26px; height: 29px; }

@media (max-width: 720px) { .lv .lv-strip { margin-bottom: 20px; } .lv .lv-zone { font-size: 10px; padding: 3px 9px; } .lv .ap-lesson-section.lv-wp { padding-left: 34px; } .lv .ap-lesson-section.lv-wp > h2::before { left: -34px; width: 24px; height: 24px; } .lv .ap-lesson-section.lv-wp::before { left: 11px; } }
@media (prefers-reduced-motion: reduce) { .lv .lv-man-in, .lv .lv-ring { animation: none !important; transition: none !important; } }
.lv .ap-next-lesson.lv-next { display: flex !important; align-items: center; justify-content: center; gap: 10px; }
.lv .lv-btnman { flex: none; margin: -8px 0 -4px; }
.lv .lv-map .apa-map__castle { --wall: #3a4b62; --shade: rgba(0, 0, 0, .22); --door: #131c2a; --win: #fde68a; --flag: #facc15; filter: drop-shadow(0 6px 0 rgba(0, 0, 0, .35)); }
/* Long zones: the frame pans along the island */
.lv .lv-map { cursor: grab; touch-action: pan-y; }
.lv .lv-map:active { cursor: grabbing; }
.lv .lv-cam { will-change: transform; }
.lv .lv-label text { font: 800 13px var(--f-sans, sans-serif); }
.lv .lv-stop.is-wide text { font-size: 12px; }
.lv .lv-strip::before, .lv .lv-strip::after { content: ""; position: absolute; top: 0; bottom: 0; width: 64px; z-index: 1; pointer-events: none; opacity: 0; transition: opacity .3s; }
.lv .lv-strip::before { left: 0; background: linear-gradient(90deg, rgba(10, 27, 48, .85), transparent); }
.lv .lv-strip::after { right: 0; background: linear-gradient(-90deg, rgba(10, 27, 48, .85), transparent); }
.lv .lv-strip.has-before::before, .lv .lv-strip.has-after::after { opacity: 1; }
.lv .lv-zoneprog { position: absolute; left: 14px; bottom: 10px; z-index: 2; display: flex; align-items: center; gap: 8px; padding: 5px 11px; border-radius: 999px; background: rgba(10, 20, 36, .7); border: 1px solid rgba(255, 255, 255, .14); color: #cbd5e1; font-size: 12px; }
.lv .lv-zoneprog b { color: #fff; }
.lv .lv-zoneprog i { width: 60px; height: 5px; border-radius: 5px; background: rgba(148, 163, 184, .25); overflow: hidden; }
.lv .lv-zoneprog s { display: block; height: 100%; border-radius: 5px; background: var(--c); }
.lv .lv-zone { position: absolute; top: 17.3%; left: 50%; transform: translate(-50%, -50%); z-index: 2; white-space: nowrap; padding: 4px 12px; border-radius: 99px; background: #0b121c; border: 2px solid var(--c); color: var(--c); font-size: 12px; font-weight: 800; pointer-events: none; }
@media (max-width: 720px) { .lv .lv-zone { font-size: 10px; padding: 3px 9px; } }
.lv .lv-lock circle { fill: #0b121c; stroke: #64748b; stroke-width: 1.5; }
.lv .lv-lock rect { fill: #94a3b8; }
.lv .lv-lock path { fill: none; stroke: #94a3b8; stroke-width: 1.3; }
/* Dashboard: the zone of the next lesson as the lesson island, inside the "Continuă" card (apa-map.js). */
.apa-dash-lv { margin: 0 0 14px; }
.apa-dash-lv .lv-strip { margin: 0; }
.apa-dash-lv .lv-stop.is-link { cursor: pointer; }
.apa-dash-lv .lv-stop.is-link:hover circle:not(.lv-ring) { stroke-width: 4; }
.apa-dash-lv .lv-map { touch-action: pan-y; cursor: grab; }
@media (max-width: 560px) { .apa-dash-lv .lv-zoneprog, .apa-dash-lv .lv-zone { font-size: 11px; } }
/* Castle moment: a new certificate since the last visit. */
.apa-cm { position: fixed; inset: 0; z-index: 9999; display: grid; place-items: center; padding: 16px; background: rgba(3, 7, 12, .74); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); animation: apa-cm-in .2s ease-out; }
.apa-cm__sheet { width: min(520px, 100%); overflow: hidden; border-radius: 22px; background: #131c29; border: 1px solid rgba(94, 234, 212, .22); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .8); animation: apa-cm-rise .35s cubic-bezier(.2, .9, .3, 1.2); }
.apa-cm__scene { position: relative; isolation: isolate; aspect-ratio: 420 / 160; overflow: hidden; background: radial-gradient(120% 140% at 80% 0, #17406a 0, #0f2c4c 45%, #0a1b30 100%); }
.apa-cm__body { display: grid; gap: 8px; padding: 20px 22px 22px; opacity: 0; transform: translateY(10px); transition: opacity .35s, transform .35s; }
.apa-cm.is-done .apa-cm__body { opacity: 1; transform: none; }
.apa-cm__body .apa-kicker { color: #fbbf24; }
.apa-cm__body h2 { margin: 0; font-size: 24px; }
.apa-cm__body p { margin: 0; }
.apa-cm__btns { display: grid; gap: 10px; margin-top: 8px; }
.apa-cm__btns .apa-btn { justify-content: center; }
.apa-cm .cs-flag { transform-box: fill-box; transform-origin: 0 50%; transform: translateY(9px) scaleX(.15); transition: transform .7s cubic-bezier(.3, 1.6, .5, 1); }
.apa-cm.is-up .cs-flag { transform: none; }
@keyframes apa-cm-in { from { opacity: 0; } }
@keyframes apa-cm-rise { from { opacity: 0; transform: translateY(16px) scale(.98); } }
@media (prefers-reduced-motion: reduce) { .apa-cm, .apa-cm__sheet, .apa-cm__body, .apa-cm .cs-flag { animation: none; transition: none; } }
/* Career map boat: rocks on the water and sails over from the previous course (apa-map.js). */
.apa-path-boat__rock { transform-box: fill-box; transform-origin: 50% 80%; animation: apa-boat-rock 3.2s ease-in-out infinite alternate; }
@keyframes apa-boat-rock { from { transform: rotate(-4deg) translateY(0); } to { transform: rotate(4deg) translateY(2px); } }
@media (prefers-reduced-motion: reduce) { .apa-path-boat__rock { animation: none; } }
/* Main career path on the dashboard as a voyage (apa-map.js). */
.apa-pp-voyage { margin: 4px 0 16px; }
.apa-pp-voyage .lv-strip { margin: 0; }
.apa-voy .apa-voy-name { fill: #e6edf5; font: 800 13px var(--f-sans, sans-serif); }
.apa-voy .apa-voy-name.is-fog { fill: #7d8b9c; }
.apa-voy .apa-voy-pct { fill: #5eead4; font: 800 12px var(--f-sans, sans-serif); }
.apa-voy .apa-voy-isle circle { transition: stroke-width .15s; }
.apa-voy .apa-voy-isle:hover circle, .apa-voy .apa-voy-isle:focus-visible circle { stroke-width: 5; }
.apa-voy .apa-voy-num { fill: #0f172a; font: 800 15px var(--f-sans, sans-serif); }
.apa-voy .apa-voy-num.is-fog { fill: #64748b; }
.apa-voy .apa-voy-sub { fill: #94a3b8; font: 600 11.5px var(--f-sans, sans-serif); }
.apa-goal__scene .lv-strip { margin: 0; }
.apa-voy.is-draggable { cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.apa-voy.is-draggable:active { cursor: grabbing; }

/* Diploma puzzle of the free module: the present at the end of each island and the popup where the piece is won (APA_PUZZLE). */
.apz-gift-at .apz-glow circle { fill: #facc15; opacity: .16; animation: apz-glow 1.8s ease-in-out infinite alternate; }
.apz-gift-at .apz-gift { animation: apz-bob 1.6s ease-in-out infinite alternate; }
.apz-gift-at .apz-lid { transition: transform .5s cubic-bezier(.3, 1.6, .5, 1); transform-box: view-box; }
.apz-gift-at .apz-pop { opacity: 0; transition: opacity .3s; }
.apz-gift-at .apz-mini, .lv-puz .apz-mini, .ap-puzzle-button .apz-mini { fill: #facc15; stroke: #92400e; stroke-width: 1.2; }
.apz-gift-at.is-open .apz-gift { animation: none; }
.apz-gift-at.is-open .apz-lid { transform: translate(14px, -16px) rotate(28deg); }
.apz-gift-at.is-open .apz-glow circle { animation: none; opacity: 0; }
.lv-map .apz-gift-at.is-open .apz-gift { opacity: .7; }
@keyframes apz-glow { from { transform: scale(.8); opacity: .1; } to { transform: scale(1.1); opacity: .28; } }
@keyframes apz-bob { from { transform: translateY(0); } to { transform: translateY(-2.5px); } }
.apz-gift-at .apz-glow { transform-box: fill-box; }
.apz-gift-at .apz-glow circle { transform-box: fill-box; transform-origin: center; }

.lv .lv-puz { position: absolute; right: 14px; bottom: 10px; z-index: 2; display: flex; align-items: center; gap: 7px; padding: 5px 11px; border-radius: 999px; background: rgba(10, 20, 36, .75); border: 1px solid rgba(250, 204, 21, .45); color: #fde68a; font: 600 12px/1.2 var(--f-sans, Inter, system-ui, sans-serif); cursor: pointer; }
.lv .lv-puz b { color: #fff; }
.lv .lv-puz:hover { border-color: #facc15; }
@media (max-width: 560px) { .lv .lv-puz { font-size: 11px; padding: 4px 9px; } }

body.apz-open { overflow: hidden; }
.apz { position: fixed; inset: 0; z-index: 100000; display: grid; grid-template-columns: minmax(0, 640px); place-content: center; align-items: center; padding: 16px; opacity: 0; transition: opacity .25s; }
.apz.is-in { opacity: 1; }
.apz-bg { position: absolute; inset: 0; background: rgba(3, 8, 18, .78); backdrop-filter: blur(4px); }
.apz-dlg { position: relative; box-sizing: border-box; width: 100%; max-height: calc(100vh - 32px); overflow: auto; padding: 22px 22px 18px; border-radius: 20px; background: radial-gradient(120% 80% at 50% 0, #12304a 0, #0b1626 60%); border: 1px solid rgba(255, 255, 255, .1); box-shadow: 0 30px 80px rgba(0, 0, 0, .6); color: #e2e8f0; text-align: center; transform: translateY(14px) scale(.97); transition: transform .35s cubic-bezier(.3, 1.4, .5, 1); }
.apz.is-in .apz-dlg { transform: none; }
.apz-x { position: absolute; top: 10px; right: 12px; width: 34px; height: 34px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .06); color: #cbd5e1; font-size: 22px; line-height: 1; cursor: pointer; }
.apz-kicker { display: block; margin: 0 36px 6px; color: #5eead4; font: 700 11px/1.4 var(--f-mono, ui-monospace, monospace); letter-spacing: .08em; text-transform: uppercase; }
.apz-h { margin: 0 0 14px; color: #fff; font-size: 24px; line-height: 1.2; }
.apz-stage { position: relative; display: grid; gap: 6px; }
.apz-board { position: relative; width: 100%; aspect-ratio: 1123 / 794; border-radius: 10px; background: rgba(148, 163, 184, .08); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08); }
.apz-in { position: absolute; top: 0; left: 0; width: 1123px; height: 794px; transform-origin: top left; }
.apz-piece { position: absolute; inset: 0; width: 1123px; height: 794px; }
.apz-piece .apa-cert-sheet { position: absolute; top: 0; left: 0; }
.apz-piece.is-fly { z-index: 3; filter: drop-shadow(0 18px 24px rgba(0, 0, 0, .55)); }
.apz-piece.is-land { animation: apz-land .5s ease-out; }
@keyframes apz-land { 0% { filter: brightness(1.6) drop-shadow(0 0 30px #facc15); } 100% { filter: none; } }
.apz-lines { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 4; }
.apz-slot { fill: rgba(148, 163, 184, .07); stroke: rgba(203, 213, 225, .45); stroke-width: 3; stroke-dasharray: 12 10; }
.apz-slot.is-have { fill: none; stroke: rgba(15, 23, 42, .28); stroke-width: 2.5; stroke-dasharray: none; }
.apz-slot.is-new { stroke: #facc15; stroke-width: 6; animation: apz-new 1.4s ease-out forwards; }
@keyframes apz-new { to { stroke: rgba(15, 23, 42, .28); stroke-width: 2.5; } }
.apz-board.is-done .apz-slot { transition: stroke-opacity 1.2s .2s; stroke-opacity: 0; }
.apz-board.is-done { box-shadow: 0 0 0 2px #facc15, 0 0 50px -6px rgba(250, 204, 21, .7); transition: box-shadow .8s; }
.apz-hero { display: flex; justify-content: center; margin-top: -2px; }
.apz-hero svg { width: 190px; height: 114px; overflow: visible; }
.apz-man { transform-box: fill-box; transform-origin: 50% 100%; }
.apz-man.is-cheer { animation: apz-cheer .55s ease-in-out 3 alternate; }
@keyframes apz-cheer { from { transform: translateY(0); } to { transform: translateY(-9px); } }
.apz-note { margin: 12px auto 14px; max-width: 460px; color: #94a3b8; font-size: 14px; line-height: 1.5; }
.apz-note a { color: #5eead4; font-weight: 700; text-decoration: underline; text-underline-offset: 2px; }
.apz-note a:hover { color: #99f6e4; }
.apz-empty svg { display: block; width: 100%; height: auto; overflow: visible; }
.apz-empty .apz-road { fill: none; stroke: #e7d3a4; stroke-width: 7; stroke-linecap: round; opacity: .85; }
.apz-empty .apz-stop { fill: #0f172a; stroke: #5eead4; stroke-width: 2.5; }
.apz-empty .apz-stop-n { fill: #e2e8f0; font: 800 11px var(--f-sans, sans-serif); text-anchor: middle; }
.apz-empty .apz-waves { fill: none; stroke: #5fb3e0; stroke-width: 2; stroke-linecap: round; opacity: .35; }
.apz-empty .apz-stars { fill: #e2e8f0; opacity: .55; }
.apz-empty .apz-sky > rect { fill: rgba(15, 23, 42, .65); stroke: rgba(250, 204, 21, .55); stroke-width: 10; }
.apz-empty .apz-sky-slots path { fill: none; stroke: rgba(203, 213, 225, .55); stroke-width: 8; stroke-dasharray: 26 20; }
.apz-empty .apz-sky-first { fill: rgba(250, 204, 21, .18); stroke: #facc15; stroke-width: 12; animation: apz-pulse 1.6s ease-in-out infinite alternate; }
.apz-empty .apz-trail { fill: none; stroke: #facc15; stroke-width: 2; stroke-dasharray: 3 6; stroke-linecap: round; opacity: .7; animation: apz-dash 1.2s linear infinite; }
.apz-empty .apz-float { animation: apz-float 1.8s ease-in-out infinite alternate; }
.apz-empty .apz-float .apz-mini { fill: #facc15; stroke: #92400e; stroke-width: 1.2; }
.ap-puzzle-button b { color: #facc15; font-weight: 800; }
/* Phones keep the lesson bar on one row (apa.css hides the certificate button there): the puzzle stays as a small chip. */
@media (max-width: 760px) {
    .apa-route-item .apa-curriculum .ap-curriculum-highlights:has(.ap-puzzle-button) { grid-template-columns: auto auto auto minmax(0, 1fr) !important; }
    .apa-route-item .apa-curriculum .ap-certificate-button.ap-puzzle-button { display: inline-flex !important; gap: 5px; padding: 0 8px; }
    .apa-route-item .apa-curriculum .ap-puzzle-button .ap-action-icon { display: grid !important; order: -1; width: 16px; height: 16px; background: none !important; }
    .apa-route-item .apa-curriculum .ap-puzzle-button .ap-action-main { font-size: 0; }
    .apa-route-item .apa-curriculum .ap-puzzle-button .ap-action-main b { font-size: 12px; }
}
@keyframes apz-pulse { from { fill-opacity: .4; } to { fill-opacity: 1; } }
@keyframes apz-dash { to { stroke-dashoffset: -18; } }
@keyframes apz-float { from { transform: translate(414px, 128px); } to { transform: translate(414px, 120px); } }
.apz-acts { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
@media (max-width: 560px) { .apz-dlg { padding: 18px 14px 14px; } .apz-h { font-size: 20px; } .apz-hero svg { width: 150px; height: 90px; } }
@media (prefers-reduced-motion: reduce) { .apz-gift-at .apz-gift, .apz-gift-at .apz-glow circle, .apz-man.is-cheer, .apz-empty .apz-sky-first, .apz-empty .apz-trail, .apz-empty .apz-float { animation: none; } }
.apa-map .apa-map__gift { position: absolute; z-index: 2; width: 40px; height: 40px; margin: -30px 0 0 -20px; padding: 0; border: 0; background: none; cursor: pointer; transition: transform .15s; }
.apa-map .apa-map__gift:hover { transform: translateY(-2px) scale(1.08); }
.apa-map .apa-map__gift svg { display: block; overflow: visible; }
.apa-map .apa-map__gift.is-got .apz-gift { opacity: .75; }
.apa-map .apa-map__gift:focus-visible { outline: 2px solid #facc15; outline-offset: 2px; border-radius: 8px; }

/* The daily streak as a campfire (APA_Streaks::fire, APA_GOAL.fire): embers with no streak, a bigger flame the longer it runs. */
.apa-fire { display: block; overflow: visible; }
.apa-fire__log { fill: #7c4a24; stroke: #4a2a12; stroke-width: 1; }
.apa-fire__glow { fill: #f97316; opacity: .25; }
.apa-fire__f1 { fill: #f97316; }
.apa-fire__f2 { fill: #fbbf24; }
.apa-fire__f3 { fill: #fef3c7; }
.apa-fire__ember { fill: #ef4444; animation: apa-ember 1.4s ease-in-out infinite alternate; }
.apa-fire__flames { transform-box: fill-box; transform-origin: 50% 100%; animation: apa-flicker .9s ease-in-out infinite alternate; }
.apa-fire.is-0 .apa-fire__flames { display: none; }
.apa-fire.is-0 .apa-fire__glow { opacity: .1; }
.apa-fire.is-1 .apa-fire__flames { transform: scale(.65); }
.apa-fire.is-2 .apa-fire__flames { transform: scale(.8); }
.apa-fire.is-1 .apa-fire__flames { animation-name: apa-flicker-1; }
.apa-fire.is-2 .apa-fire__flames { animation-name: apa-flicker-2; }
.apa-fire.is-3 .apa-fire__glow { opacity: .45; animation: apa-ember 1.2s ease-in-out infinite alternate; }
@keyframes apa-flicker { from { transform: scale(1, 1) skewX(-3deg); } to { transform: scale(.94, 1.08) skewX(3deg); } }
@keyframes apa-flicker-1 { from { transform: scale(.65, .65) skewX(-3deg); } to { transform: scale(.62, .71) skewX(3deg); } }
@keyframes apa-flicker-2 { from { transform: scale(.8, .8) skewX(-3deg); } to { transform: scale(.76, .87) skewX(3deg); } }
@keyframes apa-ember { from { opacity: .45; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .apa-fire__flames, .apa-fire__ember, .apa-fire__glow { animation: none !important; } }

/* The course card for a started learner (templates/momentum.php): streak, today's goal, "Ești aproape". */
.apa-mom { display: grid; gap: 12px; margin: 14px 0 16px; padding: 14px; border-radius: 14px; background: rgba(15, 23, 42, .55); border: 1px solid rgba(255, 255, 255, .08); text-align: left; }
.apa-mom__fire { display: flex; align-items: center; gap: 12px; }
.apa-mom__fire .apa-fire { flex: none; width: 46px; height: 50px; }
.apa-mom__fire strong { display: block; color: #fff; font-size: 15px; }
.apa-mom__fire small { display: block; margin-top: 2px; color: #94a3b8; font-size: 12.5px; line-height: 1.4; }
.apa-mom__label { display: block; margin-bottom: 6px; color: #94a3b8; font: 700 11px/1.3 var(--f-mono, ui-monospace, monospace); letter-spacing: .06em; text-transform: uppercase; }
.apa-mom__chips { display: flex; gap: 6px; flex-wrap: wrap; }
.apa-mom__chips button { padding: 5px 11px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .16); background: transparent; color: #cbd5e1; font: 600 12.5px/1.2 var(--f-sans, inherit); cursor: pointer; }
.apa-mom__chips button[aria-checked="true"] { border-color: #2dd4bf; background: rgba(45, 212, 191, .14); color: #5eead4; }
.apa-mom__bar { display: flex; gap: 5px; margin-top: 9px; }
.apa-mom__bar i { flex: 1; height: 7px; border-radius: 6px; background: rgba(148, 163, 184, .22); }
.apa-mom__bar i.is-done { background: #2dd4bf; }
.apa-mom__bar i.is-bonus.is-done { background: #fbbf24; }
.apa-mom__msg { display: block; margin-top: 6px; color: #94a3b8; font-size: 12.5px; }
.apa-mom.is-met .apa-mom__msg { color: #5eead4; font-weight: 700; }
.apa-mom__near { margin: 0; padding-top: 10px; border-top: 1px solid rgba(255, 255, 255, .07); color: #cbd5e1; font-size: 13px; line-height: 1.5; }
.apa-mom__near > span:first-child { color: #facc15; font-weight: 800; }
.apa-mom__near b { color: #fff; }

/* Under the lesson island: the streak, today's goal and the next reward. */
.lv .lv-mom { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin: -6px 0 16px; padding: 8px 12px; border-radius: 12px; background: rgba(10, 20, 36, .6); border: 1px solid rgba(255, 255, 255, .08); color: #cbd5e1; font-size: 13px; line-height: 1.4; }
.lv .lv-mom b { color: #fff; }
.lv .lv-mom__fire { display: inline-flex; align-items: center; gap: 6px; cursor: help; }
.lv .lv-mom__fire .apa-fire { width: 22px; height: 24px; }
.lv .lv-mom__goal b { color: #5eead4; }
.lv .lv-mom__goal.is-met b { color: #facc15; }
.lv .lv-mom__near { flex: 1 1 260px; color: #94a3b8; }
.lv .lv-mom__near b { color: #e2e8f0; }
@media (max-width: 560px) { .lv .lv-mom { font-size: 12px; padding: 7px 10px; } }

/* Course hero for a learner who started (variant 1): the side card holds the progress and the way on, as tall as the
   title column; the streak, today's goal and the next reward run as one bar across the hero, the four stats in a row under it. */
.apa-course-hero--wide .apa-course-hero__in { grid-template-columns: 1fr 1fr; }
.apa-course-hero__wide { grid-column: 1 / -1; display: grid; gap: 30px; }
.apa-ccard2__prog { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-top: 4px; }
.apa-ccard2__prog .apa-big-pct { line-height: 1; }
.apa-ccard2__prog p { margin: 0; text-align: right; color: #d7e4dc; }
.apa-course-hero--wide .apa-ccard2 .apa-progress { margin: 12px 0 18px; }
.apa-mom--bar { grid-template-columns: 1fr 1.1fr 1.3fr; align-items: center; gap: 0; margin: 0; padding: 16px 0; border-radius: 18px; background: rgba(13, 24, 40, .82); border-color: rgba(148, 163, 184, .16); }
.apa-mom--bar > * { padding: 0 22px; min-width: 0; }
.apa-mom--bar > .apa-mom__goal { border-left: 1px solid rgba(148, 163, 184, .18); border-right: 1px solid rgba(148, 163, 184, .18); }
.apa-mom--bar .apa-mom__near { padding-top: 0; border-top: 0; font-size: 13.5px; }
.apa-mom--bar .apa-mom__chips { flex-wrap: nowrap; }
.apa-mom__chips button { min-width: 40px; text-align: center; }
.apa-mom__bar { gap: 4px; }
.apa-mom--bar .apa-fire { width: 52px; height: 56px; }
.apa-course-hero--wide .apa-stats.apa-stats2 { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; max-width: none; margin-top: 0 !important; }
.apa-course-hero--wide .apa-stats2 li:nth-child(even) { transform: none; }
@media (max-width: 960px) {
    .apa-course-hero--wide .apa-course-hero__in { grid-template-columns: 1fr; }
    .apa-mom--bar { grid-template-columns: 1fr; gap: 14px; padding: 16px; }
    .apa-mom--bar > * { padding: 0; }
    .apa-mom--bar > .apa-mom__goal { border: 0; padding: 14px 0; border-top: 1px solid rgba(148, 163, 184, .14); border-bottom: 1px solid rgba(148, 163, 184, .14); }
    .apa-course-hero--wide .apa-stats.apa-stats2 { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
}
/* The same bar on the dashboard, under the island of the course being worked on. */
.apa-dash-mom { padding: 18px 22px 4px; }
@media (max-width: 960px) { .apa-dash-mom { padding: 14px 12px 0; } }

/* Portal popup (the next module's first island, its free lessons, the offer) and the free preview lessons in the lists. */
.apt-art { display: block; width: 100%; height: auto; margin: 12px 0 0; }
.apt .apz-road { fill: none; stroke: #e7d3a4; stroke-width: 7; stroke-linecap: round; opacity: .85; }
.apt-stop { fill: #475569; stroke: #1e293b; stroke-width: 2; }
.apt-stop.is-free { fill: #2dd4bf; stroke: #0f766e; }
.apt-n { fill: #062a26; font: 800 12px Arial, Helvetica, sans-serif; text-anchor: middle; }
.apt-lock { fill: none; stroke: #cbd5e1; stroke-width: 1.6; stroke-linejoin: round; }
.apt-list { list-style: none; margin: 0 auto 16px; padding: 0; max-width: 460px; text-align: left; display: grid; gap: 6px; }
.apt-list li > * { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .08); background: rgba(255, 255, 255, .03); color: #94a3b8; font-size: 14px; text-decoration: none; }
.apt-list small { flex: none; min-width: 64px; color: #64748b; font-size: 12px; font-weight: 700; }
.apt-list em, .apa-lesson__free { margin-left: auto; padding: 2px 8px; border-radius: 999px; background: rgba(45, 212, 191, .15); color: #5eead4; font: 800 11px Arial, Helvetica, sans-serif; font-style: normal; text-transform: uppercase; letter-spacing: .04em; }
.apt-list .is-free > a { color: #e2e8f0; border-color: rgba(45, 212, 191, .35); }
.apt-list .is-free > a:hover { background: rgba(45, 212, 191, .08); }
.apa-lesson .apa-lesson__free { flex: none; align-self: center; }

/* "Ești aproape": the islands left to the diploma, on their own line after a puzzle piece. */
.apa-near-dip { display: flex; align-items: center; gap: 7px; margin-top: 6px; }
.apa-near-dip svg { flex: none; overflow: visible; }
.apa-near-dip path { fill: #facc15; stroke: #92400e; stroke-width: 1.2; }
.lv-mom__near .apa-near-dip { margin-top: 2px; }
/* Lesson 1 welcome: the learner is away while the banner is open, then jumps in and lights the campfire (apa-map.js). */
.apa-wel-on .lv .lv-man { opacity: 0; }
.lv .lv-fire.is-unlit { opacity: 0; }
.lv .lv-fire.is-lighting { transform-box: fill-box; transform-origin: 50% 100%; animation: lv-light .9s cubic-bezier(.2, 1.5, .4, 1) both; }
@keyframes lv-light { 0% { transform: scale(0); opacity: 0; filter: brightness(2.5); } 40% { opacity: 1; } 100% { transform: scale(1); filter: none; } }
/* Bonus for enrolled learners in the island's prize popup (APA_PUZZLE bonus()): a slim strip under the buttons. */
.apz-bonus { display: flex; align-items: center; gap: 12px; margin: 16px -22px -18px; padding: 12px 22px; border-top: 1px solid rgba(255, 255, 255, .08); background: rgba(94, 234, 212, .05); border-radius: 0 0 20px 20px; text-align: left; text-decoration: none; color: inherit; transition: background .2s; }
.apz-bonus:hover { background: rgba(94, 234, 212, .1); }
.apz-bonus img { width: 40px; height: 40px; flex: none; border-radius: 10px; object-fit: contain; background: rgba(255, 255, 255, .06); padding: 5px; box-sizing: border-box; }
.apz-bonus__txt { flex: 1; min-width: 0; display: grid; gap: 1px; }
.apz-bonus__txt small { font-size: 10.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #5eead4; }
.apz-bonus__txt strong { font-size: 14px; color: #f1f5f9; }
.apz-bonus__txt em { font-style: normal; font-size: 12.5px; line-height: 1.45; color: #94a3b8; }
.apz-bonus__go { flex: none; padding: 7px 12px; border-radius: 999px; border: 1px solid rgba(94, 234, 212, .45); color: #5eead4; font-size: 13px; font-weight: 700; white-space: nowrap; }
.apz-bonus:hover .apz-bonus__go { background: #5eead4; color: #062a26; }
@media (max-width: 560px) { .apz-bonus { margin: 14px -14px -14px; padding: 12px 14px; flex-wrap: wrap; align-items: flex-start; } .apz-bonus__txt { flex: 1 1 calc(100% - 56px); } .apz-bonus__go { margin-left: 52px; } }
