
:root{
  --bg:#f3f4f6;
  --surface:#ffffff;
  --surface-2:#fbfbfc;
  --surface-3:#f6f7fa;
  --text:#121419;
  --muted:#667085;
  --line:#dde2ea;
  --line-strong:#c6ced8;
  --accent:#ff0033;
  --accent-2:#e91d2d;
  --accent-soft:rgba(255,0,51,.08);
  --good:#1f9d55;
  --warn:#d97706;
  --bad:#dc2626;
  --shadow:0 18px 42px rgba(15,23,42,.10);
  --shadow-soft:0 8px 18px rgba(15,23,42,.08);
  --radius:22px;
  --radius-lg:28px;
  --radius-sm:14px;
  --sidebar-w:360px;
  --topbar-h:76px;
  --nav-h:68px;
  color-scheme:light;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  min-height:100vh;
  font-family:Inter,system-ui,-apple-system,"Hiragino Sans","Yu Gothic","Noto Sans JP",sans-serif;
  color:var(--text);
  background:
    radial-gradient(circle at top left, rgba(255,0,51,.05), transparent 26%),
    linear-gradient(180deg,#f8f9fb 0%,#f2f4f7 100%);
}
body.dark{
  --bg:#0b0d12;
  --surface:#151922;
  --surface-2:#161b25;
  --surface-3:#1b2030;
  --text:#eef2f7;
  --muted:#a6afbe;
  --line:#2a3242;
  --line-strong:#3a4457;
  --accent:#ff3b58;
  --accent-2:#ff5773;
  --accent-soft:rgba(255,59,88,.12);
  --good:#4ade80;
  --warn:#fbbf24;
  --bad:#fb7185;
  --shadow:0 24px 54px rgba(0,0,0,.38);
  --shadow-soft:0 12px 24px rgba(0,0,0,.22);
  background:
    radial-gradient(circle at top left, rgba(255,59,88,.08), transparent 26%),
    linear-gradient(180deg,#0c0f15 0%,#090b10 100%);
  color-scheme:dark;
}
button,input,select,textarea{font:inherit}
button{cursor:pointer}
a{text-decoration:none;color:inherit}
::selection{background:rgba(255,0,51,.18)}
.hidden{display:none !important}
.mobile-only{display:none}
.app-shell{
  min-height:100vh;
  display:grid;
  grid-template-rows:auto 1fr auto;
}
.overlay{
  position:fixed;inset:0;
  background:rgba(0,0,0,.34);
  opacity:0;pointer-events:none;
  transition:opacity .2s ease;
  z-index:50;
}
body.sidebar-open .overlay{
  opacity:1;pointer-events:auto;
}
.topbar{
  position:sticky;top:0;z-index:60;
  min-height:var(--topbar-h);
  display:grid;
  grid-template-columns:minmax(280px,1.3fr) minmax(260px,1fr) auto;
  gap:14px;
  align-items:center;
  padding:14px clamp(14px,2vw,24px);
  backdrop-filter:blur(16px);
  background:color-mix(in srgb, var(--surface) 82%, transparent);
  border-bottom:1px solid var(--line);
  box-shadow:0 1px 0 rgba(255,255,255,.04) inset;
}
.topbar-left{
  min-width:0;
  display:flex;
  align-items:center;
  gap:12px;
}
.brand{
  display:flex;
  align-items:center;
  gap:12px;
  min-width:0;
}
.brand-mark{
  flex:0 0 auto;
  width:52px;height:52px;
  border-radius:18px;
  display:grid;place-items:center;
  background:linear-gradient(145deg,var(--accent),var(--accent-2));
  color:#fff;
  font-weight:900;
  letter-spacing:.08em;
  box-shadow:0 16px 30px rgba(255,0,51,.22);
}
.brand-copy{min-width:0}
.eyebrow{
  margin:0 0 2px;
  color:var(--muted);
  font-size:12px;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.brand h1{
  margin:0;
  font-size:clamp(18px,2vw,28px);
  line-height:1.05;
  letter-spacing:-.03em;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.brand h1 span{color:var(--accent)}
.subcopy{
  margin:4px 0 0;
  color:var(--muted);
  font-size:13px;
  line-height:1.4;
}
.searchbar{
  display:flex;
  align-items:center;
  gap:10px;
  min-width:0;
  padding:0 14px;
  height:48px;
  border:1px solid var(--line);
  border-radius:999px;
  background:var(--surface);
  box-shadow:var(--shadow-soft);
}
.searchbar span{color:var(--muted)}
.searchbar input{
  width:100%;
  border:0;
  outline:0;
  background:transparent;
  color:var(--text);
}
.topbar-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  justify-content:flex-end;
}
.main-shell{
  display:grid;
  grid-template-columns:var(--sidebar-w) minmax(0,1fr);
  gap:18px;
  align-items:start;
  padding:18px;
}
.sidebar{
  position:sticky;
  top:calc(var(--topbar-h) + 18px);
  align-self:start;
  max-height:calc(100vh - var(--topbar-h) - 36px);
  overflow:auto;
  padding-right:2px;
}
.sidebar-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:4px 4px 12px;
}
.sidebar-head h2{
  margin:0;
  font-size:24px;
  letter-spacing:-.03em;
}
.panel{
  background:var(--surface);
  border:1px solid var(--line);
  border-radius:var(--radius-lg);
  box-shadow:var(--shadow-soft);
}
.sidebar .panel{padding:16px}
.main{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:16px;
}
.hero{
  padding:18px;
  display:grid;
  grid-template-columns:minmax(0,1.3fr) minmax(320px,.8fr);
  gap:16px;
}
.hero-copy h2{
  margin:0;
  font-size:clamp(26px,3.1vw,44px);
  line-height:1.08;
  letter-spacing:-.05em;
}
.lead{
  margin:12px 0 0;
  color:var(--muted);
  line-height:1.75;
  max-width:70ch;
}
.hero-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:16px;
}
.stats{
  margin-top:16px;
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:12px;
}
.stat{
  padding:14px;
  border-radius:18px;
  background:var(--surface-2);
  border:1px solid var(--line);
}
.stat .label{display:block;color:var(--muted);font-size:12px;margin-bottom:8px}
.stat .value{font-size:20px;font-weight:800;letter-spacing:-.03em}
.hero-side{
  display:grid;
  gap:12px;
}
.hero-side .inner{
  padding:16px;
}
.panel-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  margin-bottom:12px;
}
.panel-head h3{
  margin:0;
  font-size:17px;
  line-height:1.2;
  letter-spacing:-.02em;
}
.panel-head p{margin:4px 0 0}
.badge, .chip{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:700;
  letter-spacing:.02em;
}
.badge.neutral, .chip.neutral{
  background:var(--surface-3);
  color:var(--muted);
  border:1px solid var(--line);
}
.stack{display:grid;gap:10px}
.field-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}
.field{
  display:grid;
  gap:7px;
}
.field span{
  font-size:12px;
  color:var(--muted);
}
.field small{color:var(--muted)}
.field input,.field select{
  width:100%;
  min-width:0;
  min-height:44px;
  padding:0 14px;
  color:var(--text);
  background:var(--surface-2);
  border:1px solid var(--line);
  border-radius:16px;
  outline:none;
  transition:border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.field input:focus,.field select:focus{
  border-color:color-mix(in srgb, var(--accent) 45%, var(--line));
  box-shadow:0 0 0 4px var(--accent-soft);
}
.field input[type="range"]{
  min-height:auto;
  padding:0;
  border:0;
  background:transparent;
  accent-color:var(--accent);
}
.slider-grid{
  display:grid;
  gap:12px;
}
.slider-grid .field{gap:8px}
.chip-wrap{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.chip-option{
  border:1px solid var(--line);
  background:var(--surface-2);
  color:var(--text);
  border-radius:999px;
  min-height:38px;
  padding:0 12px;
  display:inline-flex;
  align-items:center;
  gap:8px;
}
.chip-option[aria-pressed="true"]{
  background:var(--accent);
  border-color:var(--accent);
  color:#fff;
}
.checkline{
  display:flex;
  align-items:center;
  gap:10px;
  color:var(--text);
  padding:11px 12px;
  background:var(--surface-2);
  border:1px solid var(--line);
  border-radius:16px;
}
.checkline input{accent-color:var(--accent)}
.btn,.icon-btn,.tab,.seg,.nav-btn{
  border:1px solid var(--line);
  background:var(--surface-2);
  color:var(--text);
  border-radius:16px;
  transition:transform .15s ease, box-shadow .15s ease, border-color .15s ease, background .15s ease, color .15s ease;
}
.btn:hover,.icon-btn:hover,.tab:hover,.seg:hover,.nav-btn:hover{
  transform:translateY(-1px);
  border-color:var(--line-strong);
}
.btn{
  min-height:44px;
  padding:0 14px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  font-weight:700;
  box-shadow:var(--shadow-soft);
}
.btn.primary{
  background:linear-gradient(145deg,var(--accent),var(--accent-2));
  border-color:transparent;
  color:#fff;
}
.btn.ghost{
  background:var(--surface);
}
.btn.wide{width:100%}
.btn.tiny{
  min-height:34px;
  padding:0 10px;
  border-radius:12px;
  font-size:12px;
}
.icon-btn{
  width:42px;height:42px;
  display:grid;
  place-items:center;
  font-size:18px;
  box-shadow:var(--shadow-soft);
}
.section-tabs{
  display:flex;
  gap:10px;
  overflow:auto;
  padding-bottom:2px;
}
.tab,.seg,.nav-btn{
  min-height:42px;
  padding:0 15px;
  font-weight:700;
  white-space:nowrap;
}
.tab.active,.seg.active,.nav-btn.active{
  background:var(--accent);
  border-color:var(--accent);
  color:#fff;
  box-shadow:0 12px 24px rgba(255,0,51,.16);
}
.view-grid{min-width:0}
.view{display:none;gap:16px}
.view.active{display:grid}
.two-col{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  gap:16px;
}
.feature-card{
  padding:0;
  overflow:hidden;
}
.feature-inner{
  padding:18px;
  display:grid;
  grid-template-columns:minmax(0,1.2fr) minmax(280px,.8fr);
  gap:18px;
}
.banner{
  min-height:260px;
  border-radius:24px;
  padding:22px;
  background:
    radial-gradient(circle at top right, rgba(255,255,255,.14), transparent 30%),
    linear-gradient(135deg, #151821 0%, #22273a 60%, #111318 100%);
  color:#fff;
  border:1px solid rgba(255,255,255,.08);
  box-shadow:0 24px 40px rgba(0,0,0,.18);
  display:flex;
  flex-direction:column;
  justify-content:space-between;
}
.banner-header{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:flex-start;
}
.banner-kicker{
  display:inline-flex;
  padding:6px 10px;
  border-radius:999px;
  background:rgba(255,255,255,.12);
  font-size:12px;
  font-weight:700;
}
.banner-score{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:58px;
  min-height:58px;
  border-radius:20px;
  background:rgba(255,0,51,.86);
  font-size:22px;
  font-weight:900;
  letter-spacing:-.03em;
}
.banner-title{
  margin:14px 0 10px;
  font-size:clamp(22px,2.8vw,34px);
  line-height:1.12;
  letter-spacing:-.04em;
  overflow-wrap:anywhere;
}
.banner-meta{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  color:rgba(255,255,255,.88);
}
.pill{
  display:inline-flex;
  padding:6px 10px;
  border-radius:999px;
  background:rgba(255,255,255,.11);
  border:1px solid rgba(255,255,255,.08);
  font-size:12px;
}
.banner-foot{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:14px;
}
.detail-grid{
  display:grid;
  gap:12px;
}
.detail-card{
  padding:14px;
  border-radius:18px;
  background:var(--surface-2);
  border:1px solid var(--line);
}
.detail-card h4{
  margin:0 0 8px;
  font-size:14px;
}
.detail-card p{
  margin:0;
  color:var(--muted);
  line-height:1.7;
  overflow-wrap:anywhere;
}
.list-cards,.card-stack{
  display:grid;
  gap:10px;
}
.list-item,.stack-item,.mini-item{
  padding:13px 14px;
  border-radius:18px;
  background:var(--surface-2);
  border:1px solid var(--line);
}
.list-item h4,.stack-item h4,.mini-item h4{
  margin:0 0 6px;
  font-size:14px;
  line-height:1.3;
  overflow-wrap:anywhere;
}
.list-item p,.stack-item p,.mini-item p{
  margin:0;
  color:var(--muted);
  line-height:1.6;
  overflow-wrap:anywhere;
}
.timeline{
  display:grid;
  gap:10px;
}
.timeline-item{
  display:grid;
  grid-template-columns:92px minmax(0,1fr);
  gap:12px;
  padding:13px 14px;
  border-radius:18px;
  background:var(--surface-2);
  border:1px solid var(--line);
}
.timeline-time{
  color:var(--accent);
  font-weight:800;
  letter-spacing:.02em;
}
.timeline-title{
  margin:0;
  font-weight:800;
  overflow-wrap:anywhere;
}
.timeline-note{
  margin:4px 0 0;
  color:var(--muted);
  line-height:1.6;
  overflow-wrap:anywhere;
}
.card-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:14px;
}
.video-card{
  display:grid;
  grid-template-rows:auto 1fr;
  border-radius:24px;
  overflow:hidden;
  border:1px solid var(--line);
  background:var(--surface);
  box-shadow:var(--shadow-soft);
  min-width:0;
}
.video-card.selected{
  outline:3px solid var(--accent-soft);
  border-color:var(--accent);
}
.thumb{
  min-height:164px;
  padding:14px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  background:
    linear-gradient(145deg, rgba(255,0,51,.95) 0%, rgba(133,15,34,.96) 52%, rgba(20,22,29,.98) 100%);
  color:#fff;
}
.thumb-top{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px;
}
.thumb-badge,.thumb-score{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:6px 10px;
  border-radius:999px;
  background:rgba(255,255,255,.14);
  backdrop-filter:blur(8px);
  font-size:12px;
  font-weight:800;
}
.thumb-score{min-width:54px}
.thumb-main{
  display:grid;
  gap:8px;
}
.thumb-topic{
  font-weight:900;
  font-size:22px;
  letter-spacing:-.04em;
  line-height:1.05;
  overflow-wrap:anywhere;
}
.thumb-members{
  font-size:13px;
  opacity:.96;
  line-height:1.4;
}
.thumb-foot{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:10px;
}
.card-body{
  padding:14px;
  display:grid;
  gap:10px;
  min-width:0;
}
.card-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:8px;
}
.card-title{
  margin:0;
  font-size:16px;
  line-height:1.35;
  letter-spacing:-.02em;
  overflow-wrap:anywhere;
}
.card-meta{
  margin:0;
  color:var(--muted);
  font-size:13px;
  line-height:1.6;
  overflow-wrap:anywhere;
  white-space:normal;
}
.tag-row{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.tag{
  display:inline-flex;
  align-items:center;
  padding:5px 9px;
  border-radius:999px;
  background:var(--surface-3);
  border:1px solid var(--line);
  color:var(--muted);
  font-size:12px;
}
.card-actions{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.compare-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:14px;
}
.compare-card{
  padding:14px;
  border-radius:20px;
  border:1px solid var(--line);
  background:var(--surface);
  box-shadow:var(--shadow-soft);
}
.compare-card h4{
  margin:0 0 8px;
  font-size:16px;
  overflow-wrap:anywhere;
}
.compare-card p{
  margin:0;
  color:var(--muted);
  line-height:1.6;
  overflow-wrap:anywhere;
}
.metrics-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}
.metric{
  padding:14px;
  border-radius:18px;
  background:var(--surface-2);
  border:1px solid var(--line);
}
.metric .label{display:block;color:var(--muted);font-size:12px;margin-bottom:8px}
.metric .value{display:block;font-size:28px;font-weight:900;letter-spacing:-.04em}
.metric .note{display:block;color:var(--muted);margin-top:6px;line-height:1.5}
.bar-chart{display:grid;gap:10px}
.bar-row{
  display:grid;
  grid-template-columns:110px minmax(0,1fr) 52px;
  gap:10px;
  align-items:center;
}
.bar-name{color:var(--muted);font-size:13px}
.bar-track{
  height:12px;
  border-radius:999px;
  background:var(--surface-3);
  overflow:hidden;
  border:1px solid var(--line);
}
.bar-fill{
  height:100%;
  border-radius:inherit;
  background:linear-gradient(90deg,var(--accent),var(--accent-2));
}
.bar-value{text-align:right;font-weight:800}
.bottom-nav{
  display:none;
  position:sticky;
  bottom:0;
  z-index:55;
  gap:8px;
  padding:10px;
  background:color-mix(in srgb, var(--surface) 88%, transparent);
  border-top:1px solid var(--line);
  backdrop-filter:blur(16px);
}
.nav-btn{
  flex:1 1 0;
  min-height:46px;
  padding:0 10px;
}
.divider{
  height:1px;
  background:var(--line);
  margin:12px 0;
}
.muted{color:var(--muted)}
.flow-list{
  margin:0;
  padding-left:20px;
  display:grid;
  gap:10px;
}
.flow-list li{line-height:1.45}
.sticky-head{
  position:sticky;
  top:calc(var(--topbar-h) + 18px);
  z-index:10;
  padding-top:2px;
  background:linear-gradient(180deg, color-mix(in srgb, var(--surface) 96%, transparent) 0%, var(--surface) 88%);
}
.toolbar{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.segmented{
  display:flex;
  gap:8px;
  padding:6px;
  border-radius:18px;
  background:var(--surface-2);
  border:1px solid var(--line);
}
.seg{
  min-height:34px;
  padding:0 12px;
  border-radius:12px;
}
@media (max-width: 1180px){
  .topbar{
    grid-template-columns:1fr;
    align-items:stretch;
  }
  .topbar-actions{justify-content:flex-start}
  .hero,.feature-inner,.two-col,.compare-grid,.card-grid{
    grid-template-columns:1fr;
  }
  .stats{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width: 980px){
  :root{--sidebar-w:min(92vw,380px);--topbar-h:72px}
  .mobile-only{display:inline-grid}
  .topbar{
    grid-template-columns:1fr;
    padding:12px 12px 10px;
  }
  .searchbar{height:44px}
  .topbar-actions{display:none}
  .main-shell{grid-template-columns:1fr;padding:12px}
  .sidebar{
    position:fixed;
    top:0;left:0;bottom:0;
    width:var(--sidebar-w);
    max-height:none;
    transform:translateX(-102%);
    transition:transform .24s ease;
    z-index:70;
    padding:12px;
    background:color-mix(in srgb, var(--surface) 96%, transparent);
    border-right:1px solid var(--line);
    box-shadow:var(--shadow);
    overflow:auto;
  }
  body.sidebar-open .sidebar{transform:translateX(0)}
  .view{gap:12px}
  .hero{padding:14px}
  .feature-inner{padding:14px}
  .banner{min-height:220px}
  .stats{grid-template-columns:repeat(2,minmax(0,1fr))}
  .card-grid,.metrics-grid{grid-template-columns:1fr}
  .compare-grid{grid-template-columns:1fr}
  .bar-row{grid-template-columns:82px minmax(0,1fr) 44px}
  .bottom-nav{display:flex}
  .section-tabs{display:none}
  .sticky-head{top:12px}
  .timeline-item{grid-template-columns:74px 1fr}
  body.mobile-dense .card-body,
  body.mobile-dense .sidebar .panel{padding:12px}
  body.mobile-dense .thumb{min-height:140px}
}
@media (max-width: 560px){
  .brand-mark{width:44px;height:44px;border-radius:14px}
  .brand h1{font-size:18px}
  .subcopy{font-size:12px}
  .hero-copy h2{font-size:26px}
  .stats{grid-template-columns:1fr}
  .field-grid{grid-template-columns:1fr}
  .timeline-item{grid-template-columns:1fr}
  .banner-score{min-width:50px;min-height:50px;font-size:18px}
  .thumb-topic{font-size:19px}
  .card-title{font-size:15px}
}
