:root {
  --primary-color: #FF0000;
  --secondary-color: #282828;
  --accent-color: #3EA6FF;
  --background-color: #f9f9f9;
  --text-color: #333;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Noto Sans JP', sans-serif;
  background: linear-gradient(135deg, #f5f7fa 0%, #e4e8eb 100%);
  color: var(--text-color);
  line-height: 1.6;
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.header {
  text-align: center;
  margin-bottom: 1rem;
  position: relative;
  padding: 1.2rem;
  background: white;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* Room above the card for the floating mark (it rises 10px while animating). */
.header { margin-top: 22px; }

.header::before {
  content: '';
  position: absolute;
  /* Sits on the card's top edge so the mark never covers the title. */
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  width: 72px;
  height: 72px;
  background: url('images/movie-mark.svg?v=20260924-2') no-repeat center center;
  background-size: contain;
  animation: float 3s ease-in-out infinite;
}

@media (max-width: 640px) {
  .header::before { top: -20px; }
}

@keyframes float {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-10px); }
}

h1 {
  font-size: 3rem;
  color: var(--primary-color);
  margin: 2rem 0 1rem;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
  position: relative;
  display: inline-block;
}

h1::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
  border-radius: 3px;
}

.subtitle {
  color: var(--secondary-color);
  font-size: 1.4rem;
  margin: 1.5rem 0;
  line-height: 1.8;
}

.hero-value {
  margin-top: 1.1rem;
  margin-bottom: 0.35rem;
  font-size: clamp(1.3rem, 3vw, 1.65rem);
  font-weight: 800;
  line-height: 1.5;
}

.hero-description {
  max-width: 900px;
  margin: 0.35rem auto 0.65rem;
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  line-height: 1.7;
}

.hero-requirements {
  max-width: 900px;
  margin: 0.35rem auto 0;
  color: #555f6a;
  font-size: .9rem;
  line-height: 1.6;
}

.hero-requirements span {
  display: inline-block;
}

/* スマホで開いた人にだけ、見るのはPCだと先に伝える */
.hero-mobile-note {
  display: none;
  max-width: 34rem;
  margin: .6rem auto 0;
  padding: .55rem .9rem;
  border-radius: 10px;
  background: #fff7e0;
  color: #6b4e00;
  font-size: .9rem;
  font-weight: 700;
}

.hero-mobile-note span {
  display: inline-block;
}

@media (max-width: 640px) {
  .hero-mobile-note {
    display: block;
  }
}

.extension-announcement {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin: 0 0 3rem;
  padding: 1.4rem 1.6rem;
  background: white;
  border: 2px solid rgba(62,166,255,0.28);
  border-radius: 15px;
  box-shadow: 0 8px 24px rgba(62,166,255,0.12);
}

.extension-announcement-content {
  text-align: left;
}

.extension-announcement-label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.45rem;
  color: var(--accent-color);
  font-size: 0.9rem;
  font-weight: bold;
}

.extension-announcement h2 {
  margin-bottom: 0.45rem;
  color: var(--secondary-color);
  font-size: 1.45rem;
  line-height: 1.35;
}

.extension-announcement p {
  color: #555;
  font-size: 1rem;
}

.extension-announcement-note {
  margin-top: 0.55rem;
  color: #666 !important;
  font-size: 0.92rem !important;
}

.extension-announcement-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.extension-announcement-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 190px;
  padding: 0.9rem 1.4rem;
  border-radius: 999px;
  background: #1a73e8;
  color: white;
  text-decoration: none;
  font-weight: bold;
  box-shadow: 0 4px 14px rgba(26,115,232,0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.extension-announcement-link:hover {
  transform: translateY(-2px);
  background: #1557b0;
  box-shadow: 0 6px 18px rgba(26,115,232,0.28);
}

.hero-primary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  box-sizing: border-box;
  margin: 0.9rem 0 0.2rem;
  padding: 1rem 2.2rem;
  border-radius: 999px;
  background: #247dcc;
  color: #fff;
  font-size: 1.15rem;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(36, 125, 204, .28);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hero-primary-action:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(36, 125, 204, .32);
}

