/* Odd One Out: Outsmart the Crowd. Contained, accessible party-game effects. */
#r20MiniGame[data-game="odd"] .ccc-odd-twist-label{
 width:min(100%,900px);margin:5px auto 9px;padding:8px 15px;
 border:2px solid #f5d38a;border-radius:14px;
 background:linear-gradient(105deg,#704590,#243f80 65%,#155c7c);
 color:#fff4c5;text-align:center;letter-spacing:.045em;
 font-size:clamp(12px,1.6vw,21px);font-weight:950;
 box-shadow:0 0 14px #f4cc774d,inset 0 0 12px #a4ccff33;
}
#r20MiniGame[data-game="odd"] .ccc-odd-decision-stage{
 text-align:center;max-width:1400px;margin:0 auto;
}
#r20MiniGame[data-game="odd"] .ccc-odd-switch-progress,
#r20MiniGame[data-game="odd"] .ccc-odd-suspense-caption{
 margin:12px auto;padding:12px 18px;width:min(100%,950px);
 border-radius:16px;border:2px solid #ffdb81;
 background:#1a375f;color:#fff1c4;
 font-size:clamp(16px,2vw,26px);font-weight:950;text-align:center;
}
#r20MiniGame[data-game="odd"] .ccc-odd-switch-actions{
 display:grid;grid-template-columns:repeat(2,minmax(0,1fr));
 gap:clamp(7px,1.4vw,15px);max-width:720px;
 margin:10px auto 15px;
}
#r20MiniGame[data-game="odd"] .ccc-odd-switch-actions button{
 min-width:0;min-height:clamp(58px,10vh,88px);
 border:2px solid #ffdb91;border-radius:18px;
 background:linear-gradient(130deg,#664e99,#245581);
 box-shadow:0 5px 13px #081b47ad,inset 0 2px 8px #fff4c126;
 color:#fff8cf;font-size:clamp(14px,3.6vw,20px);
 font-weight:1000;white-space:normal;
}
#r20MiniGame[data-game="odd"] .ccc-odd-switch-actions .ccc-odd-switch-keep{
 background:linear-gradient(135deg,#198a74,#136b70);
}
#r20MiniGame[data-game="odd"] .ccc-odd-switch-actions button:disabled{
 opacity:.7;filter:saturate(.55);
}
#r20MiniGame[data-game="odd"] .ccc-odd-suspense-grid{
 position:relative;overflow:hidden;isolation:isolate;
}
#r20MiniGame[data-game="odd"] .ccc-odd-suspense-grid .ccc-chest-card{
 transform:none;animation:oddCaseRattle .17s ease-in-out 8 alternate;
 animation-delay:.5s;
}
#r20MiniGame[data-game="odd"] .ccc-odd-suspense-countdown{
 display:grid;place-items:center;margin:6px auto;
 color:#ffeba4;font-weight:1000;font-size:clamp(25px,4vw,58px);
 text-shadow:0 0 22px #ffc15a;
 animation:oddStagePulse .7s ease-in-out 4 alternate;
}
#r20MiniGame[data-game="odd"] .ccc-odd-cinematic-reveal{
 position:relative;isolation:isolate;max-width:1460px;margin:auto;
}
#r20MiniGame[data-game="odd"] .ccc-odd-cinematic-reveal .ccc-odd-reveal-grid{
 display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;
 width:min(100%,1370px);gap:clamp(5px,1vw,13px);
}
#r20MiniGame[data-game="odd"] .ccc-odd-reveal-grid .ccc-chest-card{
 min-width:0;display:flex;flex-direction:column;align-items:center;justify-content:flex-start;
 overflow:hidden!important;padding:clamp(6px,.8vw,11px)!important;
 border-radius:16px;box-shadow:0 4px 12px #081731aa;
}
#r20MiniGame[data-game="odd"] .ccc-odd-reveal-people{
 display:flex;flex-wrap:wrap;justify-content:center;align-content:start;
 gap:4px;width:100%;min-height:clamp(44px,11vh,125px);
 max-height:clamp(60px,17vh,155px);overflow:hidden;
}
#r20MiniGame[data-game="odd"] .ccc-odd-player-chip{
 display:inline-flex;align-items:center;justify-content:center;
 max-width:100%;min-width:0;min-height:24px;padding:3px 7px;
 border-radius:99px;border:1px solid #ffe3a0;
 background:linear-gradient(135deg,#244e83,#493c8e);
 color:#fff9d2;font-size:clamp(10px,1.2vw,15px);
 font-weight:900;overflow-wrap:anywhere;line-height:1.1;
 opacity:0;animation:oddNameArrives .62s cubic-bezier(.18,.78,.18,1) both;
}
#r20MiniGame[data-game="odd"] .ccc-odd-empty{
 font-size:clamp(10px,1vw,14px);color:#d2dceb;align-self:center;
}
#r20MiniGame[data-game="odd"] .ccc-odd-reward-label{
 display:block;min-height:27px;margin-top:6px;
 padding:5px 7px;border-radius:11px;background:#17345f;
 color:#fff5b8;font-size:clamp(10px,1.1vw,15px);font-weight:1000;
 opacity:0;animation:oddNameArrives .4s ease-out both;
}
#r20MiniGame[data-game="odd"] .ccc-odd-results-grid.ccc-odd-score-reveal{
 animation:oddNameArrives .4s ease both;opacity:0;
}
@keyframes oddNameArrives{
 0%{opacity:0;transform:translateY(8px) scale(.97)}
 100%{opacity:1;transform:none}
}
/* Openings follow the same server-clock offsets as each player's reveal. */
#r20MiniGame[data-game="odd"] .ccc-odd-reveal-grid .ccc-odd-opening-chest{
 animation:cccOddChestOpening .65s cubic-bezier(.2,.85,.25,1) var(--ccc-odd-open-delay,0s) both;
}
@keyframes cccOddChestOpening{
 0%{filter:brightness(.76);transform:scale(.965)}
 22%{filter:brightness(.92);transform:translateY(-2px) rotate(-.65deg) scale(.985)}
 43%{filter:brightness(1.65);transform:translateY(1px) rotate(.45deg) scale(1.055)}
 75%{filter:brightness(1.28);transform:translateY(-2px) scale(1.02)}
 100%{filter:brightness(1);transform:none}
}
/* Treasure Tactics only. The lid, light and name chips use the same opening
   offset as the existing server-clock-synced chest sound. */
