/* ============================================================
   binso.online — style.css
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@700;800&family=Fira+Mono:wght@400;500&family=Noto+Sans+JP:wght@400;500&display=swap');

/* ── Variables ─────────────────────────────────────────── */
:root {
  --accent:        #7ECEC4;
  --accent-dim:    rgba(126,206,196,0.12);
  --accent-border: rgba(126,206,196,0.40);
  --text:          #343840;
  --text-sub:      #555A63;
  --text-muted:    #838991;
  --bg-desk:       #E8EAED;
  --bg-win:        rgba(255,255,255,0.84);
  --bg-bar:        rgba(244,245,246,0.96);
  --bg-sec:        rgba(244,245,246,0.72);
  --border:        rgba(198,202,208,0.60);
  --border-lt:     rgba(198,202,208,0.35);
  --r:             10px;
}

/* ── Reset ─────────────────────────────────────────────── */
*,*::before,*::after { box-sizing:border-box; margin:0; padding:0; }
a { text-decoration:none; color:inherit; }
button { cursor:pointer; border:none; background:none; }

/* ── Page base ─────────────────────────────────────────── */
html,body {
  height:100%; width:100%;
  overflow:hidden;
  background:var(--bg-desk);
  font-family:'Noto Sans JP',sans-serif;
  font-size:14px;
  color:var(--text);
  -webkit-font-smoothing:antialiased;
}

/* ── Desktop container ─────────────────────────────────── */
.desktop {
  position:fixed;
  inset:0;
  /* overflow: visible を維持して HOME キャラクターのウィンドウ枠オーバーフローを許可 */
  /* body { overflow: hidden } でスクロールバー防止済み */
  overflow:visible;
}

/* ── ☆ Background stars ────────────────────────────────── */
.desk-stars {
  position:absolute;
  inset:0;
  pointer-events:none;
  z-index:0;
}
.desk-stars svg { position:absolute; fill:var(--accent); }

/* Dot grid */
.desk-grid {
  position:absolute;
  inset:0;
  background-image: radial-gradient(circle, rgba(126,206,196,0.16) 1px, transparent 1px);
  background-size: 24px 24px;
  pointer-events:none;
  z-index:0;
}

/* ── Loader (ウィンドウ枠内に収める / ドックは常時表示) ─── */
.loader {
  /* .main-window と同じ位置・サイズ・見た目 */
  position: fixed;
  top: 20px;
  bottom: 42px;
  left: calc(50% - 37px);
  transform: translateX(-50%);
  width: calc(100% - 80px - 74px);
  max-width: 880px;
  background: var(--bg-win);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border: 0.5px solid var(--border);
  border-radius: var(--r);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 25;  /* main-windowより上、dock(30)より下 */
  transition: opacity 0.5s ease;
}
.loader.hidden { opacity: 0; pointer-events: none; }

.loader-star {
  width: 40px; height: 40px;
  animation: loaderBounce 0.7s ease-in-out infinite alternate;
}
@keyframes loaderBounce {
  from { transform: translateY(-10px) rotate(0deg); }
  to   { transform: translateY(10px)  rotate(30deg); }
}

/* ── Main Window ────────────────────────────────────────── */
.main-window {
  position:absolute;
  top:20px;
  /* horizontal centering — offset for dock */
  left:calc(50% - 37px);   /* 74px dock / 2 = 37px */
  transform:translateX(-50%);
  width:calc(100% - 80px - 74px);
  max-width:880px;
  bottom:42px;             /* home-bottom-bar 32px + 10px margin */
  background:var(--bg-win);
  backdrop-filter:blur(18px) saturate(160%);
  -webkit-backdrop-filter:blur(18px) saturate(160%);
  border:0.5px solid var(--border);
  border-radius:var(--r);
  display:flex;
  flex-direction:column;
  overflow:visible;        /* allow character overflow */
  z-index:10;
}

/* Title bar */
.win-titlebar {
  height:32px;
  background:var(--bg-bar);
  border-bottom:0.5px solid var(--border);
  border-radius:var(--r) var(--r) 0 0;
  display:flex;
  align-items:center;
  padding:0 12px;
  gap:8px;
  flex-shrink:0;
  position:relative;
  z-index:20;
}
.win-dots { display:flex; gap:5px; }
.win-dot {
  width:9px; height:9px; border-radius:50%;
  background:var(--border);
}
.win-dot.green { background:var(--accent); }

.win-title {
  flex:1; text-align:center;
  font-family:'Fira Mono',monospace; font-size:11px;
  color:var(--text-muted);
}
.win-drawer-btn {
  padding:4px; color:var(--text);
  display:flex; align-items:center;
}
.win-drawer-btn svg { display:block; }

/* Address bar */
/* ── 共通: URLバー (全ページ統一: Profile の元デザインを正として)
   home ボタン (家マーク) + 角丸 URL pill の Chrome 風デザイン
   (2026-04-20ak: Profile のインライン CSS と見た目を完全一致) */
