/* ==========================================================================
   Smart Incubator — Site Design System
   Sobek IT · Incubation Automation Suite
   Phase E: register / verify / login (first half) + public site (second half —
   see PHASE_E2_DOCUMENTATION.md §3 for the marketing-page component plan)

   Token rationale (see PHASE_E1_DOCUMENTATION.md §3 for the full plan):
   - Palette reads as "inside a warm brooder box at night": near-black warm
     charcoal, an amber heat-lamp accent, an eggshell-cream text color.
   - Display face (Fraunces) carries personality on headings only; body/UI
     text stays in Inter for legibility; IBM Plex Mono is reserved for
     status/log-style microcopy, echoing the desktop app's own log.txt feel.
   ========================================================================== */

:root {
  /* Color */
  --bg-void:        #14110D;
  --surface:         #211C16;
  --surface-raised:  #2C2519;
  --surface-border:  #3B3223;
  --accent-heat:     #E8A23D;
  --accent-heat-dim: #C97F1E;
  --text-shell:      #F4EBD9;
  --text-muted:      #A99C87;
  --success-hatch:   #8FB35C;
  --success-hatch-bg: rgba(143, 179, 92, 0.12);
  --error-alert:     #E0574A;
  --error-alert-bg:  rgba(224, 87, 74, 0.12);

  /* Type */
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;

  /* Scale */
  --radius-card: 14px;
  --radius-control: 8px;
  --shadow-card: 0 24px 60px -20px rgba(0, 0, 0, 0.65);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg-void);
  color: var(--text-shell);
  font-family: var(--font-body);
  min-height: 100%;
}

body {
  background-image:
    radial-gradient(circle at 15% -10%, rgba(232, 162, 61, 0.14), transparent 45%),
    radial-gradient(circle at 100% 100%, rgba(232, 162, 61, 0.06), transparent 50%);
}

a { color: var(--accent-heat); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--accent-heat);
  outline-offset: 2px;
}

.page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
}

@media (max-width: 880px) {
  .page { grid-template-columns: 1fr; }
  .brand-panel { min-height: 220px; padding: 32px 28px 40px; }
  .brand-panel .gauge-wrap { display: none; }
}

/* ---------- Brand / signature panel ---------- */
.brand-panel {
  padding: 56px 56px 40px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid var(--surface-border);
  position: relative;
  overflow: hidden;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--text-shell);
}

.wordmark svg { flex: none; }

a.wordmark:hover { text-decoration: none; opacity: 0.85; }

.brand-copy h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(28px, 3.4vw, 40px);
  line-height: 1.12;
  margin: 28px 0 14px;
  max-width: 11ch;
}

.brand-copy p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 34ch;
  margin: 0;
}

.gauge-wrap {
  margin-top: 40px;
  display: flex;
  align-items: center;
  gap: 18px;
}

.gauge-caption {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
}

.gauge-caption strong {
  display: block;
  color: var(--accent-heat);
  font-size: 15px;
  letter-spacing: 0.02em;
}

.gauge-needle {
  transform-origin: 90px 90px;
  animation: settle 3.6s ease-in-out infinite;
}

@keyframes settle {
  0%, 100% { transform: rotate(-2deg); }
  50% { transform: rotate(2deg); }
}

@media (prefers-reduced-motion: reduce) {
  .gauge-needle { animation: none; }
}

.footnote {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  opacity: 0.8;
}

/* ---------- Form panel ---------- */
.form-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 28px;
}

.card {
  width: 100%;
  max-width: 380px;
}

.card h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 26px;
  margin: 0 0 6px;
}

.card .lede {
  color: var(--text-muted);
  font-size: 14px;
  margin: 0 0 28px;
  line-height: 1.5;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  font-size: 12px;
  font-family: var(--font-mono);
  letter-spacing: 0.03em;
  color: var(--text-muted);
  margin-bottom: 6px;
  text-transform: uppercase;
}

