/* =====================================================
   Candidaturas — Construir Casas
   Diseño Suizo arquitectónico: blanco + negro + rojo técnico
   Inter Tight (cabeceras) + Inter (cuerpo) + JetBrains Mono (datos)
   Esquinas afiladas, líneas finas, microinteracciones directas.
   ===================================================== */

:root {
  /* Paleta */
  --bg:           #FFFFFF;
  --surface:      #FAFAFA;
  --text:         #0A0A0A;
  --text-2:       #525252;
  --text-mute:    #A3A3A3;
  --border:       #E5E5E5;
  --border-2:     #D4D4D4;
  --accent:       #DC2626;
  --accent-soft:  #FEE2E2;
  --warn:         #B45309;
  --warn-bg:      #FFFBEB;
  --warn-border:  #FCD34D;
  --danger:       #991B1B;
  --danger-bg:    #FEE2E2;
  --danger-border:#F87171;
  --success:      #15803D;

  /* Tipografía */
  --font-sans: 'Inter Tight', 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'Menlo', 'Consolas', monospace;

  /* Radius */
  --radius-sm: 2px;
  --radius-md: 0;
  --radius-lg: 4px;

  /* Transición */
  --t: 0.15s ease-out;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ---- Topbar ---- */
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 32px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 10;
}
.logo {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text);
}
.logo span {
  color: var(--text-mute);
  margin: 0 2px;
  font-weight: 400;
}

.progress-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 240px;
  margin-left: auto;
}
.progress-bar {
  flex: 1;
  height: 2px;
  background: var(--border);
  border-radius: 0;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  width: 0%;
  background: var(--accent);
  border-radius: 0;
  transition: width .35s ease-out;
}
.progress-text {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--text-2);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* ---- Main / Screens ---- */
main {
  flex: 1;
  position: relative;
  overflow: hidden;
}
.screen {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 32px 96px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity .25s ease-out, transform .25s ease-out;
  overflow-y: auto;
}
.screen.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.screen-inner {
  width: 100%;
  max-width: 720px;
  margin: auto;
}
.screen-inner.intro { text-align: left; }

/* ---- Typography ---- */
h1 {
  font-family: var(--font-sans);
  font-size: clamp(36px, 5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin: 0 0 24px;
  font-weight: 600;
  color: var(--text);
}
h1 .accent { color: var(--accent); }
.lead {
  font-family: var(--font-sans);
  font-size: 17px;
  color: var(--text-2);
  line-height: 1.55;
  margin: 0 0 36px;
  max-width: 600px;
  font-weight: 400;
}
.eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-2);
  font-weight: 500;
  margin-bottom: 20px;
}
.muted { font-size: 14px; color: var(--text-2); }
.muted a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }

/* ---- Question screens ---- */
.q-number {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 18px;
}
.q-number svg { width: 12px; height: 12px; stroke-width: 2; }
.q-number-badge {
  margin-left: 12px;
  padding: 3px 8px;
  background: var(--accent);
  color: var(--bg);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
}
.q-title {
  font-family: var(--font-sans);
  font-size: clamp(26px, 3.6vw, 36px);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
  font-weight: 500;
  color: var(--text);
}
.q-help {
  font-size: 15px;
  color: var(--text-2);
  margin: 0 0 32px;
  line-height: 1.6;
  max-width: 620px;
}
.q-image {
  margin: 0 0 36px;
  border: 1px solid var(--border);
  border-radius: 0;
  overflow: hidden;
  background: var(--bg);
}
.q-image img,
.q-image video { display: block; width: 100%; height: auto; background: var(--surface); }

/* Grid de varias imágenes (.q-grid-N donde N=1..4+) */
.q-image.q-grid-2,
.q-image.q-grid-3,
.q-image.q-grid-4 {
  display: grid;
  gap: 1px;
  background: var(--border);
}
.q-image.q-grid-2 { grid-template-columns: 1fr 1fr; }
.q-image.q-grid-3 { grid-template-columns: 1fr 1fr 1fr; }
.q-image.q-grid-4 { grid-template-columns: 1fr 1fr; }
.q-image[class*="q-grid-"] img { aspect-ratio: 4/3; object-fit: cover; }
@media (max-width: 600px) {
  .q-image.q-grid-3 { grid-template-columns: 1fr 1fr; }
}

/* ---- Inputs ---- */
.input-wrap { margin-bottom: 8px; }
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="number"],
select,
textarea {
  width: 100%;
  padding: 14px 0;
  font-family: var(--font-sans);
  font-size: 22px;
  line-height: 1.4;
  color: var(--text);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-2);
  outline: none;
  transition: border-color var(--t);
  border-radius: 0;
  -webkit-appearance: none;
  appearance: none;
  letter-spacing: -0.005em;
}
input:focus, select:focus, textarea:focus {
  border-bottom-color: var(--text);
}
input::placeholder, textarea::placeholder {
  color: var(--text-mute);
  font-weight: 400;
}
select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%230A0A0A' stroke-width='1.5' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  padding-right: 32px;
  cursor: pointer;
}
textarea {
  resize: vertical;
  min-height: 80px;
}

