/* StunnedCandles Risk Calculator */
.scrc {
	--scrc-accent: #4ca800;
	--scrc-gold: #e5b100;
	--scrc-bg: #111111;
	--scrc-card: #181818;
	--scrc-field: #0d0d0d;
	--scrc-line: #2c2c2c;
	--scrc-text: #f2f2f2;
	--scrc-muted: #9a9a9a;
	--scrc-red: #e5484d;
	box-sizing: border-box;
	max-width: 1100px;
	margin: 0 auto;
	padding: 24px;
	background: var(--scrc-bg);
	color: var(--scrc-text);
	font-family: Poppins, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	font-size: 15px;
	line-height: 1.45;
	border-radius: 16px;
}
.scrc *, .scrc *::before, .scrc *::after { box-sizing: border-box; }
.scrc [hidden] { display: none !important; }

.scrc .scrc-head { margin-bottom: 20px; }
.scrc .scrc-head h2 { margin: 0 0 4px; color: #fff; font-size: 26px; font-weight: 700; line-height: 1.2; }
.scrc .scrc-head p { margin: 0; color: var(--scrc-muted); }

.scrc .scrc-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.scrc .scrc-card { background: var(--scrc-card); border: 1px solid var(--scrc-line); border-radius: 14px; padding: 20px; margin: 0; }
.scrc .scrc-out { position: sticky; top: 90px; }

.scrc fieldset { border: 0; margin: 0 0 18px; padding: 0; min-width: 0; }
.scrc legend { padding: 0; margin: 0 0 10px; color: var(--scrc-gold); font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }

.scrc .scrc-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; }
.scrc .scrc-field { margin: 0 0 12px; min-width: 0; }
.scrc label, .scrc .scrc-lbl { display: block; margin: 0 0 6px; color: #d6d6d6; font-size: 13px; font-weight: 500; }
.scrc label em { color: var(--scrc-muted); font-style: normal; font-weight: 400; }
.scrc small { display: block; margin-top: 4px; color: var(--scrc-muted); font-size: 12px; min-height: 0; }
.scrc .scrc-labelrow { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.scrc .scrc-labelrow label, .scrc .scrc-labelrow .scrc-lbl { margin: 0; }

.scrc input, .scrc select {
	display: block;
	width: 100%;
	height: 44px;
	margin: 0;
	padding: 0 12px;
	background: var(--scrc-field);
	color: #fff;
	border: 1px solid var(--scrc-line);
	border-radius: 10px;
	font: inherit;
	font-size: 15px;
	box-shadow: none;
	outline: none;
	transition: border-color .15s;
}
.scrc select { appearance: auto; padding-right: 8px; }
.scrc select option, .scrc select optgroup { background: #181818; color: #fff; }
.scrc input:focus, .scrc select:focus { border-color: var(--scrc-accent); box-shadow: 0 0 0 3px rgba(76, 168, 0, .2); }
.scrc input::placeholder { color: #5c5c5c; }

.scrc .scrc-suffix { position: relative; }
.scrc .scrc-suffix input { padding-right: 64px; }
.scrc .scrc-suffix span { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--scrc-muted); font-size: 13px; pointer-events: none; }

.scrc button {
	font: inherit;
	cursor: pointer;
	text-transform: none;
	letter-spacing: normal;
	box-shadow: none;
	line-height: 1.2;
}
.scrc .scrc-toggle { display: inline-flex; padding: 3px; background: var(--scrc-field); border: 1px solid var(--scrc-line); border-radius: 999px; }
.scrc .scrc-toggle button { margin: 0; padding: 5px 12px; background: transparent; color: var(--scrc-muted); border: 0; border-radius: 999px; font-size: 12px; font-weight: 600; }
.scrc .scrc-toggle button[aria-pressed="true"] { background: var(--scrc-accent); color: #fff; }
.scrc .scrc-toggle button:hover { color: #fff; }

.scrc .scrc-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.scrc .scrc-chips button { margin: 0; padding: 5px 11px; background: transparent; color: #d6d6d6; border: 1px solid var(--scrc-line); border-radius: 999px; font-size: 12px; }
.scrc .scrc-chips button:hover { border-color: var(--scrc-accent); color: #fff; background: transparent; }

.scrc .scrc-link { margin: 0; padding: 0; background: none; border: 0; color: var(--scrc-gold); font-size: 12px; font-weight: 600; }
.scrc .scrc-link:hover { background: none; color: #fff; text-decoration: underline; }

.scrc .scrc-custom { padding: 12px 12px 0; margin: 0 0 12px; border: 1px dashed var(--scrc-line); border-radius: 10px; }
.scrc .scrc-conv { margin-top: 2px; padding: 12px; background: rgba(229, 177, 0, .06); border: 1px solid rgba(229, 177, 0, .25); border-radius: 10px; }

.scrc .scrc-actions { display: flex; justify-content: flex-end; }
.scrc .scrc-btn-ghost { margin: 0; padding: 8px 14px; background: transparent; color: var(--scrc-muted); border: 1px solid var(--scrc-line); border-radius: 10px; font-size: 13px; }
.scrc .scrc-btn-ghost:hover { color: #fff; border-color: #555; background: transparent; }

/* Results */
.scrc .scrc-out-top { display: flex; align-items: center; justify-content: space-between; }
.scrc .scrc-out-top .scrc-lbl { margin: 0; color: var(--scrc-gold); font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.scrc .scrc-dir { padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; letter-spacing: .05em; }
.scrc .scrc-dir.is-buy { background: rgba(76, 168, 0, .18); color: #6fd12a; }
.scrc .scrc-dir.is-sell { background: rgba(229, 72, 77, .16); color: #ff6b70; }
.scrc .scrc-lots { display: flex; align-items: baseline; gap: 8px; margin-top: 6px; }
.scrc .scrc-lots span { color: var(--scrc-accent); font-size: 52px; font-weight: 700; line-height: 1.05; font-variant-numeric: tabular-nums; word-break: break-all; }
.scrc .scrc-lots small { margin: 0; font-size: 16px; color: var(--scrc-muted); }
.scrc .scrc-units { color: var(--scrc-muted); font-size: 13px; margin-bottom: 12px; }

.scrc .scrc-msg { margin: 0 0 14px; padding: 10px 12px; border-radius: 10px; background: rgba(255, 255, 255, .04); border: 1px solid var(--scrc-line); color: #d6d6d6; font-size: 13px; }
.scrc .scrc-msg.is-warn { background: rgba(229, 177, 0, .08); border-color: rgba(229, 177, 0, .35); color: #f3d36b; }
.scrc .scrc-msg p { margin: 0; }
.scrc .scrc-msg p + p { margin-top: 6px; }

.scrc .scrc-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin: 0 0 16px; background: var(--scrc-line); border: 1px solid var(--scrc-line); border-radius: 10px; overflow: hidden; }
.scrc .scrc-stats > div { padding: 10px 12px; background: var(--scrc-card); min-width: 0; }
.scrc .scrc-stats dt { margin: 0 0 2px; color: var(--scrc-muted); font-size: 11.5px; font-weight: 400; }
.scrc .scrc-stats dd { margin: 0; color: #fff; font-size: 14.5px; font-weight: 600; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.scrc .scrc-stats .scrc-tp dd { color: #6fd12a; }

.scrc .scrc-streak { margin-bottom: 16px; }
.scrc .scrc-streak .scrc-lbl { color: var(--scrc-muted); font-size: 12px; font-weight: 400; }
.scrc .scrc-streak-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.scrc .scrc-streak-cell { padding: 8px 4px; text-align: center; background: var(--scrc-field); border: 1px solid var(--scrc-line); border-radius: 8px; }
.scrc .scrc-streak-cell b { display: block; color: #d6d6d6; font-size: 14px; font-variant-numeric: tabular-nums; }
.scrc .scrc-streak-cell span { color: var(--scrc-muted); font-size: 11px; }
.scrc .scrc-streak-cell.is-mid b { color: var(--scrc-gold); }
.scrc .scrc-streak-cell.is-bad b { color: #ff6b70; }

.scrc .scrc-btn { display: block; width: 100%; margin: 0; padding: 12px 16px; background: var(--scrc-accent); color: #fff; border: 0; border-radius: 10px; font-size: 15px; font-weight: 600; }
.scrc .scrc-btn:hover { background: #6fd12a; color: #fff; }
.scrc .scrc-cta { display: block; margin-top: 10px; padding: 11px 16px; text-align: center; color: var(--scrc-gold); border: 1px solid rgba(229, 177, 0, .45); border-radius: 10px; font-weight: 600; text-decoration: none; }
.scrc .scrc-cta:hover { background: rgba(229, 177, 0, .08); color: var(--scrc-gold); }

.scrc .scrc-foot { margin: 16px 0 0; color: #6f6f6f; font-size: 12px; }
.scrc .scrc-foot a { color: #9a9a9a; }

/* Layout follows the space the calculator actually gets (theme sidebars, narrow content columns). */
.scrc .scrc-wrap { container-type: inline-size; }
@container (max-width: 780px) {
	.scrc .scrc-grid { grid-template-columns: 1fr; }
	.scrc .scrc-out { position: static; }
}
@container (max-width: 380px) {
	.scrc .scrc-row { grid-template-columns: 1fr 1fr; }
	.scrc .scrc-streak-grid { grid-template-columns: repeat(2, 1fr); }
	.scrc .scrc-stats { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
	.scrc { padding: 16px; border-radius: 12px; }
	.scrc .scrc-head h2 { font-size: 22px; }
	.scrc .scrc-lots span { font-size: 44px; }
}
/* Browsers without container queries */
@supports not (container-type: inline-size) {
	@media (max-width: 820px) {
		.scrc .scrc-grid { grid-template-columns: 1fr; }
		.scrc .scrc-out { position: static; }
	}
}
