:root {
  --bg-black: #060809;
  --panel: #0e1416;
  --ink: #e6f2f1;
  --muted: #9fbdbc;
  --rule: #1f3a3a;

  --accent-main: #2dd4bf;
  --accent-soft: #0b3b3a;
  --accent-warm: #f59e0b;
  --warn: #fb923c;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: radial-gradient(
    circle at top left,
    #0b2e2c 0%,
    var(--bg-black) 55%
  );
  color: var(--ink);
  font-family: "Source Serif 4", Georgia, serif;
}

.page {
  max-width: 860px;
  margin: 0 auto;
  padding: 36px 24px 56px;
}

/* Header */
.header {
  border-left: 6px solid var(--accent-main);
  padding-left: 18px;
  margin-bottom: 36px;
}

h1 {
  margin: 0;
  font-size: 2.1rem;
}

.subtitle {
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Sections */
.section {
  margin-bottom: 38px;
}

h2 {
  font-size: 1.1rem;
  margin-bottom: 16px;
  font-weight: 600;
  color: var(--accent-main);
}

/* Input layout */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

/* ⬇️ FIX APPLIED HERE */
label {
  display: flex;
  flex-direction: column;
  font-size: 0.9rem;
  white-space: nowrap;
}

label.wide {
  max-width: 320px;
}

input {
  margin-top: 6px;
  padding: 9px 10px;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.9rem;
  background: #020606;
  color: var(--ink);
  border: 1px solid var(--rule);
  border-radius: 5px;
}

input::placeholder {
  color: #6fa7a5;
}

input:focus {
  outline: none;
  border-color: var(--accent-main);
  box-shadow: 0 0 0 2px rgba(45, 212, 191, 0.25);
}

/* ⬇️ SUBSCRIPT TYPOGRAPHY FIX */
sub {
  font-size: 0.7em;
  vertical-align: baseline;
  position: relative;
  bottom: -0.25em;
}

/* Notes */
.note {
  margin-top: 10px;
  font-size: 0.85rem;
  color: var(--muted);
}

/* Progressive disclosure */
.disclosure {
  margin-top: 12px;
}

.disclosure summary {
  cursor: pointer;
  color: var(--accent-main);
  font-size: 0.85rem;
  list-style: none;
}

.disclosure summary::-webkit-details-marker {
  display: none;
}

.disclosure summary::before {
  content: "▸ ";
  color: var(--accent-main);
}

.disclosure[open] summary::before {
  content: "▾ ";
}

.disclosure-body {
  margin-top: 10px;
  padding: 14px 16px;
  background: var(--accent-soft);
  border: 1px solid #164e4b;
  border-radius: 6px;
  font-size: 0.85rem;
  line-height: 1.45;
}

/* Ordered list inside disclosure */
.disclosure-body ol {
  margin: 10px 0 14px 20px;
}

.disclosure-body li {
  margin-bottom: 8px;
}

.disclosure-body strong {
  color: var(--ink);
}

/* Results panel */
.results {
  background: linear-gradient(
    180deg,
    #0b2f2d 0%,
    var(--panel) 100%
  );
  padding: 22px 20px;
  border-radius: 10px;
  border: 1px solid #164e4b;
}

.result-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.95rem;
}

.result-row:not(:last-child) {
  border-bottom: 1px dashed #1f5e5a;
}

.emphasis {
  font-weight: 700;
  color: var(--accent-warm);
}

/* ⬇️ NEW: Interpretation text block */
.interpretation {
  margin-top: 12px;
  font-size: 0.9rem;
  line-height: 1.45;
  color: var(--muted);
}

/* Warning */
.warning {
  margin-top: 14px;
  font-size: 0.85rem;
  color: var(--warn);
}

/* Footer */
.footer {
  margin-top: 48px;
  text-align: center;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.85rem;
  color: var(--muted);
}