.win-addressbar {
  background: var(--bg-sec);
  border-bottom: 0.5px solid var(--border-lt);
  display: flex !important;
  align-items: center;
  gap: 6px;
  padding: 4px 10px !important;
  flex-shrink: 0;
  position: relative;
  z-index: 20;
}
.win-home-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px; height: 24px; padding: 0;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  flex-shrink: 0;
  background: transparent;
  color: var(--text-muted);
  transition: background .15s, color .15s;
  -webkit-appearance: none;
  appearance: none;
}
.win-home-btn:hover {
  background: var(--hover, rgba(52,56,64,0.06));
  color: var(--text);
}
.win-home-btn svg { display: block; }
.win-url-pill {
  flex: 1;
  background: var(--hover, rgba(52,56,64,0.06));
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2px 12px;
  display: flex;
  align-items: center;
  min-width: 0;
}
.win-url {
  font-family: 'Fira Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Sub-nav (inside address bar) */
.sub-nav {
  display:flex; gap:0;
  margin-left:auto;
}
.sub-nav a {
  font-family:'Fira Mono',monospace; font-size:11px;
  color:var(--text-muted); padding:4px 12px;
  border-bottom:2px solid transparent;
  transition:all .15s;
}
.sub-nav a:hover, .sub-nav a.active {
  color:var(--accent); border-bottom-color:var(--accent);
}

/* Window body */
.window-body {
  flex:1; position:relative; overflow:hidden;
  border-radius:0 0 var(--r) var(--r);
}

/* ── HOME: Character Overflow ───────────────────────────── */
.home-scene {
  position:absolute; inset:0;
  overflow:visible;
  display:flex; align-items:flex-end; justify-content:center;
}

.home-char-wrap {
  position:absolute;
  bottom:0; left:50%;
  transform:translateX(-50%);
  /* --char-scale: controlled via Notion / inline style */
  --char-scale:1.5;
  height:calc(100% * var(--char-scale));
  display:flex; align-items:flex-end; justify-content:center;
  z-index:3;
  pointer-events:none;
}

.home-char-wrap video {
  height:100%; width:auto;
  max-width:none;
  /* drop-shadow 削除: Scene1_flat.mp4 は背景単色なので動画の四角い枠に影が落ちる
     2026-04-28 (bf): 新アバター動画 (背景焼き込み) に切り替え後、シャドウは不要 */
}

/* Logo + subtitle (non-hover) */
.home-logo-area {
  position:absolute;
  bottom:28px; left:50%;
  transform:translateX(-50%);
  text-align:center;
  z-index:5;
  transition:opacity .3s ease;
  pointer-events:none;
  white-space:nowrap;
}
.home-logo-area img {
  width:96px; height:auto;
  display:block; margin:0 auto;
}
.home-subtitle {
  font-family:'Fira Mono',monospace; font-size:12px;
  color:var(--text-muted); margin-top:5px;
  letter-spacing:.06em;
}

/* Callouts (hover) */
.callout {
  position:absolute;
  left:58%;
  opacity:0; pointer-events:none;
  transition:opacity .22s ease;
  z-index:6;
}
.callout.visible { opacity:1; }

.callout-row {
  display:flex; align-items:center; gap:0;
}
.callout-dot {
  width:5px; height:5px; border-radius:50%;
  background:var(--accent); flex-shrink:0;
}
.callout-dash {
  width:36px; height:1px;
  background:var(--accent); flex-shrink:0;
}
.callout-main {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:17px; color:var(--text);
  margin-left:8px;
}
.callout-sub {
  font-family:'Fira Mono',monospace; font-size:11px;
  color:var(--text-muted); margin-top:3px;
  padding-left:49px;  /* dot + dash + gap */
}

/* When hovering a nav item, hide logo area */
.desktop.nav-hover .home-logo-area { opacity:0; }

/* ── Split Layout (inner pages) ─────────────────────────── */
.split-layout {
  display:flex; height:100%; overflow:hidden;
}

.split-char {
  width:44%; position:relative;
  flex-shrink:0; overflow:hidden;
  background:transparent;
}
.split-char video {
  position:absolute;
  bottom:0; left:50%;
  transform:translateX(-50%);
  height:100%; width:auto;
  /* transform-origin and scale set per-page inline */
}

.split-content {
  width:56%; overflow-y:auto;
  padding:24px 28px 24px 22px;
  /* scrollbar */
  scrollbar-width:thin;
  scrollbar-color:var(--border) transparent;
}
.split-content::-webkit-scrollbar { width:4px; }
.split-content::-webkit-scrollbar-track { background:transparent; }
.split-content::-webkit-scrollbar-thumb { background:var(--border); border-radius:2px; }

/* ── Typography (content area) ─────────────────────────── */
.split-content h1, .content-section h1 {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:22px; color:var(--text); margin-bottom:6px;
}
.split-content h2, .content-section h2 {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:15px; color:var(--text); margin-bottom:5px;
  margin-top:18px;
}
.split-content p, .split-content li {
  font-size:13px; line-height:1.85;
  color:var(--text-sub);
}
.split-content section { margin-bottom:24px; }

/* ── Section divider (sitewide) ─────────────────────────── */
/* Use <hr class="section-divider"> between major sections.
   See Notion "共通事項・デザイン設計 > セクション区切り線ルール" */
.section-divider {
  max-width: 720px;
  margin: 24px auto;
  border: 0;
  border-top: 1px solid var(--border);
}

/* ── Profile Page ───────────────────────────────────────── */
.spec-table { width:100%; border-collapse:collapse; }
.spec-table td {
  padding:6px 0;
  font-size:12px;
  border-bottom:0.5px solid var(--border-lt);
  vertical-align:top;
}
.spec-table td:first-child {
  font-family:'Fira Mono',monospace;
  font-size:10px; color:var(--text-muted);
  text-transform:uppercase; letter-spacing:.08em;
  width:100px; padding-right:12px;
}

/* Radar chart */
#radarCanvas { display:block; margin:0 auto; }

.radar-label-box {
  background:var(--bg-sec); border:0.5px solid var(--border-lt);
  border-radius:6px; padding:10px 14px;
  margin-top:14px;
}
.radar-label-box h3 {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:14px; color:var(--text); margin-bottom:3px;
}
.radar-label-box p {
  font-size:12px; color:var(--text-muted);
}

/* Philosophy text */
.philosophy { margin-top:16px; }
.philosophy .ph-heading {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:16px; color:var(--text); margin-bottom:4px;
}
.philosophy .ph-sub {
  font-family:'Fira Mono',monospace; font-size:11px;
  color:var(--accent); letter-spacing:.05em; margin-bottom:12px;
}
.philosophy p { font-size:13px; line-height:1.9; color:var(--text-sub); }

/* Credits */
.credits-table { width:100%; }
.credits-table td {
  padding:5px 0; font-size:12px;
  border-bottom:0.5px solid var(--border-lt);
}
.credits-table td:first-child {
  font-family:'Fira Mono',monospace; font-size:10px;
  color:var(--text-muted); width:55%; padding-right:10px;
}
.credits-table a { color:var(--accent); }

/* ── YouTube Page ───────────────────────────────────────── */
.channel-card {
  background:var(--bg-sec); border:0.5px solid var(--border-lt);
  border-radius:8px; padding:14px 16px; margin-bottom:14px;
}
.channel-header {
  display:flex; align-items:center; gap:10px; margin-bottom:8px;
}
.channel-tag {
  font-family:'Fira Mono',monospace; font-size:9px;
  color:var(--text-muted); text-transform:uppercase; letter-spacing:.1em;
  background:var(--bg-win); border:0.5px solid var(--border);
  padding:2px 7px; border-radius:3px;
}
.channel-name {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:15px; color:var(--text);
}
.channel-desc {
  font-size:12px; color:var(--text-sub);
  line-height:1.7; margin-bottom:10px;
}
.channel-footer {
  display:flex; align-items:center; justify-content:space-between;
}
.channel-subs {
  font-family:'Fira Mono',monospace; font-size:13px; color:var(--text);
}
.channel-subs span {
  font-size:11px; color:var(--text-muted); margin-left:4px;
}
.channel-subs small { font-size:10px; color:var(--text-muted); display:block; }
.btn-primary {
  font-family:'Fira Mono',monospace; font-size:11px;
  background:var(--text); color:#fff;
  padding:6px 14px; border-radius:5px;
  transition:background .15s;
  text-decoration:none; display:inline-block;
}
.btn-primary:hover { background:var(--accent); }

/* Shop section */
.shop-card {
  border:0.5px dashed var(--border);
  border-radius:8px; padding:12px 16px;
  margin-bottom:14px;
  display:flex; align-items:center; justify-content:space-between;
}
.shop-card .shop-label {
  font-family:'Fira Mono',monospace; font-size:10px;
  color:var(--text-muted); text-transform:uppercase; letter-spacing:.08em;
  margin-bottom:3px;
}
.shop-card .shop-name {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:14px; color:var(--text);
}
.shop-card .shop-desc { font-size:12px; color:var(--text-sub); }
.btn-outline {
  font-family:'Fira Mono',monospace; font-size:11px;
  color:var(--text); border:0.5px solid var(--border);
  padding:6px 14px; border-radius:5px;
  transition:all .15s; white-space:nowrap;
  text-decoration:none; display:inline-block;
}
.btn-outline:hover {
  border-color:var(--accent); color:var(--accent);
  background:var(--accent-dim);
}

/* Special offers / affiliate */
.offers-table { width:100%; border-collapse:collapse; }
.offers-table th {
  font-family:'Fira Mono',monospace; font-size:10px;
  color:var(--text-muted); text-transform:uppercase;
  letter-spacing:.08em; padding:4px 6px 6px 0;
  border-bottom:0.5px solid var(--border); text-align:left;
}
.offers-table td {
  padding:7px 6px 7px 0;
  font-size:12px; color:var(--text-sub);
  border-bottom:0.5px solid var(--border-lt);
  vertical-align:middle;
}
.offer-brand {
  font-family:'Fira Mono',monospace; font-size:12px; color:var(--text);
  display:flex; align-items:center; gap:8px;
}
.offer-brand img {
  width:20px; height:20px; object-fit:contain; border-radius:3px;
}
.offer-code {
  font-family:'Fira Mono',monospace; font-size:11px;
  background:var(--accent-dim); border:0.5px solid var(--accent-border);
  padding:2px 8px; border-radius:4px; color:var(--text);
}
.offer-link { color:var(--accent); font-size:12px; }

/* ── note Page ──────────────────────────────────────────── */
.note-grid {
  display:flex; flex-direction:column; gap:10px;
}
.note-card {
  display:flex; gap:12px; align-items:flex-start;
  background:var(--bg-sec); border:0.5px solid var(--border-lt);
  border-radius:8px; padding:10px 12px;
  cursor:pointer; transition:border-color .15s;
  text-decoration:none;
}
.note-card:hover { border-color:var(--accent-border); }

.note-thumb {
  width:56px; height:56px; object-fit:cover;
  border-radius:5px; flex-shrink:0;
  background:var(--border);
}
.note-meta { flex:1; min-width:0; }
.note-title {
  font-size:13px; font-weight:500; color:var(--text);
  line-height:1.5; margin-bottom:5px;
  display:-webkit-box; -webkit-line-clamp:2;
  -webkit-box-orient:vertical; overflow:hidden;
}
.note-footer {
  display:flex; align-items:center; gap:8px;
}
.note-date {
  font-family:'Fira Mono',monospace; font-size:10px; color:var(--text-muted);
}
.note-badge {
  font-family:'Fira Mono',monospace; font-size:9px;
  padding:1px 6px; border-radius:3px;
  text-transform:uppercase; letter-spacing:.06em;
}
.note-badge.free {
  background:var(--accent-dim); color:var(--accent);
  border:0.5px solid var(--accent-border);
}
.note-badge.paid {
  background:rgba(52,56,64,0.06); color:var(--text-muted);
  border:0.5px solid var(--border);
}

/* ── Apps Page ──────────────────────────────────────────── */
.app-card {
  background:var(--bg-sec); border:0.5px solid var(--border-lt);
  border-radius:10px; padding:16px;
  margin-bottom:14px;
}
.app-header { display:flex; align-items:center; gap:12px; margin-bottom:10px; }
.app-icon {
  width:44px; height:44px; border-radius:10px;
  object-fit:contain; background:var(--bg-win);
  border:0.5px solid var(--border-lt);
  display:flex; align-items:center; justify-content:center;
  flex-shrink:0;
}
.app-icon img { width:100%; height:100%; object-fit:contain; border-radius:10px; }
.app-icon svg { width:24px; height:24px; }

.app-info h2 {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:15px; color:var(--text); margin:0 0 3px;
}
.app-status {
  font-family:'Fira Mono',monospace; font-size:10px;
  text-transform:uppercase; letter-spacing:.07em;
}
.app-status.coming { color:var(--text-muted); }
.app-status.live { color:var(--accent); }

.app-catch {
  font-size:12px; color:var(--text-muted);
  font-style:italic; margin-bottom:8px;
}
.app-desc { font-size:12px; color:var(--text-sub); line-height:1.75; }

.app-btns { display:flex; gap:8px; margin-top:12px; flex-wrap:wrap; }
.btn-app {
  font-family:'Fira Mono',monospace; font-size:11px;
  padding:6px 14px; border-radius:5px;
  transition:all .15s; display:inline-block;
}
.btn-app.primary {
  background:var(--text); color:#fff;
}
.btn-app.primary:hover { background:var(--accent); }
.btn-app.secondary {
  color:var(--text); border:0.5px solid var(--border);
}
.btn-app.secondary:hover { border-color:var(--accent); color:var(--accent); background:var(--accent-dim); }
.btn-app.disabled {
  opacity:.38; cursor:not-allowed; pointer-events:none;
  background:var(--bg-win); color:var(--text-muted);
  border:0.5px solid var(--border);
}

/* ── Contact Page ───────────────────────────────────────── */
.contact-section { margin-bottom:22px; }
.contact-section h2 {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:14px; color:var(--text); margin-bottom:8px;
  padding-bottom:5px; border-bottom:0.5px solid var(--border-lt);
}

.contact-desc {
  font-size:12px; color:var(--text-sub); line-height:1.85;
  margin-bottom:8px;
}
.contact-mail {
  font-family: 'Fira Mono', monospace;
  font-size: 13px;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  padding: 8px 14px;
  border: 1px solid var(--accent-border, rgba(126,206,196,0.4));
  border-radius: 6px;
  background: var(--accent-dim, rgba(126,206,196,0.12));
  transition: background .15s, border-color .15s;
}
.contact-mail:hover {
  background: rgba(126,206,196,0.22);
  border-color: var(--accent);
}
.contact-mail svg {
  flex-shrink: 0;
  display: block;
  color: var(--accent);
}

/* Creative Works など、ボックス枠のないシンプルなテキストリンク */
.contact-link-plain {
  font-family: 'Fira Mono', monospace;
  font-size: 13px;
  color: var(--accent);
  text-decoration: none;
}
.contact-link-plain:hover {
  text-decoration: underline;
}

/* Achievements table */
.achievements-table { width:100%; border-collapse:collapse; }
.achievements-table th {
  font-family:'Fira Mono',monospace; font-size:10px;
  color:var(--text-muted); text-transform:uppercase;
  letter-spacing:.08em; padding:4px 0 6px;
  border-bottom:0.5px solid var(--border); text-align:left;
}
.achievements-table td {
  padding:6px 4px 6px 0; font-size:11px; color:var(--text-sub);
  border-bottom:0.5px solid var(--border-lt);
  vertical-align:top;
}
.achievements-table td:first-child {
  font-family:'Fira Mono',monospace; font-size:10px;
  color:var(--text-muted); white-space:nowrap;
}
.achievements-table td a { color:var(--accent); }

/* ── Contact: <details id="achievements"> 折りたたみ実績 ── */
.achievements-details {
  border: 0.5px solid var(--border);
  border-radius: 10px;
  background: var(--bg-sec);
  padding: 14px 16px;
  transition: background .15s, border-color .15s;
}
.achievements-details:hover {
  background: var(--accent-dim);
  border-color: var(--accent-border);
}
.achievements-details > summary {
  list-style: none;
  cursor: pointer;
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 12px;
  outline: none;
}
.achievements-details > summary::-webkit-details-marker { display: none; }
.achievements-details > summary::marker { content: ''; }
.achievements-toggle {
  font-family: 'Fira Mono', monospace;
  font-size: 0;
  color: var(--accent);
  white-space: nowrap;
  flex-shrink: 0;
}
.achievements-toggle::before { font-size: 11px; }
.achievements-details[open] .achievements-toggle::before { content: '▴ 折りたたむ'; }
.achievements-details:not([open]) .achievements-toggle::before { content: '▾ クリックで展開'; }
.achievements-body { padding: 14px 0 0; }
.achievements-details[open] .achievements-body {
  padding: 14px 16px 16px;
  margin: 0 -16px -14px;
  border-top: 0.5px dashed var(--border-lt);
}

/* ── Privacy Page ───────────────────────────────────────── */
.privacy-body {
  padding:22px 26px; overflow-y:auto;
  height:100%;
  scrollbar-width:thin;
  scrollbar-color:var(--border) transparent;
}
.privacy-body::-webkit-scrollbar { width:4px; }
.privacy-body::-webkit-scrollbar-thumb { background:var(--border); }
.privacy-body h1 {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:20px; color:var(--text); margin-bottom:16px;
}
.privacy-body h2 {
  font-family:'Manrope',sans-serif; font-weight:800;
  font-size:13px; color:var(--text); margin:18px 0 6px;
}
.privacy-body p {
  font-size:12px; color:var(--text-sub); line-height:1.85;
}
.privacy-last {
  font-family:'Fira Mono',monospace; font-size:10px;
  color:var(--text-muted); margin-top:4px;
}
.privacy-body a { color:var(--accent); }
.privacy-table { width:100%; border-collapse:collapse; margin-top:6px; }
.privacy-table td {
  padding:5px 0; font-size:12px; color:var(--text-sub);
  border-bottom:0.5px solid var(--border-lt); vertical-align:top;
}
.privacy-table td:first-child {
  font-family:'Fira Mono',monospace; font-size:10px;
  color:var(--text-muted); width:140px;
}

/* ── Folder Dock ────────────────────────────────────────── */
.icon-dock {
  position:fixed;          /* fixed so JS can use viewport coords */
  top:50%; transform:translateY(-50%);
  display:flex; flex-direction:column;
  align-items:center; gap:10px;
  z-index:30;
  /* left is set dynamically in common.js to track window right edge */
}
.dock-icon {
  display:flex; flex-direction:column; align-items:center;
  cursor:pointer;
  transition:transform .15s ease;
}
.dock-icon:hover { transform:scale(1.06); }
.dock-icon svg { display:block; }
.dock-label {
  font-family:'Fira Mono',monospace; font-size:9px;
  color:var(--text-muted); margin-top:2px;
  text-align:center;
}
.dock-icon.active .dock-label { color:var(--accent); }

/* ── Taskbar ────────────────────────────────────────────── */
.taskbar {
  position:fixed; bottom:0; left:0; right:0;
  height:40px;
  background:var(--bg-bar);
  border-top:0.5px solid var(--border);
  display:flex; align-items:center;
  padding:0 14px;
  z-index:100; gap:2px;
}
.taskbar-logo {
  width:22px; height:22px; object-fit:contain;
  margin-right:10px; flex-shrink:0;
}
.taskbar-nav {
  display:flex; align-items:center; gap:2px;
  flex:1;
}
.taskbar-nav a {
  font-family:'Fira Mono',monospace; font-size:11px;
  color:var(--text-muted); padding:3px 8px; border-radius:4px;
  transition:background .15s; white-space:nowrap;
}
.taskbar-nav a:hover { background:var(--accent-dim); color:var(--text); }
.taskbar-nav a.active { background:var(--accent-dim); color:var(--text); }

.taskbar-right {
  display:flex; align-items:center; gap:10px;
  margin-left:auto; flex-shrink:0;
}

/* Footer content in taskbar right */
.taskbar-footer-txt {
  display:flex; align-items:center; gap:6px;
  font-family:'Fira Mono',monospace; font-size:10px;
  color:var(--text-muted);
}
.taskbar-footer-txt a:hover { color:var(--text); }
.taskbar-footer-sep {
  color:var(--border); font-size:11px;
}

.taskbar-sns {
  display:flex; align-items:center; gap:5px;
  margin-left:8px; /* navの右隣・左詰め */
  flex-shrink:0;
}
.taskbar-sns a {
  display:flex; align-items:center;
  color:var(--text-muted); opacity:.65;
  transition:opacity .15s;
}
.taskbar-sns a:hover { opacity:1; }
.taskbar-sns svg { display:block; }

.taskbar-clock {
  font-family:'Fira Mono',monospace; font-size:12px;
  color:var(--text-sub); white-space:nowrap; min-width:48px;
  text-align:right;
}

/* ── Drawer ─────────────────────────────────────────────── */
.drawer {
  position:fixed; inset:0;
  background:rgba(232,234,237,0.97);
  backdrop-filter:blur(28px);
  -webkit-backdrop-filter:blur(28px);
  z-index:500;
  display:flex; align-items:center; justify-content:center;
  opacity:0; pointer-events:none;
  transition:opacity .25s ease;
}
.drawer.open { opacity:1; pointer-events:all; }

.drawer-close {
  position:absolute; top:18px; right:18px;
  padding:8px; color:var(--text);
}
.drawer-nav {
  display:flex; flex-direction:column;
  align-items:center; gap:18px;
}
.drawer-nav a {
  font-family:'Fira Mono',monospace; font-size:20px;
  color:var(--text); letter-spacing:.08em;
  transition:color .15s;
}
.drawer-nav a:hover { color:var(--accent); }

/* ── Custom Cursor ──────────────────────────────────────── */
#cursor-canvas {
  position:fixed; inset:0;
  pointer-events:none; z-index:9998;
}