#r20MiniGame[data-game="odd"] .ccc-odd-reveal-grid .ccc-odd-svg-art{position:relative;isolation:isolate;overflow:visible}
#r20MiniGame[data-game="odd"] .ccc-odd-opening-chest .ccc-odd-chest-lid{
 transform-box:view-box;transform-origin:50% 52%;
 animation:cccOddLidLift 1.12s cubic-bezier(.2,.75,.25,1) var(--ccc-odd-open-delay,0s) both;
}
#r20MiniGame[data-game="odd"] .ccc-odd-opening-chest .ccc-odd-svg-art::before{
 content:'';position:absolute;inset:15% 9% 20%;z-index:2;pointer-events:none;
 border-radius:50%;background:radial-gradient(ellipse at 50% 42%,#fff4baea 0%,#ffe07880 28%,#f7ba3d00 72%);
 mix-blend-mode:screen;opacity:0;
 animation:cccOddTreasureFlash 1.15s ease-out var(--ccc-odd-flare-delay,0s) both;
}
#r20MiniGame[data-game="odd"] .ccc-odd-opening-chest .ccc-odd-svg-art::after{
 content:'✦ ✧ ✦';position:absolute;z-index:3;left:5%;right:5%;top:6%;
 text-align:center;pointer-events:none;font-size:clamp(13px,2.15vw,29px);
 letter-spacing:.25em;color:#ffedb5;text-shadow:0 0 9px #fff1a7,0 0 18px #fbc756;
 opacity:0;animation:cccOddTreasureSparkle 1.22s ease-out var(--ccc-odd-flare-delay,0s) both;
}
#r20MiniGame[data-game="odd"] .ccc-odd-reveal-grid .ccc-odd-opening-chest.odd-unique{
 animation:cccOddChestOpening .65s cubic-bezier(.2,.85,.25,1) var(--ccc-odd-open-delay,0s) both,
   cccOddUniqueGlow 1.25s ease-out var(--ccc-odd-open-delay,0s) both;
}
#r20MiniGame[data-game="odd"] .ccc-odd-reveal-grid .ccc-odd-opening-chest.odd-consolation{
 animation:cccOddChestOpening .65s cubic-bezier(.2,.85,.25,1) var(--ccc-odd-open-delay,0s) both,
   cccOddConsolationGlow 1.15s ease-out var(--ccc-odd-open-delay,0s) both;
}
@keyframes cccOddLidLift{
 0%,15%{transform:translateY(0) scaleY(1)}
 35%{transform:translateY(-13px) scaleY(.93) rotate(-2deg)}
 54%{transform:translateY(-19px) scaleY(.89) rotate(-3deg)}
 76%{transform:translateY(-15px) scaleY(.91) rotate(-2deg)}
 100%{transform:translateY(-14px) scaleY(.92) rotate(-2deg)}
}
@keyframes cccOddTreasureFlash{
 0%,16%{opacity:0;transform:scale(.6)}
 40%{opacity:.94;transform:scale(1.12)}
 75%{opacity:.45;transform:scale(1.36)}
 100%{opacity:0;transform:scale(1.55)}
}
@keyframes cccOddTreasureSparkle{
 0%,18%{opacity:0;transform:translateY(6px) scale(.7)}
 43%{opacity:1;transform:translateY(-8px) scale(1.05)}
 78%{opacity:.55;transform:translateY(-16px) scale(1.1)}
 100%{opacity:0;transform:translateY(-22px) scale(1.15)}
}
@keyframes cccOddUniqueGlow{
 0%,22%{box-shadow:0 4px 12px #081731aa;border-color:#9fbbdf}
 48%{box-shadow:0 0 27px #ffe590d9,0 0 0 2px #ffe6a7a0;border-color:#fff0a7}
 100%{box-shadow:0 0 14px #ffd97b7d,0 0 0 1px #ffeb9a;border-color:#ffeb9a}
}
@keyframes cccOddConsolationGlow{
 0%,22%{box-shadow:0 4px 12px #081731aa}
 48%{box-shadow:0 0 20px #8bf6df9e;border-color:#a6ffe5}
 100%{box-shadow:0 0 11px #8bf6df55;border-color:#a6ffe5}
}
@media(prefers-reduced-motion:reduce){
 #r20MiniGame[data-game="odd"] .ccc-odd-reveal-grid .ccc-odd-opening-chest,
 #r20MiniGame[data-game="odd"] .ccc-odd-opening-chest .ccc-odd-chest-lid,
 #r20MiniGame[data-game="odd"] .ccc-odd-opening-chest .ccc-odd-svg-art::before,
 #r20MiniGame[data-game="odd"] .ccc-odd-opening-chest .ccc-odd-svg-art::after{
  animation:none!important;transform:none!important
 }
}
@keyframes oddCaseRattle{
 0%{transform:translateX(-2px) rotate(-.6deg)}
 100%{transform:translateX(2px) rotate(.6deg)}
}
@keyframes oddStagePulse{
 0%{filter:brightness(1)}
 100%{filter:brightness(1.7)}
}
@media(max-width:700px){
 #r20MiniGame.r20-mg-phone[data-game="odd"] .ccc-odd-switch-actions{
  grid-template-columns:repeat(2,minmax(0,1fr));
 }
 #r20MiniGame.r20-mg-phone[data-game="odd"] .ccc-odd-cinematic-reveal .ccc-odd-reveal-grid{
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
 }
}
@media(max-height:720px){
 #r20MiniGame.r20-mg-tv[data-game="odd"] .ccc-odd-reveal-people{min-height:30px;max-height:85px}
 #r20MiniGame.r20-mg-tv[data-game="odd"] .ccc-odd-reveal-grid .ccc-chest-art{height:clamp(50px,10vh,80px)!important}
 #r20MiniGame.r20-mg-tv[data-game="odd"] .ccc-odd-reward-label{margin-top:2px;padding:3px 6px}
}
@media(prefers-reduced-motion:reduce){
 #r20MiniGame[data-game="odd"] .ccc-odd-player-chip,
 #r20MiniGame[data-game="odd"] .ccc-odd-reward-label,
 #r20MiniGame[data-game="odd"] .ccc-odd-results-grid.ccc-odd-score-reveal{
  animation:none!important;opacity:1!important;transform:none!important;
 }
 #r20MiniGame[data-game="odd"] .ccc-odd-suspense-grid .ccc-chest-card,
 #r20MiniGame[data-game="odd"] .ccc-odd-suspense-countdown{animation:none!important}
}
/* A real 3–2–1 sequence, synced to the server's fixed 2.8-second stage. */
#r20MiniGame[data-game="odd"] .ccc-odd-suspense-stage{
 background:radial-gradient(ellipse at 50% 22%,#423869,#142a4b 77%);
 border:2px solid #d5b579;border-radius:23px;
 padding:clamp(9px,1.3vw,20px);isolation:isolate;
}
#r20MiniGame[data-game="odd"] .ccc-odd-suspense-stage .ccc-odd-suspense-grid{
 animation:oddLightsDown 2.8s linear both;
}
#r20MiniGame[data-game="odd"] .ccc-odd-suspense-countdown{
 display:grid;place-items:center;height:clamp(56px,10vh,105px);
 min-height:50px;margin:0 auto;animation:none!important;
}
#r20MiniGame[data-game="odd"] .ccc-odd-suspense-countdown .ccc-odd-count-digit{
 grid-area:1/1;color:#fff2aa;font-size:clamp(44px,8vw,100px);
 font-weight:1000;line-height:1;
 text-shadow:0 0 18px #ffe7b1,0 0 30px #ffad57;
 opacity:0;animation:oddCountBeat .85s ease-in-out both;
}
@keyframes oddCountBeat{
 0%{opacity:0;transform:scale(1.45)}
 20%{opacity:1;transform:scale(1)}
 80%{opacity:1;transform:scale(.95)}
 100%{opacity:0;transform:scale(.78)}
}
@keyframes oddLightsDown{
 0%{filter:brightness(1)}
 18%{filter:brightness(.38)}
 82%{filter:brightness(.26)}
 100%{filter:brightness(1.6)}
}
@media(prefers-reduced-motion:reduce){
 #r20MiniGame[data-game="odd"] .ccc-odd-suspense-stage .ccc-odd-suspense-grid{animation:none!important}
 #r20MiniGame[data-game="odd"] .ccc-odd-count-digit{animation:none!important}
 #r20MiniGame[data-game="odd"] .ccc-odd-count-digit:first-child{opacity:1!important}
}

