/* Marketing Engineer Academy: the shell (header, footer, the section frame, lesson pages, the temporary option switcher)
   Loads after /assets/tokens.css and uses its variables. Home sections bring their own CSS in /assets/home.css. */

:root {
  --hd-h: 64px;
  --gut: 40px;
  --wrap: 1320px;                 /* with the 40 px gutters: a 1240 px column, the width of the home sections */
  --dark: #0E0E0F;
  --sec-y: 120px;                 /* the section frame: space above and below the content of every home section */
  --frame: #EDEDED;               /* the section frame: the hairline between home sections */
}
@media (max-width: 759px) { :root { --hd-h: 56px; --gut: 16px; --sec-y: 72px; } }

html { scroll-padding-top: var(--hd-h); }
body { background: #fff; color: var(--ink); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 200; padding: 10px 14px; border-radius: 6px; background: var(--ink); color: #fff; font-size: 14px; }
.skip:focus { top: 12px; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut); }
.vh { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

/* ---------- brand ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-size: 16px; line-height: 20px; letter-spacing: -.01em; white-space: nowrap; }
.brand .mark { flex: none; width: 28px; height: 28px; }
.brand-n b { font-weight: 500; }
.brand-n span { color: var(--ink-3); font-weight: 500; }

/* ---------- header: the name on the left, two or three links and one button on the right ---------- */
.hd { position: sticky; top: 0; z-index: 90; height: var(--hd-h); background: rgb(255 255 255 / .88); -webkit-backdrop-filter: saturate(1.5) blur(16px); backdrop-filter: saturate(1.5) blur(16px); box-shadow: inset 0 -1px 0 var(--ll-line-2); }
.hd-in { height: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.hd-r { display: flex; align-items: center; gap: 18px; }
.hd-nav { display: flex; gap: 2px; }
.hd-nav a { padding: 8px 12px; border-radius: 999px; color: var(--ink-2); font-size: 15px; line-height: 20px; transition: background-color .2s var(--ease), color .2s var(--ease); }
.hd-nav a:hover { background: var(--inner); color: var(--ink); }
.hd-cta { display: inline-flex; align-items: center; height: 40px; padding: 0 18px; border-radius: 6px; background: var(--ink); color: #fff; font-size: 15px; font-weight: 500; white-space: nowrap; transition: background-color .2s var(--ease); }
.hd-cta:hover { background: #2a2a2a; }
@media (max-width: 899px) { .hd-nav { display: none; } }
@media (max-width: 759px) {
  .hd-in { gap: 8px; }
  .hd .brand { gap: 9px; }
  .hd .brand .mark { width: 26px; height: 26px; }
  .hd .brand-n { display: flex; flex-direction: column; font-size: 14px; line-height: 15px; }
  .hd-cta { height: 36px; padding: 0 14px; font-size: 14px; }
}

/* ---------- footer ---------- */
.ft { position: relative; background: #fff; }
.ft-dots { height: 56px; background: linear-gradient(90deg, #F58E43 0%, #E1B5A8 22%, #CDBDEB 44%, #8DD8F3 70%, #9CE7DD 100%);
  -webkit-mask: radial-gradient(circle, #000 1.7px, transparent 2.2px) 0 0 / 9px 9px, linear-gradient(180deg, transparent 0%, #000 100%);
  -webkit-mask-composite: source-in;
  mask: radial-gradient(circle, #000 1.7px, transparent 2.2px) 0 0 / 9px 9px, linear-gradient(180deg, transparent 0%, #000 100%);
  mask-composite: intersect; }
.ft-in { max-width: var(--wrap); margin: 0 auto; padding: 28px var(--gut) 40px; display: flex; align-items: center; justify-content: space-between; gap: 20px 32px; flex-wrap: wrap; box-shadow: inset 0 1px 0 var(--ll-line-2); }
.ft-nav { display: flex; gap: 28px; color: var(--ink-2); font-size: 15px; }
.ft-nav a:hover { color: var(--ink); }
.ft-credit { color: var(--ink-3); font-size: 14px; transition: color .2s var(--ease); }
.ft-credit:hover { color: var(--ink); text-decoration: underline; text-decoration-color: var(--cta); text-underline-offset: 3px; }
@media (max-width: 759px) {
  .ft-dots { height: 40px; }
  .ft-in { flex-direction: column; align-items: flex-start; gap: 18px; padding: 24px var(--gut) 64px; }
  .ft-nav { gap: 22px; }
}

/* ---------- home sections ---------- */
.sec { position: relative; scroll-margin-top: var(--hd-h); }
.opt[hidden] { display: none !important; }
.sec-ph { margin: 24px var(--gut); min-height: 200px; display: grid; place-items: center; padding: 24px; border: 1px dashed var(--gray); border-radius: 12px; color: var(--ink-3); font-size: 14px; text-align: center;
  background: radial-gradient(circle, #E4E2DD 1px, transparent 1.4px) 0 0 / 12px 12px; }
.sec-ph span { padding: 6px 12px; border-radius: 999px; background: #fff; }

/* The section frame. Every home section after the hero starts with one full-width hairline and keeps the same space above
   and below its content (--sec-y: 120 px on desktop, 72 px on a phone). Each option sets its own padding on its root
   (.opt-<section>-<id>, 96 to 136 px measured on desktop); the frame replaces those values, it never adds to them, so any
   mix of options keeps one rhythm. The hero sets its own height and stays out of the frame. The hairline is dropped next
   to a dark option (academy.js marks those sections data-tone="dark"), where the change of ground is the divider. */
.pg-home main > .sec + .sec { border-top: 1px solid var(--frame); }
.pg-home main > .sec + .sec > .opt { padding-block: var(--sec-y); }
.pg-home main > .sec[data-tone="dark"],
.pg-home main > .sec[data-tone="dark"] + .sec { border-top-color: transparent; }

/* ---------- covers: the image, or a soft gradient with the title when the image is missing ---------- */
.cover { --c1: #FFE0CC; --c2: #EADDF8; position: relative; overflow: hidden; aspect-ratio: 16 / 10; border-radius: 10px; isolation: isolate; container-type: inline-size;
  background: linear-gradient(140deg, var(--c1) 0%, var(--c2) 100%); }
.cover::before { content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(circle, rgb(255 255 255 / .9) 1.4px, transparent 1.9px) 0 0 / 9px 9px;
  -webkit-mask: radial-gradient(70% 90% at 100% 0%, #000 0%, transparent 70%); mask: radial-gradient(70% 90% at 100% 0%, #000 0%, transparent 70%); }
.cover-t { position: absolute; left: 7%; right: 7%; bottom: 8%; color: var(--ink); font-size: max(18px, 7.5cqi); line-height: 1.05; letter-spacing: -.025em; font-weight: 500; text-wrap: balance; }
.cover img { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; object-fit: cover; }
.cover--paid     { --c1: #FFD9BF; --c2: #F1CFC4; }
.cover--social   { --c1: #D3EFFA; --c2: #E5DDF8; }
.cover--creators { --c1: #F5DDD5; --c2: #E3D9F6; }
.cover--search   { --c1: #D3F4EE; --c2: #D5ECF9; }
.cover--ai       { --c1: #E4DAF7; --c2: #FFE3D0; }
/* a captured deck slide (live lessons): the deck's own dark ground while it loads, no dots */
.cover--deck { background: var(--dark); }
.cover--deck::before { content: none; }

/* ---------- lesson pages: shared ---------- */
/* the footer sits at the bottom of the window even when a page is short */
body.pg-lesson { min-height: 100svh; display: flex; flex-direction: column; }
.pg-lesson main { flex: 1; display: flex; flex-direction: column; }
.pg-lesson main > .sec { flex: 1; display: flex; flex-direction: column; }
.pg-lesson main > .sec > .opt { flex: 1; display: flex; flex-direction: column; }
.pg-lesson main > .sec > .opt > * { flex: 1; }

/* the player: as wide as the first screen allows, with the row under it still in view, and never wider than the 1240 px column */
.pg-lesson { --player-w: min(1240px, 100%, max(560px, calc((100svh - var(--hd-h) - 176px) * 16 / 9))); }
.player { position: relative; overflow: hidden; aspect-ratio: 16 / 9; border-radius: 12px; background: var(--dark); }
@media (max-width: 759px) { .player { aspect-ratio: auto; height: min(74svh, 660px); } }   /* the decks lay themselves out for a phone screen */
.player .cover { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; }
.player iframe { position: absolute; inset: 0; z-index: 3; width: 100%; height: 100%; border: 0; background: var(--dark); opacity: 0; transition: opacity .5s var(--ease); }
.player.is-on iframe { opacity: 1; }
.player-note { position: absolute; left: 50%; bottom: 18px; z-index: 2; transform: translateX(-50%); padding: 8px 14px; border-radius: 999px; background: rgb(17 17 17 / .72); color: #fff; font-size: 14px; line-height: 20px; white-space: nowrap; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.player.has-deck .player-note { display: none; }

/* the row under the player: the length on the left, the next live lesson on the right */
.lp-row { width: var(--player-w); margin: 18px auto 0; display: flex; align-items: center; justify-content: space-between; gap: 12px 32px; }
.lp-meta { display: flex; align-items: center; gap: 10px; padding-left: 2px; color: var(--ink-3); font-size: 15px; line-height: 22px; white-space: nowrap; }
.lp-meta span + span::before { content: ""; display: inline-block; width: 3px; height: 3px; margin: 0 10px 4px 0; border-radius: 50%; background: currentColor; opacity: .7; vertical-align: middle; }

/* a lesson as one link on one line: small picture, title, arrow */
.lk { display: flex; align-items: center; gap: 16px; min-width: 0; padding: 6px 14px 6px 6px; border-radius: 10px; color: var(--ink); transition: background-color .2s var(--ease); }
.lk:hover { background: var(--inner); }
.lk-img { flex: none; width: 104px; }
.lk .cover { border-radius: 6px; box-shadow: 0 0 0 1px rgb(17 17 17 / .06); }
.lk-t { min-width: 0; font-size: 17px; line-height: 24px; font-weight: 500; letter-spacing: -.01em; }
.lk .arr { flex: none; margin-left: 4px; color: var(--ink-3); transition: transform .25s var(--ease), color .2s var(--ease); }
.lk:hover .arr { transform: translateX(3px); color: var(--ink); }

/* ---------- live lesson, layout a: the dark stage ---------- */
.la { display: flex; flex-direction: column; justify-content: center; padding: 28px var(--gut) 40px; background:
  radial-gradient(40% 60% at 12% 0%, rgb(255 127 50 / .14), transparent 70%),
  radial-gradient(36% 60% at 92% 100%, rgb(141 216 243 / .12), transparent 70%),
  var(--dark); }
.la-frame { width: var(--player-w); margin-inline: auto; }
.la .player { box-shadow: 0 30px 80px -40px rgb(0 0 0 / .9), 0 0 0 1px rgb(255 255 255 / .07); }
.la .lp-meta { color: rgb(255 255 255 / .52); }
.la .lk { color: #fff; }
.la .lk:hover { background: rgb(255 255 255 / .07); }
.la .lk .cover { box-shadow: 0 0 0 1px rgb(255 255 255 / .14); }
.la .lk .arr { color: rgb(255 255 255 / .52); }
.la .lk:hover .arr { color: #fff; }

/* ---------- live lesson, layout b: the light page, with a halftone shadow under the player ---------- */
.lb { display: flex; flex-direction: column; justify-content: center; padding: 32px var(--gut) 72px; }
.lb-frame { position: relative; isolation: isolate; width: var(--player-w); margin-inline: auto; }
.lb-frame::before { content: ""; position: absolute; inset: 14px -14px -14px 14px; z-index: -1; border-radius: 14px;
  background: radial-gradient(circle, var(--cta) 1.3px, transparent 1.7px) 0 0 / 6px 6px;
  -webkit-mask: linear-gradient(135deg, transparent 35%, #000 100%); mask: linear-gradient(135deg, transparent 35%, #000 100%); opacity: .75; }
.lb .player { box-shadow: 0 0 0 1px var(--ll-line), 0 24px 60px -36px rgb(17 17 17 / .45); }
.lb .lp-row { margin-top: 30px; }

@media (max-width: 759px) {
  .la { padding: 16px var(--gut) 28px; }
  .lb { padding: 16px var(--gut) 48px; }
  .lb-frame::before { inset: 8px -8px -8px 8px; }
  .lb .lp-row { margin-top: 22px; }
  .lp-row { flex-direction: column; align-items: stretch; gap: 10px; margin-top: 14px; }
  .lp-meta { font-size: 14px; }
  .lp-row .lk-t { flex: 1; }
  .lk { padding-right: 10px; }
  .lk-img { width: 88px; }
  .lk-t { font-size: 16px; line-height: 22px; }
  .player-note { font-size: 13px; bottom: 12px; }
}

/* ---------- coming-soon lesson: the cover with a "Coming soon" pill, the title, the line and the live lessons ---------- */
.soon { flex: 1; display: grid; align-content: center; padding: 56px var(--gut) 88px; }
.soon-in { width: 100%; max-width: 1240px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 40px 72px; align-items: center; }
.soon-cover { position: relative; }
.soon-cover .cover { border-radius: 12px; box-shadow: 0 0 0 1px var(--ll-line); }
/* the same pill as the "Available now" tag on the home tiles, with a hollow dot */
.soon-tag { position: absolute; top: 18px; left: 18px; z-index: 2; display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px 6px 10px; border-radius: 999px;
  background: #fff; color: var(--ink); font-size: 13px; line-height: 17px; font-weight: 500; white-space: nowrap; box-shadow: 0 6px 18px -10px rgb(17 17 17 / .45), 0 0 0 1px rgb(17 17 17 / .04); }
.soon-tag::before { content: ""; flex: none; width: 7px; height: 7px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--ink-3); }
.soon-text h1 { font-size: 44px; line-height: 48px; letter-spacing: -.025em; }
.soon-line { max-width: 460px; margin-top: 16px; color: var(--ink-2); font-size: 20px; line-height: 30px; text-wrap: pretty; }
.soon-ready { list-style: none; margin: 40px 0 0; padding: 14px 0 0; display: grid; gap: 2px; border-top: 1px solid var(--ll-line-2); }
.soon-ready li { margin-inline: -6px; }
.soon-ready .lk-t { flex: 1; }
@media (max-width: 899px) {
  .soon-in { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 759px) {
  .soon { padding: 16px var(--gut) 56px; }
  .soon-in { gap: 28px; }
  .soon-text h1 { font-size: 34px; line-height: 38px; }
  .soon-line { margin-top: 12px; font-size: 17px; line-height: 26px; }
  .soon-tag { top: 12px; left: 12px; padding: 5px 10px 5px 9px; font-size: 12.5px; line-height: 16px; }
  .soon-ready { margin-top: 28px; padding-top: 12px; }
}

/* ---------- the option switcher and the picks chip: temporary scaffolding, delete this block when the owner has chosen ---------- */
.sec-switch { position: relative; z-index: 5; height: 44px; display: flex; align-items: center; justify-content: center; padding: 0 10px; background: #F6F6F6; box-shadow: inset 0 -1px 0 #E4E4E4, inset 0 1px 0 #E4E4E4; }
.pg-home main > .sec + .sec > .sec-switch { box-shadow: inset 0 -1px 0 #E4E4E4; }      /* the frame hairline is its top edge */
.sw { display: inline-flex; align-items: center; gap: 2px; max-width: 100%; height: 32px; padding: 0 3px; border-radius: 999px; border: 1px dashed #B9B9B9; background: #fff; color: #3d3d3d; font: 500 12px/16px var(--font-mono); }
.sw-b { flex: none; display: grid; place-items: center; width: 26px; height: 26px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: inherit; cursor: pointer; }
.sw-b:hover:not(:disabled) { background: #ececec; }
.sw-b:disabled { opacity: .35; cursor: default; }
.sw-t { display: inline-flex; gap: 6px; min-width: 0; padding: 0 4px; white-space: nowrap; overflow: hidden; }
.sw-t b { font-weight: 700; }
.sw-l { overflow: hidden; text-overflow: ellipsis; color: #6b6b6b; }
.sw-l:not(:empty)::before { content: "· "; }
.sec.is-flash .sw { border-color: var(--cta); }

.picks { position: fixed; left: 16px; bottom: 16px; z-index: 95; max-width: calc(100vw - 32px); border-radius: 14px; border: 1px dashed #B9B9B9; background: rgb(250 250 250 / .96); color: #3d3d3d; font: 500 12px/16px var(--font-mono); box-shadow: 0 10px 28px -14px rgb(0 0 0 / .4); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.picks-row { display: flex; align-items: center; gap: 4px; padding: 4px; }
.picks button { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border: 0; border-radius: 999px; background: transparent; color: inherit; font: inherit; cursor: pointer; white-space: nowrap; }
.picks button:hover { background: #e9e9e9; }
.picks-toggle svg { display: none; }
.picks-toggle b { font-weight: 700; }
.picks-sum { padding: 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #6b6b6b; }
.picks-copy { background: var(--ink) !important; color: #fff !important; }
.picks-copy.is-done { background: var(--cta) !important; }
.picks-list { margin: 0; padding: 6px 14px 12px; list-style: none; border-top: 1px dashed #d4d4d4; }
.picks-list li { display: flex; gap: 10px; padding: 3px 0; }
.picks-list li span:first-child { min-width: 112px; color: #6b6b6b; }
/* below 768 px the chip folds into a 36 px round button that opens the full list */
@media (max-width: 767px) {
  .picks { left: 10px; bottom: 10px; }
  .picks-sum { display: none; }
  .picks:not(.is-open) { border-radius: 50%; }
  .picks:not(.is-open) .picks-row { padding: 3px; }
  .picks:not(.is-open) .picks-toggle { width: 28px; padding: 0; justify-content: center; }
  .picks:not(.is-open) .picks-toggle b, .picks:not(.is-open) .picks-copy { display: none; }
  .picks-toggle svg { display: block; }
  .picks.is-open .picks-toggle svg { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* Ryze logo and "by Ryze AI" under the academy name */
.brand .brand-logo { flex: none; width: 28px; height: 28px; object-fit: contain; display: block; }
.brand-n { display: inline-flex; flex-direction: column; justify-content: center; }
.brand-t { white-space: nowrap; }
.brand-by { display: block; margin-top: 2px; font-size: 12px; line-height: 14px; font-weight: 500; color: var(--ink-3); letter-spacing: 0; }
@media (max-width: 759px) {
  .hd .brand .brand-logo { width: 26px; height: 26px; }
  .hd .brand-n .brand-t { display: block; white-space: normal; font-size: 14px; line-height: 16px; }
  .brand-by { font-size: 11px; line-height: 13px; margin-top: 1px; }
}
