/* Phonics game decks (Zac 2026-11-28): /phonics/, /phonics/year-N/, the book pages' "This week's phonics" panel and
   the home showcase strip. Loaded after site.css (+ worksheets.css on the phonics pages for the shared stats / gate /
   sticker look). Mobile first. The player itself is pptplayer.css; src/js/phonics.js opens it in .ph-dlg. */

.ph-play svg,.ph-ws svg,.ph-sub svg,.ph-hero-note svg{flex:none}

/* ---------- hero ---------- */
.ph-hero{position:relative;padding:22px 0 10px;background:linear-gradient(180deg,var(--leaf-2),rgba(221,240,211,0) 94%);overflow:hidden}
.ph-hero-row{display:grid;gap:14px;align-items:center}
.ph-hero h1{margin-top:8px}
.ph-hero .lede{max-width:34em}
.ph-hero .tag{display:inline-flex;align-items:center;gap:6px}
.ph-tag-fi{width:26px;height:26px;margin:-6px 0}
.ph-hero-btns{display:flex;flex-wrap:wrap;gap:4px 8px}
.ph-hero-note{display:flex;align-items:center;gap:6px;margin:2px 0 0;font-weight:700;font-size:15px;color:#245E21}
.ph-hero-note svg{width:18px;height:18px}
.ph-tv{position:relative;display:block;width:100%;max-width:560px;margin:0 auto;padding:10px;border:3px solid var(--ink);border-radius:22px;background:var(--ink);box-shadow:0 6px 0 rgba(42,36,64,.25);cursor:pointer;-webkit-tap-highlight-color:transparent;transition:transform .15s cubic-bezier(.3,1.5,.6,1)}
.ph-tv img{display:block;width:100%;height:auto;border-radius:12px}
.ph-tv:hover{transform:translateY(-3px) rotate(-.5deg)}
.ph-tv:focus-visible{outline:4px solid var(--sky-deep);outline-offset:4px}
.ph-tv-play{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);display:grid;place-items:center;width:76px;height:76px;border-radius:50%;background:var(--sun);border:3px solid var(--ink);box-shadow:0 4px 0 var(--ink);color:var(--ink)}
.ph-tv-play svg{width:34px;height:34px;margin-left:4px}
@media (max-width:599px){.ph-tv-play{width:58px;height:58px;top:auto;bottom:12%;left:50%;transform:translateX(-50%)}.ph-tv-play svg{width:26px;height:26px}}
/* Free badge (Zac 2026-11-29: the round tilted sticker was hard to read): one flat, high-contrast pill, top-left */
.ph-sticker{right:auto;bottom:auto;left:14px;top:14px;width:auto;height:auto;transform:none;border-radius:999px;display:inline-flex;align-items:center;gap:6px;padding:7px 14px;font:800 17px/1 var(--f-body);background:var(--sun);box-shadow:0 3px 0 var(--ink)}
.ph-sticker small{display:inline;font:inherit;margin:0}
@media (max-width:599px){.ph-sticker{left:10px;top:10px;padding:6px 11px;font-size:15px}}
@media (min-width:860px){
  .ph-hero{padding:34px 0 22px}
  .ph-hero-row{grid-template-columns:minmax(0,1fr) 500px;gap:34px}
  .ph-tv{margin:0}
}