.field input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text-shell);
  font-family: var(--font-body);
  font-size: 15px;
  padding: 11px 13px;
  border-radius: var(--radius-control);
  transition: border-color 0.15s ease;
}

.field input::placeholder { color: #6E6350; }

.field input:focus {
  border-color: var(--accent-heat);
}

.field-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

.field-error {
  font-size: 12px;
  color: var(--error-alert);
  margin-top: 6px;
  display: none;
}

.field.has-error input { border-color: var(--error-alert); }
.field.has-error .field-error { display: block; }

button.btn-primary {
  width: 100%;
  background: var(--accent-heat);
  color: #1C1408;
  border: none;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  padding: 13px 16px;
  border-radius: var(--radius-control);
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
  margin-top: 6px;
}

button.btn-primary:hover { background: #F0AE52; }
button.btn-primary:active { transform: translateY(1px); }

button.btn-primary:disabled {
  background: var(--surface-raised);
  color: var(--text-muted);
  cursor: not-allowed;
}

.alt-action {
  text-align: center;
  margin-top: 22px;
  font-size: 14px;
  color: var(--text-muted);
}

.banner {
  border-radius: var(--radius-control);
  padding: 13px 14px;
  font-size: 13.5px;
  line-height: 1.5;
  margin-bottom: 20px;
  display: none;
}

.banner.show { display: block; }

.banner.banner-error {
  background: var(--error-alert-bg);
  color: #FF9E92;
  border: 1px solid rgba(224, 87, 74, 0.35);
}

.banner.banner-success {
  background: var(--success-hatch-bg);
  color: #C6E0A9;
  border: 1px solid rgba(143, 179, 92, 0.35);
}

.status-block {
  text-align: center;
  padding: 12px 0 4px;
}

.status-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 18px;
}

.spinner {
  width: 28px;
  height: 28px;
  border: 3px solid var(--surface-border);
  border-top-color: var(--accent-heat);
  border-radius: 50%;
  margin: 0 auto 18px;
  animation: spin 0.85s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  .spinner { animation: spin 1.6s linear infinite; }
}

.session-chip {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--text-muted);
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-control);
  padding: 10px 12px;
  margin-top: 18px;
  word-break: break-all;
}

.session-chip strong { color: var(--text-shell); }

/* ==========================================================================
   Marketing pages — index.html / about.html
   Phase E, second half (§6.1). Reuses every token above unchanged; adds
   layout components for a full-width scroll rather than the auth pages'
   fixed split-panel. See PHASE_E2_DOCUMENTATION.md §3 for the plan.
   ========================================================================== */

.site-body { overflow-x: hidden; }

/* ---------- Top nav ---------- */
.site-nav {
  border-bottom: 1px solid var(--surface-border);
  position: relative;
}

.nav-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14.5px;
}

.nav-links a:not(.btn-primary):not(.btn-ghost) {
  color: var(--text-muted);
}
.nav-links a:not(.btn-primary):not(.btn-ghost):hover { color: var(--text-shell); }

.nav-actions { display: flex; align-items: center; gap: 12px; }

.btn-ghost {
  display: inline-block;
  border: 1px solid var(--surface-border);
  color: var(--text-shell);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14px;
  padding: 9px 16px;
  border-radius: var(--radius-control);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.btn-ghost:hover { border-color: var(--accent-heat); text-decoration: none; background: var(--surface); }

.nav-actions .btn-primary {
  width: auto;
  display: inline-block;
  padding: 9px 18px;
  font-size: 14px;
  margin-top: 0;
  text-decoration: none;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-control);
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
}
.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text-shell);
  border-radius: 1px;
}

@media (max-width: 720px) {
  .nav-inner { padding: 18px 20px; }
  .nav-toggle { display: flex; }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--surface-border);
    padding: 8px 20px 18px;
    box-shadow: var(--shadow-card);
    z-index: 40;
  }
  .nav-links.is-open { display: flex; }

  .nav-links a:not(.btn-primary):not(.btn-ghost) {
    padding: 13px 0;
    border-bottom: 1px solid var(--surface-border);
  }

  .nav-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding-top: 14px;
  }
  .nav-actions .btn-ghost,
  .nav-actions .btn-primary { text-align: center; }

  .dashboard-account { padding: 12px 0; }
}

