/* 2026-11-27 改版（方案 4 の配置 + 方案 5 の見た目）：ホームの 3 列、コンテストの道のり（journey.js）、スマホの真ん中の「投票」タブ、小さな枠（.home-box）。
 * 数字は Outfit（--fc-font-number）。いまの段階はコーラル（--fc-color-now、サイトでコーラルを使うのはここだけ）、済んだ段階はティール（--fc-color-accent）。
 * 文字リンクは本文色＋下線、状態・タグ・アバターは中性（2026-11-30、unslop 審査 G1）。 */

/* ---------- ヘッダー ---------- */
.site-header nav a.nav-vote {
  display: none;
}

/* ---------- 共通の部品 ---------- */
a.button.outline {
  background: var(--fc-color-surface);
  color: var(--fc-color-text);
  border: 1.5px solid var(--fc-color-border-strong);
}
a.button.outline:hover {
  background: var(--fc-color-surface-sunken);
}
a.button.primary:hover {
  background: var(--fc-color-accent-hover);
  border-color: var(--fc-color-accent-hover);
}
a.button.small {
  padding: 7px 14px;
  font-size: 13px;
  border-radius: var(--fc-radius-md);
}
.home-box {
  background: var(--fc-color-surface);
  border: 1px solid var(--fc-color-border);
  border-radius: var(--fc-radius-lg);
  padding: 14px 16px 16px;
  min-width: 0;
}
.home-box > h2 {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 700;
}
.home-box > h2 a {
  font-size: 12px;
  font-weight: 700;
  color: var(--fc-color-text);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.home-box > h2 a:hover {
  text-decoration: underline;
}

/* ---------- 道のり（journey.js、横：ホームと「コンテスト」の各行） ---------- */
.journey {
  --dot: 22px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) minmax(0, 0.85fr);
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
}
.journey-step {
  position: relative;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 3px;
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
}
/* 前の段とのあいだの線。済んだ段といまの段へは塗る。 */
.journey-step + .journey-step::before {
  content: '';
  position: absolute;
  top: calc(var(--dot) / 2 - 1px);
  right: 50%;
  width: 100%;
  height: 2px;
  background: var(--fc-color-border);
}
.journey-step:is([data-step='done'], [data-step='now'])::before {
  background: var(--fc-color-accent);
}
.journey-step[data-step='after']::before {
  background: repeating-linear-gradient(
    90deg,
    var(--fc-color-border) 0 5px,
    transparent 5px 9px
  );
}
.journey-step i {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: var(--dot);
  height: var(--dot);
  border-radius: 50%;
  background: var(--fc-color-surface);
  border: 2px solid var(--fc-color-border);
  color: var(--fc-color-text-on-accent);
}
.journey-step i svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.journey-step[data-step='done'] i {
  background: var(--fc-color-accent);
  border-color: var(--fc-color-accent);
}
.journey-step[data-step='now'] {
  color: var(--fc-color-text);
}
.journey-step[data-step='now'] i {
  background: var(--fc-color-now);
  border-color: var(--fc-color-now);
  box-shadow: 0 0 0 5px var(--fc-color-now-soft);
}
.journey-step[data-step='next'] {
  color: var(--fc-color-text);
}
.journey-step[data-step='after'] {
  color: var(--fc-color-text-muted);
  font-weight: 500;
}
.journey-step[data-step='after'] i {
  border-style: dashed;
}
.journey-step small {
  font-family: var(--fc-font-number);
  font-weight: 500;
  font-size: 11px;
  color: var(--fc-color-text-muted);
  white-space: nowrap;
}
.journey-step .journey-note {
  font-family: inherit;
  color: var(--fc-color-text);
  white-space: normal;
}
/* 横の道のりでは「公式審査中」と「11/30 発表」の 2 行。 */
.journey-note span {
  display: block;
  white-space: nowrap;
}
.journey-next {
  font-size: 13px;
  color: var(--fc-color-text-muted);
}
.journey-next time {
  white-space: nowrap;
}
.journey-next b,
.contest-mini-when b {
  font-family: var(--fc-font-number);
  font-size: 22px;
  font-weight: 700;
  color: var(--fc-color-text);
  margin: 0 2px;
}

