/*
 * Box Shadow Generator ([box_shadow_generator]). Loaded after tools.css; the
 * code boxes reuse its .gg-output styles. The preview element's shadow is set
 * inline by tool-bx.js from the same layers as the output.
 */

.bx-presets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.bx-presets button { padding: 8px 14px !important; margin: 0 !important; border: 1px solid #E2E2E8 !important; border-radius: 999px !important; background: #fff !important; color: #222 !important; font-size: 13px !important; font-weight: 600 !important; cursor: pointer; box-shadow: none !important; }
.bx-presets button:hover { border-color: #111 !important; }
.bx-presets button[aria-pressed="true"] { background: #111 !important; border-color: #111 !important; color: #fff !important; }

.bx-layout { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(300px, 1fr); gap: 20px; align-items: start; margin-bottom: 20px; }
.bx-main { position: sticky; top: 96px; }

.bx-stage { display: flex; align-items: center; justify-content: center; min-height: 380px; padding: 48px; border-radius: 28px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .05); transition: background .2s; }
.bx-el { display: flex; align-items: center; justify-content: center; width: min(280px, 70%); aspect-ratio: 4 / 3; font-size: 15px; font-weight: 700; letter-spacing: .02em; transition: border-radius .15s; }
.bx-el.is-button { width: auto; aspect-ratio: auto; padding: 16px 34px; }
.bx-el.is-circle { width: 170px; aspect-ratio: 1; }
.bx-el.is-text { width: auto; aspect-ratio: auto; padding: 0; font-size: clamp(48px, 8vw, 88px); font-weight: 900; letter-spacing: -.03em; }

.bx-stage-bar { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.bx-stage-bar .bx-seg { flex: 1; min-width: 200px; margin: 0; }
.bx-colors { margin-top: 12px; gap: 16px; }
.bx-colors label { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: #333; }
.bx-colors input[type="color"] { width: 34px !important; height: 34px !important; padding: 0 !important; border: 0 !important; border-radius: 10px !important; background: none !important; cursor: pointer; }
.bx-colors input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.bx-colors input[type="color"]::-webkit-color-swatch { border: 0; border-radius: 10px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15); }
.bx-radius { flex: 1; min-width: 200px; }
.bx-radius input { flex: 1; }
.bx-radius span { min-width: 40px; font-family: 'SF Mono', 'Fira Code', ui-monospace, monospace; font-size: 13px; color: #55555F; }

.bx-side { display: grid; gap: 12px; }
.bx-card { background: #fff; border: 1px solid #F0F0F0; border-radius: 24px; padding: 18px 20px; box-shadow: 0 1px 3px rgba(0, 0, 0, .04); }
.bx-note { margin: 0 0 10px !important; font-size: 12.5px; color: #6E6E78; }
.bx-more { padding: 0 6px; }
#bx-smooth[hidden], #bx-layers[hidden] { display: none !important; }

.bx-seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; border-radius: 999px; background: #F4F4F7; margin-bottom: 12px; }
.bx-seg button { padding: 8px 4px !important; border: 0 !important; border-radius: 999px !important; background: transparent !important; font-size: 13px !important; font-weight: 600 !important; color: #45454F !important; cursor: pointer; box-shadow: none !important; }
.bx-seg button[aria-pressed="true"] { background: #fff !important; color: #111 !important; box-shadow: 0 1px 3px rgba(0, 0, 0, .1) !important; }

.bx-slider { display: flex; align-items: center; gap: 12px; margin: 8px 0; }
.bx-slider label { min-width: 70px; font-size: 13px; font-weight: 600; color: #333; }
.bx-slider input { flex: 1; }
.bx-slider span { min-width: 50px; text-align: right; font-family: 'SF Mono', 'Fira Code', ui-monospace, monospace; font-size: 13px; color: #55555F; }

.bx-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.bx-row input[type="color"] { width: 40px !important; height: 40px !important; padding: 0 !important; border: 0 !important; border-radius: 12px !important; background: none !important; cursor: pointer; flex-shrink: 0; }
.bx-row input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.bx-row input[type="color"]::-webkit-color-swatch { border: 0; border-radius: 12px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12); }
.bx-row input[type="text"] { flex: 1; min-width: 90px; font-family: 'SF Mono', 'Fira Code', ui-monospace, monospace; text-transform: uppercase; }
.bx-check { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: #333; cursor: pointer; }

.bx-list { list-style: none; margin: 0 0 4px !important; padding: 0 !important; display: grid; gap: 4px; }
.bx-list li { margin: 0 !important; }
.bx-layer { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 12px !important; margin: 0 !important; border: 1px solid #ECECF1 !important; border-radius: 12px !important; background: #FAFAFC !important; color: #333 !important; font: 500 12.5px/1.2 'SF Mono', 'Fira Code', ui-monospace, monospace !important; text-align: left; cursor: pointer; box-shadow: none !important; }
.bx-layer.is-on { border-color: #111 !important; background: #fff !important; }
.bx-layer i { width: 16px; height: 16px; border-radius: 5px; flex-shrink: 0; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1); }
.bx-layer span { flex: 1; }
.bx-layer em { font-style: normal; color: #8A8A96; }
.bx-edit { margin-top: 6px; padding-top: 8px; border-top: 1px solid #F0F0F3; }

.bx-btn {
	display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px !important; margin: 0 !important;
	border: 1px solid #E2E2E8 !important; border-radius: 999px !important; background: #fff !important; color: #222 !important;
	font-size: 13px !important; font-weight: 600 !important; cursor: pointer; box-shadow: none !important; white-space: nowrap;
}
.bx-btn:hover { border-color: #111 !important; }
.bx-btn:disabled { opacity: .45; cursor: default; }
.bx-btn.ok { border-color: #16A34A !important; color: #166534 !important; background: #E7F8EE !important; }
.bx-btn .tg-i { width: 15px; height: 15px; }

.bx-outputs { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 14px; margin-bottom: 12px; }
.bx-outputs pre { white-space: pre-wrap !important; word-break: break-word; }
.bx-share { margin-bottom: 24px; }

@media (max-width: 960px) {
	.bx-outputs { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
	.bx-layout { grid-template-columns: 1fr; }
	.bx-main { position: static; }
	.bx-stage { min-height: 280px; padding: 32px 20px; border-radius: 20px; }
}

/* Dark mode: the stage keeps its chosen colour; only the panels change. */
html[data-theme="dark"] .tg-tool .bx-card { background: #15151D !important; border-color: rgba(255, 255, 255, .09) !important; }
html[data-theme="dark"] .tg-tool .bx-seg { background: #1D1D27 !important; }
html[data-theme="dark"] .tg-tool .bx-seg button { color: #B9B9C6 !important; }
html[data-theme="dark"] .tg-tool .bx-seg button[aria-pressed="true"] { background: #262633 !important; color: #EDEDF2 !important; }
html[data-theme="dark"] .tg-tool .bx-slider label, html[data-theme="dark"] .tg-tool .bx-check, html[data-theme="dark"] .tg-tool .bx-colors label { color: #EDEDF2 !important; }
html[data-theme="dark"] .tg-tool .bx-slider span, html[data-theme="dark"] .tg-tool .bx-note, html[data-theme="dark"] .tg-tool .bx-radius span { color: #9393A3 !important; }
html[data-theme="dark"] .tg-tool .bx-btn, html[data-theme="dark"] .tg-tool .bx-presets button { background: #1D1D27 !important; border-color: rgba(255, 255, 255, .16) !important; color: #EDEDF2 !important; }
html[data-theme="dark"] .tg-tool .bx-presets button[aria-pressed="true"] { background: #EDEDF2 !important; color: #111 !important; }
html[data-theme="dark"] .tg-tool .bx-layer { background: #1D1D27 !important; border-color: rgba(255, 255, 255, .1) !important; color: #EDEDF2 !important; }
html[data-theme="dark"] .tg-tool .bx-layer.is-on { border-color: #EDEDF2 !important; background: #262633 !important; }
html[data-theme="dark"] .tg-tool .bx-edit { border-color: rgba(255, 255, 255, .08); }
