:root {
      /* Netflix-ish tokens */
      --bg: #0b0b0b;
      --panel: rgba(255, 255, 255, .06);
      --text: #f5f5f5;
      --muted: rgba(255, 255, 255, .72);
      --muted2: rgba(255, 255, 255, .55);
      --border: rgba(255, 255, 255, .10);
      --shadow: 0 18px 40px rgba(0, 0, 0, .55);
      --nf-red: #e50914;

      --container: 1280px;
      --gutter: 56px;
      /* Netflixっぽい左右余白 */
      --row-gap: 10px;
      --radius: 10px;
    }

    * {
      box-sizing: border-box;
    }

    html,
    body {
      height: 100%;
    }

    body {
      margin: 0;
      background: var(--bg);
      color: var(--text);
      font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Hiragino Sans", "Noto Sans JP", Arial;
    }

    a {
      color: inherit;
      text-decoration: none;
    }

    button,
    input {
      font: inherit;
    }

    :focus-visible {
      outline: 2px solid rgba(229, 9, 20, .65);
      outline-offset: 2px;
    }

    /* ===== Netflix header-like ===== */
    .topbarInner {
      width: min(var(--container), 100%);
      margin: 0 auto;
      padding: 0 var(--gutter);
      display: flex;
      align-items: center;
      gap: 14px;
    }

    /* 左・中央・右のクラスタ */
    .headerLeft {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 88px;
    }

    .profileIcon {
      width: 28px;
      height: 28px;
      border-radius: 8px;
      background: linear-gradient(135deg, rgba(229, 9, 20, .9), rgba(229, 9, 20, .2));
      border: 1px solid rgba(255, 255, 255, .14);
      box-shadow: 0 10px 24px rgba(229, 9, 20, .12);
    }

    .caret {
      width: 0;
      height: 0;
      border-left: 5px solid transparent;
      border-right: 5px solid transparent;
      border-top: 6px solid rgba(255, 255, 255, .7);
      opacity: .9;
    }

    /* 中央寄せ：検索 + タブ */
    .headerCenter {
      flex: 1;
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 10px;
      min-width: 0;
    }

    .searchBtn {
      width: 34px;
      height: 34px;
      border-radius: 999px;
      border: 1px solid transparent;
      background: transparent;
      color: rgba(255, 255, 255, .85);
      cursor: pointer;
      display: grid;
      place-items: center;
      transition: background .12s ease, border-color .12s ease, transform .12s ease;
    }

    .searchBtn:hover {
      background: rgba(255, 255, 255, .08);
      border-color: rgba(255, 255, 255, .10);
      transform: translateY(-1px);
    }

    .searchBtn svg {
      width: 18px;
      height: 18px;
    }

    /* タブ */
    .tabs {
      display: flex;
      align-items: center;
      gap: 10px;
      flex-wrap: nowrap;
      white-space: nowrap;
    }

    .tab {
      font-size: 13px;
      color: rgba(255, 255, 255, .78);
      padding: 8px 12px;
      border-radius: 999px;
      cursor: pointer;
      transition: background .12s ease, color .12s ease, transform .12s ease;
    }

    .tab:hover {
      color: rgba(255, 255, 255, .92);
      background: rgba(255, 255, 255, .06);
      transform: translateY(-1px);
    }

    .tabActive {
      color: rgba(255, 255, 255, .95);
      background: rgba(255, 255, 255, .12);
    }

    /* 右側：NetflixのNっぽいロゴ */
    .headerRight {
      min-width: 88px;
      display: flex;
      justify-content: flex-end;
      align-items: center;
    }

    .nMark {
      color: var(--nf-red);
      font-weight: 900;
      font-size: 22px;
      letter-spacing: .6px;
    }

    /* 既存のsearch inputは今回使わない想定なので、残ってても邪魔になりにくいよう保険
    .searchWrap {
      display: none;
    }

    .avatar {
      display: none;
    }
    */

    /* ===== Search expand (Netflix-ish) ===== */
    .searchFieldWrap {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 0;
    }

    .searchField {
      width: 0;
      opacity: 0;
      pointer-events: none;
      transform: translateX(-6px);
      transition: width .18s ease, opacity .18s ease, transform .18s ease;
    }

    .searchFieldOpen {
      width: 320px;
      /* 好みで調整 */
      opacity: 1;
      pointer-events: auto;
      transform: translateX(0);
    }

    .searchInput2 {
      width: 100%;
      height: 34px;
      padding: 8px 12px;
      border-radius: 999px;
      border: 1px solid rgba(255, 255, 255, .14);
      background: rgba(0, 0, 0, .35);
      color: rgba(255, 255, 255, .92);
    }

    .searchInput2::placeholder {
      color: rgba(255, 255, 255, .55);
    }

    .searchClearBtn {
      width: 34px;
      height: 34px;
      border-radius: 999px;
      border: 1px solid transparent;
      background: transparent;
      color: rgba(255, 255, 255, .78);
      cursor: pointer;
      display: grid;
      place-items: center;
      transition: background .12s ease, border-color .12s ease;
    }

    .searchClearBtn:hover {
      background: rgba(255, 255, 255, .08);
      border-color: rgba(255, 255, 255, .10);
    }

    /* 画面が狭いときは幅を少し抑える */
    @media (max-width: 900px) {
      .searchFieldOpen {
        width: 220px;
      }
    }


    /* ---------- Top Nav ---------- */
    .topbar {
      position: sticky;
      top: 0;
      z-index: 100;
      height: 64px;
      display: flex;
      align-items: center;
      background: linear-gradient(to bottom, rgba(0, 0, 0, .82), rgba(0, 0, 0, .18));
      backdrop-filter: blur(10px);
    }

    .topbarSolid {
      background: rgba(0, 0, 0, .92);
      border-bottom: 1px solid rgba(255, 255, 255, .06);
    }

    .brand {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 220px;
    }

    .nfMark {
      font-weight: 900;
      letter-spacing: .6px;
      color: var(--nf-red);
      font-size: 20px;
      line-height: 1;
    }

    .brandSub {
      color: var(--muted2);
      font-size: 12px;
      margin-top: 2px;
    }

    .navLinks {
      display: flex;
      gap: 14px;
      align-items: center;
      flex-wrap: wrap;
    }

    .navLink {
      color: var(--muted);
      font-size: 13px;
      cursor: pointer;
      padding: 6px 2px;
      border-bottom: 2px solid transparent;
      transition: color .12s ease, border-color .12s ease;
    }

    .navLink:hover {
      color: var(--text);
    }

    .navLinkActive {
      color: var(--text);
      border-color: rgba(229, 9, 20, .9);
    }

    .spacer {
      flex: 1;
    }

    .searchWrap {
      position: relative;
      width: 280px;
      max-width: 40vw;
    }

    .searchInput {
      width: 100%;
      padding: 9px 12px 9px 34px;
      border-radius: 999px;
      border: 1px solid rgba(255, 255, 255, .14);
      background: rgba(0, 0, 0, .35);
      color: var(--text);
    }

    .searchIcon {
      position: absolute;
      left: 12px;
      top: 50%;
      transform: translateY(-50%);
      opacity: .75;
      font-size: 14px;
    }

    .avatar {
      width: 30px;
      height: 30px;
      border-radius: 8px;
      border: 1px solid rgba(255, 255, 255, .14);
      background:
        linear-gradient(135deg, rgba(229, 9, 20, .25), rgba(255, 255, 255, .08));
    }

    /* ---------- Layout Container ---------- */
    .page {
      width: min(var(--container), 100%);
      margin: 0 auto;
    }

    .rows {
      padding: 0 var(--gutter) 40px;
      margin-top: -60px;
      /* ビルボードに食い込ませる */
    }

    /* ---------- Billboard (Hero) ---------- */
    .billboard {
      position: relative;
      height: 74vh;
      min-height: 520px;
      max-height: 780px;
      overflow: hidden;
      background:
        radial-gradient(900px 520px at 30% 30%, rgba(229, 9, 20, .22), transparent 60%),
        radial-gradient(900px 520px at 70% 20%, rgba(255, 255, 255, .10), transparent 60%),
        linear-gradient(135deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
    }

    .billboardMedia {
      position: absolute;
      inset: 0;
      background-size: cover;
      background-position: center;
      filter: saturate(1.05) contrast(1.05);
      transform: scale(1.02);
    }

    .billboardVignette {
      position: absolute;
      inset: 0;
      background:
        linear-gradient(90deg, rgba(0, 0, 0, .92) 0%, rgba(0, 0, 0, .45) 44%, rgba(0, 0, 0, .22) 60%, rgba(0, 0, 0, .10) 100%),
        linear-gradient(0deg, rgba(0, 0, 0, .90) 0%, rgba(0, 0, 0, .10) 55%, rgba(0, 0, 0, .45) 100%);
    }

    .billboardInner {
      position: relative;
      height: 100%;
      width: min(var(--container), 100%);
      margin: 0 auto;
      padding: 88px var(--gutter) 80px;
      display: flex;
      align-items: flex-end;
    }

    .billboardContent {
      max-width: 640px;
    }

    .billboardTag {
      display: inline-flex;
      gap: 8px;
      align-items: center;
      color: rgba(255, 255, 255, .85);
      font-size: 12px;
      letter-spacing: .18em;
      text-transform: uppercase;
      margin-bottom: 10px;
    }

    .dotRed {
      width: 8px;
      height: 8px;
      border-radius: 999px;
      background: var(--nf-red);
      box-shadow: 0 0 0 6px rgba(229, 9, 20, .12);
    }

    .billboardTitle {
      font-size: 44px;
      line-height: 1.05;
      margin: 0 0 12px;
      letter-spacing: .2px;
    }

    .billboardDesc {
      margin: 0 0 16px;
      color: var(--muted);
      line-height: 1.65;
      font-size: 14px;
    }

    .billboardMeta {
      display: flex;
      gap: 10px;
      flex-wrap: wrap;
      color: var(--muted2);
      font-size: 12px;
      margin-bottom: 14px;
    }

    .metaPill {
      padding: 6px 10px;
      border-radius: 999px;
      border: 1px solid rgba(255, 255, 255, .14);
      background: rgba(0, 0, 0, .25);
    }

    .actions {
      display: flex;
      gap: 10px;
      flex-wrap: wrap;
    }

    .btn {
      border: 0;
      cursor: pointer;
      border-radius: 6px;
      padding: 10px 14px;
      display: inline-flex;
      gap: 10px;
      align-items: center;
      font-weight: 700;
      transition: transform .12s ease, filter .12s ease, background .12s ease;
    }

    .btn:hover {
      transform: translateY(-1px);
    }

    .btnPrimary {
      background: rgba(255, 255, 255, .92);
      color: #111;
    }

    .btnPrimary:hover {
      filter: brightness(1.02);
    }

    .btnGhost {
      background: rgba(109, 109, 110, .35);
      color: var(--text);
    }

    .btnGhost:hover {
      background: rgba(109, 109, 110, .48);
    }

    /* ---------- Row ---------- */
    .row {
      margin-top: 18px;
    }

    .rowHeader {
      display: flex;
      align-items: baseline;
      justify-content: space-between;
      gap: 14px;
      margin-bottom: 8px;
    }

    .rowTitle {
      margin: 0;
      font-size: 16px;
      letter-spacing: .2px;
    }

    .rowSub {
      color: var(--muted2);
      font-size: 12px;
      margin-left: 10px;
    }

    .rowLeft {
      display: flex;
      align-items: baseline;
      gap: 8px;
      min-width: 0;
    }

    .rowViewport {
      position: relative;
    }

    .scroller {
      display: flex;
      gap: var(--row-gap);
      overflow-x: auto;
      padding: 8px 4px 18px;
      scroll-snap-type: x proximity;
    }

    .scroller::-webkit-scrollbar {
      height: 10px;
    }

    .scroller::-webkit-scrollbar-thumb {
      background: rgba(255, 255, 255, .10);
      border-radius: 999px;
    }

    .scroller::-webkit-scrollbar-track {
      background: rgba(255, 255, 255, .03);
      border-radius: 999px;
    }

    .rowArrow {
      position: absolute;
      top: 8px;
      bottom: 18px;
      width: 44px;
      border: 0;
      cursor: pointer;
      color: rgba(255, 255, 255, .88);
      background: linear-gradient(to right, rgba(0, 0, 0, .85), rgba(0, 0, 0, 0));
      opacity: 0;
      transition: opacity .12s ease;
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 22px;
    }

    .rowArrowRight {
      right: 0;
      background: linear-gradient(to left, rgba(0, 0, 0, .85), rgba(0, 0, 0, 0));
    }

    .rowViewport:hover .rowArrow {
      opacity: 1;
    }

    /* ---------- Card (poster) ---------- */
    .card {
      flex: 0 0 auto;
      width: 168px;
      scroll-snap-align: start;
      position: relative;
    }

    .poster {
      width: 100%;
      aspect-ratio: 2 / 3;
      /* Netflixっぽいポスター */
      border-radius: 6px;
      overflow: hidden;
      background:
        radial-gradient(280px 180px at 20% 30%, rgba(229, 9, 20, .24), transparent 60%),
        radial-gradient(280px 180px at 80% 20%, rgba(255, 255, 255, .10), transparent 60%),
        linear-gradient(135deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
      background-size: cover;
      background-position: center;
      box-shadow: 0 8px 18px rgba(0, 0, 0, .35);
      border: 1px solid rgba(255, 255, 255, .10);
      transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease;
      cursor: pointer;
      position: relative;
    }

    .poster::after {
      content: "";
      position: absolute;
      inset: 0;
      background: linear-gradient(0deg, rgba(0, 0, 0, .65), rgba(0, 0, 0, .02) 58%);
      opacity: .85;
      pointer-events: none;
    }

    .card:hover .poster {
      transform: scale(1.06);
      box-shadow: 0 16px 34px rgba(0, 0, 0, .55);
      border-color: rgba(255, 255, 255, .16);
      z-index: 2;
    }

    .posterTopBadges {
      position: absolute;
      top: 8px;
      left: 8px;
      display: flex;
      gap: 6px;
      z-index: 2;
    }

    .badge {
      font-size: 10px;
      padding: 5px 7px;
      border-radius: 999px;
      background: rgba(0, 0, 0, .55);
      border: 1px solid rgba(255, 255, 255, .14);
      backdrop-filter: blur(10px);
    }

    .badgeRed {
      border-color: rgba(229, 9, 20, .55);
      color: rgba(255, 255, 255, .95);
      background: rgba(229, 9, 20, .18);
    }

    .posterBottom {
      position: absolute;
      left: 8px;
      right: 8px;
      bottom: 8px;
      z-index: 2;
    }

    .title {
      margin: 0 0 6px;
      font-size: 12px;
      line-height: 1.35;
      display: -webkit-box;
      -webkit-line-clamp: 2;
      -webkit-box-orient: vertical;
      overflow: hidden;
    }

    .meta {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
      color: rgba(255, 255, 255, .75);
      font-size: 10.5px;
    }

    .hoverActions {
      position: absolute;
      right: 8px;
      top: 8px;
      z-index: 3;
      display: flex;
      gap: 6px;
      opacity: 0;
      transform: translateY(-2px);
      transition: opacity .14s ease, transform .14s ease;
    }

    .card:hover .hoverActions {
      opacity: 1;
      transform: translateY(0);
    }

    .iconBtn {
      width: 30px;
      height: 30px;
      border-radius: 999px;
      border: 1px solid rgba(255, 255, 255, .14);
      background: rgba(0, 0, 0, .55);
      color: rgba(255, 255, 255, .95);
      cursor: pointer;
      display: grid;
      place-items: center;
    }

    .iconBtn:hover {
      border-color: rgba(255, 255, 255, .22);
      background: rgba(0, 0, 0, .70);
    }

    /* ---------- Detail ---------- */
    .detailWrap {
      width: min(var(--container), 100%);
      margin: 0 auto;
      padding: 0 var(--gutter) 44px;
    }

    .detailHero {
      margin-top: 10px;
      border-radius: 14px;
      overflow: hidden;
      border: 1px solid rgba(255, 255, 255, .10);
      background:
        radial-gradient(900px 520px at 30% 30%, rgba(229, 9, 20, .20), transparent 60%),
        radial-gradient(900px 520px at 70% 20%, rgba(255, 255, 255, .10), transparent 60%),
        linear-gradient(135deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
      box-shadow: var(--shadow);
    }

    /*.detailHeroTop {
      height: 320px;
      position: relative;
    }
    */

    /*.detailHeroTop::after {
      content: "";
      position: absolute;
      inset: 0;
      background:
        linear-gradient(90deg, rgba(0, 0, 0, .90), rgba(0, 0, 0, .28) 55%, rgba(0, 0, 0, .12)),
        linear-gradient(0deg, rgba(0, 0, 0, .90), rgba(0, 0, 0, .14) 55%, rgba(0, 0, 0, .45));
    }*/

    .detailBody {
      padding: 16px;
    }

    .backRow {
      display: flex;
      gap: 10px;
      flex-wrap: wrap;
      align-items: center;
      margin: 12px 0;
    }

    .pill {
      padding: 9px 12px;
      border-radius: 999px;
      border: 1px solid rgba(255, 255, 255, .14);
      background: rgba(0, 0, 0, .35);
      color: rgba(255, 255, 255, .92);
      cursor: pointer;
    }

    .pill:hover {
      background: rgba(0, 0, 0, .50);
      border-color: rgba(255, 255, 255, .20);
    }

    .pillDisabled {
      opacity: .35;
      cursor: not-allowed;
      pointer-events: none;
      filter: grayscale(.8);
    }

    .embedBox {
      margin-top: 14px;
      /*border: 1px solid rgba(255, 255, 255, .10);
      border-radius: 12px;
      background: rgba(0, 0, 0, .35);*/
      padding: 12px;
      overflow: hidden;
    }

    .embedHint {
      font-size: 12px;
      color: var(--muted2);
      margin-bottom: 10px;
    }

    .kv {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 12px;
      margin-top: 12px;
    }

    .kvItem {
      border: 1px solid rgba(255, 255, 255, .10);
      border-radius: 12px;
      padding: 12px;
      background: rgba(0, 0, 0, .25);
    }

    .kvItem .k {
      font-size: 11px;
      color: var(--muted2);
    }

    .kvItem .v {
      margin-top: 6px;
      font-size: 14px;
      color: rgba(255, 255, 255, .92);
    }

    .footer {
      padding: 18px var(--gutter) 28px;
      width: min(var(--container), 100%);
      margin: 0 auto;
      color: var(--muted2);
      font-size: 12px;
      text-align: center;
    }

    @media (max-width: 900px) {
      :root {
        --gutter: 18px;
      }

      .billboardTitle {
        font-size: 34px;
      }

      .searchWrap {
        width: 220px;
      }

      .kv {
        grid-template-columns: 1fr;
      }
    }