/* ---------- 道のり（縦：コンテストの長い投稿の右側） ---------- */
.journey.is-vertical {
  --dot: 18px;
  grid-template-columns: minmax(0, 1fr);
  margin: 0;
}
.journey.is-vertical .journey-step {
  grid-template-columns: var(--dot) minmax(0, 1fr);
  justify-items: start;
  column-gap: 10px;
  row-gap: 0;
  padding-bottom: 14px;
  text-align: left;
  font-size: 13px;
}
.journey.is-vertical .journey-step:last-child {
  padding-bottom: 0;
}
.journey.is-vertical .journey-step i {
  grid-row: span 2;
}
.journey.is-vertical .journey-step i svg {
  width: 11px;
  height: 11px;
}
.journey.is-vertical .journey-step + .journey-step::before {
  top: auto;
  bottom: calc(100% - 2px);
  left: calc(var(--dot) / 2 - 1px);
  right: auto;
  width: 2px;
  height: 100%;
}
.journey.is-vertical .journey-step[data-step='after']::before {
  background: repeating-linear-gradient(
    180deg,
    var(--fc-color-border) 0 4px,
    transparent 4px 8px
  );
}
.journey.is-vertical .journey-step em {
  margin-left: 6px;
  font-style: normal;
  font-size: 11px;
  color: var(--fc-color-text-on-accent);
  background: var(--fc-color-now);
  border-radius: var(--fc-radius-sm);
  padding: 1px 6px;
}
.journey.is-vertical .journey-step small {
  white-space: normal;
}