.input-error {
  display: none;
  margin-top: 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--accent);
}
.input-error.visible { display: block; }
.input-error[hidden] { display: none !important; }

/* ---- Time input (HH:MM) ---- */
.time-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  border-bottom: 1px solid var(--border-2);
  padding: 14px 0;
  transition: border-color var(--t);
}
.time-row:focus-within { border-bottom-color: var(--text); }
.time-row .time-part {
  border: none !important;
  padding: 0 !important;
  font-family: var(--font-mono);
  font-size: 32px !important;
  font-weight: 500;
  color: var(--text);
  background: transparent;
  outline: none;
  font-variant-numeric: tabular-nums;
  width: 70px;
  text-align: center;
  letter-spacing: -0.01em;
}
.time-row .time-part:focus { border: none !important; }
.time-row .time-part::placeholder { color: var(--border-2); font-weight: 400; }
.time-row .time-sep {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 400;
  color: var(--accent);
  user-select: none;
  line-height: 1;
}
.time-row .time-suffix {
  font-family: var(--font-mono);
  color: var(--text-mute);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-left: 16px;
  user-select: none;
  align-self: center;
}

/* ---- Time group (varios HH:MM en una sola pantalla) ---- */
.time-group {
  display: flex;
  flex-direction: column;
  gap: 32px;
  margin-top: 8px;
  border-top: 1px solid var(--border);
  padding-top: 28px;
}
.time-group-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border);
}
.time-group-field:last-child { border-bottom: none; padding-bottom: 0; }
.time-group-label {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  margin: 0;
  line-height: 1.4;
}
.time-group-help {
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--text-2);
  margin: 0;
  line-height: 1.55;
}
.time-group-help strong {
  color: var(--text);
  font-weight: 600;
}
.time-group-field .time-row {
  margin-top: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-2);
  align-self: flex-start;
  min-width: 240px;
}
.time-group-field .time-row .time-part {
  font-size: 24px !important;
  width: 56px;
}
.time-group-field .time-row .time-sep { font-size: 24px; }
.time-group-field .time-row .time-suffix {
  font-size: 10px;
  margin-left: 12px;
}
@media (max-width: 600px) {
  .time-group-field .time-row { min-width: 200px; }
}

/* ---- Year input + "no tengo título" checkbox ---- */
.year-row {
  display: flex;
  align-items: baseline;
  border-bottom: 1px solid var(--border-2);
  padding: 14px 0;
  transition: border-color var(--t);
}
.year-row:focus-within { border-bottom-color: var(--text); }
.year-row input {
  border: none !important;
  padding: 0 !important;
  font-family: var(--font-mono);
  font-size: 32px !important;
  font-weight: 500;
  color: var(--text);
  background: transparent;
  outline: none;
  font-variant-numeric: tabular-nums;
  width: 160px;
}
.year-row input:focus { border: none !important; }
.year-row input::placeholder { color: var(--border-2); font-weight: 400; }
.year-row input:disabled {
  color: var(--text-mute);
  -webkit-text-fill-color: var(--text-mute);
}
.year-row input::-webkit-outer-spin-button,
.year-row input::-webkit-inner-spin-button {
  -webkit-appearance: none; margin: 0;
}
.year-row input { -moz-appearance: textfield; }

.year-none-check {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
  padding: 12px 16px;
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: background var(--t), border-color var(--t);
  user-select: none;
  background: var(--bg);
}
.year-none-check:hover { border-color: var(--text); background: var(--surface); }
.year-none-check input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.year-none-box {
  width: 18px;
  height: 18px;
  border: 1px solid var(--border-2);
  border-radius: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  color: var(--bg);
  flex-shrink: 0;
  transition: background var(--t), border-color var(--t);
}
.year-none-box svg {
  width: 14px; height: 14px;
  opacity: 0;
  transition: opacity var(--t);
}
.year-none-check.selected {
  background: var(--bg);
  border-color: var(--text);
}
.year-none-check.selected .year-none-box {
  background: var(--text);
  border-color: var(--text);
}
.year-none-check.selected .year-none-box svg { opacity: 1; }
.year-none-label {
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
}

