/* src/public/css/css-generator.css … CSS デザイニング・ジェネレーター
   ダークモードは theme-dark.css の末尾（=== CSSジェネレーター ===）にあります。
   💡 見本（.cg-stage・.cg-sample）は、作るCSSの見た目そのものなので、ダークモードでも変えません */

.cg-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; }
.cg-tab { padding: 10px 16px; border: 1px solid #cbd5e1; border-radius: 999px; background: #f8fafc; color: #334155; font-weight: bold; cursor: pointer; }
.cg-tab.is-active { background: #2a5298; border-color: #2a5298; color: #fff; }
.cg-layout { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 18px; margin-top: 14px; }
.cg-box { background: #fff; border: 1px solid #e3e8ef; border-radius: 12px; padding: 18px; margin-top: 0; min-width: 0; }
.cg-box + .cg-box, main > .cg-box { margin-top: 18px; }
.cg-layout .cg-box { margin-top: 0; }
.cg-box [hidden] { display: none; }
.cg-h2 { font-size: 1.05rem; color: #2a5298; margin: 0; display: flex; align-items: center; gap: 8px; }

.cg-preview-box { padding: 0; overflow: hidden; }
.cg-stage { min-height: 340px; height: 100%; display: flex; align-items: center; justify-content: center; padding: 24px; box-sizing: border-box; transition: background-color 0.2s; }
.cg-stage[data-stage="aurora"] { background: radial-gradient(circle at 20% 25%, #f472b6 0, transparent 35%), radial-gradient(circle at 80% 30%, #60a5fa 0, transparent 40%), radial-gradient(circle at 50% 85%, #34d399 0, transparent 40%), #312e81; }
.cg-stage[data-stage="sunset"] { background: linear-gradient(135deg, #f97316, #db2777 50%, #7c3aed); }
.cg-stage[data-stage="ocean"] { background: radial-gradient(circle at 30% 30%, #22d3ee 0, transparent 40%), radial-gradient(circle at 75% 70%, #3b82f6 0, transparent 45%), #0f172a; }
.cg-stage[data-stage="dark"] { background: radial-gradient(circle at 35% 40%, #f59e0b 0, transparent 30%), #111827; }
.cg-sample { display: flex; align-items: center; justify-content: center; max-width: 100%; transition: all 0.15s; }
.cg-sample-text { font-weight: bold; color: #1f2937; mix-blend-mode: normal; text-align: center; padding: 8px; }
.cg-stage[data-stage]:not([data-stage="plain"]) .cg-sample-text { color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25); }

.cg-field { display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px; font-size: 0.9rem; color: #334155; }
.cg-field-head { display: flex; justify-content: space-between; gap: 8px; }
.cg-field output { font-family: 'SFMono-Regular', Consolas, monospace; color: #2a5298; font-weight: bold; }
.cg-field input[type="range"] { width: 100%; accent-color: #2a5298; }
.cg-field select { padding: 6px 8px; border: 1px solid #cbd5e1; border-radius: 6px; background: #fff; }
.cg-field-color { flex-direction: row; align-items: center; justify-content: space-between; }
.cg-field-color input { width: 48px; height: 30px; padding: 0; border: 1px solid #cbd5e1; border-radius: 6px; background: #fff; }
.cg-check { display: flex; align-items: center; gap: 6px; font-size: 0.9rem; color: #334155; margin-bottom: 8px; cursor: pointer; }
.cg-btn { padding: 8px 14px; border: 1px solid #2a5298; border-radius: 8px; background: #2a5298; color: #fff; font-weight: bold; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.cg-btn-sub { background: #f8fafc; color: #334155; border-color: #cbd5e1; }
.cg-code-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.cg-status { font-size: 0.85rem; color: #16a34a; margin-right: 8px; }
.cg-code { margin: 0; padding: 14px; border-radius: 8px; background: #0f172a; color: #e2e8f0; font-size: 0.85rem; line-height: 1.6; overflow-x: auto; }

@media (max-width: 760px) {
    .cg-layout { grid-template-columns: minmax(0, 1fr); }
    .cg-stage { min-height: 260px; }
}
