:root {
  --bg: #1F3864;
  --panel: #26406e;
  --accent: #4FD1C5;
  --accent-dark: #2c9c92;
  --text: #F5F7FA;
  --text-dim: #B9C4D6;
  --border: #3a5686;
  --danger: #E4634C;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Inter', 'Work Sans', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

/* Global nav — shared across every BeLocal tool under this domain. Adding a new tool
   means adding one <a> here AND the matching one in that tool's own page (this one has no
   build step, but the animation studio's equivalent lives in src/studio_v2_template.html
   and only takes effect after `npm run build`). */
.global-nav {
  background: #152747;
  color: rgba(255, 255, 255, 0.85);
  padding: 8px 28px;
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 12.5px;
}

.global-nav-brand { font-weight: 700; color: #fff; letter-spacing: 0.3px; }

.global-nav a, .global-nav span.current {
  color: rgba(255, 255, 255, 0.65);
  text-decoration: none;
  padding: 3px 0;
  border-bottom: 2px solid transparent;
}

.global-nav a:hover { color: #fff; }

.global-nav span.current {
  color: #fff;
  font-weight: 700;
  border-bottom-color: var(--accent);
}

header {
  padding: 20px 28px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: baseline;
  gap: 14px;
}

header h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  margin: 0;
}

header p {
  margin: 0;
  color: var(--text-dim);
  font-size: 13px;
}

main {
  max-width: 860px;
  margin: 0 auto;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
}

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

label {
  font-size: 13px;
  color: var(--text-dim);
  display: block;
  margin-bottom: 6px;
}

select, input[type=file] {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  font-size: 14px;
}

.field { display: flex; flex-direction: column; }

button {
  background: var(--accent);
  color: #0b2137;
  border: none;
  border-radius: 6px;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

button:hover { background: var(--accent-dark); }

button:disabled {
  background: #4a5d80;
  color: var(--text-dim);
  cursor: not-allowed;
}

button.secondary {
  background: transparent;
  border: 1px solid var(--accent);
  color: var(--accent);
}

.progress-wrap {
  display: none;
  flex-direction: column;
  gap: 6px;
}

.progress-wrap.active { display: flex; }

.progress-bar {
  height: 8px;
  background: var(--bg);
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.progress-bar > div {
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width .2s ease;
}

.progress-label {
  font-size: 12px;
  color: var(--text-dim);
}

.status {
  font-size: 13px;
  color: var(--text-dim);
  min-height: 18px;
}

.status.error { color: var(--danger); }

#cueList {
  display: none;
  flex-direction: column;
  gap: 8px;
  max-height: 480px;
  overflow-y: auto;
}

#cueList.active { display: flex; }

.cue {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 12px;
  align-items: start;
  padding: 8px;
  border-bottom: 1px solid var(--border);
}

.cue .time {
  font-size: 11px;
  color: var(--text-dim);
  font-variant-numeric: tabular-nums;
  padding-top: 8px;
}

.cue textarea {
  width: 100%;
  min-height: 40px;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 8px;
  font-size: 14px;
  font-family: inherit;
  resize: vertical;
}

.actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.note {
  font-size: 12px;
  color: var(--text-dim);
  line-height: 1.5;
}

.doc-handoff-banner {
  font-size: 13px;
  line-height: 1.5;
  border: 1px solid var(--accent);
  background: rgba(79, 209, 197, 0.1);
}
