:root {
  --red: #e51f2b;
  --red-deep: #9f0b1f;
  --ink: #17171a;
  --muted: #75726d;
  --paper: #efede7;
  --paper-2: #e4e0d8;
  --gold: #d3b878;
  --card: #111013;
  --card-2: #1a1518;
  --line: rgba(27, 25, 24, .14);
  --header-h: 74px;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--paper); scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: Inter, "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button { color: inherit; font: inherit; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }

.site-header {
  position: relative;
  z-index: 50;
  min-height: var(--header-h);
  display: grid;
  grid-template-columns: 1fr minmax(260px, auto) 1fr;
  align-items: center;
  gap: 18px;
  padding: 12px clamp(18px, 3vw, 42px);
  border-bottom: 1px solid var(--line);
  background: rgba(239, 237, 231, .92);
  backdrop-filter: blur(16px);
}

.brand { font-size: 29px; line-height: 1; font-weight: 950; letter-spacing: -.08em; justify-self: start; }
.brand::after { content: none !important; }

.header-live {
  justify-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 280px;
  min-height: 40px;
  padding: 7px 14px;
  gap: 9px;
  border: 1px solid rgba(229,31,43,.52);
  background: linear-gradient(180deg, #21181b, #100f11);
  color: #fff;
  border-radius: 999px;
  box-shadow: 0 8px 28px rgba(70, 7, 16, .13), inset 0 1px rgba(255,255,255,.08);
}
.header-live-label { color: #ff4554; font-weight: 950; font-size: 12px; letter-spacing: .13em; }
.header-live strong { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.status-dot { width: 8px; height: 8px; flex: 0 0 auto; border-radius: 50%; background: #ff4050; box-shadow: 0 0 0 4px rgba(255,64,80,.12), 0 0 16px rgba(255,64,80,.55); }
.header-live.is-live .status-dot { animation: pulse 1.5s ease-in-out infinite; }
.header-live.is-offline { opacity: .62; filter: grayscale(.4); }

.header-nav { justify-self: end; display: flex; align-items: center; gap: 8px; }
.nav-button { padding: 9px 11px; border: 1px solid transparent; font-size: 11px; font-weight: 850; letter-spacing: .08em; border-radius: 999px; }
.nav-button:hover, .nav-button.is-current { border-color: rgba(23,23,26,.17); background: rgba(255,255,255,.5); }
.nav-button-primary { color: #fff; background: var(--red); border-color: var(--red); }
.nav-button-primary:hover { background: #c91724; border-color: #c91724; }

.first-view {
  position: relative;
  min-height: calc(100svh - var(--header-h));
  overflow: hidden;
  display: grid;
  place-items: center;
  padding: 38px 20px 116px;
  isolation: isolate;
}
.play-field { position: absolute; inset: 0; z-index: -2; background: radial-gradient(circle at 50% 42%, rgba(255,255,255,.96) 0 8%, transparent 41%), radial-gradient(ellipse at 8% 64%, rgba(229,31,43,.14), transparent 40%), linear-gradient(140deg, #f7f4ee, #e6e1d8 52%, #f3efe8); }
.play-field::before, .play-field::after { content: ""; position: absolute; width: 42vw; height: 70vw; max-height: 920px; border: 1px solid rgba(70,58,44,.1); transform: rotate(18deg); border-radius: 26px; }
.play-field::before { left: -20vw; top: 5vh; }
.play-field::after { right: -24vw; bottom: -20vh; transform: rotate(-22deg); }
.play-field i { position: absolute; left: 50%; top: 50%; width: min(86vw, 840px); height: 1px; background: linear-gradient(90deg, transparent, rgba(72,59,44,.16), transparent); transform-origin: center; }
.play-field i:nth-child(1) { transform: translate(-50%,-50%) rotate(0deg); }
.play-field i:nth-child(2) { transform: translate(-50%,-50%) rotate(60deg); }
.play-field i:nth-child(3) { transform: translate(-50%,-50%) rotate(-60deg); }

.intro-logo { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; transition: opacity .36s ease, transform .55s cubic-bezier(.2,.8,.2,1); }
.intro-logo strong { font-size: clamp(92px, 18vw, 230px); letter-spacing: -.09em; font-weight: 950; }
.intro-logo strong::after { content: none !important; }
.intro-finished .intro-logo { opacity: 0; transform: scale(1.12); }

.deck-stage { position: relative; width: min(82vw, 530px); aspect-ratio: 0.72; perspective: 1400px; opacity: 0; transform: translateY(22px); transition: opacity .45s ease .12s, transform .5s ease .12s; }
.intro-finished .deck-stage { opacity: 1; transform: none; }
.data-card { position: absolute; inset: 0; padding: 5px; border-radius: 28px; background: linear-gradient(135deg, #4f402b, #e4d097 10%, #5b4a32 23%, #c8a96b 42%, #57472f 62%, #ead8a6 79%, #5c4c35); box-shadow: 0 34px 100px rgba(12,8,8,.26); opacity: 0; pointer-events: none; transform: translate3d(48%, 34%, -140px) rotate(12deg) scale(.83); transition: opacity .48s ease, transform .72s cubic-bezier(.18,.8,.2,1), filter .4s ease; }
.data-card.is-active { z-index: 4; opacity: 1; pointer-events: auto; transform: translate3d(0,0,0) rotate(0deg) scale(1); }
.data-card.is-before { z-index: 2; opacity: 0; transform: translate3d(-52%,-38%,-180px) rotate(-12deg) scale(.82); }
.data-card.is-after { z-index: 1; opacity: .26; transform: translate3d(7%,4%,-70px) rotate(2.5deg) scale(.98); filter: brightness(.9); }
.card-frame { position: relative; height: 100%; overflow: hidden; display: flex; flex-direction: column; padding: clamp(28px,5vw,48px); border: 1px solid rgba(237,220,178,.72); border-radius: 24px; color: #fff; background: radial-gradient(ellipse at 50% 37%, rgba(180,21,49,.2), transparent 53%), linear-gradient(145deg, #1b1719, #08080a 54%, #171316); }
.card-frame::before { content: ""; position: absolute; inset: 14px; border: 1px solid rgba(211,184,120,.24); border-radius: 17px; pointer-events: none; }
.card-frame::after { content: ""; position: absolute; inset: -40%; background: linear-gradient(110deg, transparent 42%, rgba(255,255,255,.08) 49%, transparent 56%); transform: translateX(-45%) rotate(8deg); pointer-events: none; }
.data-card.is-active .card-frame::after { animation: sheen 1.1s .18s ease-out both; }
.card-frame header { position: relative; z-index: 1; }
.card-frame header span { color: rgba(255,255,255,.48); font-size: 10px; letter-spacing: .22em; font-weight: 850; }
.card-frame h1 { margin: 9px 0 0; font-size: clamp(24px,5vw,36px); letter-spacing: -.04em; }
.card-main-number { position: relative; z-index: 1; flex: 1; display: flex; align-items: center; justify-content: center; gap: 9px; padding: 24px 0; }
.card-main-number strong { font-size: clamp(74px,18vw,124px); line-height: .9; letter-spacing: -.08em; font-variant-numeric: tabular-nums; }
.card-main-number span { align-self: flex-end; margin-bottom: 23%; font-size: 15px; color: rgba(255,255,255,.73); font-weight: 800; }
.metric-plus { position: relative; top: -.42em; margin-left: .06em; font-size: .38em; color: #ff4656; }
.card-frame footer { position: relative; z-index: 1; display: flex; align-items: end; justify-content: space-between; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.14); }
.card-frame footer > span { color: rgba(255,255,255,.58); font-size: 12px; font-weight: 700; }
.card-frame footer div { display: flex; align-items: baseline; gap: 6px; }
.card-frame footer strong { font-size: clamp(32px,8vw,52px); line-height: 1; letter-spacing: -.05em; }
.card-frame footer small { color: rgba(255,255,255,.7); font-size: 12px; }
.slide-nav { position: absolute; bottom: 74px; display: flex; gap: 9px; }
.slide-nav button { width: 30px; height: 4px; padding: 0; border: 0; border-radius: 999px; background: rgba(23,23,26,.16); cursor: pointer; transition: width .25s ease, background .25s ease; }
.slide-nav button.is-active { width: 54px; background: var(--red); }

.latest-result { position: relative; z-index: 5; width: min(calc(100% - 36px), 920px); margin: -74px auto 32px; }
.latest-result a { display: grid; grid-template-columns: 1fr auto; gap: 7px 24px; padding: 19px 22px; color: #fff; background: #151316; border: 1px solid rgba(211,184,120,.38); border-radius: 18px; box-shadow: 0 18px 60px rgba(25,12,14,.18); }
.latest-result-kicker { grid-column: 1 / -1; display: flex; justify-content: space-between; color: rgba(255,255,255,.5); font-size: 9px; letter-spacing: .18em; font-weight: 850; }
.latest-result > a > strong { font-size: clamp(17px,3vw,24px); }
.latest-result-bottom { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; color: #ff5360; font-size: 13px; font-weight: 850; }
.latest-result-bottom b { font-size: 22px; color: #fff; }

.error-box { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); width: min(90vw, 560px); padding: 10px 14px; border: 1px solid rgba(229,31,43,.28); background: rgba(255,255,255,.84); border-radius: 12px; font-size: 11px; }
.error-box strong { margin-right: 8px; color: var(--red); }

.page-heading { width: min(calc(100% - 36px), var(--max)); margin: 0 auto; padding: 64px 0 36px; border-bottom: 1px solid var(--line); }
.page-heading > span { color: var(--red); font-size: 10px; font-weight: 900; letter-spacing: .2em; }
.page-heading h1 { margin: 7px 0 5px; font-size: clamp(48px,8vw,94px); line-height: .95; letter-spacing: -.07em; }
.page-heading p { margin: 0; color: var(--muted); font-size: 12px; }

.members-main, .results-main { min-height: calc(100svh - var(--header-h)); background: radial-gradient(circle at 90% 15%, rgba(229,31,43,.08), transparent 28%), var(--paper); }
.member-groups { width: min(calc(100% - 36px), var(--max)); margin: 0 auto; padding: 20px 0 70px; }
.member-group { padding: 34px 0 42px; border-bottom: 1px solid var(--line); }
.member-group-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 22px; }
.member-group-heading div { display: flex; align-items: baseline; gap: 8px; }
.member-group-heading span { font-size: clamp(22px,4vw,34px); font-weight: 950; letter-spacing: -.04em; }
.member-group-heading strong { color: var(--red); font-size: 17px; }
.member-group-heading small, .member-group-heading p { margin: 0; color: var(--muted); font-size: 10px; font-weight: 700; }

.member-icon-grid { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 14px; }
.member-icon-button { min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 0; border: 0; background: none; cursor: pointer; }
.member-icon-image { position: relative; width: 100%; aspect-ratio: 1; overflow: hidden; border-radius: 50%; display: grid; place-items: center; background: #d8d3ca; border: 2px solid transparent; box-shadow: 0 0 0 1px rgba(24,22,21,.12); transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease; }
.member-icon-image img, .profile-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.member-icon-image.has-image .avatar-fallback, .profile-avatar.has-image .avatar-fallback { opacity: 0; }
.avatar-fallback { font-size: clamp(12px,2vw,20px); font-weight: 950; letter-spacing: -.06em; }
.member-icon-button > span { width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: center; font-size: 10px; font-weight: 750; }
.member-icon-button:hover .member-icon-image { transform: translateY(-2px); }
.member-icon-button.is-active .member-icon-image { border-color: var(--red); box-shadow: 0 0 0 4px rgba(229,31,43,.13), 0 10px 28px rgba(90,10,20,.16); transform: scale(1.03); }
.member-icon-button.is-active > span { color: var(--red); }

.profile-stage { max-height: 0; opacity: 0; margin-top: 0; overflow: hidden; transition: max-height .38s cubic-bezier(.2,.8,.2,1), opacity .25s ease, margin .3s ease; }
.profile-stage.is-open { max-height: 1000px; opacity: 1; margin-top: 30px; }
.profile-card { position: relative; width: min(100%, 860px); min-height: 420px; margin: 0 auto; padding: 5px; display: grid; grid-template-columns: minmax(280px, .8fr) 1.2fr; background: linear-gradient(135deg, #5d4d35, #dfca91 12%, #5b4932 27%, #c9a866 48%, #ead7a5 73%, #55452f); border-radius: 26px; box-shadow: 0 28px 90px rgba(20,12,13,.22); transition: transform .32s ease, opacity .32s ease; touch-action: pan-y; }
.profile-card.enter-from-right { transform: translateX(34px) rotate(1.5deg); opacity: 0; }
.profile-card.enter-from-left { transform: translateX(-34px) rotate(-1.5deg); opacity: 0; }
.profile-close { position: absolute; z-index: 4; top: 17px; right: 17px; width: 34px; height: 34px; padding: 0; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.2); border-radius: 50%; color: #fff; background: rgba(0,0,0,.35); font-size: 24px; line-height: 1; cursor: pointer; }
.profile-visual { min-width: 0; display: grid; place-items: center; padding: 36px; border: 1px solid rgba(226,207,161,.55); border-right: 0; border-radius: 22px 0 0 22px; background: radial-gradient(circle at 50% 42%, rgba(229,31,43,.24), transparent 49%), linear-gradient(145deg, #1b1719, #09090b 65%, #151214); }
.profile-avatar { position: relative; width: min(80%, 250px); aspect-ratio: 1; overflow: hidden; display: grid; place-items: center; border-radius: 50%; color: #fff; background: #292226; border: 3px solid rgba(226,207,161,.78); box-shadow: 0 0 0 9px rgba(229,31,43,.08), 0 20px 60px rgba(0,0,0,.34); }
.profile-avatar .avatar-fallback { font-size: clamp(36px,6vw,72px); }
.profile-body { min-width: 0; padding: 42px 42px 36px; color: #fff; border: 1px solid rgba(226,207,161,.55); border-left: 0; border-radius: 0 22px 22px 0; background: linear-gradient(150deg, #171416, #0b0a0c 72%, #171214); }
.profile-meta { display: flex; justify-content: space-between; gap: 16px; color: rgba(255,255,255,.42); font-size: 9px; font-weight: 850; letter-spacing: .16em; }
.profile-title-row { display: flex; align-items: center; gap: 16px; margin-top: 15px; padding-bottom: 19px; border-bottom: 1px solid rgba(255,255,255,.13); }
.profile-title-row h2 { min-width: 0; margin: 0; font-size: clamp(34px,6vw,58px); line-height: 1; letter-spacing: -.06em; overflow-wrap: anywhere; }
.profile-x-link { flex: 0 0 auto; width: 38px; height: 38px; display: grid; place-items: center; color: #0b0b0d; background: #fff; border-radius: 50%; transition: transform .2s ease; }
.profile-x-link:hover { transform: scale(1.08); }
.profile-x-link svg { width: 16px; height: 16px; fill: currentColor; }
.profile-section-label { margin-top: 23px; color: #ff4d5c; font-size: 10px; font-weight: 900; letter-spacing: .2em; }
.profile-results { margin: 13px 0 0; padding: 0; list-style: none; }
.profile-results li { position: relative; padding: 9px 0 9px 17px; color: rgba(255,255,255,.88); font-size: 13px; line-height: 1.55; border-bottom: 1px solid rgba(255,255,255,.08); }
.profile-results li::before { content: ""; position: absolute; left: 0; top: 16px; width: 6px; height: 6px; border: 1px solid var(--gold); transform: rotate(45deg); }

.results-list { width: min(calc(100% - 36px), 980px); margin: 0 auto; padding: 32px 0 80px; display: grid; gap: 22px; }
.result-card { overflow: hidden; display: grid; grid-template-columns: minmax(220px, .7fr) 1.3fr; min-height: 260px; border: 1px solid rgba(87,72,53,.28); background: #fffdf8; box-shadow: 0 16px 48px rgba(40,30,25,.07); }
.result-card:not(:has(.result-card-media)) { grid-template-columns: 1fr; }
.result-card-media { min-height: 260px; background: #171416; }
.result-card-media img { width: 100%; height: 100%; object-fit: cover; }
.result-card-body { padding: 34px; align-self: center; }
.result-card-body time { color: var(--red); font-size: 10px; font-weight: 850; letter-spacing: .12em; }
.result-card-body h2 { margin: 9px 0 13px; font-size: clamp(25px,4vw,38px); letter-spacing: -.045em; }
.result-card-body strong { display: block; font-size: clamp(18px,3vw,26px); }
.result-card-body p { margin: 14px 0 0; color: var(--muted); font-size: 13px; line-height: 1.7; }
.empty-state { width: min(calc(100% - 36px), var(--max)); margin: 32px auto 80px; padding: 42px; color: var(--muted); text-align: center; border: 1px dashed rgba(23,23,26,.2); }
.page-error { position: static; transform: none; margin: 0 auto 40px; }

.site-footer { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 22px clamp(18px,3vw,42px); border-top: 1px solid var(--line); color: var(--muted); font-size: 10px; }
.site-footer nav { display: flex; gap: 15px; }
.site-footer a:hover { color: var(--ink); }

.simple-header { height: 72px; display: flex; align-items: center; justify-content: space-between; padding: 0 clamp(18px,5vw,70px); border-bottom: 1px solid var(--line); }
.simple-header > a:last-child { font-size: 10px; font-weight: 850; letter-spacing: .1em; }
.text-main { width: min(calc(100% - 36px), 760px); margin: 0 auto; padding: 72px 0 120px; }
.text-kicker { color: var(--red); font-size: 10px; font-weight: 900; letter-spacing: .18em; }
.text-main h1 { margin: 8px 0 38px; font-size: clamp(52px,10vw,100px); letter-spacing: -.07em; }
.text-main p { color: #55514d; font-size: 14px; line-height: 2; }

@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(255,64,80,.04), 0 0 22px rgba(255,64,80,.75); } }
@keyframes sheen { from { transform: translateX(-45%) rotate(8deg); } to { transform: translateX(45%) rotate(8deg); } }

@media (max-width: 900px) {
  .member-icon-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  :root { --header-h: 122px; }
  .site-header { grid-template-columns: auto 1fr; grid-template-rows: 42px 44px; gap: 7px 10px; padding: 10px 14px; }
  .brand { grid-column: 1; grid-row: 1; font-size: 26px; }
  .header-nav { grid-column: 2; grid-row: 1; gap: 3px; }
  .nav-button { padding: 7px 7px; font-size: 9px; }
  .header-live { grid-column: 1 / -1; grid-row: 2; justify-self: stretch; width: 100%; min-width: 0; min-height: 38px; }
  .header-live strong { max-width: calc(100vw - 100px); text-align: center; }

  .first-view { min-height: calc(100svh - var(--header-h)); padding: 28px 18px 104px; }
  .deck-stage { width: min(82vw, 390px); aspect-ratio: .72; }
  .data-card { border-radius: 23px; }
  .card-frame { border-radius: 19px; padding: 30px 27px; }
  .card-frame::before { inset: 11px; border-radius: 14px; }
  .slide-nav { bottom: 61px; }
  .latest-result { margin-top: -58px; }

  .page-heading { padding: 42px 0 28px; }
  .page-heading h1 { font-size: 58px; }
  .member-groups { width: calc(100% - 28px); padding-top: 8px; }
  .member-group { padding: 27px 0 34px; }
  .member-group-heading { margin-bottom: 18px; }
  .member-group-heading p { display: none; }

  /* スマホは必ず5列。6人目以降は自動で次の行へ。 */
  .member-icon-grid {
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    grid-auto-flow: row !important;
    grid-auto-columns: auto !important;
    width: 100% !important;
    max-width: none !important;
    overflow: visible !important;
    gap: 14px 9px;
  }
  .member-icon-button { width: 100% !important; min-width: 0 !important; max-width: none !important; }
  .member-icon-button > span { font-size: 9px; }

  .profile-stage.is-open { max-height: 1400px; margin-top: 24px; }
  .profile-card {
    width: 100%;
    min-height: 0;
    grid-template-columns: 1fr;
    border-radius: 24px;
  }
  .profile-visual {
    min-height: 290px;
    padding: 42px 28px 30px;
    border-right: 1px solid rgba(226,207,161,.55);
    border-bottom: 0;
    border-radius: 20px 20px 0 0;
  }
  .profile-avatar { width: min(58vw, 230px); }
  .profile-body {
    padding: 27px 25px 30px;
    border-left: 1px solid rgba(226,207,161,.55);
    border-top: 0;
    border-radius: 0 0 20px 20px;
  }
  .profile-title-row { margin-top: 12px; }
  .profile-title-row h2 { font-size: clamp(34px,10vw,48px); }
  .profile-results li { font-size: 12px; }
  .profile-close { top: 15px; right: 15px; }

  .results-list { width: calc(100% - 28px); gap: 16px; }
  .result-card { grid-template-columns: 1fr; }
  .result-card-media { min-height: 220px; }
  .result-card-body { padding: 25px; }

  .site-footer { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 380px) {
  .member-icon-grid { gap: 12px 7px; }
  .member-icon-button > span { font-size: 8px; }
  .profile-visual { min-height: 260px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
