.connect-four-root{width:100%;max-width:33rem;color:var(--body);font-family:var(--font-sans,system-ui, sans-serif);--board:#1a52cc;--board-edge:#1242a8;--well:var(--canvas);--rim:#0000004d;--red-1:#ff6f66;--red-2:#e23b3b;--red-3:#bd2f2f;--yel-1:#ffe389;--yel-2:#f5c130;--yel-3:#d9a31c;--cf-shadow:0 18px 50px #0000002e, 0 2px 8px #00000014;flex-direction:column;gap:1.25rem;margin-inline:auto;padding-top:.5rem;padding-bottom:1rem;line-height:1.5;display:flex}.dark .connect-four-root{--board:#2057cf;--board-edge:#15409c;--rim:#00000073;--cf-shadow:0 18px 50px #0000008c, 0 2px 8px #00000059}.connect-four-root .cf-app{flex-direction:column;justify-content:center;gap:1.25rem;min-height:0;display:flex}.connect-four-root .cf-header{text-align:center}.connect-four-root h1{font-family:var(--font-serif,Georgia, serif);letter-spacing:-.02em;color:var(--heading);margin:0;font-size:clamp(1.75rem,6vw,2.4rem);font-weight:600}.connect-four-root .cf-legend{color:var(--muted);gap:1.1rem;margin-top:.4rem;font-size:.85rem;display:inline-flex}.connect-four-root .cf-legend span{align-items:center;gap:.45rem;display:inline-flex}.connect-four-root .cf-legend i{border-radius:50%;width:.85rem;height:.85rem;box-shadow:inset 0 0 0 1px #00000026}.connect-four-root .cf-legend .red{background:radial-gradient(circle at 35% 30%, var(--red-1), var(--red-2))}.connect-four-root .cf-legend .yellow{background:radial-gradient(circle at 35% 30%, var(--yel-1), var(--yel-2))}.connect-four-root .cf-controls{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:1rem;display:flex}.connect-four-root .cf-difficulty{border:1px solid var(--border);background:#00000006;border-radius:11px;gap:2px;padding:3px;display:inline-flex}.dark .connect-four-root .cf-difficulty{background:#ffffff0a}.connect-four-root .cf-difficulty button{color:var(--body);font:inherit;cursor:pointer;background:0 0;border:0;border-radius:8px;padding:.4rem .85rem;font-size:.9rem;transition:background .15s,color .15s}.connect-four-root .cf-difficulty button:hover{color:var(--heading)}.connect-four-root .cf-difficulty button[aria-pressed=true]{background:var(--accent-bg);color:var(--accent-fg)}.connect-four-root .cf-btn{border:1px solid var(--border);background:var(--accent-bg);color:var(--accent-fg);font:inherit;cursor:pointer;border-radius:10px;padding:.5rem 1.1rem;font-size:.9rem;font-weight:500;transition:opacity .15s,transform 50ms}.connect-four-root .cf-btn:hover{opacity:.85}.connect-four-root .cf-btn:active{transform:translateY(1px)}.connect-four-root .cf-status{min-height:1.6rem;color:var(--heading);justify-content:center;align-items:center;gap:.6rem;font-size:1rem;font-weight:500;display:flex}.connect-four-root .cf-turn-dot{background:var(--muted);border-radius:50%;flex:none;width:.8rem;height:.8rem;box-shadow:inset 0 0 0 1px #0000001f}.connect-four-root .cf-turn-dot.red{background:radial-gradient(circle at 35% 30%, var(--red-1), var(--red-2))}.connect-four-root .cf-turn-dot.yellow{background:radial-gradient(circle at 35% 30%, var(--yel-1), var(--yel-2))}.connect-four-root .cf-turn-dot.thinking{animation:.9s ease-in-out infinite cf-pulse}@keyframes cf-pulse{0%,to{opacity:1}50%{opacity:.35}}.connect-four-root .cf-board-wrap{justify-content:center;display:flex}.connect-four-root .cf-board{--cols:7;--rows:6;--frame:clamp(9px, 2.6vw, 16px);width:min(94vw,30rem);padding:var(--frame);background:var(--board);box-shadow:var(--cf-shadow), inset 0 2px 0 #ffffff1f, inset 0 -3px 0 var(--board-edge);border-radius:clamp(14px,4vw,22px)}.connect-four-root .cf-playfield{aspect-ratio:var(--cols) / var(--rows);border-radius:6px;position:relative;overflow:hidden}.connect-four-root .cf-layer{position:absolute;inset:0}.connect-four-root .cf-well{background:var(--well)}.connect-four-root .cf-lattice{grid-template-columns:repeat(var(--cols), 1fr);grid-template-rows:repeat(var(--rows), 1fr);pointer-events:none;display:grid}.connect-four-root .cf-cell{background:radial-gradient(circle closest-side, transparent 0 73%, var(--rim) 73% 78%, var(--board) 78%)}.connect-four-root .cf-columns{grid-template-columns:repeat(var(--cols), 1fr);display:grid}.connect-four-root .cf-columns button{cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent;background:0 0;border:0;padding:0}@media (hover:hover) and (pointer:fine){.connect-four-root .cf-columns button:not(:disabled):hover{background:#ffffff12}}.connect-four-root .cf-columns button:disabled{cursor:default}.connect-four-root .cf-columns button:focus-visible{outline:2px solid var(--accent-bg);outline-offset:-3px;background:#ffffff1a}.connect-four-root .cf-disc{width:calc(100% / var(--cols));height:calc(100% / var(--rows));left:calc(var(--col) * 100% / var(--cols));top:calc(var(--row) * 100% / var(--rows));place-items:center;display:grid;position:absolute}.connect-four-root .cf-piece{aspect-ratio:1;border-radius:50%;width:82%;box-shadow:inset -2px -3px 6px #00000038,inset 2px 2px 5px #ffffff59}.connect-four-root .cf-disc.red .cf-piece{background:radial-gradient(circle at 35% 30%, var(--red-1), var(--red-2) 55%, var(--red-3))}.connect-four-root .cf-disc.yellow .cf-piece{background:radial-gradient(circle at 35% 30%, var(--yel-1), var(--yel-2) 55%, var(--yel-3))}.connect-four-root .cf-disc.ghost{opacity:.4}.connect-four-root .cf-disc.falling{animation:cf-drop var(--fall-ms,.38s) cubic-bezier(.45, .05, .4, 1) both}@keyframes cf-drop{0%{transform:translateY(calc((var(--row) + 1) * -100%))}55%{transform:translateY(0)}70%{transform:translateY(-6%)}85%{transform:translateY(0)}93%{transform:translateY(-2%)}to{transform:translateY(0)}}.connect-four-root .cf-board.has-winner .cf-disc:not(.win) .cf-piece{opacity:.45}.connect-four-root .cf-disc.win .cf-piece{animation:1.1s ease-in-out infinite cf-winpulse;box-shadow:inset 0 0 0 4px #fffffff2,0 0 14px 2px #ffffff8c}@keyframes cf-winpulse{0%,to{transform:scale(1)}50%{transform:scale(1.06)}}@media (prefers-reduced-motion:reduce){.connect-four-root .cf-disc.falling{animation-duration:1ms}.connect-four-root .cf-disc.win .cf-piece,.connect-four-root .cf-turn-dot.thinking{animation:none}}
