:root {
  color-scheme: light;
  --ink: #382642;
  --muted: #654f70;
  --accent: #9c366b;
  --line: #ecdfed;
  --paper: #fffafd;
  --pink: #f9dcea;
  --lilac: #ece1f9;
  --blue: #def2fc;
  --display: "Trebuchet MS", "Segoe UI", sans-serif;
  --body: "Segoe UI", system-ui, Meiryo, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { width: 100%; height: 100%; margin: 0; overflow: hidden; }
body {
  color: var(--ink);
  background-color: #f9eef8;
  background-image: radial-gradient(ellipse at 10% 4%, #ffe8f3 0%, transparent 56%),
    radial-gradient(ellipse at 95% 100%, #e4f4fc 0%, transparent 55%),
    repeating-linear-gradient(0deg, #8e60a114 0 1px, transparent 1px 26px),
    repeating-linear-gradient(90deg, #8e60a114 0 1px, transparent 1px 26px);
  font: 1rem/1.4 var(--body);
}
h1, h2, h3, p, ul, ol { margin: 0; }
h1, h2, h3 { font-family: var(--display); line-height: 1.12; }
a { color: inherit; }
button, input { font: inherit; }
button { cursor: pointer; }
:where(button, a, input, .timeline-scroll):focus-visible { outline: 3px solid #8a339f; outline-offset: 2px; }
[hidden] { display: none !important; }
::selection { background: #f4c8df; color: var(--ink); }
img { display: block; max-width: 100%; }
.symbol-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { display: block; flex: none; width: 1.24em; height: 1.24em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.pink { background: var(--pink); color: #95285f; }
.lilac { background: var(--lilac); color: #683d85; }
.blue { background: var(--blue); color: #345d77; }

.shell {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: clamp(.52rem, .85vw, .82rem);
  width: min(106rem, 100%);
  height: 100vh;
  height: 100dvh;
  margin-inline: auto;
  padding: max(.8rem, env(safe-area-inset-top)) max(.8rem, env(safe-area-inset-right))
    max(.44rem, env(safe-area-inset-bottom)) max(.8rem, env(safe-area-inset-left));
}
.masthead {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 5rem;
  padding: .4rem clamp(4.45rem, 11vw, 7rem);
  border-radius: 20px;
}
.brand { min-width: 0; max-width: 100%; }
.brand-logo { display: block; width: clamp(8rem, 19vw, 15rem); height: auto; object-fit: contain; }
.preferences { position: absolute; inset: .66rem .76rem auto auto; }
.chip { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: 2.4rem; padding: .34rem .63rem; border: 1px solid #e9d6ea; border-radius: 100px; color: var(--ink); background: #fff; font-weight: 700; font-size: .86rem; line-height: 1.2; text-decoration: none; white-space: nowrap; }
.chip:hover { background: #fff0f8; border-color: #d9b4d9; }
.chip[aria-pressed="true"] { background: #fae8f5; border-color: #dcbbdc; }
.chip .icon { color: #94386a; }
.bgm-state { display: inline-grid; place-items: center; min-width: 2.03rem; padding: .14rem .38rem; border-radius: 99px; color: #69447c; background: #f0e5f7; font-size: .74rem; }
.bgm-toggle[aria-pressed="true"] .bgm-state { background: #d8eef9; color: #345571; }
.tab-bar { display: none; }
.dashboard {
  --scrapbook-width: clamp(6.75rem, 10.8vw, 10.3rem);
  display: grid;
  grid-row: 2;
  grid-template-columns: var(--scrapbook-width) repeat(6, minmax(0, 1fr)) var(--scrapbook-width);
  grid-template-rows: minmax(0, max-content) minmax(12.5rem, 1fr);
  grid-template-areas:
    "scrap-left streams streams streams music music music scrap-right"
    "scrap-left posts posts merch merch timeline timeline scrap-right";
  gap: .72rem;
  min-width: 0;
  min-height: 0;
}
.panel {
  display: flex;
  flex-direction: column;
  gap: .52rem;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  min-height: 0;
  min-width: 0;
  padding: clamp(.67rem, 1.1vw, 1.04rem);
  border: 1px solid #e6d5e9;
  border-radius: 22px;
  background: linear-gradient(145deg, #fff 0%, var(--paper) 34%, var(--paper) 100%);
  box-shadow: 0 2px 0 #e4cce530, 0 5px 20px #66416e0d;
}
.panel-header { display: flex; flex: none; align-items: center; gap: .48rem; min-width: 0; }
.panel-header h2 { min-width: 0; font-size: clamp(1.38rem, 1.82vw, 1.72rem); letter-spacing: -.05em; }
.panel-icon { display: grid; flex: none; width: 2.12rem; height: 2.12rem; place-items: center; border-radius: 9px; }
.panel-header .chip, .panel-header .category, .stream-status { margin-left: auto; }
.category { display: block; width: max-content; padding: .29rem .57rem; color: #8c2e61; background: #fae2ee; border: 1px solid #eed0e2; border-radius: 100px; font-size: .76rem; font-weight: 750; white-space: nowrap; }

.streams-panel { grid-area: streams; }
.music-panel { grid-area: music; }
.posts-panel { grid-area: posts; }
.merch-panel { grid-area: merch; }
.timeline-panel { grid-area: timeline; overflow: hidden; }
.streams-panel, .music-panel { container-type: inline-size; }

.screen {
  position: relative;
  flex: 1 1 auto;
  align-self: center;
  width: 100%;
  min-height: 200px;
  max-height: max(200px, min(56.25cqw, 45dvh));
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 13px;
  background: #35263e;
}
.video-poster, .video-mount, .video-mount iframe { display: block; width: 100%; height: 100%; }
.video-poster, .video-mount { position: absolute; inset: 0; }
.video-poster img { width: 100%; height: 100%; object-fit: cover; }
.video-poster:focus-visible { outline-offset: -4px; }
.poster-play { position: absolute; inset: 50% auto auto 50%; transform: translate(-50%, -50%); display: grid; place-items: center; width: clamp(3.2rem, 6vw, 4.4rem); aspect-ratio: 1; border-radius: 50%; border: 2px solid white; background: #61344edb; color: white; box-shadow: 0 4px 17px #45243f7d; font-size: 1.48rem; }
.video-poster:hover .poster-play { background: #a13267; }
.video-mount iframe { border: 0; }
.now-playing { display: flex; flex: none; align-items: center; justify-content: space-between; gap: .52rem; min-width: 0; }
.now-title { min-width: 0; overflow-wrap: anywhere; }
.now-title h3 { font-size: clamp(1.02rem, 1.36vw, 1.28rem); letter-spacing: -.02em; }
.now-title p { margin-top: .15rem; color: var(--muted); font-size: .78rem; }
.volume { display: inline-flex; flex: none; align-items: center; gap: .27rem; color: var(--muted); font-size: .82rem; font-weight: 650; }
.volume input { width: clamp(3.1rem, 7vw, 6.5rem); accent-color: var(--accent); }
.volume output { min-width: 2.1rem; text-align: end; }
.player-message { flex: none; color: var(--muted); font-size: .82rem; }
.player-message a { color: var(--accent); font-weight: 700; text-underline-offset: .18em; }
.play-list, .post-list, .merch-list, .stream-list, .timeline-list { padding: 0; list-style: none; }
.play-list { flex: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; margin-top: auto; }
.play-list li { min-width: 0; }
.track { display: flex; align-items: center; min-width: 0; min-height: 100%; gap: .5rem; padding: .49rem; border: 1px solid var(--line); border-radius: 12px; background: #fff; text-decoration: none; }
.track:hover { border-color: #d9b5d5; background: #fff4f9; }
.track[aria-current="true"] { border-color: #dfaecd; background: #fdf0f8; }
.track-play { display: grid; flex: none; place-items: center; width: 1.95rem; aspect-ratio: 1; border-radius: 8px; font-size: .86rem; }
.track-copy { min-width: 0; }
.track strong, .track small, .merch-row strong, .merch-row small { display: block; }
.track strong { overflow-wrap: anywhere; font-size: .86rem; line-height: 1.22; }
.track small, .merch-row small { margin-top: .17rem; color: var(--muted); font-size: .76rem; }

.stream-status {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: .35rem;
  padding: .25rem .55rem;
  border-radius: 100px;
  color: #5b4b66;
  background: #efe8f2;
  font-size: .74rem;
  font-weight: 750;
  white-space: nowrap;
}
.stream-status::before { width: .42rem; aspect-ratio: 1; border-radius: 50%; background: currentColor; content: ""; }
.stream-status[data-state="live"] { color: #981944; background: #ffdfec; }
.stream-status[data-state="checking"] { color: #315f76; background: #e0f0fa; }
.stream-now h3 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stream-now p { margin: 0 0 .14rem; font-weight: 650; }
.stop-button { min-height: 1.95rem; padding: .22rem .52rem; font-size: .77rem; }
.stream-schedule {
  display: flex;
  flex: none;
  flex-direction: column;
  gap: .27rem;
  padding: .45rem .58rem;
  border: 1px solid #eaddec;
  border-radius: 10px;
  background: #f9f2fb;
}
.schedule-heading { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .17rem .5rem; }
.schedule-heading h3 { font-size: .94rem; }
.stream-schedule p { color: var(--muted); font-size: .78rem; }
.stream-list { max-height: clamp(3.2rem, calc(17dvh - 4.5rem), 7.35rem); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.stream-list li + li { border-top: 1px solid var(--line); }
.stream-list button {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  width: 100%;
  align-items: center;
  gap: .1rem .45rem;
  padding: .33rem .28rem;
  border: 0;
  border-radius: 5px;
  color: var(--ink);
  background: none;
  text-align: start;
  font-size: .8rem;
}
.stream-list button:hover { background: #f1e5f5; }
.stream-list button:focus-visible { outline-offset: -2px; }
.stream-list strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stream-list strong::before { display: inline-block; width: .48rem; height: .53rem; margin-right: .35rem; clip-path: polygon(0 0, 100% 50%, 0 100%); background: var(--accent); content: ""; }
.stream-list time { color: var(--muted); font-size: .71rem; white-space: nowrap; }

.timeline-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #d6adce transparent; }
.timeline-scroll:focus-visible { border-radius: 7px; outline-offset: -2px; }
.timeline-list { padding: .2rem .35rem .05rem .4rem; }
.timeline-list li { position: relative; padding: .05rem 0 .8rem .8rem; border-left: 2px solid #eccfe4; }
.timeline-list li:last-child { border-left-color: transparent; }
.timeline-list li::before { position: absolute; top: .3rem; left: -.28rem; width: .44rem; aspect-ratio: 1; border-radius: 50%; background: #9f4782; content: ""; }
.timeline-list time { display: block; color: var(--muted); font-size: .76rem; font-weight: 650; }
.timeline-list a { display: inline-block; margin-top: .12rem; color: #733555; font-weight: 750; font-size: .93rem; text-underline-offset: .15em; text-decoration-color: #e2b5d2; }
.timeline-list a:hover { text-decoration-color: currentColor; }
.timeline-list p { margin-top: .14rem; color: var(--muted); font-size: .79rem; line-height: 1.35; }

.scrapbook-left { grid-area: scrap-left; }
.scrapbook-right { grid-area: scrap-right; }
.scrapbook-side {
  position: relative;
  isolation: isolate;
  min-width: 0;
  min-height: 0;
  overflow: clip;
  overflow-clip-margin: .6rem;
}
.scrapbook-side::before, .scrapbook-side::after {
  position: absolute;
  pointer-events: none;
  content: "";
}
.scrapbook-side::before {
  inset: 11% 11% 16% 8%;
  rotate: -3deg;
  background: repeating-linear-gradient(0deg, #d6a8be55 0 1px, transparent 1px 1.05rem), #fff6e8;
  clip-path: polygon(2% 0, 99% 1%, 96% 13%, 100% 23%, 96% 33%, 98% 42%, 95% 53%, 99% 64%, 95% 74%, 100% 85%, 96% 97%, 7% 100%, 0 91%, 5% 81%, 1% 69%, 5% 57%, 0 45%, 4% 33%, 1% 22%, 6% 11%);
}
.scrapbook-side::after {
  inset: 39% 3% 29% 13%;
  rotate: 6deg;
  background: radial-gradient(#f9c0d4 1px, transparent 1px) 0 0 / .48rem .48rem, #ffe9f1;
}
.scrapbook-right::before { inset: 6% 7% 19% 14%; rotate: 4deg; background-color: #eff6fb; }
.scrapbook-right::after { inset: 32% 14% 37% 0; rotate: -8deg; background-color: #f4e9fb; }

.scrapbook-left .scrapbook-card:nth-child(1) {
  --top: 2%; --left: 5%; --width: 89%; --height: 28%; --tilt: -8deg; --layer: 2;
  --tape-x: 63%; --tape-angle: -13deg;
}
.scrapbook-left .scrapbook-card:nth-child(2) {
  --top: 26%; --left: 20%; --width: 73%; --height: 24%; --tilt: 10deg; --layer: 4;
  --tape-x: 25%; --tape-angle: -28deg; --tape-color: #c0e7f3d9; --tape-light: #e5f6fbd9;
}
.scrapbook-left .scrapbook-card:nth-child(3) {
  --top: 46%; --left: 4%; --width: 92%; --height: 31%; --tilt: -6deg;
  --tape-x: 78%; --tape-angle: 23deg; --tape-color: #e3cef6df; --tape-light: #f3e6fadf;
}
.scrapbook-left .scrapbook-card:nth-child(4) {
  --top: 73%; --left: 17%; --width: 80%; --height: 25%; --tilt: 7deg; --layer: 3;
  --tape-x: 48%; --tape-angle: -7deg; --tape-color: #fae1a9e5; --tape-light: #fff1cde5;
}
.scrapbook-right .scrapbook-card:nth-child(1) {
  --top: 3%; --left: 18%; --width: 77%; --height: 24%; --tilt: 9deg; --layer: 3;
  --tape-x: 31%; --tape-angle: 16deg; --tape-color: #e3cef6df; --tape-light: #f3e6fadf;
}
.scrapbook-right .scrapbook-card:nth-child(2) {
  --top: 23%; --left: 4%; --width: 91%; --height: 31%; --tilt: -7deg;
  --tape-x: 61%; --tape-angle: 11deg; --tape-color: #fae1a9e5; --tape-light: #fff1cde5;
}
.scrapbook-right .scrapbook-card:nth-child(3) {
  --top: 51%; --left: 21%; --width: 75%; --height: 23%; --tilt: 10deg; --layer: 4;
  --tape-x: 75%; --tape-angle: 25deg;
}
.scrapbook-right .scrapbook-card:nth-child(4) {
  --top: 70%; --left: 4%; --width: 88%; --height: 28%; --tilt: -8deg; --layer: 2;
  --tape-x: 27%; --tape-angle: -20deg; --tape-color: #c0e7f3d9; --tape-light: #e5f6fbd9;
}
.scrapbook-card {
  position: absolute;
  inset: var(--top) auto auto var(--left);
  z-index: var(--layer, 1);
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  width: var(--width);
  height: var(--height);
  min-width: 0;
  min-height: 0;
  padding: clamp(.21rem, .53vw, .5rem);
  border: 1px solid #e9d9e8;
  background: #fffdf9;
  box-shadow: 1px 6px 15px #6b365f28, 1px 1px 2px #5b2b5422;
  text-align: center;
  text-decoration: none;
  rotate: var(--tilt);
}
.scrapbook-card::before {
  position: absolute;
  top: -.32rem;
  left: var(--tape-x);
  width: 44%;
  height: .8rem;
  transform: translateX(-50%) rotate(var(--tape-angle));
  background: repeating-linear-gradient(135deg, var(--tape-color, #f8c5dbd9) 0 3px, var(--tape-light, #fde4efd9) 3px 6px);
  clip-path: polygon(2% 0, 98% 4%, 96% 31%, 100% 55%, 97% 75%, 99% 100%, 0 96%, 4% 71%, 1% 49%, 4% 21%);
  pointer-events: none;
  content: "";
}
.scrapbook-card:is(:hover, :focus-visible) { z-index: 5; rotate: 0deg; }
.scrapbook-card img { width: 100%; height: 100%; min-height: 0; object-fit: cover; object-position: center 29%; background: #f7ebf7; }
.scrapbook-card span { display: block; margin-top: .22rem; color: #7d4c70; font: 700 clamp(.55rem, .82vw, .72rem)/1.2 "Segoe Print", var(--body); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.posts-panel, .merch-panel { gap: .49rem; }
.post-list, .merch-list { display: grid; flex: 1 0 auto; }
.post-list { grid-template-rows: repeat(5, minmax(1.67rem, 1fr)); }
.post-list li + li, .merch-list li + li { border-top: 1px solid var(--line); }
.post, .merch-row { display: grid; height: 100%; align-items: center; gap: .5rem; border-radius: 8px; text-decoration: none; }
.post { grid-template-columns: 3rem minmax(0, 1fr) auto; padding: .16rem .25rem; font-size: .83rem; line-height: 1.23; }
.post:hover, .merch-row:hover { background: #faedf7; }
.post:focus-visible, .merch-row:focus-visible { outline-offset: -2px; }
.post time { font-size: .78rem; font-weight: 750; color: #84517e; }
.post > span { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; }
.post .icon, .merch-row > .icon { color: #8a578c; }
.snapshot-date { flex: none; color: var(--muted); font-size: .75rem; }
.merch-list { grid-template-rows: repeat(3, minmax(2.85rem, 1fr)); }
.merch-row { grid-template-columns: auto minmax(0, 1fr) auto; padding: .28rem .23rem; }
.merch-row strong { font-size: .94rem; line-height: 1.18; }
.merch-thumbnail { display: grid; width: 3.45rem; height: 2.35rem; place-items: center; object-fit: cover; border: 1px solid #efd9e6; border-radius: 7px; }
.merch-thumbnail.pink { background-image: repeating-linear-gradient(-45deg, #fff6 0 3px, transparent 3px 8px); }

.detail-dialog {
  width: min(38rem, calc(100% - 1.5rem));
  max-height: calc(100dvh - 1.5rem);
  padding: 0;
  border: 1px solid #e5c9e4;
  border-radius: 20px;
  color: var(--ink);
  background: #fffaff;
}
.detail-dialog::backdrop { background: #3623449c; }
.detail-header { display: flex; position: sticky; z-index: 1; top: 0; justify-content: space-between; align-items: center; gap: .6rem; padding: .7rem 1rem; border-bottom: 1px solid var(--line); background: #fff6fc; }
.detail-header h2 { font-size: clamp(1.18rem, 4vw, 1.64rem); }
.icon-button { width: 2.5rem; padding: .35rem; font-size: 1rem; }
.detail-content { display: grid; gap: .64rem; padding: .95rem 1rem 1.1rem; }
.detail-content .detail-meta, .embed-status { color: var(--muted); font-size: .86rem; }
.embed-status:empty { display: none; }
.detail-link { justify-self: start; }
.detail-art { width: 100%; max-height: min(44vh, 24rem); object-fit: contain; border-radius: 10px; background: #fcf0f7; }
.x-embed iframe { max-width: 100% !important; }
.shell.has-site-cursor, .shell.has-site-cursor :where(a, button, input) { cursor: none; }
.shell.has-site-cursor iframe { cursor: auto; }
.site-cursor {
  position: fixed;
  z-index: 20;
  inset: 0 auto auto 0;
  width: 32px;
  height: 32px;
  pointer-events: none;
  background: url("assets/cursor-normal.png") no-repeat;
  translate: -1px -1px;
  animation: cursor-frames 1.6s steps(16) infinite;
}
.site-cursor[data-shape="link"] { background-image: url("assets/cursor-link.png"); translate: -4px -1px; }
@keyframes cursor-frames {
  from { background-position-x: 0; }
  to { background-position-x: -512px; }
}

@media (min-width: 80rem) {
  .shell { padding-inline: 1.5rem; }
}
@media (70rem < width <= 85rem) and (height > 42rem) {
  .track { justify-content: center; min-height: 2.4rem; padding: .3rem; text-align: center; }
  .track-play, .track small { display: none; }
  .track strong { font-size: .79rem; }
}
@media (max-width: 70rem), (max-height: 42rem) {
  .shell { grid-template-rows: auto auto minmax(0, 1fr); }
  .tab-bar { display: block; min-width: 0; }
  .tab-bar > div { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: .3rem; padding: .25rem; border: 1px solid #e9d7eb; border-radius: 13px; background: #fff8fd; }
  .tab-bar button { display: flex; align-items: center; justify-content: center; min-height: 2.42rem; gap: .28rem; padding: .28rem .2rem; border: 1px solid transparent; border-radius: 8px; color: var(--muted); background: transparent; font-size: .9rem; font-weight: 750; }
  .tab-bar button:hover { background: #f8eef9; }
  .tab-bar button[aria-selected="true"] { color: #85285e; border-color: #eac3dd; background: #f9e5f2; }
  .dashboard {
    --scrapbook-width: clamp(4.8rem, 11vw, 8rem);
    grid-row: 3;
    grid-template-columns: var(--scrapbook-width) minmax(0, 1fr) var(--scrapbook-width);
    grid-template-rows: minmax(0, 1fr);
    grid-template-areas: "scrap-left pane scrap-right";
  }
  .dashboard > .panel { grid-area: pane; align-self: start; max-height: 100%; }
  .dashboard:not([data-pane="streams"]) #streams,
  .dashboard:not([data-pane="music"]) #music,
  .dashboard:not([data-pane="posts"]) #posts,
  .dashboard:not([data-pane="merch"]) #merch,
  .dashboard:not([data-pane="timeline"]) #timeline { display: none; }
  .screen { flex: none; }
  .post-list, .merch-list { flex-grow: 0; }
  .post-list { grid-template-rows: repeat(5, minmax(2.9rem, 1fr)); }
  .merch-list { grid-template-rows: repeat(3, minmax(3.15rem, 1fr)); }
}
@media (max-height: 42rem) {
  .shell { gap: .37rem; padding-top: .38rem; }
  .masthead { min-height: 3.1rem; padding-block: .3rem; }
  .brand-logo { width: min(100%, 8rem); max-height: 2.4rem; }
  .preferences { inset-block-start: .28rem; }
  .panel { gap: .38rem; padding-block: .55rem; }
}
@media (max-height: 34rem) and (min-width: 38rem) {
  .masthead { min-height: 2.65rem; }
  .tab-bar button { min-height: 2.05rem; }
  .panel-icon { width: 2.15rem; height: 2.15rem; }
  .music-panel, .streams-panel { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(10rem, 1fr); grid-template-rows: auto auto minmax(0, 1fr) auto; column-gap: .62rem; }
  :is(.music-panel, .streams-panel) .panel-header { grid-column: 1 / -1; }
  .screen { grid-area: 2 / 1 / 5 / 2; justify-self: center; width: 100%; }
  .now-playing { grid-area: 2 / 2; }
  .music-panel .now-playing { flex-wrap: wrap; }
  .play-list { grid-area: 3 / 2; grid-template-columns: minmax(0, 1fr); align-content: start; }
  .player-message { grid-area: 4 / 2; }
  .stream-schedule { grid-area: 3 / 2 / 5 / 3; align-self: start; }
  .post-list { grid-template-rows: repeat(5, minmax(2.15rem, 1fr)); }
}
@media (max-width: 48rem), (max-width: 70rem) and (pointer: coarse) {
  html, body { height: auto; min-height: 100%; overflow: visible; }
  html { scroll-padding-block-start: calc(4rem + env(safe-area-inset-top)); }
  body { overflow-x: clip; }
  .shell {
    display: block;
    height: auto;
    min-height: 100svh;
    padding: max(.55rem, env(safe-area-inset-top)) max(.5rem, env(safe-area-inset-right))
      max(.75rem, env(safe-area-inset-bottom)) max(.5rem, env(safe-area-inset-left));
  }
  .masthead { min-height: 3.6rem; border-radius: 14px; padding: .35rem 4.4rem; }
  .brand-logo { width: clamp(7rem, 32vw, 11rem); max-height: none; }
  .preferences { inset: .28rem .3rem auto auto; }
  .preferences .chip { gap: .22rem; padding-inline: .35rem; font-size: .78rem; }
  .bgm-state { min-width: 1.75rem; padding-inline: .28rem; font-size: .69rem; }
  .tab-bar {
    position: sticky;
    inset-block-start: env(safe-area-inset-top);
    z-index: 6;
    margin-block: .3rem .48rem;
    padding-block: .14rem;
  }
  .tab-bar > div { gap: .16rem; padding: .2rem; box-shadow: 0 3px 10px #5d3a6021; }
  .tab-bar button { flex-direction: column; min-width: 0; gap: .16rem; padding: .2rem .05rem; font-size: .76rem; overflow-wrap: anywhere; }
  .tab-bar button, .preferences .chip, .stop-button, .track, .post, .merch-row, .stream-list button {
    min-height: 2.75rem;
  }
  .dashboard {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto auto;
    grid-template-areas: "pane pane" "scrap-left scrap-right";
    gap: .55rem;
  }
  .dashboard > .panel { align-self: stretch; max-height: none; overflow: visible; border-radius: 16px; padding: .7rem; gap: .65rem; }
  .music-panel, .streams-panel { display: flex; }
  .screen { width: min(100%, 40rem); max-height: none; }
  .now-playing { flex-wrap: wrap; }
  .now-title { flex: 1 1 13rem; }
  .stream-now h3 { overflow: visible; white-space: normal; }
  .play-list { grid-template-columns: minmax(0, 1fr); gap: .38rem; }
  .post-list { grid-template-rows: repeat(5, minmax(2.9rem, auto)); }
  .timeline-scroll, .stream-list { max-height: none; overflow: visible; overscroll-behavior: auto; }
  .scrapbook-side {
    display: grid;
    grid-template-rows: minmax(0, 1fr);
    grid-auto-flow: column;
    grid-auto-columns: clamp(3rem, 44%, 8.2rem);
    height: clamp(7rem, 31vw, 10rem);
    gap: .28rem;
    padding: .65rem .45rem .4rem;
    overflow: auto hidden;
    overscroll-behavior-inline: contain;
    scrollbar-width: thin;
    scrollbar-color: #e2b5cf transparent;
    scroll-snap-type: x proximity;
  }
  .scrapbook-side::before, .scrapbook-side::after { display: none; }
  .scrapbook-side .scrapbook-card {
    position: relative;
    inset: auto;
    align-self: center;
    width: 106%;
    height: min(var(--strip-height, 92%), 8.1rem);
    padding: .23rem;
    scroll-snap-align: center;
  }
  .scrapbook-side .scrapbook-card:nth-child(even) { --strip-height: 78%; }
  .scrapbook-card::before { height: .58rem; }
}
@media (max-width: 23rem) {
  .stream-list button { grid-template-columns: minmax(0, 1fr); }
  .post { grid-template-columns: 2.65rem minmax(0, 1fr) auto; gap: .26rem; }
}
@media (prefers-reduced-motion: reduce) {
  .site-cursor { display: none !important; animation: none; }
  .shell.has-site-cursor, .shell.has-site-cursor :where(a, button, input) { cursor: revert; }
}