.hero-screenshot {
  display: block;
  max-width: 820px;
  margin: 1.2rem auto 0.4rem;
}

.hero-screenshot img,
.hero-video {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.18);
}

.hero-video[hidden] { display: none; }

@media (max-width: 640px) {
  .hero-screenshot { max-width: 420px; }
}

.hero-guide-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 150px;
  margin-top: 1rem;
  max-width: 100%;
  box-sizing: border-box;
  padding: 0.85rem 1.15rem;
  border: 1px solid rgba(62,166,255,0.28);
  border-radius: 999px;
  background: #fff;
  color: #1557b0;
  text-decoration: none;
  font-weight: bold;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hero-guide-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(62,166,255,0.16);
}

.official-x-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  max-width: 1100px;
  min-height: 68px;
  margin: 2rem auto 2.5rem;
  padding: 0.85rem 1rem;
  border: 1px solid #e1e4e8;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

.official-x-strip-copy {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-width: 0;
}

/* 公式X・公式YouTubeのアイコン。どちらも押すとそのアカウントを新しいタブで開く。 */
.official-account-icons {
  display: flex;
  flex: 0 0 auto;
  gap: 0.5rem;
}

.official-account-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.official-account-icon:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16);
}

.official-account-icon:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

.official-account-icon-x {
  background: #111;
  color: #fff;
}

.official-account-icon-x svg {
  width: 18px;
  height: 18px;
}

.official-account-icon-youtube {
  border: 1px solid #e1e4e8;
  background: #fff;
}

.official-account-icon-youtube svg {
  width: 26px;
  height: auto;
}

.official-x-strip p {
  margin: 0;
  color: #4b5563;
  font-size: 0.95rem;
}

.official-x-strip strong {
  color: var(--secondary-color);
}

footer {
  text-align: center;
  margin-top: 4rem;
  padding: 2rem;
  background: white;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

/* スマホ幅でリンクの言葉の途中（「プ/ライバシー」など）で折り返さないよう、リンクごとに折り返す。 */
footer a {
  display: inline-block;
  margin: 0.25rem 1rem;
  white-space: nowrap;
  color: var(--secondary-color);
  text-decoration: none;
  transition: color 0.2s;
}

footer a:hover {
  color: var(--primary-color);
}

.mascot {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 150px;
  height: 150px;
  background: url('images/miru/full.png') no-repeat center center;
  background-size: contain;
  animation: bounce 2s ease-in-out infinite;
  cursor: pointer;
  z-index: 1000;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-20px); }
}

.mascot-speech {
  position: absolute;
  bottom: 100%;
  right: 0;
  background: white;
  padding: 1rem;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  margin-bottom: 1rem;
  max-width: 200px;
  display: none;
}

.mascot:hover .mascot-speech {
  display: block;
}

@media (max-width: 768px) {
  body {
    padding: 1rem;
  }

  h1 {
    font-size: 2rem;
  }

  .extension-announcement {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    padding: 1.2rem;
  }

  .extension-announcement-content {
    text-align: center;
  }

  .extension-announcement-link {
    width: 100%;
    min-width: 0;
  }

  .extension-announcement-actions {
    width: 100%;
  }

  .official-x-strip {
    flex-direction: column;
    align-items: center;
    padding: 1rem;
  }

  /* 説明が「最新情/報」のように途中で切れないよう、見出しと説明を2行に分ける。 */
  .official-x-strip strong {
    display: block;
  }

  .official-x-strip-separator {
    display: none;
  }

  .mascot {
    display: none;
  }
}

/* Screen reader only class */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus styles for accessibility */
button:focus,
a:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
}

/* Skip to main content link */
.skip-link {
  position: absolute;
  top: -40px;
  left: 6px;
  background: var(--primary-color);
  color: white;
  padding: 8px;
  text-decoration: none;
  border-radius: 4px;
  z-index: 1001;
}