/* ---------- ホーム ---------- */
#app:has(> .home) {
  max-width: 1440px;
  padding-top: 28px;
}
.home {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr) 272px;
  grid-template-areas: 'left main right';
  gap: 24px;
  align-items: start;
}
.home-left {
  grid-area: left;
}
.home-main {
  grid-area: main;
  min-width: 0;
}
.home-right {
  grid-area: right;
}
.home-left,
.home-right {
  display: grid;
  gap: 16px;
  min-width: 0;
}
/* 最新のコンテスト */
.home-hero {
  position: relative;
  background: var(--fc-color-surface);
  border: 1px solid var(--fc-color-border);
  border-radius: var(--fc-radius-xl);
  overflow: hidden;
}
.home-hero-cover {
  display: block;
  height: 148px;
  background: var(--fc-color-surface-sunken);
}
.home-hero-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.home-hero-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
  padding: 22px;
}
.home-hero.has-first .home-hero-body {
  grid-template-columns: minmax(0, 1fr) 216px;
}
.home-hero-info {
  display: grid;
  gap: 10px;
  align-content: start;
  min-width: 0;
}
.home-hero-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.home-hero .badge.contest-phase {
  margin: 0;
}
/* 「コンテストの詳細」：バッジの行の右端の静かな文字リンク */
.home-hero-more {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 13px;
  font-weight: 500;
  color: var(--fc-color-text);
  text-decoration: underline;
  text-underline-offset: 3px;
  white-space: nowrap;
}
.home-hero-more svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.home-hero-more:hover {
  text-decoration-thickness: 2px;
}
.home-hero h2 {
  font-size: 30px;
  font-weight: 900;
  line-height: 1.25;
  margin: 0;
  overflow-wrap: anywhere;
}
.home-hero h2 a:hover {
  text-decoration: underline;
}
.home-hero-theme {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.6;
}
.home-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}
.home-hero-actions .button {
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 700;
}
.home-hero-top {
  position: relative;
  display: block;
  align-self: start;
  aspect-ratio: 1;
  border-radius: var(--fc-radius-lg);
  overflow: hidden;
  background: var(--fc-color-surface-sunken);
}
.home-hero-top img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s;
}
.home-hero-top:hover img {
  transform: scale(1.03);
}
.home-hero-top span {
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 2px 9px;
  border-radius: var(--fc-radius-sm);
  background: var(--fc-color-surface);
  color: var(--fc-color-text);
  font-size: 12px;
  font-weight: 700;
}
/* ほかのコンテスト */
.home-minis {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 16px;
}
.contest-mini {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 12px;
  background: var(--fc-color-surface);
  border: 1px solid var(--fc-color-border);
  border-radius: var(--fc-radius-lg);
}
.contest-mini-cover {
  display: block;
  width: 84px;
  height: 84px;
  border-radius: var(--fc-radius-md);
  overflow: hidden;
  background: var(--fc-color-surface-sunken);
}
.contest-mini-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.contest-mini-copy {
  display: grid;
  gap: 4px;
  justify-items: start;
  min-width: 0;
}
.contest-mini .badge.contest-phase {
  margin: 0;
}
.contest-mini h3 {
  font-size: 15px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.contest-mini h3 a:hover {
  text-decoration: underline;
}
.contest-mini-when {
  margin: 0;
  font-size: 12px;
  line-height: 1.5;
}
.contest-mini-when b {
  font-size: 16px;
}
.contest-mini .button {
  margin-top: 4px;
}
/* 投票中の作品 */
.home-goods-title {
  margin: 24px 0 12px;
}
.home-goods-title h2 {
  font-size: 16px;
}
.home-goods-title a {
  font-size: 13px;
  font-weight: 700;
  color: var(--fc-color-text);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.home .home-goods {
  gap: 10px;
}
.home .home-goods-card {
  aspect-ratio: 1;
  border-radius: var(--fc-radius-md);
}
.home .home-goods-card img {
  object-position: 50% 15%;
}
/* 左：マイ作品 */
.home-counts {
  display: grid;
  gap: 8px;
  margin: 0;
}
.home-counts div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
}
.home-counts dd {
  margin: 0;
  font-family: var(--fc-font-number);
  font-size: 20px;
  font-weight: 700;
}
/* 左：コンテスト一覧 */
.home-contest-list {
  display: grid;
  gap: 8px;
}
.contest-line {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  margin: 0 -8px;
  padding: 4px 8px;
  border-radius: var(--fc-radius-md);
  font-size: 13px;
  line-height: 1.35;
}
.contest-line:hover {
  background: var(--fc-color-surface-sunken);
}
.contest-line.is-current {
  background: var(--fc-color-accent-soft);
}
.contest-line img,
.contest-line > i {
  width: 40px;
  height: 40px;
  border-radius: var(--fc-radius-md);
  object-fit: cover;
  background: var(--fc-color-surface-sunken);
}
.contest-line strong {
  display: block;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.contest-line small {
  display: block;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--fc-color-text-muted);
}
.contest-line small::before {
  content: '● ';
  color: var(--st, var(--fc-color-text-muted));
}
.contest-line small[data-phase='voting'] {
  --st: var(--fc-color-status-voting);
}
.contest-line small[data-phase='open'] {
  --st: var(--fc-color-status-recruit);
}
/* 左：Category */
.home-kinds {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.home-kinds a {
  padding: 3px 10px;
  border-radius: var(--fc-radius-sm);
  background: var(--fc-color-surface-sunken);
  font-size: 12px;
  font-weight: 700;
}
.home-kinds a:hover {
  background: var(--fc-color-border);
}
/* 右：活動報告 */
.home-reports {
  display: grid;
  margin: 0;
  padding: 0;
  list-style: none;
}
.home-report {
  position: relative;
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  gap: 10px;
  padding-bottom: 14px;
}
.home-report:last-child {
  padding-bottom: 0;
}
.home-report:not(:last-child)::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 16px;
  bottom: 0;
  width: 2px;
  background: var(--fc-color-border);
}
.home-report > i {
  z-index: 1;
  width: 16px;
  height: 16px;
  margin-top: 2px;
  border-radius: 50%;
  background: var(--fc-color-surface);
  border: 2px solid var(--fc-color-border-strong);
}
.home-report.is-new > i {
  background: var(--fc-color-text);
  border-color: var(--fc-color-text);
}
.home-report a {
  display: grid;
  gap: 1px;
  min-width: 0;
}
/* 本文はふつうの太さ、日付と所属のコンテストは控えめな色（層は太さではなく大きさと色で分ける）。 */
.home-report time {
  font-family: var(--fc-font-number);
  font-size: 11.5px;
  font-weight: 400;
  color: var(--fc-color-text-muted);
}
.home-report strong {
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.home-report a:hover strong {
  text-decoration: underline;
}
.home-report small {
  font-size: 11.5px;
  color: var(--fc-color-text-muted);
}
/* 右：お知らせ（通知センターの行をそのまま小さく） */
.home-news {
  display: grid;
  gap: 2px;
  margin: 0 -8px;
}
.home-news .notify-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 3px;
  padding: 8px;
  border: 0;
  border-radius: var(--fc-radius-md);
  font-size: 12.5px;
  line-height: 1.5;
}
.home-news .notify-item:hover {
  background: var(--fc-color-surface-sunken);
}
.home-news .notify-type {
  justify-self: start;
}
.home-news .notify-item.unread {
  padding-left: 20px;
}
.home-news .notify-item.unread::before {
  left: 7px;
  top: 15px;
}
.home-news .notify-item .notify-text {
  font-size: 12.5px;
}
.home-news .notify-item time {
  grid-column: auto;
  font-family: var(--fc-font-number);
  font-size: 11px;
  color: var(--fc-color-text-muted);
}

/* 1280 未満：左の列はなくし、中身は右の列の下へ */
@media (max-width: 1239px) {
  .home {
    grid-template-columns: minmax(0, 1fr) 260px;
    grid-template-areas: 'main right' 'main left';
    grid-template-rows: auto 1fr;
  }
  .home-left {
    align-self: start;
  }
}
@media (max-width: 1000px) {
  .home {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
    grid-template-areas: 'main' 'right' 'left';
  }
  .home-right,
  .home-left {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    align-items: start;
  }
}

/* ---------- スマホ ---------- */
@media (max-width: 720px) {
  /* 5 つ目のタブ「投票」：ほかのタブと同じ高さ・同じ見た目の 1 マス */
  .site-header nav {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
  .site-header nav a.nav-vote {
    display: flex;
  }
  #app:has(> .home) {
    padding-top: 14px;
  }
  .home {
    gap: 16px;
    grid-template-areas: 'main' 'right' 'left';
  }
  .home-left {
    display: none;
  }
  .home-hero-cover {
    height: 112px;
  }
  .home-hero-body,
  .home-hero.has-first .home-hero-body {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px 12px;
    padding: 16px;
  }
  .home-hero-info {
    display: contents;
  }
  .home-hero-info > :not(.journey, .home-hero-actions) {
    grid-column: 1;
  }
  .home-hero-head {
    margin-bottom: -6px;
  }
  .home-hero h2 {
    font-size: 22px;
  }
  .home-hero-theme {
    display: none;
  }
  .home-hero .journey-next-sep {
    display: none;
  }
  .home-hero .journey-next time {
    display: block;
  }
  .home-hero-top {
    grid-column: 2;
    grid-row: 1 / span 3;
    width: 104px;
  }
  .home-hero-top span {
    left: 6px;
    top: 6px;
    padding: 1px 6px;
    font-size: 10.5px;
  }
  .journey,
  .home-hero-actions {
    grid-column: 1 / -1;
  }
  .home-hero .journey-step small:not(.journey-note) {
    display: none;
  }
  .home-hero-actions .button {
    flex: 1 1 auto;
    justify-content: center;
    padding: 10px 12px;
    white-space: nowrap;
  }
  .home-minis {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: 86%;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    margin: 12px -18px 0;
    padding: 0 18px 4px;
    scroll-padding: 0 18px;
    gap: 12px;
  }
  .contest-mini {
    scroll-snap-align: start;
  }
  .home .home-goods {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }
  .home-right {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- コンテストの長い投稿（pages/thread.js） ---------- */
#app:has(> .contest-page) {
  max-width: 1440px;
  padding-top: 24px;
}
.contest-page {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) 300px;
  grid-template-areas: 'back back back' 'side head panel' 'side main panel';
  grid-template-rows: auto auto 1fr;
  gap: 0 24px;
  align-items: start;
}
.contest-page > .back {
  grid-area: back;
  margin: 0 0 14px;
}
.contest-page > .back::before {
  content: '‹';
  margin-right: 6px;
  font-size: 16px;
}
.contest-page .thread {
  max-width: none;
  margin: 0;
}
.contest-side {
  grid-area: side;
  position: sticky;
  top: calc(var(--header-h) + 16px);
  display: grid;
  gap: 16px;
}
.contest-side-toc nav {
  display: grid;
  gap: 2px;
  margin: 0 -8px;
}
.contest-side-toc a {
  padding: 6px 8px;
  border-radius: var(--fc-radius-md);
  color: var(--fc-color-text-muted);
  font-size: 13px;
  font-weight: 600;
}
.contest-side-toc a:hover {
  background: var(--fc-color-surface-sunken);
  color: var(--fc-color-text);
}
.contest-post-head {
  grid-area: head;
}
.contest-post-head .contest-visual {
  margin-top: 20px;
}
.contest-post-head .contest-overview {
  scroll-margin-top: calc(var(--header-h) + 16px);
}
.contest-post-main {
  grid-area: main;
  margin-top: 16px;
}
.contest-post-main > .body:first-child {
  margin-top: 0;
}
#contest-reports {
  scroll-margin-top: calc(var(--header-h) + 16px);
}
/* 右のパネル */
.contest-panel {
  grid-area: panel;
  display: grid;
  gap: 16px;
}
.contest-panel-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  background: var(--fc-color-surface);
  border: 1px solid var(--fc-color-border);
  border-radius: var(--fc-radius-lg);
}
.contest-panel-card .badge.contest-phase {
  justify-self: start;
  margin: 0;
}
.contest-panel-next {
  display: grid;
  gap: 2px;
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
}
.contest-panel-next strong {
  color: var(--fc-color-text);
  font-size: 14px;
  font-weight: 700;
}
.contest-panel-next strong b {
  font-family: var(--fc-font-number);
  font-size: 32px;
  line-height: 1.1;
  margin-right: 2px;
}
.contest-panel-next time {
  font-size: 12px;
}
.contest-panel-actions {
  display: grid;
  gap: 8px;
}
.contest-panel-actions .button,
.contest-dock .button {
  justify-content: center;
  font-weight: 700;
}
.contest-panel-note {
  margin: -6px 0 0;
  font-size: 12px;
  line-height: 1.6;
}
.contest-panel .contest-top {
  display: grid;
  gap: 10px;
  padding: 0;
  border: 0;
}
.contest-panel .contest-top-title {
  justify-self: start;
  color: var(--fc-color-text);
  font-size: 14px;
}
.contest-panel .contest-top-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.contest-panel .contest-top-entry,
.contest-panel .contest-top-entry[data-rank='1'] {
  width: auto;
}
.contest-panel .contest-top-entry[data-rank='1'] {
  grid-column: span 2;
  grid-row: span 2;
}
.contest-top-rank {
  font-family: var(--fc-font-number);
}
.contest-dock {
  display: none;
}
/* 活動報告：公式の日付つきの返信を縦の時間の線に並べる。いちばん新しいもの（最後）はコーラルの点。 */
.contest-post-main .floors {
  position: relative;
  padding-left: 28px;
}
.contest-post-main .floors:has(> .comment + .comment)::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 30px;
  bottom: 30px;
  width: 2px;
  background: var(--fc-color-border);
}
.contest-post-main .floors > .comment {
  position: relative;
}
.contest-post-main .floors > .comment::after {
  content: '';
  position: absolute;
  left: -28px;
  top: 22px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--fc-color-surface);
  border: 2px solid var(--fc-color-border-strong);
}
.contest-post-main .floors > .comment:last-child::after {
  background: var(--fc-color-text);
  border-color: var(--fc-color-text);
}
.contest-post-main .official-floor {
  background: var(--fc-color-surface);
  border: 1px solid var(--fc-color-border);
  border-radius: var(--fc-radius-lg);
}
.contest-post-main .official-floor .meta time {
  font-family: var(--fc-font-number);
}

