/* ═══ SELFEARN — questly layout, at night ═══
   One gradient card on a black page. The nav is a notch cut out of the card in the page colour.
   Unbounded 800 for the headline and wordmark, Inter for everything else. */
:root{
  --bg:#0b0b0b; --ink:#15110e; --paper:#fff; --mute:#8b8880; --line:rgba(255,255,255,.1);
  --g1:#2e2e2e; --g2:#161616; --g3:#060606;
  --disp:Unbounded,"Arial Black",system-ui,sans-serif; --ui:Inter,system-ui,sans-serif;
  --out:cubic-bezier(.16,1,.3,1); --spring:cubic-bezier(.34,1.56,.64,1);
  color-scheme:dark;
}
*{box-sizing:border-box;margin:0;padding:0}
html{-webkit-text-size-adjust:100%;overflow-x:clip}
body{background:var(--bg);color:#fff;font:400 15px/1.5 var(--ui);-webkit-font-smoothing:antialiased}
::selection{background:#fff;color:var(--ink)}
a{color:inherit;text-decoration:none}
button,input{font:inherit;color:inherit}
svg{display:block}

/* ══ HERO CARD ══ */
.hero{padding:14px 15px 0}
.card{
  position:relative;height:calc(100svh - 28px);min-height:680px;border-radius:30px;overflow:hidden;isolation:isolate;
  background:linear-gradient(180deg,var(--g1) 0%,var(--g2) 55%,var(--g3) 100%);
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.07);
  transform-origin:50% 0;animation:cardIn 1.2s cubic-bezier(.16,1,.3,1) both;
}
@keyframes cardIn{from{transform:scale(.965);opacity:0;border-radius:60px}to{transform:none;opacity:1}}
.card::before{
  content:"";position:absolute;inset:0;z-index:0;pointer-events:none;
  background:radial-gradient(90% 60% at 50% 0%,rgba(255,255,255,.16),transparent 60%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* notch nav */
.notch{position:absolute;z-index:30;top:0;left:50%;transform:translateX(-50%);display:flex;align-items:flex-start}
.nc{width:120px;height:88px;flex:none;fill:var(--bg)}
.nc.l{margin-right:-1px}.nc.r{margin-left:-1px}
.nav{height:88px;display:flex;align-items:center;gap:22px;padding:0 6px 8px;background:var(--bg)}
.logo{display:flex;align-items:center;gap:8px;font:800 19px/1 var(--disp);letter-spacing:-.02em;color:#fff;white-space:nowrap}
.lm{width:28px;height:28px;border-radius:8px;display:grid;place-items:center;background:linear-gradient(180deg,#2e2e2e,#050505);box-shadow:inset 0 0 0 1px rgba(255,255,255,.12);color:#fff}
.lm svg{width:20px;height:20px}
.sep{width:1px;height:38px;background:var(--line)}
.nl{font:500 17px/1 var(--ui);color:#d9d6ce;transition:color .2s}
.nl:hover{color:#fff}
.pill-w{display:inline-flex;align-items:center;height:62px;padding:0 32px;border-radius:999px;background:#fff;color:var(--ink);font:600 16px/1 var(--ui);white-space:nowrap;transition:transform .35s var(--spring)}
.pill-w:hover{transform:scale(1.03)}
.circ{width:45px;height:45px;border-radius:50%;background:#1d1c1a;display:grid;place-items:center;margin-left:-8px;transition:background .2s}
.circ:hover{background:#2a2927}
.circ svg{width:16px;height:16px}

/* the scene */
.scene{position:absolute;inset:0;z-index:5}
#gl{position:absolute;inset:0;width:100%;height:100%;display:block;opacity:0;transition:opacity 1.2s ease .2s}
.gl-on #gl{opacity:1}
.ground{display:none;position:absolute;left:30%;right:8%;top:69%;height:2px;border-radius:2px;background:rgba(21,17,14,.35);transform:rotate(3deg);transform-origin:left}
.ground::after{content:"";position:absolute;left:12%;right:-6%;top:-40px;height:1px;background:rgba(21,17,14,.22);transform:rotate(-2deg)}
.me{position:absolute;left:50%;top:47%;width:min(30vw,44vh);aspect-ratio:1;transform:translate(-50%,-50%);filter:drop-shadow(0 30px 40px rgba(21,17,14,.35)) drop-shadow(0 4px 0 rgba(21,17,14,.25))}
.me svg{width:100%;height:100%;animation:bob 5s ease-in-out infinite}
@keyframes bob{50%{transform:translateY(-10px)}}

.tk{position:absolute;display:flex;align-items:center;gap:12px;padding:10px 22px 10px 10px;border-radius:999px;background:#fff;color:var(--ink);box-shadow:0 18px 40px -16px rgba(21,17,14,.45),0 2px 0 rgba(21,17,14,.12);white-space:nowrap;will-change:transform;opacity:0}
.tk i{width:44px;height:44px;border-radius:50%;background:var(--ic);display:grid;place-items:center;flex:none}
.tk i svg{width:22px;height:22px;fill:none;stroke:var(--ink);stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.tk span{font:600 16px/1.1 var(--ui)}
.tk small{display:block;font:500 12px/1 var(--ui);color:#7a756d;margin-top:4px}
.tk.dark{background:var(--ink);color:#fff}
.tk.dark i svg{stroke:#fff}
.tk.dark small{color:#a39e95}
.t1{left:20%;top:22%;--r:-8deg}
.t2{left:63%;top:17%;--r:6deg}
.t3{left:69%;top:41%;--r:-5deg}
.t4{left:16%;top:44%;--r:7deg}
.t5{left:61%;top:60%;--r:-4deg}
.t6{left:31%;top:63%;--r:5deg}
.streak{position:absolute;left:78%;top:24%;width:170px;padding:14px;border-radius:20px;background:#fff;color:var(--ink);box-shadow:0 18px 40px -16px rgba(21,17,14,.45);--r:8deg;will-change:transform;opacity:0}
.streak b{font:800 18px/1 var(--disp)}
.ticks{display:flex;gap:4px;margin:10px 0 8px}
.ticks i{flex:1;aspect-ratio:1;border-radius:5px;border:1.5px solid var(--ink);background:#8fe3b0 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M2 5.2 4.2 7.4 8 2.8' fill='none' stroke='%2315110e' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/80% no-repeat}
.ticks i.x{background:#fff}
.streak small{font:600 12px/1 var(--ui);color:#2f7d4b}

/* headline */
.h1{position:absolute;z-index:20;left:42px;bottom:28px;font:800 clamp(46px,5.2vw,82px)/.86 var(--disp);letter-spacing:-.01em;color:#fff;pointer-events:none}
.h1 .dk{color:#6f6f6f}
/* questly's SplitText line reveal: lines rise 150% and fold up from rotateX(-90) */
.h1{perspective:600px}
.ln{display:block;padding-bottom:.02em}
.ln>span{display:inline-block;transform-origin:50% 100%;transform:translateY(150%) rotateX(-90deg);opacity:0;transition:transform 1s cubic-bezier(.165,.84,.44,1),opacity 1s cubic-bezier(.165,.84,.44,1);transition-delay:.35s}
.ready .ln>span{transform:none;opacity:1}
.ready .ln:nth-child(2)>span{transition-delay:.55s}
.notch{animation:notchIn .9s cubic-bezier(.16,1,.3,1) .15s both}
@keyframes notchIn{from{transform:translate(-50%,-100%)}to{transform:translate(-50%,0)}}
.join{animation:popIn .9s cubic-bezier(.34,1.56,.64,1) .7s both}
@keyframes popIn{from{opacity:0;transform:translateY(30px) scale(.94)}to{opacity:1;transform:none}}

/* waitlist, where questly has its store buttons */
.join{position:absolute;z-index:20;right:18px;bottom:18px;width:min(600px,46%)}
.tag{font:500 15px/1.45 var(--ui);color:rgba(255,255,255,.92);max-width:430px;margin:0 0 14px 22px;text-wrap:balance}
.wl-row{display:flex;align-items:center;gap:8px;height:120px;padding:0 14px 0 34px;border-radius:999px;background:#fff;color:var(--ink);box-shadow:0 24px 50px -20px rgba(21,17,14,.5);transition:transform .35s var(--spring)}
.wl-row:focus-within{transform:scale(1.01)}
.wl-row input[type=email]{flex:1;min-width:0;border:0;background:none;outline:none;font:600 20px/1 var(--ui);color:var(--ink)}
.wl-row input::placeholder{color:#a8a299}
.wl-hp{position:absolute;left:-9999px;width:1px;height:1px;opacity:0}
.pill-b{height:92px;padding:0 34px;border:0;border-radius:999px;background:var(--ink);color:#fff;font:600 17px/1 var(--ui);cursor:pointer;white-space:nowrap;transition:transform .35s var(--spring),background .2s}
.pill-b:hover{background:#2a2622}
.pill-b:active{transform:scale(.97)}
.pill-b:disabled{opacity:.7;cursor:wait}
.wl-msg{font:600 14px/1.45 var(--ui);color:#fff;margin:0 22px}
.wl-msg:not(:empty){margin-top:12px}
.wl-msg.err{color:#ffe1e1}
.wl-fine{margin:10px 22px 0;font:400 12px/1.5 var(--ui);color:rgba(255,255,255,.75)}
.wl-fine a{color:#fff;text-decoration:underline;text-underline-offset:2px}
.wl.done .wl-row{display:none}
.wl.done .wl-msg{margin:0;padding:26px 34px;border-radius:40px;background:#fff;color:var(--ink);font-size:16px}

/* ══ FOOTER (questly: chips, links, legal, big wordmark) ══ */
.foot{display:grid;grid-template-columns:auto 1fr auto;grid-template-areas:"chips mid logo" "chips copy logo";gap:10px 40px;align-items:end;padding:36px 32px max(32px,env(safe-area-inset-bottom))}
.foot .chips{grid-area:chips;display:flex;flex-wrap:wrap;gap:8px;align-self:end}
.foot .chips a{height:34px;padding:0 15px;display:inline-flex;align-items:center;border-radius:999px;background:#1d1c1a;font:600 13px/1 var(--ui);color:#e4e1d9;transition:background .2s}
.foot .chips a:hover{background:#2a2927}
.fmid{grid-area:mid;display:flex;gap:22px;font:600 13.5px/1 var(--ui);color:#d9d6ce}
.fmid a:hover{color:#fff}
.fcopy{grid-area:copy;font:400 12px/1.5 var(--ui);color:var(--mute)}
.logo.big{grid-area:logo;font-size:26px}
.logo.big .lm{width:36px;height:36px;border-radius:10px}
.logo.big .lm svg{width:26px;height:26px}

/* ══ responsive ══ */
@media (max-width:1180px){
  .nl{display:none}
  .join{width:min(560px,52%)}
  .wl-row{height:100px}.pill-b{height:76px}
}
@media (max-width:860px){
  .hero{padding:8px 8px 0}
  .card{height:auto;min-height:calc(100svh - 16px);border-radius:24px;display:flex;flex-direction:column;justify-content:flex-end;padding:0 14px 14px}
  .nc{width:56px;height:70px}
  .nav{height:70px;gap:10px;padding:0 4px 6px;border-radius:0 0 24px 24px}
  .sep{display:none}
  .logo{font-size:15px}.lm{width:24px;height:24px}.lm svg{width:17px;height:17px}
  .pill-w{height:44px;padding:0 18px;font-size:14px}
  .circ{width:40px;height:40px;margin-left:0}
  .scene{position:relative;inset:auto;height:50svh;min-height:340px;margin:70px -14px 0}
  .me{width:min(52vw,34svh);top:50%}
  .tk{padding:7px 14px 7px 7px;gap:8px}
  .tk i{width:32px;height:32px}.tk i svg{width:17px;height:17px}
  .tk span{font-size:13px}.tk small{font-size:10.5px}
  .t1{left:4%;top:8%}.t2{left:52%;top:4%}.t3{left:56%;top:60%}.t4{left:2%;top:40%}.t5{display:none}.t6{left:8%;top:76%}
  .streak{left:60%;top:24%;width:132px;padding:10px}
  .ground{top:80%;left:10%;right:10%}
  .h1{position:relative;left:auto;bottom:auto;font-size:clamp(38px,12vw,64px);margin:0 4px 18px}
  .join{position:relative;right:auto;bottom:auto;width:100%}
  .tag{margin:0 4px 14px;font-size:14px}
  .wl-row{height:auto;flex-direction:column;align-items:stretch;padding:8px;border-radius:28px}
  .wl-row input[type=email]{height:56px;padding:0 16px;text-align:center;font-size:17px}
  .pill-b{height:60px}
  .wl-fine,.wl-msg{margin-left:4px;margin-right:4px}
  .foot{grid-template-columns:1fr;grid-template-areas:"logo" "chips" "mid" "copy";padding:28px 18px;gap:16px}
}
@media (max-width:420px){.pill-w{display:none}}
@media (prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}.ln>span{transform:none}.tk,.streak{opacity:1}}

/* ══ reward tags + earned counter (hero3d.js) ══ */
.tags{position:absolute;inset:0;pointer-events:none;z-index:6}
.ptag{position:absolute;transform:translate(-50%,-100%);display:flex;flex-direction:column;align-items:center;gap:3px;padding:9px 14px;border-radius:16px;background:#fff;color:var(--ink);box-shadow:0 16px 36px -14px rgba(0,0,0,.7);white-space:nowrap;animation:tagUp 1.7s cubic-bezier(.16,1,.3,1) forwards}
.ptag b{font:800 14px/1 var(--disp);letter-spacing:-.01em}
.ptag span{font:600 11px/1 var(--ui);color:#7a756d}
@keyframes tagUp{0%{opacity:0;transform:translate(-50%,-60%) scale(.7)}14%{opacity:1;transform:translate(-50%,-100%) scale(1.04)}22%{transform:translate(-50%,-100%) scale(1)}75%{opacity:1}100%{opacity:0;transform:translate(-50%,-190%) scale(.96)}}
.hud{position:absolute;z-index:7;left:42px;top:130px;display:flex;flex-direction:column;gap:6px;padding:16px 20px 14px;border-radius:22px;background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.1);backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px);pointer-events:none;opacity:0;animation:popIn .9s cubic-bezier(.34,1.56,.64,1) 1.4s both}
.hud-l{font:600 11px/1 var(--ui);letter-spacing:.12em;text-transform:uppercase;color:#9a9a96}
.hud-l b{color:#fff;font-weight:700}
.hud-n{font:800 30px/1 var(--disp);color:#fff;letter-spacing:-.02em;font-variant-numeric:tabular-nums}
.hud-n b{font-weight:800}
.hud-s{font:500 12px/1 var(--ui);color:#9a9a96}
@media (max-width:860px){.hud{left:10px;top:12px;padding:10px 13px;border-radius:16px}.hud-n{font-size:19px}.hud-s{display:none}.ptag{padding:7px 11px}.ptag b{font-size:12px}}
