/* Toy Sports — tactile white shells, coral accents and glacial blue glass. */
:root {
  --pink: #f9669d; --pink-dark: #cb3d78; --pink-light: #ffe5ef;
  --blue: #46b9ef; --blue-dark: #1682bd; --blue-light: #def5ff;
  --ink: #203d61; --ink-soft: #54748d;
  --shadow: 0 4px 0 #bfd5e5, 0 8px 16px #365c7812;
}
body { background: #e5f4ff; }
body::before { opacity: .35; }
.screen {
  background: rgba(216,239,253,.45);
  backdrop-filter: blur(9px); -webkit-backdrop-filter: blur(9px);
}
#screen-title { background: rgba(231,247,255,.08); backdrop-filter: none; -webkit-backdrop-filter: none; }
.panel {
  position: relative;
  background: linear-gradient(145deg, #fffffffa, #f8fcfff5 52%, #dfedf9f5);
  border: 2px solid #fff;
  border-radius: 30px;
  box-shadow: 0 3px 0 #fff inset, 0 -5px 0 #c9dfef inset, 0 0 0 1px #8fb8d233,
    0 9px 0 #b6d0e1, 0 24px 52px #1745742e;
}
.panel-title { letter-spacing: .025em; }
.title-panel { padding: 14px 27px 23px; }
.title-penguin { animation: toyFloat 4s ease-in-out infinite; filter: drop-shadow(0 12px 10px #3c709533); }
#title-peng { width: 280px; max-width: 100%; height: 154px; }
.logo { font-size: 43px; letter-spacing: .05em; margin: 0 0 13px; }
.logo, .logo .l2 {
  color: #285982;
  text-shadow: 0 -1px 0 #fff, 0 2px 0 #fff, 0 5px 0 #afdcef, 0 8px 12px #42749a26;
}
.logo span { animation: none; }
.tagline { font-size: 12px; margin-bottom: 18px; letter-spacing: .025em; }
.title-note { font-size: 10.5px; }
.name-row, .code-box {
  border: 1px solid #c5dbea; background: linear-gradient(#e8f2f9, #f9fcff);
  box-shadow: inset 0 2px 4px #466f8910, 0 1px 0 #fff;
  border-radius: 14px;
}
.name-row { padding: 10px 14px; }
.name-label { font-size: 11px; }
.menu { gap: 12px; }
.btn {
  border: 1px solid #bfd8e9; border-radius: 18px;
  background: linear-gradient(#fff 8%, #f6faff 70%, #e5eef7);
  box-shadow: 0 2px 0 #fff inset, 0 -2px 0 #d6e6f2 inset, 0 5px 0 #b4cddd, 0 9px 15px #335c7b16;
  transition: transform .15s, box-shadow .15s, filter .15s;
}
.btn-big { padding: 15px 20px; font-size: 18px; }
.btn-pink {
  background: linear-gradient(#ff91bc, #f9649f 60%, #e44b88);
  border-color: #e66399;
  box-shadow: 0 2px 0 #ffd4e7 inset, 0 -2px 0 #df4f88 inset, 0 5px 0 #bd3b70, 0 10px 19px #de5c8e2b;
  text-shadow: 0 1px 1px #b3325a3b;
}
.btn-blue {
  background: linear-gradient(#80d7fc, #48baf0 62%, #2ca0da);
  border-color: #5ab9e5;
  box-shadow: 0 2px 0 #d7f6ff inset, 0 -2px 0 #299acb inset, 0 5px 0 #1981b4, 0 10px 19px #358dcc24;
}
.btn:active:not(:disabled) { transform: translateY(4px); box-shadow: 0 1px 0 #a4c0d4, inset 0 1px 2px #fff9; }
.btn-mini { border-radius: 13px; padding: 8px 14px; }
button:focus-visible, input:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 3px solid #1769a2; outline-offset: 4px;
}
@media (hover:hover) {
  .btn:hover:not(:disabled), .stage:hover:not(:disabled), .pick:hover { filter: brightness(1.035); transform: translateY(-1px); }
  .btn:active:not(:disabled) { transform: translateY(4px); }
}
.pick { border-width: 1px; border-color: #c7dce9; background: linear-gradient(#fff,#eaf4fc); box-shadow: inset 0 1px 0 #fff, 0 3px 0 #c6d9e7; border-radius: 14px; }
.pick.sel { background: linear-gradient(#61c8f5,#2da2db); border-color: #2394c8; box-shadow: inset 0 2px 0 #b6ecff, 0 3px 0 #1677a8; }
.stage { border-width: 1px; border-color: #c5ddea; border-radius: 17px; background: linear-gradient(115deg,#fff,#edf6fe); box-shadow: 0 2px 0 #fff inset, 0 4px 0 #c1d6e5; padding: 12px; gap: 11px; }
.stage.now { background: linear-gradient(110deg,#fff5fa,#fff); border-color: #f084b0; box-shadow: inset 4px 0 0 #f9669d, 0 4px 0 #e788ac; }
.stage.boss { background: linear-gradient(115deg,#fffaf0,#fff); }
.stage.boss.now { border-color: #e9b04d; box-shadow: inset 4px 0 0 #efb749,0 4px 0 #dca544; }
.stage:disabled { opacity: .62; filter: saturate(.45); }
.stage-no { width: 27px; height: 27px; border-radius: 9px; font-size: 12px; }
.stage-face { width: 57px; height: 57px; }
.stage-name { font-size: 15px; }
.stage-sub, .stage-role { font-size: 10.5px; }
.pager-btn { border-width: 1px; box-shadow: inset 0 2px 0 #fff,0 3px 0 #bad4e5; }
.talk-panel #talk-peng { width: 180px; height: 180px; }
.talk-line { background: #fff; border: 1px solid #cbdfea; box-shadow: 0 3px 0 #deedf7; }
.talk-line::after { border-bottom-color: #fff; }
.talk-intro { background: #e5f1fa; color: #42617d; }
.result-peng { width: 102px; height: 102px; }
.result-score { padding: 10px 0; background: linear-gradient(#f8fcff,#e5f1fa); border: 1px solid #d2e5f1; border-radius: 16px; }
.lobby-card { border-width: 1px; box-shadow: inset 0 1px 0 #fff,0 3px 0 #d1e2ee; }
.lobby-card .pengy { display: inline-flex; }
.lobby-avatar { width: 34px; height: 38px; flex-shrink: 0; }
.draw-chip { border-width: 1px; box-shadow: 0 2px 0 #cfdfeb; }
.draw-chip { position: relative; padding-left: 42px; min-height: 48px; justify-content: center; }
.draw-face { position: absolute; left: 1px; top: 50%; transform: translateY(-50%); width: 40px; height: 44px; }
.code-input { border-width: 1px; background: linear-gradient(#e7f1fa,#fff); box-shadow: inset 0 2px 5px #44739612; }
.scoreboard {
  background: linear-gradient(145deg,#32699b,#173c65 65%,#142d50);
  border: 2px solid #e3f5ff; border-radius: 21px;
  box-shadow: 0 0 0 2px #8fbcda, inset 0 2px 0 #96c9e9, inset 0 -3px 0 #102843,0 6px 0 #86abc6,0 12px 22px #2549672b;
}
.scoreboard::before, .scoreboard::after { display: none; }
.badge { font-variant-numeric: tabular-nums; }
.score-mid { color: #e1f2ff; }
.skill-btn {
  border-radius: 17px; background: linear-gradient(#4e86b8,#173f6c);
  border: 2px solid #e6f8ff; box-shadow: inset 0 2px 0 #9dcbef,0 3px 0 #719cbc,0 7px 12px #12385833;
}
.skill-btn.on { border-color: #fff0bd; box-shadow: inset 0 2px 0 #bcecff,0 3px 0 #749fbd,0 0 0 2px #d9b267; }
.skill-btn.active { background: linear-gradient(#6fd9ff,#218bc9); box-shadow: 0 3px 0 #176b9c,0 0 14px #7adbff7f; }
.skill-on { background: #237e68; border-width: 1px; border-radius: 5px; }
.skill-left { color: #195581; }
/* Match announcements: a chunky countdown token and a team-colored score ribbon. */
.ov-count, .ov-goal { text-shadow: none; -webkit-text-stroke: 0; }
.ov-count.pop, .ov-goal.show { animation: none; }
.count-disc, .goal-banner, .goal-burst { scale: .85; }
.count-disc {
  position: relative; isolation: isolate; display: flex; flex-direction: column;
  align-items: center; justify-content: center; width: 164px; height: 164px;
  border-radius: 50%; border: 5px solid #f4fdff;
  background: radial-gradient(ellipse at 35% 18%,#66d7fc,#279ada 58%,#126aaa);
  box-shadow: 0 0 0 3px #64b4de, inset 0 3px 0 #c2f2ff,inset 0 -7px 0 #11629d,0 9px 0 #215d92,0 20px 35px #194c7540;
}
.count-disc::before {
  content: ''; position: absolute; inset: -18px; border: 2px solid #ffffffc9;
  border-radius: inherit; box-shadow: 0 0 0 7px #8bd9fc25; z-index: -1;
}
.count-disc::after {
  content: ''; position: absolute; inset: 8px; border-radius: inherit;
  border: 1px solid #d1f6ff70; pointer-events: none;
}
.count-word {
  font-size: 108px; font-weight: 900; line-height: 1; color: #fff;
  letter-spacing: -4px; padding-right: 4px; transform: translateY(-4px);
  -webkit-text-stroke: 1px #d9f7ff;
  text-shadow: 0 3px 0 #8bd4f2,0 7px 0 #145892,0 10px 10px #143e6855;
}
.count-lights { display: flex; gap: 9px; position: absolute; bottom: 17px; }
.count-lights i { width: 10px; height: 10px; border-radius: 50%; background: #135785; box-shadow: inset 0 2px 2px #103d6860; }
.count-lights .lit { background: #ffe799; box-shadow: inset 0 2px 0 #fff,0 0 9px #ffd875aa; }
.ov-count.pop .count-disc { animation: toyCountIn .46s cubic-bezier(.18,.8,.3,1) both; }
.ov-count.pop .count-disc::before { animation: toyCountRing .7s ease-out both; }
.is-go .count-disc {
  width: 244px; height: 138px; border-radius: 38px; transform: rotate(-7deg);
  background: linear-gradient(150deg,#fff0b2,#ffd15a 48%,#ffaf37);
  border-color: #fffaf0; box-shadow: 0 0 0 3px #eaa84b,inset 0 4px 0 #fff7d7,inset 0 -7px 0 #e98c24,0 9px 0 #bd6d24,0 20px 35px #80581740;
}
.is-go .count-word { font-size: 92px; letter-spacing: -5px; color: #fffdf1; -webkit-text-stroke: 2px #b86e23; paint-order: stroke fill; text-shadow: 0 6px 0 #b86e23,0 9px 0 #efac3e; }
.count-speed { position: absolute; bottom: 7px; font-size: 26px; letter-spacing: 10px; line-height: 1; color: #ae6628; }
.ov-count.is-go.pop .count-disc { animation: toyGoIn .55s cubic-bezier(.18,.8,.3,1) both; }
.goal-banner {
  position: relative; display: flex; flex-direction: column; align-items: center;
  width: min(350px,calc(100vw - 40px)); padding: 18px 12px 16px;
  border: 4px solid #fff; border-radius: 30px; transform: rotate(-5deg);
  background: linear-gradient(155deg,#396e9a,#173c64 62%,#122c4d);
  box-shadow: 0 0 0 3px var(--goal-color),inset 0 3px 0 #89b7d7,inset 0 -6px 0 #102742,0 9px 0 var(--goal-dark),0 22px 36px #173d6c40;
}
.goal-banner::before, .goal-banner::after {
  content: ''; position: absolute; top: 45px; width: 36px; height: 69px; z-index: -1;
  background: linear-gradient(var(--goal-color),var(--goal-dark));
}
.goal-banner::before { left: -24px; clip-path: polygon(0 0,100% 8%,100% 100%,0 92%,23% 48%); }
.goal-banner::after { right: -24px; clip-path: polygon(0 8%,100% 0,77% 48%,100% 92%,0 100%); }
.goal-stars { color: #ffdb7a; font-size: 24px; letter-spacing: 12px; padding-left: 12px; line-height: 1; text-shadow: 0 3px 0 #9f6828; white-space: nowrap; }
.goal-stars.many { font-size: 18px; letter-spacing: 3px; padding-left: 3px; }   /* 6点目から（5・10点先取）は詰める */
.goal-word {
  display: block; margin: 7px 0 16px; font-size: clamp(40px,12vw,61px); font-weight: 900; line-height: 1.15;
  white-space: nowrap; letter-spacing: 1px; color: #fff2af; -webkit-text-stroke: 2px #ad6c24; paint-order: stroke fill;
  text-shadow: 0 4px 0 #c48029,0 7px 0 #8b5124,0 11px 10px #10223d80;
}
.goal-team {
  display: flex; align-items: center; justify-content: center; gap: 8px; max-width: 100%; min-width: 65%;
  color: var(--goal-dark); font-size: 16px; line-height: 1.4; padding: 7px 12px;
  border: 2px solid #fff; background: linear-gradient(#fff,#e7f4ff); box-shadow: 0 4px 0 #b2cce0;
}
.goal-team > span { overflow-wrap: anywhere; min-width: 0; }
.goal-team .tie { width: 15px; height: 23px; flex-shrink: 0; }
.goal-team b { flex-shrink: 0; background: var(--goal-color); color: #fff; border-radius: 8px; padding: 1px 6px; font-size: 15px; text-shadow: 0 1px 0 var(--goal-dark); }
.goal-burst { position: absolute; left: 50%; top: 50%; width: 0; height: 0; }
.goal-burst i {
  position: absolute; width: 9px; height: 17px; border-radius: 2px; background: var(--goal-color);
  transform: translate(var(--x),var(--y)) rotate(var(--spin));
}
.goal-burst i:nth-child(3n) { background: #ffc74f; }
.goal-burst i:nth-child(3n + 1) { background: #fff; box-shadow: 0 0 0 1px #9cd5f8; }
.ov-goal.show .goal-banner { animation: toyGoalIn .5s cubic-bezier(.17,.8,.25,1) both; }
.ov-goal.show .goal-burst i { animation: toyConfetti 1.25s ease-out var(--delay) both; }
@keyframes toyCountIn { 0% { transform: scale(.6) rotate(-12deg); opacity: 0; } 65% { transform: scale(1.08) rotate(3deg); opacity: 1; } 100% { transform: scale(1) rotate(0); } }
@keyframes toyCountRing { from { transform: scale(.8); opacity: 1; } to { transform: scale(1.18); opacity: 0; } }
@keyframes toyGoIn { 0% { transform: scale(.65) rotate(-14deg); opacity: 0; } 50% { transform: scale(1.09) rotate(-5deg); opacity: 1; } 100% { transform: scale(1) rotate(-7deg); } }
@keyframes toyGoalIn { 0% { transform: translateY(30px) scale(.55) rotate(-12deg); opacity: 0; } 65% { transform: translateY(-5px) scale(1.05) rotate(-3deg); opacity: 1; } 100% { transform: translateY(0) scale(1) rotate(-5deg); } }
@keyframes toyConfetti { 0% { transform: translate(0,0) rotate(0); opacity: 0; } 15% { opacity: 1; } 80% { opacity: 1; } 100% { transform: translate(var(--x),calc(var(--y) + 35px)) rotate(var(--spin)); opacity: 0; } }
.lp-card { border: 1px solid #fff; background: #ffffffeb; box-shadow: inset 0 2px 0 #fff,0 5px 0 #c5deee,0 18px 40px #3b6f8f18; }
.lang-row a { border: 1px solid #fff; box-shadow: 0 2px 0 #c0d9ea; }
@keyframes toyFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@media (min-width: 850px) and (min-height: 620px) {
  .title-panel { width: min(860px,95%); display: grid; grid-template-columns: 1fr 1fr; column-gap: 34px; padding: 36px; }
  .title-penguin { grid-column: 1; grid-row: 1 / 6; align-self: center; }
  #title-peng { width: 350px; height: 300px; }
  .title-panel > :not(.title-penguin):not(.logo-img) { grid-column: 2; }
  .title-panel .logo-img { grid-column: 1; grid-row: 1 / 6; align-self: center; margin: 0 -10px; }
  .title-panel .logo { font-size: 46px; }
  .title-panel .tagline { margin-top: 4px; }
}
@media (max-height: 760px) and (max-width: 849px) {
  #title-peng { height: 119px; width: 240px; }
  .title-panel { padding: 10px 22px 20px; }
  .title-panel .logo { font-size: 36px; margin-bottom: 10px; }
  .title-panel .tagline { margin-bottom: 12px; font-size: 11px; }
  .title-panel .name-row { padding-top: 8px; padding-bottom: 8px; margin-bottom: 12px; }
  .title-panel .btn-big { padding-top: 12px; padding-bottom: 12px; }
  .title-panel .title-note { margin-top: 10px; }
  .talk-panel #talk-peng { width: 140px; height: 140px; }
}
@media (max-height: 640px) {
  #title-peng { height: 90px; width: 210px; }
  .title-panel .logo-img { margin: -6px 12px 2px; }   /* 背の低い画面ではロゴを少し小さく */
  .title-panel .logo { font-size: 30px; }
  .title-panel .tagline { margin-bottom: 9px; }
  .title-panel .btn-big { padding-top: 10px; padding-bottom: 10px; }
  .title-panel .menu { gap: 9px; }
  .title-panel .title-note { margin-top: 8px; }
  .talk-panel #talk-peng { width: 115px; height: 115px; }
  .result-peng { width: 70px; height: 70px; }
  #screen-solo .draw-chip { padding-left: 35px; min-height: 39px; }
  #screen-solo .draw-face { width: 34px; height: 38px; }
}
@media (max-width: 360px) {
  .panel { padding-left: 17px; padding-right: 17px; }
  .stage { gap: 7px; }
  .stage-face { width: 45px; height: 45px; }
  .scoreboard { gap: 5px; padding-left: 9px; padding-right: 9px; }
  .badge { gap: 3px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
