:root{color-scheme:light;box-sizing:border-box;padding-top:env(safe-area-inset-top,0px);padding-bottom:env(safe-area-inset-bottom,0px)}html{scroll-padding-top:env(safe-area-inset-top,0px)}body{margin:0;padding:0;font:14px -apple-system,BlinkMacSystemFont,sans-serif;background:#fff;color:#000}img{max-width:100%}[hidden]:not([hidden=until-found i]){display:none!important}

/* Med Recall — ported from mockup v30. Colours locked by the user: lavender 273°, Light tone 51, Night tone 60. */
:root{
  --bg:#f8f4fb; --surface:#ffffff; --ink:#2f203c; --mute:#81708f; --line:#e6ddee;
  --lamp:#8d51bd; --lamp-ink:#ffffff; --lamp-soft:#f3e9fb; --cov:#eee5f5;
  --again:#c4587a; --again-soft:#fbe7ee; --hard:#a9801c; --hard-soft:#fbf1d9; --good:#4f8f69; --good-soft:#e5f3ea;
  --s-gyn:#a24f92; --s-gyn-soft:#f8e5f3; --s-psy:#3f7fb5; --s-psy-soft:#e2eef9; --s-sur:#3f8a66; --s-sur-soft:#e0f1e7; --s-def:#8d51bd; --s-def-soft:#f3e9fb;
  --bar-good:#83b498; --bar-hard:#dfbf70; --bar-again:#d991a9; --bar-track:#e9e0ee;
  --display:-apple-system,BlinkMacSystemFont,system-ui,"Segoe UI","Noto Sans Thai",sans-serif; --body:-apple-system,BlinkMacSystemFont,system-ui,"Segoe UI","Noto Sans Thai",sans-serif;
}
@media (prefers-color-scheme: dark){:root:not([data-theme="light"]){
  --bg:#1f1924; --surface:#2f2636; --ink:#fbf9fd; --mute:#b8afc0; --line:#483d52;
  --lamp:#d2aaf3; --lamp-ink:#1f1924; --lamp-soft:rgba(210,170,243,.22); --cov:rgba(210,170,243,.13);
  --again:#ec93ae; --again-soft:rgba(236,147,174,.2); --hard:#e8c46a; --hard-soft:rgba(232,196,106,.18); --good:#8cc7a1; --good-soft:rgba(140,199,161,.18);
  --bar-track:#40364c; --subj-ink:#ffffff;
  --s-gyn:#9d5a91; --s-gyn-soft:rgba(214,150,200,.18); --s-psy:#4f7fa8; --s-psy-soft:rgba(140,190,235,.18); --s-sur:#4a8466; --s-sur-soft:rgba(140,210,170,.16); --s-def:#8660b5; --s-def-soft:rgba(200,160,240,.18);
  color-scheme:dark}}
:root[data-theme="dark"]{
  --bg:#1f1924; --surface:#2f2636; --ink:#fbf9fd; --mute:#b8afc0; --line:#483d52;
  --lamp:#d2aaf3; --lamp-ink:#1f1924; --lamp-soft:rgba(210,170,243,.22); --cov:rgba(210,170,243,.13);
  --again:#ec93ae; --again-soft:rgba(236,147,174,.2); --hard:#e8c46a; --hard-soft:rgba(232,196,106,.18); --good:#8cc7a1; --good-soft:rgba(140,199,161,.18);
  --bar-track:#40364c; --subj-ink:#ffffff;
  --s-gyn:#9d5a91; --s-gyn-soft:rgba(214,150,200,.18); --s-psy:#4f7fa8; --s-psy-soft:rgba(140,190,235,.18); --s-sur:#4a8466; --s-sur-soft:rgba(140,210,170,.16); --s-def:#8660b5; --s-def-soft:rgba(200,160,240,.18);
  color-scheme:dark}
html{-webkit-text-size-adjust:100%;text-size-adjust:100%;overscroll-behavior:none}
body{overscroll-behavior:none;background:var(--bg);color:var(--ink);font:17px/1.5 var(--body);font:-apple-system-body;font-size:17px;line-height:1.5;-webkit-font-smoothing:antialiased;
  padding-left:max(16px,env(safe-area-inset-left,0px));padding-right:max(16px,env(safe-area-inset-right,0px));padding-block:12px 40px}
main{max-width:640px;margin:0 auto;display:flex;flex-direction:column;gap:16px}
h1,h2,h3{font-family:var(--display);font-weight:700;text-wrap:balance;margin:0;line-height:1.35}
h1{font-size:1.75rem} h2{font-size:1.15rem} h3{font-size:1rem}
p{margin:0}
button{font:inherit;color:inherit;cursor:pointer}
button:focus-visible{outline:3px solid var(--lamp);outline-offset:2px}
.muted{color:var(--mute)} .small{font-size:.88rem}
.num{font-variant-numeric:tabular-nums}
.big{display:flex;flex-direction:column;align-items:flex-start;gap:2px;width:100%;text-align:left;border:0;border-radius:18px;
  background:var(--lamp);color:var(--lamp-ink);padding:20px 22px}
.big b{font-family:var(--display);font-size:1.35rem;font-weight:600}
.big span{opacity:.85;font-size:.92rem}
.big:disabled{background:var(--surface);color:var(--mute);border:1px solid var(--line);cursor:default}
.list{display:flex;flex-direction:column;border:1px solid var(--line);border-radius:16px;background:var(--surface);overflow:hidden}
.row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 18px;border:0;background:none;text-align:left;width:100%;border-top:1px solid var(--line)}
.row:first-child{border-top:0}
.row:disabled{cursor:default;color:var(--mute)}
.counts{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.pill{font-size:.82rem;border-radius:999px;padding:2px 10px;background:var(--cov);white-space:nowrap}
.pill.due{background:var(--lamp-soft);color:var(--lamp);font-weight:600}
.label{font-size:.85rem;color:var(--mute);margin-bottom:-6px}
.brand{display:flex;align-items:center;gap:12px}
.logo{width:44px;height:44px;border-radius:14px;background:var(--lamp-soft);display:grid;place-items:center;color:var(--lamp)}
.logo svg{width:26px;height:26px;fill:none;stroke:currentColor;stroke-width:1.7}
.brand b{display:block;font-family:var(--display);font-size:1.25rem;line-height:1.2}
.brand small{font-size:.7rem;letter-spacing:.3em;color:var(--lamp);font-weight:600}
.top{display:flex;align-items:center;justify-content:space-between;gap:12px}
.back-btn{border:1px solid var(--line);background:var(--surface);border-radius:999px;padding:6px 16px}
.set{background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:16px 18px;display:flex;flex-direction:column;gap:12px}
.acts{display:flex;gap:8px;flex-wrap:wrap}
.act{border:1px solid var(--line);background:var(--bg);border-radius:12px;padding:8px 14px}
.act.main{background:var(--lamp);color:var(--lamp-ink);border-color:var(--lamp)}
.act:disabled{opacity:.45;cursor:default}
.card{background:var(--surface);border:1px solid var(--line);border-radius:20px;padding:20px;display:flex;flex-direction:column;gap:12px}
.tag{align-self:flex-start;font-size:.8rem;border-radius:999px;padding:2px 10px;background:var(--cov)}
.q{font-family:var(--display);font-weight:500;font-size:1.12rem;white-space:pre-line}
.shape{font-size:.92rem;color:var(--mute);border-left:3px solid var(--lamp);padding-left:10px}
.flip{border:1px dashed var(--line);background:none;border-radius:14px;padding:18px;color:var(--mute)}
.ans h4{font-family:var(--display);font-size:.82rem;color:var(--mute);margin:10px 0 2px;font-weight:500}
.ans ul,.ans ol{margin:0;padding-left:22px}
.warn{font-size:.82rem;color:var(--again)}
.scroll{overflow-x:auto;border:1px solid var(--line);border-radius:12px}
table{border-collapse:collapse;font-size:.85rem;min-width:560px}
th,td{border-bottom:1px solid var(--line);border-left:1px solid var(--line);padding:6px 8px;text-align:left;vertical-align:top}
tr:last-child td,tr:last-child th{border-bottom:0}
th:first-child{border-left:0}
thead th{background:var(--bg);font-weight:600}
td.cov{background:var(--cov)}
td.hl{background:var(--lamp-soft);font-weight:600}
td button{all:unset;cursor:pointer;display:block}
.dot{display:inline-block;width:8px;height:8px;border-radius:50%;background:var(--again);margin-left:4px;vertical-align:middle}
.group{display:flex;flex-direction:column;background:var(--surface);border:1px solid var(--line);border-radius:16px;overflow:hidden}
.ghead{display:flex;align-items:center;gap:8px;border:0;background:none;padding:14px 16px;text-align:left;font-size:1.05rem}
.ghead:disabled{cursor:default;color:var(--mute)}
.chev{width:14px;color:var(--mute)}
.chaprow{display:grid;grid-template-columns:1fr auto;gap:8px 12px;align-items:center;border:0;border-top:1px solid var(--line);background:none;text-align:left;padding:14px 16px 16px}
.ctitle{min-width:0}
.cnum{font-size:.9rem}
.pbar{grid-column:1/-1;display:flex;height:8px;border-radius:4px;overflow:hidden;background:var(--bar-track)}
.pbar i{display:block}
.stat-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.stat{border:1px solid var(--line);background:var(--surface);border-radius:14px;padding:10px 6px;display:flex;flex-direction:column;align-items:center}
.stat b{font-family:var(--display);font-size:1.3rem}
.stat span{font-size:.82rem;color:var(--mute)}
.stat.on{border-color:var(--lamp);background:var(--lamp-soft)}
.stat:disabled{opacity:.45;cursor:default}
.tiles2{display:flex;flex-direction:column;gap:12px}
.tile2{display:flex;flex-direction:column;gap:6px;text-align:left;border:1px solid var(--line);border-radius:20px;padding:18px 20px;background:var(--surface)}
.tile2:disabled{opacity:.5;cursor:default}
.t-head{display:flex;justify-content:space-between;align-items:center;gap:12px;color:var(--mute);font-size:.95rem}
.t-head svg{width:24px;height:24px;flex:none;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.tile2 b{font-family:var(--display);font-size:2.4rem;font-weight:700;line-height:1.15}
.t-bar{display:block;height:6px;border-radius:3px;background:var(--line);overflow:hidden}
.t-bar i{display:block;height:100%;background:currentColor;border-radius:3px}
.t-foot{font-size:.88rem;color:var(--mute)}
.t-due{background:var(--lamp-soft);border-color:var(--lamp)}.t-due b,.t-due .t-bar,.t-due svg{color:var(--lamp)}
.t-again{background:var(--again-soft)}.t-again b,.t-again svg{color:var(--again)}
.t-hard{background:var(--hard-soft)}.t-hard b,.t-hard svg{color:var(--hard)}
.t-new .t-bar,.t-new svg,.t-new b{color:var(--lamp)}
.t-good{background:var(--good-soft)}.t-good b,.t-good svg{color:var(--good)}
.search{display:flex;align-items:center;gap:10px;background:var(--surface);border:1px solid var(--line);border-radius:14px;padding:10px 14px}
.search:focus-within{border-color:var(--lamp)}
.search svg{width:20px;height:20px;flex:none;fill:none;stroke:var(--mute);stroke-width:2;stroke-linecap:round}
.search input{flex:1;min-width:0;border:0;background:none;color:var(--ink);font:inherit;outline:none}
.star{border:0;background:none;font-size:1.5rem;line-height:1;color:var(--lamp);padding:4px 8px}
.countdown{display:flex;flex-direction:column;gap:4px;background:var(--lamp-soft);border:1px solid var(--lamp);border-radius:20px;padding:18px 20px}
.countdown b.num{font-family:var(--display);font-size:2rem;color:var(--lamp);line-height:1.2}
.tools{display:flex;gap:2px}
.star{position:relative}
.fdot{position:absolute;top:4px;right:4px;width:7px;height:7px;border-radius:50%;background:var(--lamp)}
.sheet{background:var(--surface);border:1px solid var(--lamp);border-radius:18px;padding:14px;display:flex;flex-direction:column;gap:4px}
.folders{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}
.folder{display:flex;flex-direction:column;align-items:flex-start;gap:2px;text-align:left;border:1px solid var(--line);background:var(--surface);border-radius:16px;padding:14px;min-width:0}
.folder .ficon{font-size:1.3rem;color:var(--lamp);line-height:1.2}
.folder .fname{font-weight:600;min-width:0;overflow-wrap:anywhere}
.folder.own{background:var(--lamp-soft)}
.folder.add{border-style:dashed;color:var(--mute)}
.newf{grid-column:1/-1;display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.newf input{flex:1;min-width:160px;font:inherit;background:var(--bg);color:var(--ink);border:1px solid var(--line);border-radius:10px;padding:8px 10px}
.x{border:0;background:none;color:var(--mute);font-size:1rem;padding:6px 10px}
.act.danger{background:var(--again-soft);color:var(--again);border-color:var(--again)}
.resume{display:flex;flex-direction:column;gap:6px;background:var(--surface);border:1px solid var(--lamp);border-radius:20px;padding:16px 18px}
.resume>b{font-family:var(--display);font-size:1.15rem}
.resume .t-bar i{background:var(--lamp)}
.resume .act{align-self:flex-start;margin-top:4px}
.confirm{display:flex;flex-direction:column;gap:6px;background:var(--again-soft);border:1px solid var(--again);border-radius:16px;padding:14px 16px}
.act.ghost-danger{align-self:flex-start;background:none;color:var(--again);border-color:var(--again)}
.act.ghost-danger:disabled{opacity:.4}
.crow{display:grid;grid-template-columns:1fr auto auto;align-items:center;gap:6px 8px;border-top:1px solid var(--line);padding-top:10px}
.cinfo{display:flex;flex-direction:column;gap:2px;min-width:0}
.cinfo .t-bar{margin-top:4px}
.linkbtn{align-self:flex-start;border:0;background:none;color:var(--lamp);font-weight:600;padding:4px 0}
.stat.s-due{background:var(--lamp-soft)}.stat.s-due b{color:var(--lamp)}
.stat.s-nw{background:var(--cov)}.stat.s-nw b{color:var(--lamp)}
.stat.s-again{background:var(--again-soft)}.stat.s-again b{color:var(--again)}
.stat.s-hard{background:var(--hard-soft)}.stat.s-hard b{color:var(--hard)}
.stat.s-good{background:var(--good-soft)}.stat.s-good b{color:var(--good)}
.stat.on{border-color:var(--ink);box-shadow:inset 0 0 0 1px var(--ink)}
.ghead.static{cursor:default}
.tgroup{display:flex;flex-direction:column}
.tgroup .row{border-top:1px solid var(--line)}
.sublabel{font-size:.82rem;color:var(--mute);padding:10px 16px 0;margin:0;border-top:1px solid var(--line)}
.tsubj{background:var(--subj);border-color:var(--subj)}
.tsubj>.ghead{background:var(--subj);color:var(--subj-ink,#fff);font-weight:700}
.tsubj .tgroup{background:var(--surface)}
.tsubj .sublabel{background:var(--subj-soft);color:var(--ink);font-size:.95rem;font-weight:600;padding:9px 16px;border-top:0}
.tsubj .row{padding-left:24px}
.cmore{border-top:1px solid var(--line);padding-top:8px}
.chaprow .ficon{color:var(--lamp)}
.addrow{color:var(--lamp);font-weight:600}
.newf.pad{padding:12px 16px;border-top:1px solid var(--line)}
.tabs{position:fixed;left:0;right:0;bottom:0;z-index:5;display:grid;grid-template-columns:repeat(4,1fr);background:var(--surface);border-top:1px solid var(--line);
  padding:6px max(8px,env(safe-area-inset-right,0px)) calc(6px + env(safe-area-inset-bottom,0px)) max(8px,env(safe-area-inset-left,0px))}
.tabs button{position:relative;border:0;background:none;display:flex;flex-direction:column;align-items:center;gap:2px;padding:6px 4px;border-radius:12px;color:var(--mute);font-size:.82rem}
.tabs button.on{color:var(--lamp);background:var(--lamp-soft);font-weight:600}
.tabs svg{width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.badge{position:absolute;top:2px;left:calc(50% + 6px);font-style:normal;font-size:.72rem;background:var(--lamp);color:var(--lamp-ink);border-radius:999px;padding:0 6px;line-height:1.5}
.pill.bad{background:var(--again-soft)}
.chaps{display:flex;flex-direction:column;gap:8px}
.chap{display:flex;align-items:center;gap:8px;background:var(--surface);border:1px solid var(--line);border-radius:14px;padding:6px 10px 6px 6px}
.chap.on{border-color:var(--lamp)}
.pick{flex:1;min-width:0;display:flex;align-items:center;gap:12px;border:0;background:none;text-align:left;padding:8px}
.pick:disabled{cursor:default;opacity:.55}
.box{flex:none;width:24px;height:24px;border-radius:7px;border:2px solid var(--line);display:grid;place-items:center;font-size:.85rem;font-weight:700}
.chap.on .box{background:var(--lamp);border-color:var(--lamp);color:var(--lamp-ink)}
.show:disabled{background:var(--surface);color:var(--mute);border:1px solid var(--line);cursor:default}
.dock{position:fixed;left:0;right:0;bottom:0;z-index:5;background:var(--bg);border-top:1px solid var(--line);
  padding:10px max(16px,env(safe-area-inset-right,0px)) calc(10px + env(safe-area-inset-bottom,0px)) max(16px,env(safe-area-inset-left,0px))}
.dock>*{max-width:640px;margin:0 auto}
body.docked{padding-bottom:calc(110px + env(safe-area-inset-bottom,0px))}
.show{width:100%;border:0;border-radius:16px;padding:16px;background:var(--lamp);color:var(--lamp-ink);font-family:var(--display);font-weight:600;font-size:1.1rem}
.key{font-family:var(--display);font-weight:600;font-size:1.25rem;line-height:1.45;background:var(--lamp-soft);border-radius:14px;padding:12px 14px}
.confuse{border-left:3px solid var(--again);padding-left:10px}
.rate{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.rate button{border:0;border-radius:14px;padding:14px 6px;color:#fff;display:flex;flex-direction:column;align-items:center;gap:0;font-weight:600;font-size:1.05rem}
.rate button small{font-size:.78rem;opacity:.9}
.r0{background:var(--again-soft);color:var(--again)!important;border:1px solid var(--again)!important} .r1{background:var(--hard-soft);color:var(--hard)!important;border:1px solid var(--hard)!important} .r2{background:var(--good-soft);color:var(--good)!important;border:1px solid var(--good)!important}
.rate b{font-size:1.2rem;line-height:1}
.rate button{color:var(--bg)}
details{border-top:1px solid var(--line);padding-top:10px}
summary{cursor:pointer;color:var(--mute);font-size:.9rem}
.chips{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px}
.chip{border:1px solid var(--line);background:var(--bg);border-radius:999px;padding:4px 12px;font-size:.85rem}
.chip.on{background:var(--ink);color:var(--bg);border-color:var(--ink)}
textarea{width:100%;box-sizing:border-box;margin-top:8px;font:inherit;font-size:.9rem;background:var(--bg);color:var(--ink);border:1px solid var(--line);border-radius:10px;padding:8px}
.tiles{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}
.tile{background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:14px 16px}
.tile b{display:block;font-family:var(--display);font-size:1.6rem;font-variant-numeric:tabular-nums}
.ratio{display:flex;height:12px;border-radius:6px;overflow:hidden;background:var(--bar-track)}
.ratio i{display:block}
svg text{fill:var(--mute);font:11px var(--body)}
.legend{display:flex;gap:12px;flex-wrap:wrap;font-size:.82rem;color:var(--mute)}
.legend span::before{content:"";display:inline-block;width:10px;height:10px;border-radius:3px;margin-right:4px;vertical-align:-1px;background:var(--c)}
@media (prefers-reduced-motion:no-preference){.card{animation:in .18s ease-out}@keyframes in{from{transform:translateY(6px);opacity:.6}}}
.mode-btn{position:absolute;top:10px;right:12px;z-index:60;height:40px;padding:0 14px 0 10px;border-radius:20px;border:1px solid var(--line);background:var(--surface);color:var(--ink);font:inherit;font-size:.9rem;display:flex;align-items:center;gap:6px;box-shadow:0 2px 8px rgba(0,0,0,.12)}
.mode-btn svg{width:20px;height:20px;fill:none;stroke:var(--lamp);stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
main{padding-right:0}h1{padding-right:120px}
/* Night: text stays white like black text in Light; pastel only on icons, bars, borders and fills */
:root[data-theme="dark"] :is(.t-due b,.t-new b,.stat b,.countdown b.num,.linkbtn,.addrow,.pill.due,.brand small,.tabs button.on,.act.danger,.act.ghost-danger,.warn,.r0,.r1,.r2){color:var(--ink)!important}
:root[data-theme="dark"] .tile2 .t-foot,:root[data-theme="dark"] .small.muted{color:var(--mute)}
.frow{display:flex;align-items:stretch;border-top:1px solid var(--line)}.frow:first-child{border-top:0}
.frow .chaprow{flex:1;border-top:0;min-width:0}
.fedit{border:0;border-left:1px solid var(--line);background:none;color:var(--lamp);font-weight:600;padding:0 16px}
.fore{display:grid;grid-template-columns:repeat(7,1fr);gap:6px;align-items:end}
.fcol{display:flex;flex-direction:column;align-items:center;gap:4px;text-align:center}
.fcol b{font-size:1rem}.fcol.today b{color:var(--lamp)}
.fbar{display:flex;align-items:flex-end;width:100%;max-width:34px;height:80px;background:var(--bar-track);border-radius:6px;overflow:hidden}
.fbar i{display:block;width:100%;background:var(--lamp);opacity:.55;border-radius:6px 6px 0 0}.fcol.today .fbar i{opacity:1}
.seg3{display:grid;grid-template-columns:repeat(4,1fr);gap:6px}
.seg3 button{border:1px solid var(--line);background:none;border-radius:10px;padding:6px 4px;font-size:.88rem}
.seg3 button.on{border-color:var(--lamp);background:var(--lamp-soft);font-weight:600}
svg.hist text{font-size:12px;fill:var(--mute)}
.pday{display:flex;flex-direction:column;gap:4px;background:var(--lamp-soft);border-radius:12px;padding:10px 12px}
body.docked.rv{padding-bottom:calc(150px + env(safe-area-inset-bottom,0px))}
.rv-top{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:10px}
.rv-prog{display:flex;flex-direction:column;gap:3px}
.fc{background:var(--surface);border:1px solid var(--line);border-radius:22px;padding:16px 20px;display:flex;flex-direction:column;gap:10px;
}
.fc:not(.open){cursor:pointer}
.crumb{text-align:center;font-size:.82rem;color:var(--mute);margin:0}
.fc-front{flex:1;display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;gap:12px;padding:12px 0}
.fc-front .q{font-size:1.35rem;font-weight:600;line-height:1.45}
.fc-front .shape{border-left:0;padding-left:0}
.fc-hint{align-self:center;border:0;background:none;font-size:.75rem;letter-spacing:.06em;color:var(--mute);padding:6px 0;margin:0}
.fc-back{flex:1;display:flex;flex-direction:column;gap:8px}
.q-small{font-size:.9rem;color:var(--mute);text-align:center;white-space:pre-line}
.klabel{text-align:center;font-size:.75rem;letter-spacing:.12em;color:var(--lamp);font-weight:600;margin:4px 0 0}
.fc-back .key{text-align:center;background:none;font-size:1.4rem;padding:0 4px 8px;border-bottom:1px solid var(--line)}
.fc-back .ans h4{color:var(--lamp);font-weight:600;font-size:.88rem;margin:14px 0 4px}
.rate button:disabled{opacity:.45;cursor:default}
.rv-nav{display:flex;justify-content:space-between;margin-top:6px}
.rv-nav .linkbtn{color:var(--mute);font-weight:500}
body.sub .mode-btn{display:none}body.sub h1{padding-right:0}
.titlerow{display:flex;align-items:center;justify-content:space-between;gap:12px}
.ftitle{color:var(--lamp)}
.editbtn{flex-shrink:0;color:var(--lamp);border-color:var(--lamp);font-weight:600}
.row>span{min-width:0;overflow-wrap:anywhere}
.rv-screen{position:fixed;inset:0;z-index:4;background:var(--bg);display:flex;flex-direction:column;gap:12px;
  padding:12px max(16px,env(safe-area-inset-right,0px)) calc(10px + env(safe-area-inset-bottom,0px)) max(16px,env(safe-area-inset-left,0px));overflow:hidden}
.rv-screen>*{box-sizing:border-box;width:100%;max-width:640px;margin-left:auto;margin-right:auto}
.rv-screen .fc{flex:1;min-height:0;overflow-y:auto;-webkit-overflow-scrolling:touch;overscroll-behavior:contain}
.rv-screen .sheet{flex-shrink:0;max-height:40%;overflow-y:auto}
.rv-dock{flex-shrink:0;display:flex;flex-direction:column;gap:4px}
.rv-prog .t-bar i{background:var(--lamp)}
.rv-dock .rate{gap:6px}
.rv-dock .rate button{display:grid;grid-template-columns:auto auto;justify-content:center;align-items:baseline;column-gap:5px;row-gap:0;padding:6px 4px;border-radius:12px;font-size:.95rem;line-height:1.3}
.rv-dock .rate b{font-size:.95rem}
.rv-dock .rate button small{grid-column:1/-1;text-align:center;font-size:.72rem;line-height:1.2}
.rv-dock .rv-nav{margin-top:2px}.rv-dock .rv-nav .linkbtn{padding:2px 0;font-size:.92rem}
.fc.open{cursor:pointer}
.banner{position:sticky;top:0;z-index:70;align-self:stretch;text-align:center;font-size:.9rem;background:var(--again-soft);color:var(--ink);border:1px solid var(--again);border-radius:12px;padding:8px 12px}
.rv-screen .banner{flex-shrink:0}
.empty{font-size:.92rem;color:var(--mute);background:var(--bg);border:1px dashed var(--line);border-radius:12px;padding:12px 14px}
.loading{color:var(--mute);text-align:center;padding:40px 0}