/* ---- Currency input ---- */
.currency-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  border-bottom: 1px solid var(--border-2);
  padding: 14px 0;
  font-size: 28px;
  transition: border-color var(--t);
}
.currency-row:focus-within { border-bottom-color: var(--text); }
.currency-row .currency-symbol {
  color: var(--text);
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 24px;
  min-width: 28px;
}
.currency-row input {
  flex: 1;
  border: none !important;
  padding: 0 !important;
  font-family: var(--font-mono) !important;
  font-size: 28px !important;
  font-weight: 500;
  color: var(--text);
  background: transparent;
  outline: none;
  font-variant-numeric: tabular-nums;
  min-width: 60px;
}
.currency-row input:focus { border: none !important; }
.currency-row .currency-decimals {
  font-family: var(--font-mono);
  color: var(--text-mute);
  font-size: 20px;
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  user-select: none;
}
.currency-row .currency-code {
  font-family: var(--font-mono);
  color: var(--text-mute);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-left: 10px;
  user-select: none;
  align-self: center;
  white-space: nowrap;
}

/* ---- Currency range ---- */
.currency-range {
  display: flex;
  flex-direction: column;
  gap: 28px;
}
.currency-range-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.currency-range-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-2);
}
.currency-range .currency-row { font-size: 22px; padding: 10px 0; }
.currency-range .currency-row .currency-symbol { font-size: 20px; }
.currency-range .currency-row input { font-size: 24px !important; }
.currency-range .currency-row .currency-decimals { font-size: 16px; }
.currency-range .currency-row .currency-code { font-size: 11px; }

.currency-warning {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-top: 16px;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--warn-border);
  border-left: 3px solid var(--warn);
  border-radius: 0;
  font-size: 13px;
  line-height: 1.55;
  color: var(--warn);
  transition: border-color var(--t), color var(--t);
}
.currency-warning[hidden] { display: none !important; }
.currency-warning svg { width: 14px; height: 14px; flex-shrink: 0; margin-top: 2px; color: var(--warn); stroke-width: 2; }
.currency-warning .warn-text { color: var(--warn); }
.currency-warning .warn-text strong { color: inherit; font-weight: 600; }

/* Tramo rojo (DANGER) */
.currency-warning.danger {
  background: var(--bg);
  border-color: var(--danger-border);
  border-left-color: var(--danger);
  color: var(--danger);
}
.currency-warning.danger svg { color: var(--danger); }
.currency-warning.danger .warn-text { color: var(--danger); }

/* ---- Choice options (radio / checkbox) ---- */
.options { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.options.compact { display: grid; grid-template-columns: repeat(auto-fit, minmax(56px, 1fr)); gap: 6px; }

.option {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg);
  cursor: pointer;
  font-size: 15px;
  line-height: 1.55;
  transition: border-color var(--t), background var(--t);
  position: relative;
}
.option:hover { border-color: var(--text); background: var(--surface); }
.option.selected {
  border-color: var(--text);
  background: var(--bg);
  box-shadow: inset 0 0 0 1px var(--text);
}
.option .key {
  flex-shrink: 0;
  min-width: 26px;
  height: 22px;
  padding: 0 6px;
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  color: var(--text-2);
  transition: background var(--t), border-color var(--t), color var(--t);
}
.option:hover .key {
  border-color: var(--text);
  color: var(--text);
}
.option.selected .key {
  background: var(--text);
  border-color: var(--text);
  color: var(--bg);
}
.option .label { flex: 1; color: var(--text); }
.option .check {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  opacity: 0;
  color: var(--accent);
  stroke-width: 2.5;
}
.option.selected .check { opacity: 1; }

.options.compact .option {
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 14px 8px;
  min-height: 60px;
  text-align: center;
}
.options.compact .option .key { display: none; }
.options.compact .option .label {
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.options.compact .option .check { display: none; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 22px;
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--t), color var(--t), border-color var(--t);
}
.btn svg { width: 14px; height: 14px; stroke-width: 2; }
.btn-primary {
  background: var(--text);
  color: var(--bg);
  border: 1px solid var(--text);
}
.btn-primary:hover {
  background: var(--accent);
  border-color: var(--accent);
}
.btn-primary:disabled {
  background: var(--border-2);
  border-color: var(--border-2);
  color: var(--text-mute);
  cursor: not-allowed;
}
.btn-ghost {
  background: transparent;
  color: var(--text-2);
  border: 1px solid transparent;
}
.btn-ghost:hover {
  color: var(--text);
  background: var(--surface);
}

.link {
  background: none;
  border: none;
  color: var(--accent);
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 14px;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.link:hover { color: var(--text); }

/* ---- Bottombar ---- */
.bottombar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 32px;
  border-top: 1px solid var(--border);
  background: var(--bg);
}
.hint {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--text-2);
}
kbd {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 2px 6px;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  margin: 0 2px;
}
.nav-buttons { display: flex; gap: 8px; }
.nav-buttons[hidden] { display: none; }

