/* Free Fall Calculator — content styles.
   Prefix: --ff-  /  .ff-

   Reference point: a plain, textbook-neutral register — no dramatic
   "falling object" visual metaphor, since the tool is a formula
   solver, not a physics simulation. Eighth `education`-cluster tool
   this loop, and the first physics (rather than pure-math) tool.

   THIS FILE STYLES THE CONTENT AREA ONLY. Chrome is owned by chrome.css. */

:root {
  --ff-surface: #ffffff;
  --ff-panel:   #f4f5f6;
  --ff-line:    #dde0e3;
  --ff-text:    #171a1c;
  --ff-muted:   #5c6368;
  --ff-mono: ui-monospace, SFMono-Regular, "JetBrains Mono", Menlo, Consolas, monospace;
}

.ff-wrap {
  width: 100%;
  max-width: 28rem;
  margin-inline: auto;
  padding-inline: 1.5rem;
}

/* ── Input panel ─────────────────────────────────────────────────────────── */

.ff-panel {
  padding: 1.5rem;
  margin-bottom: 1rem;
  border: 1px solid var(--ff-line);
  border-radius: 2px;
  background: var(--ff-surface);
}

.ff-field {
  margin-bottom: 1rem;
}

.ff-panel > .ff-field:last-of-type {
  margin-bottom: 1.25rem;
}

.ff-field label {
  display: block;
  margin-bottom: 0.375rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ff-muted);
}

.ff-optional {
  font-weight: 500;
  color: var(--ff-muted);
}

.ff-field input,
.ff-field select {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 0.625rem 0.75rem;
  font-family: inherit;
  font-size: 0.9375rem;
  color: var(--ff-text);
  background: var(--ff-panel);
  border: 1px solid var(--ff-line);
  border-radius: 2px;
}

.ff-field input {
  font-family: var(--ff-mono);
  font-size: 1rem;
}

.ff-field input:focus-visible,
.ff-field select:focus-visible {
  outline: 2px solid var(--tf-accent);
  outline-offset: -1px;
}

/* ── Primary action button ──────────────────────────────────────────────── */

.ff-btn {
  display: block;
  width: 100%;
  padding: 0.75rem 1.5rem;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--tf-accent-ink);
  background: var(--tf-accent);
  border: 1px solid var(--tf-accent);
  border-radius: 2px;
  cursor: pointer;
}

.ff-btn:hover  { background: var(--tf-accent-hover);  border-color: var(--tf-accent-hover); }
.ff-btn:active { background: var(--tf-accent-active); border-color: var(--tf-accent-active); }

.ff-btn:focus-visible {
  outline: 2px solid var(--tf-accent);
  outline-offset: 2px;
}

/* ── Results ─────────────────────────────────────────────────────────────── */

.ff-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  margin-bottom: 1rem;
}

@media (max-width: 22rem) {
  .ff-grid { grid-template-columns: 1fr; }
}

.ff-metric {
  padding: 1rem 0.75rem;
  border: 1px solid var(--ff-line);
  border-radius: 2px;
  background: var(--ff-panel);
  text-align: center;
}

.ff-metric-label {
  margin: 0 0 0.375rem;
  font-size: 0.75rem;
  color: var(--ff-muted);
}

.ff-metric-value {
  margin: 0;
  font-family: var(--ff-mono);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--tf-accent);
}

.ff-note {
  margin: 0;
  font-size: 0.8125rem;
  line-height: 1.55;
  color: var(--ff-muted);
}

/* ── Ad slots ───────────────────────────────────────────────────────────── */

.ff-ad {
  min-height: 280px;
  margin: 2rem auto 0;
  max-width: 28rem;
  padding-inline: 1.5rem;
  overflow: hidden;
}

@media (max-width: 26rem) {
  .ff-wrap,
  .ff-ad { padding-inline: 1rem; }
  .ff-panel { padding: 1.25rem; }
}

/* tf:dark-palette — generated by migrate_chrome.py */
/* Neutrals inherit the shared chrome tokens so all tools share one
   ground; brand hues are kept and lightened, never inverted. */
[data-theme="dark"] {
  --ff-surface: var(--tf-surface);
  --ff-panel: var(--tf-surface);
  --ff-line: var(--tf-rule);
  --ff-text: var(--tf-ink);
  --ff-muted: var(--tf-ink-soft);
}
