/* runpod-translate PWA — black/white minimal, big touch targets, mobile-first. */

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: #000;
  color: #fff;
  font: 16px/1.4 -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
}

main {
  padding: 16px;
  padding-bottom: max(16px, env(safe-area-inset-bottom));
}

/* ---- tabs ---- */
.tabs {
  display: flex;
  position: sticky;
  top: 0;
  background: #000;
  border-bottom: 1px solid #222;
  padding-top: env(safe-area-inset-top);
  z-index: 10;
}
.tab-btn {
  flex: 1;
  padding: 16px 8px;
  background: transparent;
  color: #888;
  border: 0;
  border-bottom: 3px solid transparent;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.tab-btn.active {
  color: #fff;
  border-bottom-color: #fff;
}

/* ---- panels ---- */
.tab-panel { display: none; }
.tab-panel.active { display: block; }

.row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 12px 0;
}
.row label {
  flex: 0 0 110px;
  color: #888;
  font-size: 14px;
}
.row select,
.row input[type="password"] {
  flex: 1;
  padding: 12px;
  background: #111;
  color: #fff;
  border: 1px solid #333;
  border-radius: 8px;
  font: inherit;
}

/* ---- buttons ---- */
.big-btn,
.warn-btn,
.danger-btn {
  display: block;
  width: 100%;
  padding: 24px;
  margin: 16px 0;
  font: inherit;
  font-size: 18px;
  font-weight: 600;
  border-radius: 12px;
  border: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.big-btn   { background: #fff; color: #000; }
.warn-btn  { background: #c4a200; color: #000; }
.danger-btn{ background: #b00020; color: #fff; }
.big-btn:active,
.warn-btn:active,
.danger-btn:active { transform: scale(0.98); }

/* ---- readouts ---- */
.readout {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
  color: #888;
  margin: 8px 0;
  min-height: 1.4em;
}
.readout.err, .err { color: #ff6464; }
.status, .latency { font-variant-numeric: tabular-nums; }

.hint {
  color: #666;
  font-size: 13px;
  margin-top: 24px;
}

/* ---- subtitle full-screen overlay ---- */
.subtitle-fs {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: #000;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
  flex-direction: column;
  justify-content: flex-end;
  cursor: pointer;
}
body.fs-active .subtitle-fs { display: flex; }

.subtitle-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 24px;
  font-size: clamp(28px, 8vw, 56px);
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
  text-wrap: balance;
}
.subtitle-text .line { margin: 8px 0; }
.subtitle-text .line.partial { opacity: 0.6; }

.subtitle-fs-meta {
  text-align: center;
  color: #666;
  font-size: 13px;
  padding: 12px;
}
