/* ============================================================
   Papilio Works — flash.css (hosted web flasher)
   ============================================================ */

.flash-page {
  padding: 48px 24px 96px;
  max-width: 760px;
}

.flash-intro {
  margin-bottom: 2rem;
}

.hero-eyebrow {
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.flash-banner {
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.flash-banner-warn {
  background: var(--warn-dim);
  border: 1px solid var(--warn);
  color: var(--text);
}

.flash-banner-info {
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  color: var(--text);
}

.flash-log-wrap {
  margin-bottom: 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.flash-log-wrap summary {
  cursor: pointer;
  padding: 10px 14px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.85rem;
}

.flash-log {
  margin: 0;
  padding: 12px 14px;
  max-height: 220px;
  overflow-y: auto;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  white-space: pre-wrap;
  word-break: break-word;
}

.flash-step {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 1.5rem;
}

.flash-advanced {
  margin: 0.75rem 0 1rem;
}

.flash-advanced summary {
  cursor: pointer;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.flash-advanced .flash-row {
  margin-top: 0.75rem;
}

.flash-step-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 0.75rem;
}

.flash-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  color: var(--accent);
  font-family: var(--font-mono);
  font-weight: 700;
  flex-shrink: 0;
}

.flash-step-header h2 {
  font-size: 1.15rem;
  font-weight: 700;
}

.flash-step-desc {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.flash-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 0.75rem;
}

.flash-row input[type="text"],
.flash-row input[type="password"],
.flash-row select {
  flex: 1 1 200px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 10px 12px;
  font-family: var(--font-body);
  font-size: 0.9rem;
}

.file-picker {
  position: relative;
  flex: 1 1 220px;
  display: inline-flex;
  align-items: center;
  background: var(--bg-alt);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
  font-size: 0.9rem;
  color: var(--text-muted);
  cursor: pointer;
}

.file-picker input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  padding: 10px 18px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #06110d;
}

.btn-primary:hover:not(:disabled) { filter: brightness(1.08); }

.btn-outline {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn-outline:hover:not(:disabled) { border-color: var(--accent); color: var(--accent); }

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.progress {
  height: 8px;
  border-radius: 100px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  overflow: hidden;
  margin-bottom: 0.5rem;
}

.progress-bar {
  height: 100%;
  background: var(--accent);
  transition: width 0.15s ease-out;
}

.flash-status {
  font-size: 0.85rem;
  color: var(--text-muted);
  min-height: 1.2em;
}

.flash-status.is-error { color: #ff6b6b; }
.flash-status.is-ok { color: var(--accent); }

.flash-ip-label {
  color: var(--text-muted);
  font-size: 0.9rem;
}

#device-ip {
  font-family: var(--font-mono);
  color: var(--accent);
}