/* ---------- Hero ---------- */
.hero {
  max-width: 1180px;
  margin: 0 auto;
  padding: 72px 40px 40px;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}

@media (max-width: 940px) {
  .hero { grid-template-columns: 1fr; padding: 48px 24px 20px; }
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-heat);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.eyebrow::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-heat);
}

.hero h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(32px, 4.2vw, 52px);
  line-height: 1.08;
  margin: 0 0 20px;
  max-width: 14ch;
}

.hero .lede {
  font-size: 16.5px;
  line-height: 1.65;
  color: var(--text-muted);
  max-width: 46ch;
  margin: 0 0 30px;
}

.hero-ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.hero-ctas .btn-primary { width: auto; display: inline-block; padding: 13px 22px; margin-top: 0; text-decoration: none; }
.hero-ctas .btn-ghost { padding: 13px 22px; }

.hero-note {
  margin-top: 18px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
}

/* ---------- Dashboard preview (hero signature element) ---------- */
.dash-mock {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: 22px;
}

.dash-mock-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.dash-mock-title {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.dash-mock-dot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--success-hatch);
}
.dash-mock-dot::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--success-hatch);
}

.dash-mock-body {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
}

.tray-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}

.tray-cell {
  aspect-ratio: 1;
  border-radius: 6px;
  border: 1px solid var(--surface-border);
  background: var(--bg-void);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
  position: relative;
}

.tray-cell.filled {
  border-color: var(--accent-heat-dim);
  background: rgba(232, 162, 61, 0.1);
  color: var(--text-shell);
}
.tray-cell.filled::after {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-heat);
  position: absolute;
  top: 6px;
  right: 6px;
}

.tray-cell.hatch-day {
  border-color: var(--accent-heat);
  box-shadow: 0 0 0 1px var(--accent-heat), 0 0 14px rgba(232, 162, 61, 0.35);
  animation: hatch-pulse 2.4s ease-in-out infinite;
}

@keyframes hatch-pulse {
  0%, 100% { box-shadow: 0 0 0 1px var(--accent-heat), 0 0 14px rgba(232, 162, 61, 0.25); }
  50% { box-shadow: 0 0 0 1px var(--accent-heat), 0 0 20px rgba(232, 162, 61, 0.55); }
}

@media (prefers-reduced-motion: reduce) {
  .tray-cell.hatch-day { animation: none; }
}

.dash-mock-gauge { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.dash-mock-gauge .gauge-caption { text-align: center; }

.dash-ticker {
  margin-top: 16px;
  border-top: 1px solid var(--surface-border);
  padding-top: 12px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  line-height: 1.9;
  color: var(--text-muted);
}
.dash-ticker span { color: var(--accent-heat-dim); }

/* ---------- Generic section scaffolding ---------- */
.section {
  max-width: 1180px;
  margin: 0 auto;
  padding: 64px 40px;
}

.section-border-top { border-top: 1px solid var(--surface-border); }

@media (max-width: 720px) {
  .section { padding: 48px 24px; }
}

.section-head { max-width: 60ch; margin-bottom: 40px; }
.section-head h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(24px, 3vw, 32px);
  margin: 0 0 12px;
}
.section-head p { color: var(--text-muted); font-size: 15px; line-height: 1.6; margin: 0; }

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

.feature-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  padding: 24px;
}

.feature-icon {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: rgba(232, 162, 61, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}
.feature-icon svg { display: block; }

.feature-card h3 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  margin: 0 0 8px;
}

.feature-card p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
}