/* ── Page transition (main-window / home-stage をふわっとフェード) ── */
@keyframes pageIn {
  from { opacity: 0; transform: translateX(-50%) scale(0.985); }
  to   { opacity: 1; transform: translateX(-50%) scale(1); }
}
@keyframes pageOut {
  from { opacity: 1; transform: translateX(-50%) scale(1); }
  to   { opacity: 0; transform: translateX(-50%) scale(0.99); }
}
.main-window.page-entering,
.home-stage.page-entering {
  animation: pageIn 0.4s cubic-bezier(0.2, 0.9, 0.3, 1) both;
}
.main-window.page-leaving,
.home-stage.page-leaving {
  animation: pageOut 0.22s cubic-bezier(0.6, 0, 0.8, 0.2) both;
}

/* ── Scroll to top btn ──────────────────────────────────── */
.scroll-top {
  position:fixed; bottom:56px; right:16px;
  width:32px; height:32px;
  background:var(--bg-bar); border:0.5px solid var(--border);
  border-radius:6px; display:none; align-items:center; justify-content:center;
  cursor:pointer; z-index:50; transition:opacity .2s;
}
.scroll-top.visible { display:flex; }
.scroll-top img { width:16px; height:16px; image-rendering:pixelated; }

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width:768px) {
  /* モバイル統一: body/html をスクロール可能に (HOME と同じ挙動) */
  html, body { overflow: auto !important; }
  /* .desktop を静的配置に (非HOMEの浮いたウィンドウ解除) */
  body .desktop { position: static !important; overflow: visible !important; }
  /* main-window を edge-to-edge に (HOME と同じ感じ) */
  body .main-window {
    position: static !important;
    top: auto !important; left: 0 !important; right: 0 !important; bottom: auto !important;
    width: 100% !important; max-width: none !important;
    transform: none !important;
    border: 0 !important; border-radius: 0 !important; box-shadow: none !important;
    overflow: visible !important;
  }
  /* タイトルバー + 旧☆ボタンは新トップバーで置き換え */
  body .win-titlebar,
  body .win-drawer-btn-star { display: none !important; }

  /* モバイル: win-addressbar は各ウィンドウ内の自然な位置 (static) に留める。
     固定は home-mobile-topbar だけ。addressbar までスクロール追従が必要なら次回調整。 */

  .main-window {
    left:8px; right:8px;
    transform:none;
    width:auto; max-width:none;
  }
  /* loader もモバイル main-window と同じ位置 */
  .loader {
    top: max(12px, env(safe-area-inset-top));
    bottom: 6px;
    left: 6px; right: 6px;
    transform: none;
    width: auto;
    max-width: none;
    border-radius: 14px;
  }
  .icon-dock { display:none; }
  .split-layout { flex-direction:column; }
  .split-char { width:100%; height:180px; }
  .split-content { width:100%; }
  .home-char-wrap { width:100%; }
  .taskbar-footer-txt { display:none; }
}
@media (max-width:480px) {
  .main-window { left:4px; right:4px; }
  .taskbar { padding:0 8px; }
  .taskbar-sns a:nth-child(n+4) { display:none; }
}