/* ---- WhatsApp combo ---- */
.whatsapp-combo {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 2fr;
  gap: 16px;
  align-items: end;
}
.whatsapp-combo select,
.whatsapp-combo input[type="tel"] {
  width: 100%;
}
@media (max-width: 600px) {
  .whatsapp-combo { grid-template-columns: 1fr; gap: 12px; }
}

/* ---- Text libre para "Otro" en checkbox ---- */
.q-checkbox-other-input { margin-top: 12px; }
.q-checkbox-other-input[hidden] { display: none; }

/* ---- Intro screen meta (legacy, hoy oculto) ---- */
.meta {
  display: flex;
  gap: 32px;
  margin: 32px 0 40px;
  padding: 24px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.meta-item { display: flex; flex-direction: column; gap: 4px; }
.meta-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-2);
}
.meta-item span:not(.meta-label) {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 500;
}

.resume-hint { margin-top: 24px; font-size: 14px; }

/* ---- File upload ---- */
.file-drop {
  border: 1px dashed var(--border-2);
  border-radius: 0;
  padding: 40px 24px;
  text-align: center;
  cursor: pointer;
  transition: border-color var(--t), background var(--t);
  background: var(--bg);
}
.file-drop:hover, .file-drop.dragover {
  border-color: var(--text);
  border-style: solid;
  background: var(--surface);
}
.file-drop.has-file {
  border-style: solid;
  border-color: var(--text);
  background: var(--surface);
  text-align: left;
  padding: 20px 24px;
}
.file-drop input[type="file"] { display: none; }
.file-drop .upload-icon {
  width: 36px;
  height: 36px;
  margin: 0 auto 14px;
  color: var(--text-2);
  stroke-width: 1.5;
}
.file-drop .upload-text {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 4px;
}
.file-drop .upload-hint {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--text-2);
  text-transform: uppercase;
}
.file-info {
  display: flex;
  align-items: center;
  gap: 12px;
}
.file-info-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.file-info .file-icon {
  width: 32px;
  height: 32px;
  background: var(--text);
  color: var(--bg);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background var(--t);
}
.file-info .file-icon-done {
  background: var(--success);
}
.file-info .file-icon-error {
  background: var(--accent);
}
.file-info .file-name {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 14px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.file-info .file-size,
.file-info .file-status {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-2);
  letter-spacing: 0.02em;
}
.file-info .file-status-done { color: var(--success); }
.file-info .file-status-error { color: var(--accent); }
.file-info .file-remove {
  margin-left: auto;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-2);
  padding: 4px;
}
.file-info .file-remove:hover { color: var(--accent); }
.file-info .file-retry {
  margin-left: auto;
  background: var(--text);
  color: var(--bg);
  border: none;
  cursor: pointer;
  padding: 6px 12px;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  border-radius: var(--radius-sm);
  transition: background var(--t);
}
.file-info .file-retry:hover { background: var(--accent); }

/* Barra de progreso debajo del file-info durante la subida */
.file-progress {
  margin-top: 12px;
  height: 2px;
  background: var(--border);
  border-radius: 0;
  overflow: hidden;
}
.file-progress-fill {
  height: 100%;
  background: var(--accent);
  transition: width .25s ease-out;
}
.file-drop.is-uploading {
  border-style: solid;
  border-color: var(--text);
  background: var(--surface);
}
.file-drop.is-done {
  border-style: solid;
  border-color: var(--success);
  background: var(--surface);
}
.file-drop.is-failed {
  border-style: solid;
  border-color: var(--accent);
  background: var(--surface);
}

/* ---- Success ---- */
.success-icon {
  width: 56px;
  height: 56px;
  color: var(--text);
  margin-bottom: 28px;
  stroke-width: 1.5;
  border: 1px solid var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0;
  padding: 12px;
}
.success-icon svg { width: 100%; height: 100%; }

/* ---- Submitting overlay ---- */
.submitting {
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.96);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  flex-direction: column;
  gap: 24px;
}
.submitting .spinner {
  width: 32px;
  height: 32px;
  border: 2px solid var(--border);
  border-top-color: var(--text);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.submitting .upload-progress {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--text);
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- Focus visible global ---- */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
button:focus-visible,
.option:focus-visible,
.year-none-check:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---- Mobile ---- */
@media (max-width: 720px) {
  .topbar { padding: 14px 20px; }
  .progress-wrap { min-width: 140px; gap: 12px; }
  .screen { padding: 32px 20px 72px; }
  .bottombar { padding: 12px 20px; }
  .meta { gap: 20px; }
  .options.compact { grid-template-columns: repeat(5, 1fr); }
  input[type="text"], input[type="email"], input[type="tel"],
  input[type="url"], input[type="number"], select, textarea {
    font-size: 18px;
  }
  .hint { display: none; }
}
