/* updater/styles.css — components specific to the firmware updater UI.
   Loaded after the root /styles.css, which provides the design tokens
   (--bg, --surface, --accent, --mono, --radius, etc.), the header/footer
   shell, the nav-toggle, and the table-overflow rules. This file only
   defines updater-specific UI: hero, steps, banners, progress, log. */

/* ── Hero ────────────────────────────────────────────────── */
.hero {
  background: var(--bg);
  padding: 72px 0 48px;
  border-bottom: 1px solid var(--border);
  text-align: left;
}
.hero-content { display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.hero h1 {
  font-family: var(--mono);
  font-size: clamp(28px, 6vw, 40px);
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
  line-height: 1.1;
  margin: 0;
}
.hero h1 span { color: var(--accent); }
.hero .lede {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--text-dim);
  max-width: 56ch;
  margin: 0;
}
.hero-meta {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 4px 10px;
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  background: var(--surface);
}

/* ── Section ─────────────────────────────────────────────── */
.section { padding: 32px 0 64px; }

/* ── Banners (browser warning, MAC change) ────────────────── */
.banner {
  margin-bottom: 18px;
  padding: 12px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border2);
  background: var(--surface);
  font-size: 13px;
  border-left-width: 3px;
}
.banner-warn  { border-left-color: var(--warn); }
.banner-error { border-left-color: var(--err);  color: var(--text); }
.banner strong { display: block; margin-bottom: 4px; color: var(--text); font-family: var(--mono); font-size: 12px; letter-spacing: 0.04em; }
.hidden { display: none !important; }

/* ── Card / flasher steps ────────────────────────────────── */
.card {
  padding: 24px 28px;
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.step {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}
.step:last-child  { border-bottom: 0; padding-bottom: 0; }
.step:first-child { padding-top: 0; }
.step-num {
  width: 28px; height: 28px;
  display: grid; place-items: center;
  background: var(--surface2);
  border: 1px solid var(--accent);
  color: var(--accent);
  border-radius: var(--radius);
  font-family: var(--mono);
  font-weight: 700;
  font-size: 13px;
}
.step-body h3 {
  margin: 2px 0 4px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}
.step-body p {
  margin: 4px 0 12px;
  font-size: 13px;
  color: var(--text-dim);
  line-height: 1.6;
}
.step-body p code,
.step-body code {
  font-family: var(--mono);
  font-size: 12px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 2px;
  padding: 1px 5px;
  color: var(--accent2);
}

.row {
  display: flex; flex-wrap: wrap;
  align-items: center; gap: 10px;
}

/* ── Buttons (override site btn for in-step controls) ────── */
.btn {
  font-family: var(--sans);
  font-size: 13px;
  padding: 8px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #000;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  text-decoration: none;
  display: inline-block;
}
.btn:hover:not(:disabled) { background: var(--accent2); border-color: var(--accent2); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }
.btn.ghost {
  background: var(--surface2);
  color: var(--text);
  border-color: var(--border2);
}
.btn.ghost:hover:not(:disabled) { background: var(--surface); border-color: var(--accent); }
.btn.small { padding: 6px 12px; font-size: 12px; }

/* ── Form controls ───────────────────────────────────────── */
.select {
  font-family: var(--mono);
  font-size: 13px;
  padding: 7px 12px;
  border-radius: var(--radius);
  background: var(--surface2);
  color: var(--text);
  border: 1px solid var(--border2);
  min-width: 18rem;
  outline: none;
  transition: border-color 0.15s;
  cursor: pointer;
}
.select:focus { border-color: var(--accent); }
.select:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── Progress bar ────────────────────────────────────────── */
.progress-wrap { width: 100%; margin-top: 14px; }
.progress-bar {
  height: 4px;
  background: var(--surface2);
  border-radius: 2px;
  overflow: hidden;
  border: 1px solid var(--border);
}
.progress-fill {
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width 0.15s ease;
}
#progress-label {
  display: block;
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--text-dim);
}

/* ── Console log ─────────────────────────────────────────── */
.log-wrap {
  margin-top: 24px;
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
}
.log-wrap summary {
  cursor: pointer;
  padding: 10px 16px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
  user-select: none;
  border-bottom: 1px solid transparent;
}
.log-wrap[open] summary {
  border-bottom-color: var(--border);
  color: var(--accent);
}
.log-wrap pre {
  margin: 0;
  padding: 12px 16px;
  background: var(--bg);
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-dim);
  max-height: 22rem;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
}