/* ── Status Panel / Widget System ───────────────────────────
   Profile ページおよび将来的に他ページでも使うウィジェットベースの
   統計ダッシュボード。大ウィジェット（.widget-large）と小ウィジェット
   （.widget-small）の2種類で構成される。                          */
.status-panel {
  font-family: 'Fira Mono', monospace;
  max-width: 560px;
  margin: 16px auto 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* 共通: ウィジェットヘッダ（セクションラベル） */
.widget-head {
  font-family: 'Fira Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 10px;
}

/* 大ウィジェット */
.widget-large {
  background: var(--bg-sec);
  border-radius: 10px;
  padding: 20px 22px;
}
.widget-large .widget-head:not(:first-child) {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 0.5px solid var(--border-lt);
}

/* KPI: 主要数値を Manrope 800 / 34px で大きく */
.widget-kpi {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
  font-family: 'Fira Mono', monospace;
}
.kpi-value {
  font-family: 'Fira Mono', monospace;
  font-weight: 600;
  font-size: 34px;
  line-height: 1;
  color: var(--text);
  letter-spacing: -0.015em;
  font-variant-numeric: tabular-nums;
}
.kpi-value.placeholder {
  color: var(--text-muted);
  font-weight: 500;
}
.kpi-unit {
  font-family: 'Fira Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

/* ツリー (├─ biso, └─ bisotube) */
.widget-tree {
  margin-top: 12px;
  padding-left: 2px;
  font-family: 'Fira Mono', monospace;
}
.tree-row {
  display: flex;
  justify-content: space-between;
  padding: 3px 0;
  font-family: 'Fira Mono', monospace;
  font-size: 14px;
  align-items: baseline;
  font-variant-numeric: tabular-nums;
}
.tree-row span:first-child { color: var(--text-sub); }
.tree-row span:last-child {
  color: var(--text);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.tree-row span:last-child.placeholder {
  color: var(--text-muted);
  font-weight: 400;
}

/* tree-row をリンクにした時のスタイル (PR DEALS → contact.html#achievements など) */
.tree-row-link {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: background .15s, color .15s;
  border-radius: 4px;
  padding-left: 6px;
  padding-right: 6px;
  margin-left: -6px;
  margin-right: -6px;
}
.tree-row-link:hover {
  background: rgba(126,206,196,0.10);
}
.tree-row-link:hover span:first-child { color: var(--accent); }
.tree-row-link:hover span:last-child  { color: var(--accent); }

/* ↗ アイコン: HP全体でリンクの視覚記号として共通利用 */
.link-arrow {
  color: var(--accent) !important;
  font-size: 12px;
  margin-left: 2px;
  letter-spacing: 0;
}

/* 1行コンパクトセクション: widget-large 内でラベル左・値右に配置
   （例: YOUTUBE の下の PR DEALS 行）
   2026-04-20as: PR DEALS は YOUTUBE Total の関連情報として、線で区切らず
   同じ流れに自然に並べる (Rena指示)。線は一切付けない。 */
.widget-row-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-top: 14px;
  text-decoration: none;
  color: inherit;
  transition: color .15s;
}
.widget-row-line .widget-head {
  margin: 0;
  padding: 0;
  border: none;
}
.widget-row-val {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  font-family: 'Fira Mono', monospace;
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.widget-row-sublabel {
  color: var(--text-sub);
  font-size: 12px;
  letter-spacing: 0.02em;
}
.widget-row-val .placeholder { color: var(--text-muted); font-weight: 400; }
.widget-row-line:hover .widget-head,
.widget-row-line:hover .widget-row-sublabel,
.widget-row-line:hover #stat-pr { color: var(--accent); }

/* 詳細ページへの誘導リンク（PR DEALS → contact.html#achievements など） */
.see-details-link {
  display: inline-block;
  margin-top: 6px;
  padding: 2px 0;
  font-family: 'Fira Mono', monospace;
  font-size: 12px;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.04em;
  transition: opacity .15s;
}
.see-details-link:hover {
  opacity: 0.65;
  text-decoration: underline;
}

/* 小ウィジェットセクション */
.widget-section .widget-head { margin-bottom: 8px; }
.widget-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

/* 小ウィジェット */
.widget-small {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 12px 6px 10px;
  background: var(--bg-sec);
  border-radius: 8px;
  text-align: center;
  min-height: 70px;
}
.widget-small-mark {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 14px;
  line-height: 1;
  color: var(--accent);
  opacity: .88;
}
.widget-small-num {
  font-family: 'Fira Mono', monospace;
  font-weight: 500;
  font-size: 16px;
  line-height: 1.1;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.widget-small-num.placeholder { color: var(--text-muted); font-weight: 500; }
.widget-small-name {
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  font-family: 'Fira Mono', monospace;
}

/* フッター: src + updated (ノイズ的情報なので極力目立たなく)
   2026-04-20as: Rena指示で更に控えめに、opacity を下げてノイズレベルに */
.status-foot {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 0.5px solid var(--border-lt);
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 9px;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  opacity: 0.5;
  font-weight: 400;
}
.status-foot .status-src {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* モバイル: 小ウィジェット 4列→2列、KPI 少し縮める */
@media (max-width: 768px) {
  .widget-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .kpi-value { font-size: 28px; }
  .widget-small-num { font-size: 16px; }
}

/* ── Widget grid variant: 3-column (note, etc.) ────────────── */
.widget-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
@media (max-width: 768px) {
  .widget-grid-3 { grid-template-columns: repeat(3, 1fr); gap: 6px; }
}

/* 2列グリッド (APPS: Ochiba Active/Online now 用) */
.widget-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
@media (max-width: 768px) {
  .widget-grid-2 { grid-template-columns: repeat(2, 1fr); gap: 6px; }
}

/* Online now: pulse dot (Ochiba リアルタイム用) */
.online-pulse {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  margin-right: 5px;
  vertical-align: 1px;
  animation: homeNowPulse 2s ease-in-out infinite;
}

/* ================================================================
   HOME v2 — Frameless dashboard (proto-b6 base)
   ================================================================ */

body.home-body-v2 { overflow: hidden; background: var(--bg-desk); }
body.home-body-v2 .loader { display: none; }

/* キャラ表示: 白背景除去、Scene2_sbs.mp4 は canvas描画なのでvideoタグ自体は見えない */
body.home-body-v2 .home-char-wrap {
  background: transparent !important;
}
body.home-body-v2 .home-char-video {
  background: transparent !important;
}

/* HOME ドット背景 (taskbarが無いためstyle変更) */
body.home-body-v2 .desk-stars,
body.home-body-v2 .win-drawer-btn-star,
body.home-body-v2 .taskbar { display: none !important; }
/* PC 時 home-data-col 内の mobile-footer は非表示 (モバイル時の mobile-home-window
   内の mobile-footer は @media 内で明示的に表示する) */
body.home-body-v2 .home-data-col .mobile-footer { display: none !important; }

/* 背景の星 */
.home-stars {
  position: fixed; inset: 0;
  pointer-events: none; z-index: 1;
}
.home-star {
  position: absolute;
  width: 14px; height: 14px;
  color: var(--accent); opacity: 0.4;
}
.home-star.s1 { top: 44px; left: 56px; }
.home-star.s2 { top: 84px; right: 144px; }
.home-star.s3 { bottom: 80px; left: 30%; }
.home-star.s4 { bottom: 120px; right: 120px; opacity: 0.25; }

/* Mobile topbar (HOMEのみ) */
.home-mobile-topbar { display: none; }

/* 🖥 Main stage (PC) — v4: 中央キャラ + 5フロートウィンドウ (placeholder) */
.home-stage {
  position: fixed;
  top: 36px;
  bottom: 40px;
  left: calc(50% - 37px);
  transform: translateX(-50%);
  width: calc(100% - 80px - 74px);
  max-width: 880px;
  z-index: 2;
  display: block;
  overflow: visible;
  transform-origin: center center;
  will-change: transform;
}

/* キャラ: ステージ内で絶対配置、底辺揃え・水平中央 */
.home-char-col {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  overflow: hidden;
}
.home-char-wrap {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  height: 100%;
  width: auto;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  /* drop-shadow 削除: 新アバター動画は背景焼き込みのため、影をかけると四角い枠に影が落ちる
     2026-04-28 (bf) */
}
.home-char-video {
  height: 100%;
  width: auto;
  max-width: none;
  object-fit: contain;
  object-position: center bottom;
  display: block;
}

/* モバイル専用コンテンツは デスクトップ 非表示 */
.home-data-col {
  display: none;
}

/* ── 🪟 Widget base (mini-window 風) ──────────────── */
.home-widget {
  position: absolute;
  background: rgba(255,255,255,0.93);
  border: 0.5px solid var(--border-lt);
  border-radius: 8px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: transform .2s ease, border-color .15s, box-shadow .2s ease;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 8px rgba(52,56,64,0.04);
}
.home-widget:hover {
  border-color: var(--accent-border);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(52,56,64,0.08);
}
.hw-titlebar {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 22px;
  padding: 0 10px;
  background: var(--bg-sec);
  border-bottom: 0.5px solid var(--border-lt);
  flex-shrink: 0;
}
.hw-dots {
  display: inline-flex; gap: 4px; align-items: center;
  flex-shrink: 0;
}
.hw-dots i {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--text-muted); opacity: 0.3;
  display: block;
}
.hw-dots i:first-child {
  background: var(--accent); opacity: 0.55;
}
.hw-label {
  font-family: 'Fira Mono', monospace;
  font-size: 9px;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hw-body {
  padding: 10px 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}
.hw-placeholder-body {
  align-items: center;
  text-align: center;
}
.hw-ph-title {
  font-family: 'Manrope', sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: var(--text);
}
.hw-ph-desc {
  font-family: 'Fira Mono', monospace;
  font-size: 10px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ── 7-widget positioning (絶対座標、ステージ基準) ────────
   v7: W7 を下中央から外し、左中央オフセットに配置。
   全ウィジェットを情報量に合わせたサイズに調整。
   - 上2 (W1/W2): 最新動画、横長
   - 中上2 (W3/W6): YT節目 / SNS、左右ペア
   - HL  : biso ロゴ (左上・大型装飾) — 画像 + サブタイトル
   - W_YT: YOUTUBE TOTAL subs (左下)
   - W_REC: Recent 最新動画 (右上)
   - W_SOC: SOCIAL 4セル (右中)
   - W_MIL: マイルストーン 2行 (右下)
   ウィンドウは「キャラを取り囲まない」「左右ブロックで明確に分離」。
*/

/* ── HL: biso ロゴウィンドウ (装飾、リンクなし) ── */
.home-logo-window {
  position: absolute;
  top: 40px;
  left: 18px;
  width: 360px;
  z-index: 4;
  pointer-events: none;
}
.home-logo-img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 180px;
  object-fit: contain;
  object-position: left center;
}
.home-logo-sub {
  margin: 6px 0 0 4px;
  font-family: 'Fira Mono', monospace;
  font-size: 13px;
  letter-spacing: 0.10em;
  color: var(--accent);
  font-weight: 500;
}

/* ── W_YT: YOUTUBE TOTAL + Milestone 統合 (左下・縦長) ── */
.hw-yttotal {
  top: auto; bottom: 30px; left: 18px;
  width: 340px; height: 250px;
  z-index: 5;
}
.hw-yttotal-body {
  padding: 12px 16px 14px;
  justify-content: flex-start;
  gap: 8px;
}
.hw-kpi-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.hw-kpi-value {
  font-family: 'Fira Mono', monospace;
  font-size: 28px;
  font-weight: 600;
  line-height: 1;
  color: var(--text);
  letter-spacing: -0.02em;
}
.hw-kpi-unit {
  font-family: 'Fira Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}
.hw-yttotal-tree {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 2px;
}
.hw-yttotal-tree .tree-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-family: 'Fira Mono', monospace;
  font-size: 11.5px;
}
.hw-yttotal-tree .tree-line span:first-child { color: var(--text-sub); }
.hw-yttotal-tree .tree-line span:last-child {
  color: var(--text);
  font-weight: 500;
}
.hw-yttotal-divider {
  height: 0.5px;
  background: var(--border-lt);
  margin: 4px 0 2px;
}
.hw-mile-inline {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* ── W_REC: Recent 最新動画 (右上) ── */
.hw-recent {
  top: 40px; right: 18px;
  width: 340px; height: 120px;
  z-index: 5;
}
.hw-recent-body {
  padding: 10px;
  flex-direction: row;
  gap: 10px;
  align-items: stretch;
}
.hw-recent-thumb {
  width: 130px;
  flex-shrink: 0;
  background: var(--bg-sec);
  overflow: hidden;
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
}
.hw-recent-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.hw-recent-text {
  flex: 1;
  padding: 2px 4px 2px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow: hidden;
  justify-content: center;
  min-width: 0;
}
.hw-recent-title {
  font-size: 11.5px;
  line-height: 1.4;
  color: var(--text);
  font-weight: 500;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.hw-recent-meta {
  font-family: 'Fira Mono', monospace;
  font-size: 10px;
  color: var(--text-muted);
}

/* ── W_SOC: SOCIAL 4セル (右中) ── */
.hw-social {
  top: 186px; right: 18px;
  width: 340px; height: 140px;
  z-index: 5;
}
.hw-social-body {
  padding: 10px 12px;
}
/* .hw-social-grid/cell/mark/num/name は widget-small 構造に移行したため削除 (20260420ae) */
/* Profile と同じ .widget-grid-4 / .widget-small を内部で使う。
   HOME の SOCIAL ウィンドウは高さ 140px 制約があるので widget-small を小さめに調整 */
.hw-social-body .widget-grid-4 {
  gap: 6px;
  height: 100%;
}
.hw-social-body .widget-small {
  padding: 8px 4px 6px;
  min-height: 0;
  gap: 3px;
}

/* ── W_OCHIBA: Ochiba カード (SOCIAL の下、apps.html と同じ app-card デザイン)
   2026-04-20as: 2ボタン追加 (使ってみる / noteで読む)、min-height 拡張 */
.hw-ochiba {
  top: 346px; right: 18px;
  width: 340px; height: auto;
  min-height: 220px;
  z-index: 5;
}
.hw-ochiba-body {
  padding: 12px 14px;
}
.hw-ochiba .app-header {
  margin-bottom: 6px;
}
.hw-ochiba .app-icon {
  width: 36px; height: 36px; border-radius: 8px;
}
.hw-ochiba .app-info h2 {
  font-size: 13px;
}
.hw-ochiba .app-status {
  font-size: 9px;
}
.hw-ochiba .app-catch {
  font-size: 11px; margin-bottom: 4px;
}
.hw-ochiba .app-desc {
  font-size: 11px; line-height: 1.5;
}
.hw-ochiba .app-stats {
  margin-top: 8px; padding: 6px 0;
}
.hw-ochiba .app-stat-label {
  font-size: 9px;
}
.hw-ochiba .app-stat-value {
  font-size: 14px;
}
/* 内部ボタンは独立リンクとして動作させるため position:relative で浮かせる */
.hw-ochiba .app-btns { position: relative; z-index: 2; }
.hw-ochiba .app-btns a { position: relative; z-index: 2; }

/* ── マイルストーン行 (YOUTUBE ウィンドウ内に統合) ── */
.hw-mile-row { margin-bottom: 0; }
.hw-mile-title {
  font-family: 'Fira Mono', monospace;
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  margin: 0 0 3px;
  text-transform: uppercase;
}
.hw-mile-title .hw-mile-ch {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  color: var(--text);
  font-size: 12px;
  text-transform: none;
  letter-spacing: 0;
  margin-right: 6px;
}
.hw-mile-svg {
  display: block;
  width: 100%;
  height: 72px;
  max-height: 72px;
}
/* HOME 装飾モード: viewBox 640×40 の小型版。主役(現在値)の引き立て役。 */
.hw-mile-svg-decor {
  height: 32px !important;
  max-height: 32px !important;
}
.hw-mile-decor {
  gap: 10px !important;
  margin-top: 6px;
}

/* ── Starmap SVG 共通スタイル (HOME + youtube.html で共用) ── */
.line-base {
  stroke: var(--border-lt);
  stroke-width: 1;
}
.line-progress {
  stroke: var(--accent);
  stroke-width: 1.5;
}
/* マイルストーン マーカー:
   - star-passed: ● 塗り丸 (通過済み、accent)
   - star-next:   ○ 抜き丸 (次の目標、accent 輪郭のみ)
   - star-future: · 中点 (text、muted) */
.star-passed {
  fill: var(--accent);
}
.star-next {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.5;
}
.star-future {
  fill: var(--text-muted);
  font-family: 'Fira Mono', monospace;
  font-size: 16px;
  opacity: 0.5;
}
/* 現在位置マーカー: ✮ 大きめ塗り (accent、主役)
   進捗ライン上の ● に覆いかぶさる存在感を出すため、他のマーカーより圧倒的に大きく */
.current-star {
  fill: var(--accent);
  font-family: 'Fira Mono', monospace;
  font-size: 32px;
  font-weight: 700;
}
.milestone-label {
  fill: var(--text-muted);
  font-family: 'Fira Mono', monospace;
  font-size: 13px;
}
.milestone-label-next {
  fill: var(--accent);
  font-weight: 700;
}
.current-now {
  fill: var(--accent);
  font-family: 'Fira Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.08em;
  font-weight: 700;
}

/* HOME の .hw-mile-svg 内では starmap SVG が viewBox基準で小さく描画されるので、
   viewBox 内の font-size を大きめに上書き (viewBox 640×80 → 実表示約58px高、縮小率0.72倍) */
.hw-mile-svg .current-star { font-size: 48px; }
.hw-mile-svg .star-future { font-size: 22px; }
.hw-mile-svg .milestone-label { font-size: 20px; }
.hw-mile-svg .current-now { font-size: 16px; }
/* 丸マーカーの半径を HOME 用に拡大 (SVG2: CSS で r 指定可能) */
.hw-mile-svg .star-passed,
.hw-mile-svg .star-next { r: 6; }
.hw-mile-svg .star-next { stroke-width: 2; }

/* HOME 装飾モード (viewBox 640×40): ✮ やマーカー小さめに、控えめな装飾として */
.hw-mile-svg-decor .current-star { font-size: 18px !important; }
.hw-mile-svg-decor .star-future  { font-size: 11px !important; }
.hw-mile-svg-decor .milestone-label { font-size: 12px !important; }
.hw-mile-svg-decor .star-passed,
.hw-mile-svg-decor .star-next    { r: 3 !important; }
.hw-mile-svg-decor .star-next    { stroke-width: 1.5 !important; }

/* HL は装飾なのでホバーなし。ただしクリックアフォーダンスもないので OK */
.home-logo-window:hover { transform: none; box-shadow: none; border-color: transparent; }

/* Hero: biso ✮ OFFICIAL */
.home-hero {
  flex-shrink: 0;
  display: flex; align-items: center; gap: 10px;
  padding: 4px 6px 2px;
}
.home-hero-name {
  font-family: 'Manrope', sans-serif;
  font-size: 22px; font-weight: 800; line-height: 1;
  letter-spacing: -0.01em;
  color: var(--text);
}
.home-hero-star {
  color: var(--accent);
  font-size: 13px;
  line-height: 1;
  animation: starPulse 2.4s ease-in-out infinite;
}
@keyframes starPulse {
  0%, 100% { opacity: 0.7; transform: scale(1); }
  50%      { opacity: 1;   transform: scale(1.15); }
}
.home-hero-tag {
  font-family: 'Fira Mono', monospace;
  font-size: 10px; color: var(--text-muted);
  letter-spacing: 0.3em; text-transform: uppercase;
  font-weight: 500;
}

/* ── 現在地スクリーン: Tagline + "いま" Card + Profile link ── */
.home-tagline {
  flex-shrink: 0;
  font-family: 'Fira Mono', monospace;
  font-size: 12px;
  color: var(--accent);
  margin: 2px 6px 14px;
  letter-spacing: 0.02em;
}
.home-now {
  flex-shrink: 0;
  border: 0.5px solid var(--border-lt);
  border-radius: 12px;
  padding: 16px 18px;
  background: var(--bg-sec);
  display: flex; flex-direction: column;
  gap: 10px;
}
.home-now-head {
  display: flex; align-items: center; gap: 6px;
  font-family: 'Fira Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  padding-bottom: 6px;
  border-bottom: 0.5px dashed var(--border-lt);
}
.home-now-star { color: var(--accent); font-size: 11px; }
.home-now-row {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 10px;
  align-items: baseline;
  text-decoration: none;
  color: inherit;
  padding: 4px 0;
  transition: opacity .15s;
}
.home-now-row:hover { opacity: 0.7; }
.home-now-row-label {
  font-family: 'Fira Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
  display: flex; align-items: center; gap: 6px;
}
.home-now-row-value {
  font-size: 13px;
  color: var(--text);
  font-weight: 500;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  min-width: 0;
}
.home-now-row-meta {
  font-family: 'Fira Mono', monospace;
  font-size: 10px;
  color: var(--text-muted);
  white-space: nowrap;
}
.home-now-pulse {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: homeNowPulse 2s ease-in-out infinite;
}
@keyframes homeNowPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(126,206,196,0.5); }
  50%      { box-shadow: 0 0 0 6px rgba(126,206,196,0); }
}
.home-now-ochiba .home-now-row-value {
  font-family: 'Fira Mono', monospace;
  font-size: 16px;
  color: var(--accent);
  font-weight: 600;
}
.home-more {
  flex-shrink: 0;
  font-family: 'Fira Mono', monospace;
  font-size: 11px;
  color: var(--accent);
  text-decoration: none;
  padding: 8px 6px 0;
  transition: opacity .15s;
  align-self: flex-start;
}
.home-more:hover { opacity: 0.7; }

/* KPI Row */
.home-kpi-row {
  flex-shrink: 0;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 10px;
}

.home-kpi {
  position: relative;
  background: rgba(255,255,255,0.82);
  border-radius: 10px;
  border: 0.5px solid var(--border-lt);
  padding: 14px 16px;
  backdrop-filter: blur(6px);
  display: flex; flex-direction: column;
  gap: 6px;
  transition: transform .15s, border-color .15s;
  overflow: hidden;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}
.home-kpi:hover {
  transform: translateY(-2px);
  border-color: var(--accent-border);
}

.home-kpi-head {
  display: flex; align-items: center; gap: 8px;
  min-width: 0;
}
.home-kpi-icon {
  width: 22px; height: 22px;
  border-radius: 6px;
  background: var(--accent-dim);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}
.home-kpi-icon svg { width: 12px; height: 12px; }
.home-kpi-title {
  font-family: 'Fira Mono', monospace;
  font-size: 10px; color: var(--text-muted);
  letter-spacing: 0.12em; text-transform: uppercase;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  min-width: 0;
}

/* YouTube big card */
.home-kpi-yt { display: flex; flex-direction: column; gap: 8px; }
.home-kpi-yt-total {
  display: flex; align-items: baseline; gap: 8px;
  flex-wrap: wrap;
}
.home-kpi-yt-num {
  font-family: 'Fira Mono', monospace;
  font-size: 26px; font-weight: 500;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.home-kpi-yt-unit {
  font-family: 'Fira Mono', monospace;
  font-size: 10px; color: var(--text-muted);
}
.home-kpi-yt-channels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding-top: 8px;
  border-top: 0.5px solid var(--border-lt);
}
.home-kpi-yt-ch {
  display: flex; flex-direction: column; gap: 2px;
  min-width: 0;
  text-decoration: none;
  color: inherit;
  transition: opacity .15s;
}
.home-kpi-yt-ch:hover { opacity: 0.7; }
.home-kpi-yt-ch-name {
  font-family: 'Fira Mono', monospace;
  font-size: 9px; color: var(--text-muted);
  letter-spacing: 0.04em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.home-kpi-yt-ch-num {
  font-family: 'Fira Mono', monospace;
  font-size: 14px; color: var(--text);
  font-variant-numeric: tabular-nums;
}

/* Small KPI */
.home-kpi-sm { padding: 12px 14px; }
.home-kpi-value {
  font-family: 'Fira Mono', monospace;
  font-size: 20px; color: var(--text);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
  margin-top: auto;
  padding-right: 4px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.home-kpi-sub {
  font-family: 'Fira Mono', monospace;
  font-size: 9px; color: var(--text-muted);
  letter-spacing: 0.04em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* Recent videos */
.home-recent {
  flex: 1;
  min-height: 0;
  background: rgba(255,255,255,0.7);
  border: 0.5px solid var(--border-lt);
  border-radius: 10px;
  padding: 12px 14px;
  backdrop-filter: blur(6px);
  display: flex; flex-direction: column;
  overflow: hidden;
}
.home-recent-head {
  flex-shrink: 0;
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 10px;
}
.home-recent-head-left {
  display: flex; align-items: center; gap: 8px;
  min-width: 0;
}
.home-recent-icon {
  width: 20px; height: 20px;
  border-radius: 5px;
  background: var(--accent-dim);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}
.home-recent-icon svg { width: 11px; height: 11px; }
.home-recent-title {
  font-family: 'Fira Mono', monospace;
  font-size: 10px; color: var(--text-muted);
  letter-spacing: 0.16em; text-transform: uppercase;
}
.home-recent-link {
  font-family: 'Fira Mono', monospace;
  font-size: 10px; color: var(--accent);
  text-decoration: none;
  flex-shrink: 0;
}
.home-recent-link:hover { opacity: 0.7; }

.home-recent-list {
  flex: 1;
  display: flex; flex-direction: column;
  gap: 6px;
  min-height: 0;
  overflow: hidden;
}
.home-video-item {
  flex: 1;
  display: flex; gap: 12px; align-items: center;
  padding: 4px 8px; border-radius: 6px;
  text-decoration: none; color: var(--text);
  transition: background .15s;
  min-height: 0;
}
.home-video-item:hover { background: var(--hover, rgba(198,202,208,0.25)); }
.home-video-item.placeholder { opacity: 0.4; pointer-events: none; }
.home-video-thumb {
  height: 100%; aspect-ratio: 16/9;
  max-height: 56px;
  border-radius: 4px;
  background: linear-gradient(135deg, rgba(126,206,196,0.22), rgba(126,206,196,0.06));
  background-size: cover;
  background-position: center;
  flex-shrink: 0;
  position: relative;
  border: 0.5px solid var(--border-lt);
}
.home-video-info {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column; gap: 2px;
  justify-content: center;
  padding-right: 4px;
}
.home-video-title {
  font-size: 12px; color: var(--text);
  line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.home-video-meta {
  font-family: 'Fira Mono', monospace;
  font-size: 10px; color: var(--text-muted);
  display: flex; gap: 6px; align-items: center;
}
.home-video-ch { font-weight: 600; color: var(--accent); }
.home-video-ch.sub { color: var(--text-sub); font-weight: 500; }

/* Bottom bar (PC) */
.home-bottom-bar {
  position: fixed; bottom: 0; left: 0; right: 0; height: 32px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px;
  font-family: 'Fira Mono', monospace;
  font-size: 10px; color: var(--text-muted);
  z-index: 4;
}
.home-bottom-bar .hbb-logo { color: var(--text-muted); }
.home-bottom-bar .hbb-right {
  display: flex; align-items: center; gap: 12px;
}
.home-bottom-bar .hbb-sns {
  display: flex; gap: 10px;
}
.home-bottom-bar .hbb-sns a {
  color: var(--text-muted); text-decoration: none;
  transition: color .15s;
}
.home-bottom-bar .hbb-sns a:hover { color: var(--text); }
.home-bottom-bar .hbb-sep { color: var(--text-muted); }
.home-bottom-bar .hbb-link {
  color: var(--text-muted); text-decoration: none;
  transition: color .15s;
}
.home-bottom-bar .hbb-link:hover { color: var(--text); }
.home-bottom-bar .hbb-clock {
  font-variant-numeric: tabular-nums;
  margin-left: 4px;
}

/* 🗂 ドック hover 拡張 */
.dock-icon {
  transition: transform .2s ease, background .15s ease, color .15s ease;
}
.dock-icon:hover {
  transform: translateX(-3px);
}

/* ❌ ×ボタン (他ページの titlebar 右端) */
.win-close-btn {
  width: 28px; height: 28px;
  min-width: 28px; /* 押しやすく */
  border-radius: 50%;
  border: 0.5px solid var(--border);
  background: transparent;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  transition: background .15s, color .15s, border-color .15s, transform .2s ease;
  padding: 0;
  margin-left: auto;
}
.win-close-btn:hover {
  background: var(--accent-dim);
  color: var(--accent);
  border-color: var(--accent-border);
  transform: rotate(90deg);
}
.win-close-btn svg { width: 12px; height: 12px; }

/* ================================================================
   Mobile HOME (max-width: 768px) — 他ページと同じ main-window 構造を採用
   - PC 時: .mobile-home-window は非表示、.home-stage を表示
   - Mobile 時: .home-stage を非表示、.mobile-home-window を表示
   ================================================================ */

/* PC 時: mobile-home-window は非表示 */
.mobile-home-window { display: none; }

@media (max-width: 768px) {
  /* body の overflow を強制的に auto に (PC 用 home-body-v2 の overflow:hidden を上書き)
     + fixed ヘッダー (home-mobile-topbar 48px) 分のトップパディング
     ※ win-addressbar は sticky なのでパディング加算不要 (main-window 内に占有) */
  html, body, body.home-body-v2 { overflow: auto !important; height: auto !important; }
  body { padding-top: 48px; }
  body.home-body-v2 { padding-top: 48px !important; }

  /* 星装飾を非表示 */
  .home-stars { display: none !important; }

  /* PC 用要素を完全非表示 (ドック、bottom-bar、stage、home-char-col、home-data-col、ローダー) */
  body.home-body-v2 .icon-dock,
  body.home-body-v2 .home-stage,
  body.home-body-v2 .home-char-col,
  body.home-body-v2 .home-data-col,
  body.home-body-v2 .home-bottom-bar,
  body.home-body-v2 .loader {
    display: none !important;
  }

  /* モバイル HOME: home-mobile-topbar は表示 (他ページと同じ星型メニュー) */
  .home-mobile-topbar { display: grid !important; }

  /* モバイル HOME 専用ウィンドウ表示 (通常の block flow でスクロール) */
  .mobile-home-window {
    display: flex !important;
    position: static !important;
    top: auto !important; left: auto !important; right: auto !important; bottom: auto !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    overflow: visible !important;
    flex-direction: column !important;
    background: var(--bg-win);
    min-height: calc(100vh - 48px); /* home-mobile-topbar 高さ 48px 引く (addressbar は sticky で占有) */
  }

  /* mobile-home-window 内の win-titlebar は非表示 (他ページと同じ運用) */
  .mobile-home-window .win-titlebar { display: none !important; }

  /* win-addressbar は表示 (家マーク + URL、他ページと同じ) */
  .mobile-home-window .win-addressbar { display: flex !important; }

  /* mobile-home-window 内は通常の block flow */
  .mobile-home-window .window-body {
    flex: 1 1 auto !important;
    overflow: visible !important;
    display: block !important;
  }

  /* モバイル HOME 縦積みスタック (通常の block flow、padding 管理) */
  .mobile-home-stack {
    display: block;
    padding: 20px 20px 24px;
  }
  .mobile-home-stack > section {
    margin-bottom: 18px;
  }
  .mobile-home-stack > hr.section-divider {
    margin: 18px 0;
  }

  /* モバイル biso ロゴセクション (トップ) */
  .mobile-logo-section {
    text-align: center;
    padding: 4px 0 8px;
  }
  .mobile-logo-img {
    display: block;
    margin: 0 auto;
    max-width: 260px;
    width: 100%;
    height: auto;
  }
  .mobile-logo-sub {
    margin: 10px 0 0;
    font-family: 'Fira Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.10em;
    color: var(--accent);
    font-weight: 500;
    text-align: center;
  }

  /* モバイル キャラクター動画セクション (ロゴ直下、背景白) */
  .mobile-char-section {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    padding: 12px 0;
    background: #ffffff;
    border-radius: 8px;
    overflow: hidden;
    min-height: 320px;
  }
  .mobile-char-video {
    display: block;
    width: auto;
    max-width: 100%;
    max-height: 420px;
    height: auto;
    object-fit: contain;
    object-position: center bottom;
    background: #ffffff;
  }

  /* モバイル マイルストーン (YOUTUBE ウィジェット内、装飾モード) */
  .mobile-mile-wrap {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 0.5px dashed var(--border-lt);
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  /* モバイル "YouTube ページへ" CTA */
  .mobile-home-cta {
    display: block;
    margin-top: 12px;
    padding: 10px 14px;
    text-align: center;
    font-family: 'Fira Mono', monospace;
    font-size: 12px;
    color: var(--accent);
    text-decoration: none;
    border: 0.5px solid var(--accent-border);
    border-radius: 6px;
    background: var(--accent-dim);
    transition: background .15s, border-color .15s;
  }
  .mobile-home-cta:active {
    background: rgba(126,206,196,0.22);
  }

  /* モバイル Recent カード */
  .mobile-recent-card {
    display: flex;
    gap: 12px;
    padding: 10px;
    border: 0.5px solid var(--border-lt);
    border-radius: 8px;
    background: var(--bg-sec);
    text-decoration: none;
    color: inherit;
    margin-top: 8px;
  }
  .mobile-recent-thumb {
    width: 120px;
    flex-shrink: 0;
    aspect-ratio: 16 / 9;
    border-radius: 4px;
    overflow: hidden;
    background: var(--bg-desk);
  }
  .mobile-recent-thumb img {
    width: 100%; height: 100%; object-fit: cover; display: block;
  }
  .mobile-recent-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
  }
  .mobile-recent-title {
    font-size: 12px;
    line-height: 1.45;
    color: var(--text);
    font-weight: 500;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .mobile-recent-meta {
    font-family: 'Fira Mono', monospace;
    font-size: 10px;
    color: var(--text-muted);
  }

  /* mobile-footer は Profile と同じ扱い (flex 内で下に並ぶ) */
  .mobile-home-window .mobile-footer {
    display: flex !important;
    flex-direction: column; align-items: center;
    padding: 20px 16px max(24px, env(safe-area-inset-bottom));
    font-family: 'Fira Mono', monospace; font-size: 10px;
    color: var(--text-muted); gap: 4px;
    border-top: 1px solid var(--border);
  }
  .mobile-home-window .mobile-footer a {
    color: var(--text-muted); text-decoration: none;
  }

  /* mobile-home-window 内の widget-small-mark は左寄せでなく中央揃え */
  .mobile-home-window .widget-grid-4 .widget-small { align-items: center; }
}

/* ================================================================
   (旧 Mobile HOME) — mobile-a pattern (現在は mobile-home-window に移行)
   ================================================================ */
@media (max-width: 768px) {
  body.home-body-v2 { overflow: auto; }

  /* 星装飾を非表示 */
  .home-stars { display: none; }
  .home-bottom-bar { position: static; }

  /* PC ドックは非表示 */
  body.home-body-v2 .icon-dock { display: none; }

  /* モバイル topbar: 画面最上部に完全固定 (スクロール追従) */
  .home-mobile-topbar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    height: 48px;
    padding: 0 16px;
    background: rgba(255,255,255,0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 0.5px solid var(--border-lt);
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
  }
  .hmtb-time {
    font-family: 'Fira Mono', monospace;
    font-size: 11px; color: var(--text-muted);
    letter-spacing: 0.04em;
    justify-self: start;
  }
  .hmtb-brand {
    display: flex; align-items: center; gap: 6px;
    font-family: 'Manrope', sans-serif;
    font-size: 15px; font-weight: 800;
    color: var(--text);
    justify-self: center;
  }
  .hmtb-brand .hmtb-star {
    color: var(--accent); font-size: 11px;
  }
  .hmtb-menu-btn {
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: var(--accent-dim);
    color: var(--accent);
    border: 0.5px solid var(--accent-border);
    cursor: pointer;
    transition: transform .25s ease, background .15s;
    justify-self: end;
    padding: 0;
  }
  .hmtb-menu-btn:hover,
  .hmtb-menu-btn:active {
    background: rgba(126,206,196,0.22);
    transform: rotate(72deg);
  }
  .hmtb-menu-btn svg {
    width: 18px; height: 18px;
  }

  /* Mobile stage: 縦積み */
  .home-stage {
    position: static;
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow: visible;
    padding-bottom: 0;
  }

  /* デスクトップ用ウィジェットはモバイル非表示 */
  .home-widget { display: none; }
  .home-logo-window { display: none; }

  /* キャラ列: 上部にヒーローとして大きく (モバイル設定復元) */
  .home-char-col {
    position: static;
    height: 340px;
    padding: 20px 0 0;
    background: linear-gradient(180deg, var(--bg-desk) 0%, var(--accent-dim) 100%);
    border-bottom: 0.5px solid var(--border-lt);
    pointer-events: auto;
    display: flex;
    align-items: flex-end;
    justify-content: center;
  }
  .home-char-wrap {
    height: 100%;
    max-width: none;
  }

  /* データ列: モバイルで表示、下に縦積み、14px padding */
  .home-data-col {
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow: visible;
    padding: 14px;
  }

  /* Hero: モバイルではキャラ下の帯として扱う */
  .home-hero {
    padding: 6px 2px;
  }
  .home-hero-name { font-size: 20px; }
  .home-hero-tag { margin-left: auto; }

  /* モバイル: タグライン + "いま"カード + Profile link */
  .home-tagline {
    margin: 0 2px 8px;
    font-size: 13px;
  }
  .home-now {
    padding: 14px 16px;
  }
  .home-now-row {
    grid-template-columns: 60px 1fr auto;
    gap: 8px;
  }
  .home-now-row-value { font-size: 14px; }
  .home-now-ochiba .home-now-row-value { font-size: 17px; }

  /* KPI row: モバイルは YTフルワイド→Apps/note横並び */
  .home-kpi-row {
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: auto;
  }
  .home-kpi.home-kpi-yt {
    grid-column: 1 / -1; /* YouTubeを全幅 */
  }

  /* Recent videos */
  .home-recent {
    flex: initial;
    min-height: 0;
  }
  .home-recent-list {
    flex: initial;
    gap: 10px;
  }
  .home-video-item {
    flex: initial;
  }
  .home-video-thumb {
    max-height: none;
    width: 80px;
    flex-shrink: 0;
  }

  /* Bottom bar: モバイルで可変配置 */
  .home-bottom-bar {
    height: auto;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 16px 20px;
    border-top: 0.5px solid var(--border-lt);
    background: rgba(255,255,255,0.4);
  }
  .home-bottom-bar .hbb-right {
    flex-wrap: wrap; justify-content: flex-start;
  }
  .home-bottom-bar .hbb-clock { display: none; } /* 時刻は topbar に表示済み */
}