/* ---------- Steps ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

@media (max-width: 820px) {
  .steps { grid-template-columns: 1fr; }
}

.step-card { position: relative; padding-top: 6px; }

.step-num {
  font-family: var(--font-display);
  font-size: 34px;
  color: var(--accent-heat-dim);
  line-height: 1;
  margin-bottom: 14px;
  display: block;
}

.step-card h3 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  margin: 0 0 8px;
}

.step-card p { font-size: 14px; line-height: 1.6; color: var(--text-muted); margin: 0; }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--surface);
  border-top: 1px solid var(--surface-border);
  border-bottom: 1px solid var(--surface-border);
}

.cta-band-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 56px 40px;
  text-align: center;
}

.cta-band h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(24px, 3vw, 32px);
  margin: 0 0 12px;
}

.cta-band p { color: var(--text-muted); font-size: 15px; margin: 0 0 26px; }

.cta-band .hero-ctas { justify-content: center; }

/* ---------- Footer ---------- */
.site-footer {
  max-width: 1180px;
  margin: 0 auto;
  padding: 40px 40px 56px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.footer-links { display: flex; gap: 22px; font-size: 13.5px; }
.footer-links a { color: var(--text-muted); }
.footer-links a:hover { color: var(--text-shell); }

.footer-brand { display: flex; flex-direction: column; gap: 6px; }
.footer-brand .wordmark { font-size: 16px; }

/* ---------- About page: architecture split ---------- */
.split-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

@media (max-width: 720px) { .split-2 { grid-template-columns: 1fr; } }

.split-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  padding: 26px;
}

.split-card h3 {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-heat);
  margin: 0 0 16px;
}

.split-card ul { margin: 0; padding-left: 18px; }
.split-card li { font-size: 14.5px; line-height: 1.7; color: var(--text-shell); }
.split-card li span { color: var(--text-muted); }

/* ---------- About page: philosophy blockquote ---------- */
.philosophy {
  border-left: 2px solid var(--accent-heat);
  padding-left: 24px;
}

.philosophy p {
  font-family: var(--font-display);
  font-weight: 450;
  font-size: clamp(19px, 2.1vw, 24px);
  line-height: 1.5;
  color: var(--text-shell);
  margin: 0 0 14px;
}

.philosophy cite {
  font-family: var(--font-mono);
  font-style: normal;
  font-size: 12px;
  color: var(--text-muted);
}

/* ---------- About page: security checklist ---------- */
.check-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.check-list li {
  display: flex;
  gap: 12px;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--text-muted);
}
.check-list li strong { color: var(--text-shell); font-weight: 600; }
.check-list li svg { flex: none; margin-top: 3px; }

/* ==========================================================================
   Dashboard — dashboard.html
   Phase F1 (roadmap Phase F, PHASE_F_PLANNING_WebsiteDashboard.md §2). Reuses every token
   above unchanged, plus the .tray-grid/.tray-cell components the hero mock already defined —
   this is that same grid wired to real data and given room to breathe at full page width
   instead of the hero card's compact 3-column layout.
   ========================================================================== */

.dashboard-account {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-muted);
}

.dashboard-shell {
  max-width: 900px;
  margin: 0 auto;
  padding: 56px 40px 80px;
}

@media (max-width: 720px) {
  .dashboard-shell { padding: 40px 20px 60px; }
}

.dashboard-topline {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 28px;
}

.dashboard-topline h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(26px, 3vw, 34px);
  margin: 0;
}

.dashboard-status {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dashboard-synced {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
}

.session-pill {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.02em;
  border-radius: 999px;
  padding: 6px 13px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--surface-border);
  color: var(--text-muted);
  background: var(--surface);
}

.session-pill::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.session-pill-online { color: var(--success-hatch); border-color: rgba(143, 179, 92, 0.35); background: var(--success-hatch-bg); }
.session-pill-offline { color: var(--text-muted); }
.session-pill-error { color: var(--error-alert); border-color: rgba(224, 87, 74, 0.35); background: var(--error-alert-bg); }

.dashboard-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  padding: 24px;
  margin-bottom: 20px;
}