.skip-link:focus {
  top: 6px;
}



/* 管理者だけにCallable確認後表示する旧作成導線 */
#adminTools {
  display: none;
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 1000;
  gap: 0.5rem;
}

#adminTools button {
  background: linear-gradient(45deg, #ff6b35, #ff8c42);
  color: white;
  border: none;
  padding: 0.65rem 1rem;
  font-size: 0.9rem;
  border-radius: 25px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: bold;
  box-shadow: 0 4px 15px rgba(255,107,53,0.2);
}

#adminTools button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255,107,53,0.3);
}

/* Print styles */
@media print {
  .mascot,
  .skip-link {
    display: none;
  }

  body {
    background: white;
    color: black;
  }
}

/* Link hover effects */
.subtitle a:hover {
  text-decoration: underline !important;
  opacity: 0.8;
  transition: opacity 0.2s ease;
}

.watch-guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  max-width: 1000px;
  margin: 0 auto;
}

.watch-guide-link {
  display: block;
  padding: 1.2rem;
  border: 1px solid #eee;
  border-radius: 10px;
  color: #333;
  text-decoration: none;
  font-weight: bold;
}

.watch-guide-link:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.watch-mode-choice {
  max-width: 1100px;
  margin: 0 auto 2.5rem;
  text-align: center;
}

.watch-mode-choice-heading {
  max-width: 720px;
  margin: 0 auto 1.35rem;
}

.watch-mode-choice-heading h2,
.watch-mode-choice-heading p {
  margin: 0;
}

.watch-mode-choice-heading h2 {
  color: var(--secondary-color);
  font-size: clamp(1.65rem, 4vw, 2.1rem);
  line-height: 1.35;
}

.watch-mode-card-label {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  color: #1662a8;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .04em;
}

/* 友達とみんなで見るを同じ幅に（2026-10-22。みんなで見るの情報を増やすため。前は 3:2）。 */
.watch-mode-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1.2rem;
  text-align: left;
}

.watch-mode-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 310px;
  padding: 1.5rem;
  border: 2px solid transparent;
  border-radius: 16px;
  box-shadow: 0 5px 18px rgba(0, 0, 0, .05);
}