/* ---------- Overview / Year 1 / 2 / 3 switcher ---------- */
.ph-yrs{display:flex;gap:8px;margin:18px calc(-1 * var(--gutter)) 0;padding:4px var(--gutter) 8px;overflow-x:auto;scrollbar-width:none}
.ph-yrs::-webkit-scrollbar{display:none}
.ph-yrs a{flex:none;display:inline-flex;align-items:center;gap:6px;min-height:46px;padding:6px 16px 6px 10px;border-radius:999px;background:var(--card);box-shadow:inset 0 0 0 2px var(--line);font:600 16px/1.1 var(--f-head);color:var(--ink);text-decoration:none}
.ph-yrs a:first-child{padding-left:16px}
.ph-yrs a[aria-current="page"]{background:var(--ink);color:#fff;box-shadow:none}
.ph-yr-fi{width:32px;height:32px}

/* ---------- sections ---------- */
.ph-sec{padding:30px 0 4px;scroll-margin-top:72px}
.ph-sem-h{display:flex;align-items:center;gap:10px;margin:0 0 14px}
.ph-sem-h .count{font:800 14px/1 var(--f-body);background:var(--paper-2);color:var(--ink-2);border-radius:999px;padding:6px 10px}

/* ---------- the 3 year cards ---------- */
.ph-years{list-style:none;margin:0;padding:0;display:grid;gap:14px}
.ph-year a{display:flex;flex-direction:column;gap:10px;height:100%;padding:16px;border-radius:var(--r-l);background:var(--card);box-shadow:var(--shadow);color:var(--ink);text-decoration:none;border-top:8px solid var(--tc);transition:transform .15s,box-shadow .15s}
.ph-year a:hover{transform:translateY(-3px);box-shadow:var(--shadow-lift)}
.ph-year-top{display:flex;align-items:center;gap:12px}
.ph-year-top b{display:block;font:600 24px/1.1 var(--f-head)}
.ph-year-top small{display:block;color:var(--ink-2);font-weight:700;font-size:14px;margin-top:2px}
.ph-year-fi{width:64px;height:64px}
.ph-year-blurb{color:var(--ink-2);line-height:1.45}
.ph-year-chips{display:flex;flex-wrap:wrap;gap:6px}
.ph-year-chips i{font:600 17px/1 var(--f-head);font-style:normal;padding:7px 11px;border-radius:12px;background:var(--tb);color:var(--ink)}
.ph-year-go{margin-top:auto;display:flex;align-items:center;justify-content:space-between;font:600 17px/1 var(--f-head);padding-top:4px}
.ph-year-go svg{width:22px;height:22px}
@media (min-width:860px){.ph-years{grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}}

/* tones: Year 1 leaf, Year 2 sky, Year 3 sun (same as the curriculum levels) */
.ph-leaf{--tc:var(--leaf-mid);--tb:var(--leaf-2)}
.ph-sky{--tc:var(--sky-mid);--tb:var(--sky-2)}
.ph-sun{--tc:var(--sun);--tb:var(--sun-2)}

/* ---------- how a lesson runs ---------- */
.ph-steps{list-style:none;margin:0 calc(-1 * var(--gutter));padding:4px var(--gutter) 12px;display:grid;grid-auto-flow:column;grid-auto-columns:84%;gap:14px;overflow-x:auto;scroll-snap-type:x mandatory;scroll-padding:0 var(--gutter);scrollbar-width:none}
.ph-steps::-webkit-scrollbar{display:none}
.ph-steps li{scroll-snap-align:start;min-width:0;background:var(--card);border-radius:var(--r);box-shadow:var(--shadow);padding:10px 10px 14px}
.ph-steps img{display:block;width:100%;height:auto;border-radius:10px;box-shadow:0 0 0 1px var(--line)}
.ph-steps h3{display:flex;align-items:center;gap:8px;margin:12px 4px 4px;font-size:19px}
.ph-steps h3 i{font-style:normal;flex:none;display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:var(--ink);color:#fff;font:800 14px/1 var(--f-body)}
.ph-steps p{margin:0 4px;color:var(--ink-2);font-size:15px;line-height:1.45}
@media (min-width:700px){.ph-steps{grid-auto-columns:46%}}
@media (min-width:980px){.ph-steps{grid-auto-flow:row;grid-template-columns:repeat(3,minmax(0,1fr));overflow:visible;margin:0;padding:4px 0 10px;gap:18px}}

/* ---------- free sample, inline ---------- */
.ph-try{display:grid;gap:12px}
.ph-try h2{margin:0 0 4px}
.ph-try p{margin:0;color:var(--ink-2)}
.ph-try .sc-pill-free{display:inline-flex;align-items:center;gap:6px}
.ph-try .sc-pill svg{width:14px;height:14px}

/* ---------- worksheets tie-in ---------- */
.ph-ws-tie{display:grid;grid-template-columns:auto minmax(0,1fr);gap:6px 14px;align-items:center;background:var(--card);border-radius:var(--r-l);box-shadow:var(--shadow);padding:16px;margin-top:30px}
.ph-ws-tie h2{font-size:clamp(19px,4.6vw,24px);margin:0 0 2px}
.ph-ws-tie p{margin:0;color:var(--ink-2)}
.ph-ws-tie .btn{grid-column:1/-1;justify-self:start}
.ph-tie-fi{width:60px;height:60px}
@media (min-width:760px){.ph-ws-tie{grid-template-columns:auto minmax(0,1fr) auto;padding:18px 22px}.ph-ws-tie .btn{grid-column:auto}.ph-tie-fi{width:76px;height:76px}}
.ph-cta{margin:30px 0 0}
.ph-gate{margin-top:14px}

/* ---------- year page head ---------- */
.ph-hero-yr{background:linear-gradient(180deg,var(--tb),rgba(255,255,255,0) 94%)}
.ph-crumb{margin:0 0 6px;font-weight:700;font-size:14px;color:var(--ink-2)}
.ph-crumb a{color:var(--ink-2)}
.ph-yr-head{display:flex;align-items:center;gap:14px}
.ph-yr-head h1{margin:0 0 4px}
.ph-yr-head .lede{margin:0}
.ph-yr-big{width:72px;height:72px;flex:none}
.ph-stats{margin-top:14px}
@media (min-width:760px){.ph-yr-big{width:104px;height:104px}}

/* ---------- deck cards ---------- */
.ph-grid{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:minmax(0,1fr);gap:12px}
@media (min-width:600px){.ph-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (min-width:980px){.ph-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}}
.ph-card{display:grid;grid-template-columns:104px minmax(0,1fr);background:var(--card);border-radius:var(--r);box-shadow:var(--shadow);overflow:hidden;scroll-margin-top:84px;min-width:0}
.ph-card:target{box-shadow:0 0 0 4px var(--sky-deep),var(--shadow-lift)}
.ph-pic{position:relative;display:grid;place-items:center;background:var(--tb);padding:10px 8px 34px;min-height:132px}
.ph-pic img{width:100%;height:auto;max-height:96px;object-fit:contain}
.ph-lbl{position:absolute;left:50%;bottom:8px;transform:translateX(-50%);max-width:94%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font:600 22px/1 var(--f-head);color:var(--ink);background:#fff;border:2px solid var(--ink);border-radius:12px;padding:3px 10px 4px;box-shadow:0 2px 0 var(--ink)}
.ph-lbl-long{font-size:15px;padding:5px 8px}
.ph-free{position:absolute;left:6px;top:6px;font:800 11px/1 var(--f-body);letter-spacing:.04em;text-transform:uppercase;background:var(--leaf-mid);color:var(--ink);border:2px solid var(--ink);border-radius:999px;padding:4px 7px}
.ph-body{padding:10px 12px 12px;min-width:0;display:flex;flex-direction:column}
.ph-meta{display:flex;flex-wrap:wrap;gap:4px 6px;margin:0 0 4px}
.ph-meta span{font:800 12px/1 var(--f-body);border-radius:999px;padding:5px 8px}
.ph-wk{background:var(--ink);color:#fff}
.ph-type{background:var(--tb);color:var(--ink)}
.ph-t-R .ph-type{background:#F3E8FF}
.ph-t-T .ph-type{background:#FFE4EC}
.ph-card h3{font-size:18px;line-height:1.2;margin:2px 0 4px;overflow-wrap:anywhere}
.ph-sub{display:flex;flex-wrap:wrap;align-items:center;gap:4px;margin:0 0 8px;font-size:14px;font-weight:700;color:var(--ink-2)}
.ph-sub svg{width:15px;height:15px}
.ph-acts{margin-top:auto;display:flex;flex-wrap:wrap;align-items:center;gap:6px}
.ph-play{min-height:44px;padding:6px 16px;font-size:17px;border-radius:16px;gap:6px;margin:3px 3px 6px}
.ph-play svg{width:18px;height:18px}
.ph-lock{display:inline-grid;place-items:center;margin-left:2px;opacity:.75}
.ph-lock svg{width:15px;height:15px}
.ph-ws{display:inline-flex;align-items:center;gap:5px;max-width:100%;min-height:40px;padding:3px 10px 3px 4px;border-radius:12px;background:var(--paper);box-shadow:inset 0 0 0 2px var(--line);font-weight:800;font-size:13px;color:var(--ink);text-decoration:none}
.ph-ws > span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}
.ph-ws svg{width:15px;height:15px;color:var(--ink-2)}
.ph-ws:hover{box-shadow:inset 0 0 0 2px var(--ink-3)}
.ph-ws-fi{width:30px;height:30px;flex:none}
.ph-ws-locked{color:var(--ink-2)}
html.kl-in .ph-ws.kl-in-only{display:inline-flex!important}
@media (min-width:980px){.ph-card{grid-template-columns:112px minmax(0,1fr)}}

/* ---------- book page panel ---------- */
.ph-week .vcard-head{margin-bottom:12px}
.ph-grid-book{grid-template-columns:minmax(0,1fr)}
@media (min-width:600px){.ph-grid-book{grid-template-columns:repeat(2,minmax(0,1fr))}}
.ph-week-more{margin:12px 0 0}

/* ---------- player dialog (src/js/phonics.js) ---------- */
.ph-dlg{width:min(100vw - 16px,1180px);max-width:none;max-height:calc(100dvh - 16px);padding:0;border:0;border-radius:20px;background:var(--paper);box-shadow:0 20px 60px -10px rgba(20,16,40,.6);overflow:auto;color:var(--ink)}
.ph-dlg::backdrop{background:rgba(26,22,44,.72)}
.ph-dlg-box{padding:8px 10px 12px}
.ph-dlg-head{display:flex;align-items:center;gap:10px;margin:0 0 8px}
.ph-dlg-t{flex:1;min-width:0;font:600 18px/1.2 var(--f-head);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;padding-left:4px}
.ph-dlg-x{flex:none;display:inline-flex;align-items:center;gap:6px;min-height:44px;padding:6px 14px;border-radius:14px;border:2px solid var(--ink);background:#fff;color:var(--ink);font:700 15px/1 var(--f-head);cursor:pointer}
.ph-dlg-x svg{width:18px;height:18px}
.ph-dlg-stage .klp{margin:0}
html.ph-dlg-on{overflow:hidden}
@media (min-width:760px){.ph-dlg-box{padding:12px 16px 16px}}

/* ---------- home showcase strip ---------- */
.ph-home{background:linear-gradient(180deg,var(--leaf-2),var(--paper) 90%)}
.ph-loop{position:relative;display:block;width:100%;max-width:560px;margin:0 auto;aspect-ratio:16/9;padding:0;border:10px solid var(--ink);border-radius:22px;background:var(--ink);box-shadow:0 6px 0 rgba(42,36,64,.25);cursor:pointer;overflow:hidden}
.ph-loop img{position:absolute;inset:0;width:100%;height:100%;border-radius:12px;opacity:0;animation:ph-loop 12s infinite}
.ph-loop img:nth-child(1){animation-delay:0s}
.ph-loop img:nth-child(2){animation-delay:4s}
.ph-loop img:nth-child(3){animation-delay:8s}
@keyframes ph-loop{0%{opacity:0}4%{opacity:1}33%{opacity:1}37%{opacity:0}100%{opacity:0}}
.ph-loop .ph-tv-play{z-index:2}
@media (prefers-reduced-motion:reduce){.ph-loop img{animation:none}.ph-loop img:nth-child(1){opacity:1}}