.dashboard-summary {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.dashboard-summary-icon { width: 44px; height: 44px; object-fit: contain; flex: none; }

.dashboard-summary-value {
  font-family: var(--font-display);
  font-size: 24px;
  color: var(--text-shell);
  line-height: 1.1;
}

.dashboard-summary-label {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.dashboard-empty h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 20px;
  margin: 0 0 8px;
}

.dashboard-empty p { color: var(--text-muted); font-size: 14.5px; line-height: 1.6; margin: 0; }

/* Same .tray-grid/.tray-cell base as the hero mock (grid-template-columns is set inline per
   snapshot, since slot layout is dynamic per install — see TrayInventory.Configure). This
   modifier just gives the full-page version more room than the compact hero card gets. */
.tray-grid-lg {
  gap: 8px;
  justify-content: start; /* cluster cells at their fixed size instead of stretching across the card */
}
.tray-grid-lg .tray-cell { font-size: 10px; border-radius: 6px; }
.tray-grid-lg .tray-cell.filled::after { width: 7px; height: 7px; top: 5px; right: 5px; }

.dashboard-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.dashboard-legend span { display: inline-flex; align-items: center; gap: 8px; }
.dashboard-legend img { width: 16px; height: 16px; object-fit: contain; }

.tray-cell-swatch {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  border: 1px solid var(--surface-border);
  background: var(--bg-void);
  display: inline-block;
}

.tray-cell-swatch-hatch {
  border-color: var(--accent-heat);
  box-shadow: 0 0 0 1px var(--accent-heat);
}

.dashboard-footnote {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
  border-top: 1px solid var(--surface-border);
  padding-top: 20px;
}

/* ---------- Phase F2 — telemetry gauges + history charts ---------- */
.telemetry-gauges {
  display: flex;
  justify-content: center;
  gap: 56px;
  flex-wrap: wrap;
}

.gauge-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.gauge-svg { width: 130px; height: 130px; }
.gauge-block .gauge-caption { text-align: center; }

.telemetry-chart-title {
  margin-bottom: 14px;
}

.telemetry-chart {
  width: 100%;
  height: auto;
  display: block;
}

/* ---------- Phase F3 — egg photo browser ---------- */
.egg-card { margin-bottom: 16px; }

.egg-card-head {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.egg-card-grid {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 20px;
  color: var(--text-shell);
}

.egg-card-count {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  margin-left: auto;
}

.photo-strip {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.photo-thumb {
  flex: none;
  width: 84px;
  height: 84px;
  border-radius: 8px;
  border: 1px solid var(--surface-border);
  background: var(--bg-void);
  padding: 0;
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.15s ease;
}

.photo-thumb:hover { border-color: var(--accent-heat-dim); }
.photo-thumb:focus-visible { outline: 2px solid var(--accent-heat); outline-offset: 2px; }

.photo-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(20, 17, 13, 0.92);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.photo-lightbox-img {
  max-width: min(900px, 100%);
  max-height: 78vh;
  border-radius: 10px;
  box-shadow: var(--shadow-card);
}

.photo-lightbox-close {
  position: absolute;
  top: 20px;
  right: 24px;
  background: none;
  border: none;
  color: var(--text-shell);
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
  padding: 8px;
}
.photo-lightbox-close:hover { color: var(--accent-heat); }

.photo-lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text-shell);
  font-size: 28px;
  line-height: 1;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
}
.photo-lightbox-nav:hover { border-color: var(--accent-heat); }
.photo-lightbox-prev { left: 20px; }
.photo-lightbox-next { right: 20px; }

.photo-lightbox-caption {
  position: absolute;
  bottom: 24px;
  left: 0;
  right: 0;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--text-muted);
}

@media (max-width: 600px) {
  .photo-lightbox { padding: 16px; }
  .photo-lightbox-nav { width: 40px; height: 40px; font-size: 22px; }
  .photo-lightbox-prev { left: 8px; }
  .photo-lightbox-next { right: 8px; }
}