@media (min-width: 1240px) {
  /* 目次は左の列にあるので、本文の上に貼り付く目次は出さない。 */
  .contest-page .contest-toc {
    display: none;
  }
}
@media (max-width: 1239px) {
  .contest-page {
    grid-template-columns: minmax(0, 1fr) 280px;
    grid-template-areas: 'back back' 'head panel' 'main panel';
  }
  .contest-side {
    display: none;
  }
}
@media (max-width: 1000px) {
  .contest-page {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: 'back' 'head' 'panel' 'main';
    grid-template-rows: none;
  }
  .contest-panel {
    margin-top: 16px;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    align-items: start;
  }
}
@media (max-width: 720px) {
  .contest-panel {
    grid-template-columns: minmax(0, 1fr);
  }
  .contest-panel-actions,
  .contest-panel-note {
    display: none;
  }
  /* 画面の下に固定するボタン列。タブバーはこのあいだ隠れ、上にスクロールすると出てきてこの列を押し上げる（community.css の --tabbar-visible）。 */
  .contest-dock {
    position: fixed;
    left: 0;
    right: 0;
    bottom: var(--tabbar-visible, 0px);
    z-index: 35;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 10px 16px calc(10px + var(--dock-safe, 0px));
    transition:
      bottom var(--fc-motion-duration-base) var(--fc-motion-ease-standard),
      padding-bottom var(--fc-motion-duration-base)
        var(--fc-motion-ease-standard);
    background: color-mix(in srgb, var(--fc-color-surface) 94%, transparent);
    backdrop-filter: blur(8px);
    border-top: 1px solid var(--fc-color-border);
  }
  .contest-dock .button {
    padding: 11px 10px;
    font-size: 14px;
    white-space: nowrap;
  }
  #app:has(.contest-dock) {
    padding-bottom: 96px;
  }
  .contest-post-main .floors {
    padding-left: 22px;
  }
  .contest-post-main .floors > .comment::after {
    left: -22px;
  }
  .contest-post-main .floors:has(> .comment + .comment)::before {
    left: 5px;
  }
}