.watch-mode-card--friends {
  border-color: rgba(62, 166, 255, .32);
  background: linear-gradient(135deg, #fff 0%, #eef8ff 100%);
}

.watch-mode-card--minna {
  min-height: 0;
  border-color: #e3e7ec;
  background: #fff;
}

.watch-mode-card--minna .watch-mode-card-label {
  color: var(--primary-color);
}

/* 改装中（minna-renovation.js） */
.watch-mode-renovation-badge {
  display: inline-block;
  margin-left: .4rem;
  padding: .1rem .6rem;
  border-radius: 999px;
  background: #fff4d6;
  color: #6b4a00;
  font-size: .78rem;
  font-weight: 700;
  vertical-align: middle;
}

.watch-mode-renovation-note {
  margin: .8rem 0 0;
  padding: .7rem .8rem;
  border-radius: 10px;
  background: #f5f6fa;
  color: #486174;
  font-size: .85rem;
  font-weight: 700;
}

.watch-mode-renovation-badge[hidden],
.watch-mode-renovation-note[hidden],
.watch-mode-action[hidden] {
  display: none;
}

/* 「みんなで見る」の上映の一覧: 予定表の行（docs/design/home-minna-card/ のB。2026-10-22）。
   左に日付の箱（札と開始の時刻）、写真、題名と添える情報。行全体は題名のリンク（::after で広げる）。 */
.home-screenings {
  display: grid;
  gap: .6rem;
  margin: 1rem 0 1.1rem;
  container-type: inline-size;
}

.home-screenings-heading {
  margin: .35rem 0 0;
  color: #526173;
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .04em;
}

.home-screenings-heading:first-child {
  margin-top: 0;
}

.home-screenings-heading--live {
  color: var(--primary-color);
}

.home-screening {
  position: relative;
  display: grid;
  grid-template-columns: 78px 120px minmax(0, 1fr);
  gap: .7rem;
  align-items: center;
  padding: .6rem;
  border: 1px solid #e3e7ec;
  border-radius: 12px;
  background: #fff;
}

/* 赤い枠と赤い札は、今入れる上映だけ（開始前の上映に付けると開催中に見える） */
.home-screening--live {
  border-color: rgba(255, 0, 0, .35);
}

.home-screening-date {
  display: grid;
  justify-items: center;
  gap: .1rem;
  margin: 0;
  line-height: 1.15;
  text-align: center;
}

/* 日付の札は「11/14(土)」が日付の列（78px、スマホは72px）に1行で収まる大きさ。大きくするときは列も広げる。 */
.home-screening-day {
  padding: 0 .3rem;
  border-radius: 5px;
  background: #eef0f3;
  color: #3b4450;
  font-size: .85rem;
  font-weight: 800;
  white-space: nowrap;
}

.home-screening--live .home-screening-day {
  background: var(--primary-color);
  color: #fff;
}

.home-screening-time {
  color: var(--secondary-color);
  font-size: 1.45rem;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.home-screening-start {
  color: #5e6573;
  font-size: .7rem;
  font-weight: 800;
}

.home-screening .public-watch-room-artwork {
  border: 0;
  border-radius: 8px;
}

.home-screening--live .public-watch-room-artwork {
  box-shadow: 0 0 0 2px var(--primary-color);
}

/* 2枚のカードが横に並ぶ幅（およそ641〜1050px）では一覧が狭く、写真を入れると題名の列が潰れて
   「参加したい！」がカードからはみ出す。一覧の幅が420px未満なら、スマホと同じく写真を外す。 */
@container (width < 420px) {
  .home-screening {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .home-screening .public-watch-room-artwork {
    display: none;
  }
}

.home-screening-info {
  display: grid;
  gap: .1rem;
  min-width: 0;
}

.home-screening-title {
  display: -webkit-box;
  overflow: hidden;
  color: var(--secondary-color);
  font-size: .9rem;
  font-weight: 800;
  line-height: 1.45;
  text-decoration: none;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* 題名のリンクを行いっぱいに広げ、行のどこを押しても上映のページへ。 */
.home-screening-title::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 12px;
}

.home-screening:hover .home-screening-title {
  color: var(--primary-color);
}

.home-screening-title:focus-visible {
  outline: none;
}

.home-screening-title:focus-visible::after {
  outline: 2px solid #247dcc;
  outline-offset: 2px;
}

.home-screening small {
  display: block;
  font-size: .74rem;
  font-weight: 700;
}

/* 動画のタイトルと長さ。長いときは名前だけを省き、長さは残す。 */
.home-screening small.home-screening-video {
  display: flex;
  min-width: 0;
  color: #555f6a;
}

.home-screening-video-title {
  overflow: hidden;
  min-width: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.home-screening-video-title::before {
  content: '▶';
  margin-right: .25rem;
  color: #8a949e;
  font-size: .7rem;
}

.home-screening-video-length {
  flex: none;
}

.home-screening small.home-screening-live {
  color: var(--primary-color);
}

.home-screening small.home-screening-channel {
  color: #4b2fb3;
}

.home-screening small.home-screening-host {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--secondary-color);
}

.home-screening-host img {
  width: 16px;
  height: 16px;
  flex: none;
  border-radius: 50%;
  object-fit: cover;
  background: #fff;
}

.home-screening small.home-screening-note {
  color: #16804b;
}

.home-screening-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .35rem .6rem;
  margin-top: .3rem;
}

/* ボタンは行のリンクの上に重ねる。 */
.home-screening-interest {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: .2rem .85rem;
  border: 0;
  border-radius: 999px;
  background: var(--primary-color);
  color: #fff;
  font: inherit;
  font-size: .82rem;
  font-weight: 800;
  white-space: nowrap;
  cursor: pointer;
}

.home-screening-interest:hover {
  background: #d40000;
}

.home-screening-interest[aria-pressed="true"] {
  background: #fff;
  color: var(--primary-color);
  box-shadow: inset 0 0 0 2px var(--primary-color);
}

.home-screening-interest:disabled {
  cursor: wait;
  opacity: .7;
}

.home-screening-countdown {
  color: #b0000a;
  font-size: .78rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.home-screening-hearts {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  padding: 0 9px 0 7px;
  border-radius: 999px;
  background: #fdecec;
  color: #b0000a;
  font-size: .82rem;
  font-style: normal;
  font-weight: 800;
  line-height: 1.6;
}

.home-screening-hearts b {
  color: #d0000c;
  font-size: 1.05rem;
  line-height: 1;
}

.home-screening-status {
  margin: .3rem 0 0;
  color: #486174;
  font-size: .74rem;
  font-weight: 700;
}

.watch-mode-card h3 {
  margin: .45rem 0 .4rem;
  color: var(--secondary-color);
  font-size: 1.45rem;
  line-height: 1.4;
}

.watch-mode-card > p {
  margin: 0;
  color: #555f6a;
}

.watch-mode-card ul {
  display: grid;
  gap: .45rem;
  margin: 1rem 0 1.25rem;
  padding: 0;
  color: #374151;
  font-size: .92rem;
  list-style: none;
}

.watch-mode-card li {
  position: relative;
  padding-left: 1.35rem;
}

.watch-mode-card li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: #16804b;
  font-weight: 900;
}

/* 友達のカードの「はじめ方」の3手順（2枚を同じ幅にしたぶん空く高さに置く。スマホでは隠す）。 */
.watch-mode-steps-title {
  margin: 0 0 .4rem;
  color: #1662a8;
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .04em;
}

.watch-mode-card .watch-mode-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .5rem;
  margin: 0 0 1.25rem;
  counter-reset: step;
}

.watch-mode-card .watch-mode-steps li {
  display: grid;
  align-content: start;
  gap: .3rem;
  padding: .65rem .6rem;
  border: 1px solid rgba(62, 166, 255, .3);
  border-radius: 12px;
  background: #fff;
  color: #374151;
  font-size: .8rem;
  font-weight: 700;
  line-height: 1.45;
  counter-increment: step;
}

.watch-mode-card .watch-mode-steps li::before {
  content: counter(step);
  position: static;
  display: grid;
  place-items: center;
  width: 1.45rem;
  height: 1.45rem;
  border-radius: 50%;
  background: #247dcc;
  color: #fff;
  font-size: .78rem;
  font-weight: 800;
}

.watch-mode-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 50px;
  margin-top: auto;
  padding: .8rem 1rem;
  border-radius: 999px;
  border: 0;
  color: #fff;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease;
}