/* ---------- Phase F4.2 — remote control (Home CNC) ---------- */
/* button.btn-primary defaults to width:100% (built for narrow login/register forms) — same
   override pattern .hero-ctas .btn-primary already uses to go back to an inline, content-sized
   button inside a wider dashboard card. */
.control-btn {
  width: auto;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 4px;
}

.control-btn-icon { width: 18px; height: 18px; object-fit: contain; }

/* Small status/log-style microcopy under a command button — same font-family rationale as
   .dashboard-synced/.egg-card-count (IBM Plex Mono reserved for status/log text, per the design
   system's own token rationale at the top of this file). Empty and untouched until a command's
   first sendCommand() call. */
.command-status {
  font-family: var(--font-mono);
  font-size: 12.5px;
  margin-top: 10px;
  min-height: 1.4em;
}

.command-status-pending { color: var(--text-muted); }
.command-status-success { color: var(--success-hatch); }
.command-status-error { color: var(--error-alert); }

/* ---------- Phase F4.3 — clickable tray grid, per-egg action panel ---------- */
.tray-cell-clickable {
  cursor: pointer;
  transition: border-color 0.15s ease, transform 0.1s ease;
}
.tray-cell-clickable:hover { border-color: var(--accent-heat); }
.tray-cell-clickable:active { transform: translateY(1px); }

.egg-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.egg-panel-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
}
.egg-panel-close:hover { color: var(--text-shell); }

/* ---------- Phase F4.4 — Discard Egg ---------- */
.egg-panel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.egg-panel-actions .control-btn { margin-top: 4px; }

/* button.btn-primary (same specificity, element+class) already sets background/color — this
   rule needs to come after it in the cascade to win on the tie, which it does simply by being
   appended here. Same red used everywhere else for a destructive/error state in this file
   (--error-alert), not a new color introduced just for this button. */
button.control-btn-danger {
  background: var(--error-alert);
  color: #2A0E0B;
}
button.control-btn-danger:hover { background: #E87367; }
button.control-btn-danger:disabled {
  background: var(--surface-raised);
  color: var(--text-muted);
}

/* ---------- PART6_VOICE_OVER_WEB_PLANNING.md Stage 6C — voice.html ---------- */

.voice-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 32px 24px;
}

.voice-mic-btn {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  border: none;
  background: var(--accent-heat);
  color: #2A1B05;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
  /* Prevents the press-and-hold gesture from also selecting page text or triggering a
     pull-to-refresh on mobile — both would otherwise interrupt the recording it starts. */
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}

.voice-mic-btn:hover { background: #F0AE52; }
.voice-mic-btn:active { transform: scale(0.97); }

.voice-mic-btn:disabled {
  background: var(--surface-raised);
  color: var(--text-muted);
  cursor: not-allowed;
}

/* The only visual state that matters here: recording or not. Red rather than the accent heat
   colour, and pulsing, so a glance across the room (or a half-lit hallway with a phone in
   someone's pocket) still shows whether the mic is live — the same "push-to-talk, not open-mic"
   instinct the plan itself argues for, made visible rather than just true underneath. */
.voice-mic-btn.recording {
  background: var(--error-alert);
  color: #2A0E0B;
  animation: voice-record-pulse 1.4s ease-in-out infinite;
}

@keyframes voice-record-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(224, 87, 74, 0.45); }
  50% { box-shadow: 0 0 0 14px rgba(224, 87, 74, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .voice-mic-btn.recording { animation: none; }
}

.voice-mic-hint {
  margin-top: 14px;
  color: var(--text-muted);
  font-size: 13px;
}

/* The spoken answer, shown on screen too (LOCAL_AI_PLAN.md §6.2's "for a noisy room or a muted
   phone") — deliberately larger and higher-contrast than .command-status, which is status
   microcopy, not the answer itself. */
.voice-answer {
  margin-top: 16px;
  padding: 16px 18px;
  background: var(--surface-raised);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  color: var(--text-shell);
  font-size: 15px;
  line-height: 1.5;
  text-align: left;
}

