/* Bullish Gator Calculators, v1.2.1 (2026-10-22)
   Pure monochrome. Binds to the SITE theme tokens (html[data-theme=light|dark])
   so cards invert in lockstep with the user's manual theme toggle,
   NOT the OS prefers-color-scheme setting.
   Button is inline-styled on the element to defeat theme CSS cascade.
*/

.bg-calc-intro,
.bg-calc {
  box-sizing: border-box;
  max-width: 640px;
  margin: 1.5em auto;
  padding: 1.75em 1.5em;
  border: 1px solid var(--bg-border, rgba(17,17,17,0.14));
  border-radius: 12px;
  background: var(--bg-panel, #ffffff);
  color: var(--bg-text, #111111);
  font: 400 15px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
.bg-calc-intro { margin: 1.5em auto 0; }
.bg-calc *,
.bg-calc *::before,
.bg-calc *::after { box-sizing: inherit; }

.bg-calc-title {
  margin: 0 0 1.1em;
  font-size: 1.25em;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--bg-text, #111111);
}

.bg-calc-form { display: grid; gap: 1em; }
.bg-calc-form label {
  display: grid;
  gap: 0.4em;
  font-weight: 600;
  font-size: 0.92em;
  color: var(--bg-muted, #6b7280);
}
.bg-calc-form input,
.bg-calc-form select {
  width: 100%;
  padding: 0.72em 0.9em;
  border: 1px solid var(--bg-border, rgba(17,17,17,0.14));
  border-radius: 6px;
  font: inherit;
  background: var(--bg-panel, #ffffff);
  color: var(--bg-text, #111111);
  appearance: none;
  -webkit-appearance: none;
}
.bg-calc-form input:focus,
.bg-calc-form select:focus {
  outline: 2px solid var(--bg-text, #111111);
  outline-offset: 1px;
  border-color: var(--bg-text, #111111);
}

/* Button is inline-styled on the element to defeat Spectra One cascade.
   This block is a safety net only; the inline style wins regardless. */
.bg-calc .bg-calc-run,
.bg-calc button.bg-calc-run { font-family: inherit; }
.bg-calc .bg-calc-run:hover { opacity: 0.88; }
.bg-calc .bg-calc-run:active { transform: translateY(1px); }
.bg-calc .bg-calc-run:focus-visible {
  outline: 2px solid var(--bg-text, #111111);
  outline-offset: 2px;
}

.bg-calc-out {
  display: block;
  margin: 0;
  padding: 0;
  min-height: 0;
  color: var(--bg-text, #111111);
  font-variant-numeric: tabular-nums;
}
.bg-calc-out:empty { display: none; }
.bg-calc-out[data-filled="1"] {
  margin-top: 1.1em;
  padding-top: 1.1em;
  border-top: 1px solid var(--bg-border, rgba(17,17,17,0.10));
}

/* Hero result row: first dt/dd pair is 2x size. */
.bg-calc-out dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.6em 1.5em;
  margin: 0;
}
.bg-calc-out dt {
  color: var(--bg-muted, #6b7280);
  font-weight: 500;
}
.bg-calc-out dd {
  margin: 0;
  text-align: right;
  font-weight: 800;
  color: var(--bg-text, #111111);
}
.bg-calc-out dl > dt:first-of-type,
.bg-calc-out dl > dd:first-of-type {
  font-size: 1.6em;
  padding-bottom: 0.3em;
}
.bg-calc-out dl > dt:first-of-type { align-self: end; font-weight: 500; }
.bg-calc-out dl > dd:first-of-type { line-height: 1.1; }

.bg-calc-disclaimer {
  margin: 1.4em 0 0;
  padding-top: 1em;
  border-top: 1px dashed var(--bg-border, rgba(17,17,17,0.10));
  font-size: 0.82em;
  line-height: 1.55;
  color: var(--bg-muted, #6b7280);
  font-style: italic;
}
.bg-calc-disclaimer strong {
  color: var(--bg-text, #111111);
  font-weight: 700;
  font-style: normal;
}

@media (max-width: 480px) {
  .bg-calc-intro,
  .bg-calc {
    padding: 1.4em 1.1em;
    border-radius: 10px;
    margin-left: 0.75em;
    margin-right: 0.75em;
  }
  .bg-calc-out dl > dt:first-of-type,
  .bg-calc-out dl > dd:first-of-type {
    font-size: 1.35em;
  }
}
