/* ---------- home: "Learn Loopster in one afternoon" (tools/learn_markup.py). Nick, 2026-10-24: a dark band, edge to edge,
   after the feature cards; the heading on the left, then one line of two tutorials and a YouTube-style playlist card.
   The night sky and grain are the home hero's ---------- */
.learn{position:relative;isolation:isolate;background:var(--night);color:#fff;overflow:clip}
.learn-sky{position:absolute;inset:0;z-index:-1;pointer-events:none}
.learn-sky i{position:absolute;inset:0;background-size:256px 256px;opacity:.1}
.learn-sky .g1{background-image:url(/https/loopster.ai/assets/site/grain-dark.avif);mix-blend-mode:difference}
.learn-sky .g2{background-image:url(/https/loopster.ai/assets/site/grain-light.avif);mix-blend-mode:plus-lighter}
/* Nick's riso bust in a galaxy behind the heading (2026-10-24): the band's height, nudged left, fading out towards the
   videos; darkened along the bottom and the left edge so the heading and titles read */
.learn-art{position:absolute;left:0;top:0;height:100%;width:auto;max-width:none;opacity:.9;transform:translateX(-12%);-webkit-mask-image:linear-gradient(90deg,#000 45%,transparent 92%);mask-image:linear-gradient(90deg,#000 45%,transparent 92%)}
.learn-sky::after{content:"";position:absolute;inset:0;background:linear-gradient(0deg,rgba(20,20,20,.85),rgba(20,20,20,.15) 60%),linear-gradient(90deg,rgba(20,20,20,.35),transparent 40%)}
.learn-head h2,.learn-head p{text-shadow:0 2px 18px rgba(0,0,0,.65)}
.learn-in{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,2.1fr);gap:clamp(28px,4vw,56px);align-items:center;width:min(var(--grid-body),calc(100% - var(--gut) * 2));margin:0 auto;padding:clamp(84px,8vw,124px) 0 clamp(80px,8vw,120px)}

.learn-head{display:flex;flex-direction:column;align-items:flex-start;gap:14px}
/* the pixel badge of the Loopgents hero, in Loopster magenta on the night */
.learn-badge{--cc:#FF4FD8;display:inline-flex;align-items:center;gap:9px;height:32px;padding:0 13px 0 10px;border-radius:7px;background:color-mix(in srgb,var(--cc) 14%,rgba(20,18,26,.55));box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--cc) 48%,transparent);color:#fff;font:400 13px/1 var(--pixel);letter-spacing:.04em;text-transform:uppercase}
.learn-badge svg{width:16px;height:16px;flex:none;color:var(--cc)}
.learn-head h2{margin:0;font:500 var(--h2)/1.08 var(--sans);letter-spacing:-.02em;text-wrap:balance}
.learn-head p{margin:0;font:450 clamp(15.5px,1.2vw,18px)/1.5 var(--sans);color:rgba(255,255,255,.72);text-wrap:pretty}

.learn-row{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px;margin:0;padding:0;list-style:none}
.lc{display:flex;flex-direction:column;gap:12px;color:#fff;text-decoration:none;outline:none}
.lc-thumb{position:relative;display:block;aspect-ratio:16/9;border-radius:10px;overflow:hidden;background:#222;box-shadow:0 0 0 1px rgba(255,255,255,.08),0 18px 36px -22px rgba(0,0,0,.9);transition:transform .3s cubic-bezier(.2,.7,.2,1)}
.lc-thumb img{display:block;width:100%;height:100%;object-fit:cover}
.lc-len{position:absolute;right:8px;bottom:8px;padding:3px 6px;border-radius:5px;background:rgba(10,10,10,.82);font:500 12px/1 var(--sans);color:#fff}
.lc-play{position:absolute;left:50%;top:50%;display:grid;place-items:center;width:48px;height:48px;border-radius:50%;background:rgba(255,255,255,.94);color:var(--brand);transform:translate(-50%,-50%) scale(.85);opacity:0;transition:opacity .25s,transform .25s}
.lc-play svg{width:14px;height:14px;margin-left:3px}
.lc:hover .lc-thumb,.lc:focus-visible .lc-thumb{transform:translateY(-4px)}
.lc:hover .lc-play,.lc:focus-visible .lc-play{opacity:1;transform:translate(-50%,-50%) scale(1)}
.lc:focus-visible .lc-thumb{box-shadow:0 0 0 2px #fff}
.lc-meta{display:flex;gap:10px;align-items:baseline}
.lc-n{flex:none;font:400 12px/1 var(--pixel);color:rgba(255,255,255,.5)}
.lc-t{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;font:500 15px/1.35 var(--sans);color:rgba(255,255,255,.92);text-wrap:balance}   /* the short titles: no word alone on the second line on phones */

/* the playlist card: YouTube's playlist thumbnail (a mosaic of the next tutorials, the count on a dark panel), "Play all" on hover */
.lp-mosaic{position:absolute;inset:0;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr;gap:2px;background:#111}
.lp-m{overflow:hidden}
.lp-m img{width:100%;height:100%;object-fit:cover}
.lp-side{position:absolute;top:0;right:0;bottom:0;width:38%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;background:rgba(12,12,14,.86);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px)}
.lp-side b{font:600 28px/1 var(--sans)}
.lp-side span{font:500 13px/1 var(--sans);color:rgba(255,255,255,.75)}
.lp-ic{width:20px;height:20px;margin-bottom:4px;color:#FF4FD8}
.lp-hover{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;gap:8px;background:rgba(10,10,10,.72);font:600 16px/1 var(--sans);opacity:0;transition:opacity .25s}
.lp-hover svg{width:13px;height:13px;color:var(--brand)}
.lc-pl:hover .lp-hover,.lc-pl:focus-visible .lp-hover{opacity:1}
.lc-pl .lc-t{color:#fff}

@media (prefers-reduced-motion:reduce){.lc-thumb,.lc-play,.lp-hover{transition:none}}
/* desktop: the band's content sits in the 1080 body column (--grid-body). There a 46px heading and three cards didn't
   both fit (the heading went to three lines, the 90-second tour's title lost its end to the two-line clamp): the heading
   is the site's --h2 (36px at most), the gap narrows and the row gets the room, the titles take the phones' 14.5px and
   split evenly.
   The clamp allows a third line: the 6-minute tutorial's title needs it at every desktop width (the row stays shorter
   than the heading, so the band keeps its height) */
@media (min-width:1024px){
  .learn-in{grid-template-columns:minmax(0,.86fr) minmax(0,2.14fr);gap:clamp(28px,3vw,44px)}
  .lc-t{-webkit-line-clamp:3;font-size:14.5px;text-wrap:balance}
}
/* tablets: the heading above the row */
@media (max-width:1023px){.learn-in{grid-template-columns:minmax(0,1fr)}.learn-head p{max-width:34em}.learn-art{opacity:.6}}   /* the bust sits behind the heading here: quieter */
/* phones: the heading centred, then one line you swipe, the playlist card last */
@media (max-width:720px){
  .learn-art{width:100%;height:auto;transform:none;-webkit-mask-image:linear-gradient(180deg,#000 40%,transparent 95%);mask-image:linear-gradient(180deg,#000 40%,transparent 95%)}
  .learn-head{align-items:center;text-align:center}
  .learn-row{display:flex;gap:14px;margin:0 calc(-1 * var(--gut));padding:6px var(--gut) 10px;overflow-x:auto;overscroll-behavior-x:contain;scroll-snap-type:x mandatory;scroll-padding-inline:var(--gut);scrollbar-width:none}
  .learn-row::-webkit-scrollbar{display:none}
  .learn-row>li{flex:0 0 78%;scroll-snap-align:start}
  .lc-t{font-size:14.5px}
}