/* Crowded-case fallback: ten names must remain visible without scrolling. */
#r20MiniGame[data-game="odd"] .ccc-odd-busy-case .ccc-odd-reveal-people{
 display:grid;grid-template-columns:repeat(2,minmax(0,1fr));
 width:100%;align-items:start;align-content:start;justify-items:stretch;
 min-height:0;max-height:190px;overflow:visible;gap:3px;
}
#r20MiniGame[data-game="odd"] .ccc-odd-busy-case .ccc-odd-player-chip{
 width:100%;max-width:100%;padding:3px 4px;
 font-size:clamp(9px,.9vw,12px);white-space:normal;
 overflow-wrap:anywhere;word-break:break-word;line-height:1.05;
}
@media(max-height:720px){
 #r20MiniGame.r20-mg-tv[data-game="odd"] .ccc-odd-busy-case .ccc-odd-reveal-people{max-height:160px}
 #r20MiniGame.r20-mg-tv[data-game="odd"] .ccc-odd-busy-case .ccc-odd-player-chip{font-size:10px;min-height:20px}
}


/* Final overall-winner reveal. Separate from the per-round chest countdown. */
#r20MiniGame.r20-mg-tv[data-game="odd"][data-stage="odd_winner_suspense"] :is(.r20-mg-scores,.r20-mg-footer){
 display:none!important;
}
#r20MiniGame.r20-mg-tv[data-game="odd"][data-stage="odd_winner_suspense"] .r20-mg-layout{
 min-height:100dvh!important;height:auto!important;max-height:none!important;
 box-sizing:border-box!important;justify-content:flex-start!important;
 padding-top:clamp(65px,9dvh,100px)!important;
 padding-bottom:clamp(12px,2dvh,24px)!important;
 gap:clamp(5px,.8dvh,10px)!important;
}
#r20MiniGame.r20-mg-tv[data-game="odd"][data-stage="odd_winner_suspense"] .r20-mg-center{
 flex:1!important;min-height:0!important;max-height:none!important;overflow:visible!important;
}
#r20MiniGame.r20-mg-tv[data-game="odd"][data-stage="odd_winner_suspense"] .r20-mg-stage-main{
 width:min(100%,1150px)!important;max-width:1150px!important;
 min-height:0!important;max-height:none!important;box-sizing:border-box!important;
 padding:4px!important;background:transparent!important;border:0!important;box-shadow:none!important;
}
#r20MiniGame[data-game="odd"] .ccc-odd-grand-finale{
 width:100%;display:grid;justify-items:center;gap:0;
}
#r20MiniGame[data-game="odd"] .ccc-odd-final-countdown{
 position:relative;isolation:isolate;overflow:hidden;
 width:min(100%,1100px);min-height:clamp(300px,57dvh,610px);
 display:flex;flex-direction:column;align-items:center;justify-content:center;
 gap:clamp(8px,1.3dvh,16px);padding:clamp(15px,2dvh,30px);
 box-sizing:border-box;text-align:center;
 border:3px solid #ffda8b;border-radius:25px;
 background:radial-gradient(ellipse at 50% 40%,#51428e,#18386a 65%,#081a40);
 box-shadow:inset 0 2px #fff5d080,0 8px 0 #7d4e23,0 14px 35px #0008;
}
#r20MiniGame[data-game="odd"] .ccc-odd-final-countdown:before{
 content:"";position:absolute;inset:-50%;z-index:-1;pointer-events:none;
 background:repeating-conic-gradient(from 0deg at 50% 50%,#b5d7ff16 0deg 11deg,transparent 12deg 24deg);
 animation:oddFinalRays 12s linear infinite;
}
@keyframes oddFinalRays{to{transform:rotate(360deg)}}
#r20MiniGame[data-game="odd"] .ccc-odd-final-eyebrow{
 font-size:clamp(16px,2.7dvh,29px);font-weight:1000;color:#ffe4a3;letter-spacing:.1em;
}
#r20MiniGame[data-game="odd"] .ccc-odd-final-title{
 font-size:clamp(25px,4.7dvh,53px);font-weight:1000;line-height:1.08;
 color:#fff7d9;text-shadow:0 4px 14px #0009;margin:0;
}
#r20MiniGame[data-game="odd"] .ccc-odd-final-digits{
 position:relative;width:min(100%,310px);height:clamp(125px,26dvh,275px);
 display:grid;place-items:center;border-radius:50%;
 background:radial-gradient(circle,#ffc65b46,transparent 72%);
}
#r20MiniGame[data-game="odd"] .ccc-odd-final-digit{
 position:absolute;inset:0;display:grid;place-items:center;
 opacity:0;font-weight:1000;line-height:1;font-size:clamp(105px,24dvh,255px);
 color:#ffebaf;-webkit-text-stroke:1px #fff6d1;
 text-shadow:0 6px #ae662c,0 12px 22px #000a,0 0 35px #ffde88;
 animation:oddFinalDigit 1s ease-out both;
 animation-delay:calc(.15s + var(--odd-final-index)*1s - var(--odd-final-elapsed,0s));
}
@keyframes oddFinalDigit{
 0%{opacity:0;transform:scale(.45) rotate(-8deg)}
 19%{opacity:1;transform:scale(1.16)}
 74%{opacity:1;transform:scale(1)}
 100%{opacity:0;transform:scale(1.4)}
}
#r20MiniGame[data-game="odd"] .ccc-odd-final-announce{
 font-size:clamp(20px,3.4dvh,38px);font-weight:1000;color:#ffe8a3;
 opacity:0;animation:oddFinalAnnounce .6s ease-out both;
 animation-delay:calc(3.2s - var(--odd-final-elapsed,0s));
 text-shadow:0 4px 12px #0008;
}
@keyframes oddFinalAnnounce{
 from{opacity:0;transform:translateY(17px)}to{opacity:1;transform:none}
}
@media(max-height:720px){
 #r20MiniGame[data-game="odd"] .ccc-odd-final-countdown{
  min-height:clamp(250px,48dvh,400px);padding:10px;gap:6px;
 }
 #r20MiniGame[data-game="odd"] .ccc-odd-final-digits{height:21dvh}
 #r20MiniGame[data-game="odd"] .ccc-odd-final-digit{font-size:20dvh}
}
@media(prefers-reduced-motion:reduce){
 #r20MiniGame[data-game="odd"] .ccc-odd-final-countdown:before{animation:none}
 #r20MiniGame[data-game="odd"] .ccc-odd-final-digit{animation:none;opacity:0}
 #r20MiniGame[data-game="odd"] .ccc-odd-final-digit:last-child{opacity:1}
 #r20MiniGame[data-game="odd"] .ccc-odd-final-announce{animation:none;opacity:1}
}
