#custom-bingo-app {--cb-accent:#166a60;--cb-soft:#e9f5ef;--cb-text:#213b39;--cb-border:#d6e6df;color:var(--cb-text);font-family:-apple-system,BlinkMacSystemFont,"Noto Sans JP",sans-serif;line-height:1.7}
#custom-bingo-app *,#custom-bingo-app *::before,#custom-bingo-app *::after {box-sizing:border-box}
#custom-bingo-app [hidden] {display:none!important}
#custom-bingo-app h2,#custom-bingo-app h3 {background:none;border:0;border-radius:0;padding:0;margin:0 0 16px;line-height:1.5;color:var(--cb-text);font-weight:750}
#custom-bingo-app h2 {font-size:1.15rem}
#custom-bingo-app h3 {font-size:.95rem}
#custom-bingo-app h2::before,#custom-bingo-app h2::after,#custom-bingo-app h3::before,#custom-bingo-app h3::after {content:none!important;display:none!important;background:none!important;width:auto!important;height:auto!important}
#custom-bingo-app p {margin:0 0 14px}
#custom-bingo-app button,#custom-bingo-app input,#custom-bingo-app select,#custom-bingo-app textarea {font:inherit}
#custom-bingo-app button,#custom-bingo-app .cb-file-button {display:inline-flex;align-items:center;justify-content:center;min-height:44px;cursor:pointer;border:1px solid var(--cb-border);border-radius:10px;padding:10px 15px;background:#fff;color:var(--cb-accent);font-size:.87rem;font-weight:650;line-height:1.4;text-align:center;transition:background .15s,box-shadow .15s}
#custom-bingo-app button:hover,#custom-bingo-app .cb-file-button:hover {background:var(--cb-soft)}
#custom-bingo-app button:disabled {opacity:.45;cursor:default}
#custom-bingo-app input,#custom-bingo-app select,#custom-bingo-app textarea {display:block;width:100%;min-width:0;border:1px solid #b7cec4;background:#fff;color:var(--cb-text);border-radius:9px;padding:10px 12px;box-shadow:none;margin:0 0 16px}
#custom-bingo-app textarea {resize:vertical;line-height:1.85;font-size:.94rem}
#custom-bingo-app input[type=checkbox] {width:18px;height:18px;margin:0;accent-color:var(--cb-accent);flex:none}
#custom-bingo-app label {display:block;font-size:.88rem;font-weight:650;margin:0 0 7px}
#custom-bingo-app :focus-visible {outline:3px solid #c47635;outline-offset:3px}
#custom-bingo-app .cb-intro {padding:26px;border:1px solid var(--cb-border);border-radius:18px;background:linear-gradient(125deg,#edf8f1,#faf7ed);margin-bottom:20px}
#custom-bingo-app .cb-eyebrow {font-size:1.1rem;color:var(--cb-accent);font-weight:750;letter-spacing:.05em}
#custom-bingo-app .cb-lead {font-size:.95rem}
#custom-bingo-app .sticky-note {font-size:.76rem;color:#647972;margin:8px 0 0}
#custom-bingo-app .cb-project-bar {display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;margin:16px 0;font-size:.85rem;font-weight:650}
#custom-bingo-app .cb-actions {display:flex;gap:8px;flex-wrap:wrap}
#custom-bingo-app .cb-actions label {margin:0}
#custom-bingo-app .cb-status {padding:12px 16px;border-radius:9px;background:#f0f6f3;font-size:.86rem;color:#335d4d;overflow-wrap:anywhere;min-height:48px}
#custom-bingo-app .cb-error {padding:12px 16px;border-left:3px solid #b04730;border-radius:6px;background:#fff0ec;color:#8c3023;font-size:.9rem;white-space:pre-line;overflow-wrap:anywhere}
#custom-bingo-app .cb-tabs {display:flex;gap:6px;background:#eef4f0;padding:6px;border-radius:13px;margin:20px 0}
#custom-bingo-app .cb-tabs button {flex:1;gap:9px;border:0;background:transparent;padding:12px 8px;color:#577367;min-width:0}
#custom-bingo-app .cb-tabs button[aria-selected=true] {background:#fff;color:var(--cb-accent);box-shadow:0 3px 12px #183e2410}
#custom-bingo-app .cb-tabs span {font-size:.72rem;letter-spacing:.05em;opacity:.7}
#custom-bingo-app .cb-panel {padding:25px;border:1px solid var(--cb-border);background:#fff;border-radius:16px;box-shadow:0 4px 20px #13382b08;margin-bottom:20px;min-width:0}
#custom-bingo-app .cb-editor-layout {display:grid;grid-template-columns:minmax(0,1.5fr) minmax(230px,1fr);gap:20px;align-items:start}
#custom-bingo-app .cb-settings {position:sticky;top:20px}
#custom-bingo-app .cb-presets {display:flex;gap:6px;flex-wrap:wrap;align-items:center;margin:12px 0 18px}
#custom-bingo-app .cb-presets span {font-size:.76rem;color:#678075;width:100%}
#custom-bingo-app .cb-presets button {font-size:.78rem;padding:7px 12px}
#custom-bingo-app .cb-help {font-size:.78rem;color:#61786f;overflow-wrap:anywhere}
#custom-bingo-app .cb-check {display:flex;align-items:center;gap:9px;font-weight:500;margin:10px 0 18px}
#custom-bingo-app .cb-needed {font-size:.8rem;padding:10px 12px;background:var(--cb-soft);border-radius:8px;margin:0 0 20px}
#custom-bingo-app .cb-section-top {display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin:10px 0 14px}
#custom-bingo-app .cb-section-top h2,#custom-bingo-app .cb-section-top h3 {margin:0}
#custom-bingo-app .cb-tag {font-size:.72rem;color:#557364;padding:3px 10px;border-radius:20px;background:#edf5f0}
#custom-bingo-app .cb-upload {cursor:pointer;padding:20px 12px;border:1px dashed #8fb7a3;border-radius:10px;background:#f7fbf8;text-align:center;color:var(--cb-accent)}
#custom-bingo-app .cb-upload small {display:block;font-size:.73rem;font-weight:400;margin-top:6px}
#custom-bingo-app .cb-upload:has(+input:focus-visible),#custom-bingo-app .cb-file-button:has(+input:focus-visible) {outline:3px solid #c47635;outline-offset:3px}
#custom-bingo-app .cb-pic-list {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
#custom-bingo-app .cb-pic {min-width:0;background:#f5f8f5;border:1px solid var(--cb-border);border-radius:10px;padding:12px}
#custom-bingo-app .cb-pic img {display:block;width:100%;height:88px;object-fit:contain;margin:0 0 10px}
#custom-bingo-app .cb-pic label {font-size:.74rem}
#custom-bingo-app .cb-pic input {padding:7px;font-size:.8rem;margin-bottom:8px}
#custom-bingo-app .cb-pic button {min-height:36px;padding:6px 10px;font-size:.72rem;width:100%}
#custom-bingo-app button.cb-primary {background:var(--cb-accent);border-color:var(--cb-accent);color:#fff}
#custom-bingo-app button.cb-primary:hover {background:#11554d}
#custom-bingo-app .cb-wide {width:100%;min-height:50px;margin-top:8px}
#custom-bingo-app .cb-save-note {font-size:.77rem;color:#6b7660;padding:12px;background:#f9f6e9;border-radius:8px;margin:16px 0 0}
#custom-bingo-app .cb-page-nav {display:flex;align-items:center;justify-content:center;gap:18px;margin:16px 0;font-size:.85rem}
#custom-bingo-app .cb-preview {background:#e7ece8;padding:16px;border-radius:12px;min-height:160px;overflow:hidden;container-type:inline-size}
#custom-bingo-app .cb-sheet {aspect-ratio:210/297;width:100%;padding:4.762cqw;display:grid;gap:2.857cqw;background:#fff;box-shadow:0 3px 12px #14302718;align-items:center}
#custom-bingo-app .cb-sheet-1 {grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr)}
#custom-bingo-app .cb-sheet-2 {grid-template-columns:minmax(0,1fr);grid-template-rows:repeat(2,minmax(0,1fr))}
#custom-bingo-app .cb-sheet-4 {grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:repeat(2,minmax(0,1fr))}
#custom-bingo-app .cb-card {min-width:0;min-height:0;width:100%;border:.167cqw solid #7c9990;border-radius:.95cqw;padding:1.429cqw;background:#fff;align-self:center}
#custom-bingo-app .cb-sheet-2 .cb-card {width:61.053%;justify-self:center}
#custom-bingo-app .cb-card-head {display:flex;align-items:center;justify-content:space-between;gap:.952cqw;color:#166a60;font-weight:750;margin-bottom:1.429cqw;font-size:2.688cqw;line-height:1.25}
#custom-bingo-app .cb-sheet-2 .cb-card-head {font-size:2.016cqw}
#custom-bingo-app .cb-sheet-4 .cb-card-head {font-size:1.68cqw}
#custom-bingo-app .cb-card-title {overflow-wrap:anywhere;min-width:0;flex:1;height:2.6em;display:flex;align-items:center}
#custom-bingo-app .cb-card-title span {display:block;max-width:100%}
#custom-bingo-app .cb-card-no {white-space:nowrap;font-size:.65em;color:#677b70}
#custom-bingo-app .cb-grid {display:grid;gap:.19cqw;aspect-ratio:1;grid-auto-rows:minmax(0,1fr)}
#custom-bingo-app .cb-size-3 .cb-grid {grid-template-columns:repeat(3,minmax(0,1fr))}
#custom-bingo-app .cb-size-4 .cb-grid {grid-template-columns:repeat(4,minmax(0,1fr))}
#custom-bingo-app .cb-size-5 .cb-grid {grid-template-columns:repeat(5,minmax(0,1fr))}
#custom-bingo-app .cb-cell {aspect-ratio:1;border:.095cqw solid #ccdcd4;background:#f7fbf8;padding:4%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4%;min-width:0;min-height:0;overflow:hidden}
#custom-bingo-app .cb-cell img {width:100%;height:65%;min-height:0;object-fit:contain;flex:0 0 65%}
#custom-bingo-app .cb-label {width:100%;height:100%;min-height:0;display:flex;align-items:center;justify-content:center;text-align:center;font-size:3.024cqw;line-height:1.2;overflow-wrap:anywhere}
#custom-bingo-app .cb-sheet-2 .cb-label {font-size:2.184cqw}
#custom-bingo-app .cb-sheet-4 .cb-label {font-size:1.68cqw}
#custom-bingo-app .cb-with-picture .cb-label {height:30%;flex:0 0 30%}
#custom-bingo-app .cb-label span {display:block;max-width:100%;font-weight:650}
#custom-bingo-app .cb-free-cell {background:#e3f3ea;color:#166a60}
#custom-bingo-app .cb-card-foot {text-align:center;font-size:1.344cqw;color:#748278;margin-top:1.429cqw;line-height:1.3}
#custom-bingo-app .cb-sheet-4 .cb-card-foot {font-size:.84cqw;margin-top:.952cqw}
#custom-bingo-app .cb-theme-sunset .cb-card-head {color:#a84a35}
#custom-bingo-app .cb-theme-sunset .cb-cell {background:#fff8f1;border-color:#ecd8c7}
#custom-bingo-app .cb-theme-sunset .cb-free-cell {background:#ffe9d7;color:#a84a35}
#custom-bingo-app .cb-theme-ink .cb-card-head,#custom-bingo-app .cb-theme-ink .cb-free-cell {color:#222}
#custom-bingo-app .cb-theme-ink .cb-cell {background:#fff;border-color:#777}
#custom-bingo-app .cb-theme-ink .cb-free-cell {background:#eee}
#custom-bingo-app .cb-fit-1 {font-size:.95em}#custom-bingo-app .cb-fit-2 {font-size:.9em}#custom-bingo-app .cb-fit-3 {font-size:.85em}#custom-bingo-app .cb-fit-4 {font-size:.8em}#custom-bingo-app .cb-fit-5 {font-size:.75em}#custom-bingo-app .cb-fit-6 {font-size:.7em}#custom-bingo-app .cb-fit-7 {font-size:.65em}#custom-bingo-app .cb-fit-8 {font-size:.6em}#custom-bingo-app .cb-fit-9 {font-size:.55em}#custom-bingo-app .cb-fit-10 {font-size:.5em}#custom-bingo-app .cb-fit-11 {font-size:.45em}#custom-bingo-app .cb-fit-12 {font-size:.4em}#custom-bingo-app .cb-fit-13 {font-size:.35em}#custom-bingo-app .cb-fit-14 {font-size:.3em}#custom-bingo-app .cb-fit-15 {font-size:.25em}
#custom-bingo-app .cb-stage {padding:26px;border-radius:18px;background:#123e38;color:#fff;min-width:0}
#custom-bingo-app .cb-fit-16 {font-size:.2em}#custom-bingo-app .cb-fit-17 {font-size:.15em}#custom-bingo-app .cb-fit-18 {font-size:.1em}
#custom-bingo-app .cb-stage h2,#custom-bingo-app .cb-stage h3 {color:#fff}
#custom-bingo-app .cb-stage-top {display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
#custom-bingo-app .cb-stage-top h2 {margin:0;font-size:1.1rem;overflow-wrap:anywhere}
#custom-bingo-app .cb-stage button:not(.cb-draw) {background:#ffffff12;color:#fff;border-color:#ffffff38}
#custom-bingo-app .cb-stats {display:flex;gap:24px;justify-content:center;font-size:.85rem;color:#bed8d0;margin:26px 0 16px}
#custom-bingo-app .cb-stats strong {font-size:1.4rem;color:#fff;margin-left:8px}
#custom-bingo-app .cb-result {min-height:250px;padding:24px 20px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:18px;background:#ffffff0a;border:1px solid #ffffff20;border-radius:14px;margin-bottom:22px;overflow:hidden}
#custom-bingo-app .cb-result img {width:100%;height:210px;object-fit:contain;min-width:0}
#custom-bingo-app .cb-result-name {font-size:clamp(1.6rem,5vw,3.4rem);font-weight:750;text-align:center;line-height:1.4;overflow-wrap:anywhere;max-width:100%;margin:0}
#custom-bingo-app .cb-result-placeholder {text-align:center;color:#a4c7bb;margin:0}
#custom-bingo-app .cb-stage-actions {display:flex;justify-content:center;gap:10px;flex-wrap:wrap}
#custom-bingo-app button.cb-draw {background:#f7ce6b;color:#243c31;border-color:#f7ce6b;font-size:1.08rem;padding:15px 30px;min-height:56px}
#custom-bingo-app button.cb-draw:hover {background:#ffe19b}
#custom-bingo-app .cb-play-options {display:flex;align-items:center;justify-content:center;gap:26px;flex-wrap:wrap;margin:22px 0 10px}
#custom-bingo-app .cb-play-options .cb-check {margin:0}
#custom-bingo-app .cb-play-options label {margin:0;font-size:.82rem}
#custom-bingo-app .cb-play-options select {display:inline-block;width:auto;margin:0 0 0 6px;padding:5px 8px}
#custom-bingo-app .cb-stage-help {text-align:center;font-size:.72rem;color:#a8c8bd;margin-bottom:26px}
#custom-bingo-app .cb-history {display:grid;grid-template-columns:repeat(auto-fill,minmax(110px,1fr));gap:10px;padding:0;margin:0;list-style:none}
#custom-bingo-app .cb-history li {padding:10px;background:#ffffff0a;border:1px solid #ffffff1c;border-radius:9px;text-align:center;font-size:.78rem;overflow-wrap:anywhere;min-width:0}
#custom-bingo-app .cb-history img {width:100%;height:65px;object-fit:contain;display:block;margin-bottom:6px}
#custom-bingo-app .cb-history small {display:block;color:#a8c8bd;font-size:.68rem}
#custom-bingo-app .cb-empty {padding:22px 12px;text-align:center;color:#6c8075;font-size:.85rem}
#custom-bingo-app .cb-history .cb-empty {grid-column:1/-1;color:#a8c8bd}
#custom-bingo-app .cb-guide {margin-top:22px;font-size:.9rem}
#custom-bingo-app .cb-guide ol {padding-left:24px}
#custom-bingo-app .cb-guide li {margin-bottom:10px}
#custom-bingo-app details {border-top:1px solid var(--cb-border);padding:14px 0}
#custom-bingo-app summary {cursor:pointer;font-weight:650}
#custom-bingo-app details p {margin:12px 0 0;color:#577165;font-size:.85rem}
#custom-bingo-app .cb-guide h2:not(:first-child) {margin-top:24px}
#custom-bingo-app .cb-related {display:flex;gap:12px 26px;flex-wrap:wrap;padding:0;list-style:none}
#custom-bingo-app .cb-related a {color:var(--cb-accent)}
#custom-bingo-app .cb-sr {position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
#custom-bingo-app .cb-stage:fullscreen {overflow:auto;border-radius:0;padding:30px min(6vw,80px)}
#custom-bingo-app .cb-stage.cb-expanded {position:fixed;inset:0;z-index:100000;overflow:auto;border-radius:0;padding:30px min(6vw,80px)}
#custom-bingo-app .cb-stage:fullscreen .cb-result,#custom-bingo-app .cb-expanded .cb-result {min-height:42vh}
@media (max-width:760px) {#custom-bingo-app .cb-editor-layout {grid-template-columns:1fr}#custom-bingo-app .cb-settings {position:static}#custom-bingo-app .cb-panel {padding:20px}#custom-bingo-app .cb-intro {padding:20px}#custom-bingo-app .cb-tabs button {font-size:.8rem;gap:4px}#custom-bingo-app .cb-tabs span {display:none}}
@media (max-width:400px) {#custom-bingo-app .cb-panel {padding:14px}#custom-bingo-app .cb-stage {padding:16px}#custom-bingo-app .cb-actions {width:100%}#custom-bingo-app .cb-actions>* {flex:1;font-size:.75rem;padding:9px 8px}#custom-bingo-app .cb-result {min-height:210px;padding:20px 12px}#custom-bingo-app .cb-preview {padding:8px}#custom-bingo-app .cb-play-options {gap:12px}#custom-bingo-app .cb-stage-actions button {width:100%}}
@media (prefers-reduced-motion:reduce) {#custom-bingo-app button {transition:none}}