/* ---------- 作品の詳細（voting.js entryPage） ---------- */
#app:has(> .entry-page) {
  max-width: 1440px;
}
.entry-page {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr) 260px;
  gap: 24px;
  align-items: start;
}
.entry-side {
  display: grid;
  gap: 16px;
  min-width: 0;
}
.entry-info {
  display: grid;
  gap: 10px;
  padding: 18px;
}
.entry-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.entry-tags span {
  padding: 2px 9px;
  border-radius: var(--fc-radius-sm);
  background: var(--fc-color-surface-sunken);
  color: var(--fc-color-text);
  font-size: 12px;
  font-weight: 700;
}
.entry-info h1 {
  margin: 0;
  font-size: 24px;
  font-weight: 900;
  line-height: 1.3;
  overflow-wrap: anywhere;
}
.entry-info .meta {
  margin: 0;
}
.entry-info p {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
}
.entry-actions {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 8px;
  margin-top: 4px;
}
.entry-actions button {
  padding: 11px 12px;
  font-weight: 700;
}
.entry-actions button.chosen {
  outline: 3px solid var(--fc-color-text);
  outline-offset: 2px;
}
.entry-info > :last-child {
  justify-self: start;
  font-size: 12px;
}
.entry-contest {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
}
.entry-stage {
  position: relative;
  height: min(720px, calc(100vh - var(--header-h) - 120px));
  min-height: 420px;
  border-radius: var(--fc-radius-xl);
  overflow: hidden;
  background: var(--fc-color-surface-sunken);
  border: 1px solid var(--fc-color-border);
}
.entry-stage iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}
.entry-more-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.entry-more-grid a {
  position: relative;
  display: block;
  aspect-ratio: 1;
  border-radius: var(--fc-radius-md);
  overflow: hidden;
  background: radial-gradient(
    circle at 50% 35%,
    #fff,
    var(--fc-color-accent-soft)
  );
}
.entry-more-grid img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 15%;
  transition: transform 0.2s;
}
.entry-more-grid a:hover img {
  transform: scale(1.04);
}
.entry-more-grid .vote-mark {
  top: 6px;
  right: 6px;
  width: 22px;
  height: 22px;
  font-size: 12px;
}
@media (max-width: 1239px) {
  .entry-page {
    grid-template-columns: 280px minmax(0, 1fr);
  }
  .entry-more {
    grid-column: 1 / -1;
  }
  .entry-more-grid {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  }
}
@media (max-width: 860px) {
  .entry-page {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
  .entry-stage {
    grid-row: 1;
    height: min(72vh, 520px);
    min-height: 0;
  }
}
@media (max-width: 720px) {
  .entry-more-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  /* Skip／Like は画面の下に固定（タブバーの扱いは .contest-dock と同じ） */
  .entry-actions {
    position: fixed;
    left: 0;
    right: 0;
    bottom: var(--tabbar-visible, 0px);
    z-index: 35;
    margin: 0;
    padding: 10px 16px calc(10px + var(--dock-safe, 0px));
    transition:
      bottom var(--fc-motion-duration-base) var(--fc-motion-ease-standard),
      padding-bottom var(--fc-motion-duration-base)
        var(--fc-motion-ease-standard);
    background: color-mix(in srgb, var(--fc-color-surface) 94%, transparent);
    backdrop-filter: blur(8px);
    border-top: 1px solid var(--fc-color-border);
  }
  #app:has(> .entry-page) {
    padding-bottom: 96px;
  }
}