.watch-mode-action:hover {
  transform: translateY(-2px);
}

.watch-mode-action--friends {
  background: #247dcc;
  box-shadow: 0 4px 14px rgba(36, 125, 204, .2);
}

.watch-mode-action--minna {
  border: 2px solid var(--primary-color);
  background: #fff;
  color: var(--primary-color);
}

.watch-mode-action--minna:hover {
  background: #fff4f4;
}

.watch-mode-action-note {
  margin: auto 0 .45rem;
  color: #486174;
  font-size: .8rem;
  font-weight: 700;
  text-align: center;
}

.watch-mode-action-note + .watch-mode-action {
  margin-top: 0;
}

.public-watch-room-artwork {
  display: grid;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  place-items: center;
  border-bottom: 1px solid #eee;
  background: #f7f7f7;
}

.public-watch-room-artwork img {
  min-height: 0;
  min-width: 0;
  object-position: center;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.public-watch-room-artwork-platform-logo img {
  object-fit: contain;
}

.public-watch-room-artwork.public-watch-room-cover {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  padding: 12px 16px;
  background: #f3f5f7;
  color: #333;
  border-bottom: 1px solid #eee;
}
.public-watch-room-cover[data-platform="amazon_prime"] { background: #edf6fa; }
.public-watch-room-cover[data-platform="netflix"] { background: #faf1f2; }
.public-watch-room-cover[data-platform="disney_plus"] { background: #f1f3fa; }
.public-watch-room-cover img.public-watch-room-cover-logo {
  flex: 0 0 44px;
  align-self: center;
  width: 112px;
  max-width: 100%;
  height: 44px;
  padding: 0;
  border-radius: 5px;
  background: transparent;
  object-fit: contain;
}
.public-watch-room-cover .public-watch-room-cover-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  margin: auto 0;
  max-height: 3.9em;
  font-size: 18px;
  line-height: 1.3;
  font-weight: 750;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
}

@media (max-width: 640px) {
  .header {
    padding: 1rem;
  }

  .hero-value {
    margin-top: .85rem;
  }

  .watch-mode-grid {
    grid-template-columns: 1fr;
  }

  .watch-mode-card {
    min-height: 0;
    padding: 1.25rem;
  }

  /* 1列では友達のカードに空きができないので、はじめ方は出さない（みんなで見るを下へ押し下げない）。 */
  .watch-mode-steps-block {
    display: none;
  }

  /* 上映の行は、上映予定のページの予定表と同じく写真を外す。 */
  .home-screening {
    grid-template-columns: 72px minmax(0, 1fr);
    gap: .6rem;
    padding: .55rem .6rem;
  }

  .home-screening .public-watch-room-artwork {
    display: none;
  }

  .home-screening-time {
    font-size: 1.25rem;
  }

  /* 幅の狭いスマホでも行からはみ出さないよう、ボタンの中で折り返す。 */
  .home-screening-interest {
    max-width: 100%;
    white-space: normal;
  }

}

/* 右上: ゲストには「ログイン」、ログイン中の人には画像・名前・マイページ・お知らせ。
   登録の途中の人には「登録を完了する」だけを出す（マイページとお知らせは、登録が済むまで使えない）。 */
.user-section { position: absolute; top: 20px; right: 20px; display: flex; align-items: center; gap: 10px; }
.home-user-info { flex-direction: column; align-items: center; }
.home-profile-btn { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; border: 2px solid #3EA6FF; cursor: pointer; background: #fff; }
.home-user-nickname { color: #333; font-weight: bold; margin-top: 8px; cursor: pointer; }
.home-user-info.is-pending .home-notifications-link { display: none; }
.home-login-btn { background: #FF0000; color: #fff; border: none; padding: 8px 16px; border-radius: 20px; cursor: pointer; font-size: 14px; font-weight: 700; }
.home-login-btn:hover { background: #d90000; }
@media (max-width: 900px) {
  /* 狭い画面では小さく横に並べ、上の映画のマークと見出しに重ならないようにする。名前は登録の途中の案内だけ出す。 */
  .user-section { top: 10px; right: 12px; }
  .home-user-info { flex-direction: row; gap: 6px; }
  .home-profile-btn { width: 32px; height: 32px; }
  .home-user-nickname { display: none; }
  .home-user-info.is-pending .home-user-nickname { display: inline; margin-top: 0; font-size: 12px; }
  .home-login-btn { padding: 6px 14px; font-size: 13px; }
}

/* ログイン中の人だけに出す「お知らせ」。未読の数は赤い丸。 */
.home-notifications-link { display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; color: #333; font-size: 13px; text-decoration: none; }
.home-notifications-link:hover { color: #f00; }
.home-notifications-badge { min-width: 18px; padding: 0 5px; border-radius: 9px; background: #f00; color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.home-notifications-label { font-weight: 700; }
@media (max-width: 680px) {
  /* 狭い画面では鈴と数だけにして、見出しに重なる高さを増やさない。 */
  .home-notifications-label { display: none; }
  .home-notifications-link { margin-top: 2px; font-size: 15px; }
}
