/* Formulario demo y panel de leads — GarageMax */
.demo-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(160deg, var(--bg-muted) 0%, var(--bg-page) 45%);
}

.demo-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(var(--header-h) + 2rem) 1rem 3rem;
}

.demo-card {
  width: min(100%, 440px);
  background: var(--bg-surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
  border: 1px solid var(--border-light);
}

.demo-card--wide {
  width: min(100%, 920px);
}

.demo-card h1 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.demo-card .demo-lead {
  color: var(--text-muted);
  font-size: 0.9375rem;
  margin-bottom: 1.5rem;
}

.demo-form label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.375rem;
}

.demo-optional {
  font-weight: 500;
  color: var(--text-primary);
  opacity: 0.75;
}

.demo-form input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-family: inherit;
  margin-bottom: 1rem;
  background: var(--bg-page);
  color: var(--text-primary);
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.demo-form input:focus {
  outline: none;
  border-color: var(--azul-acero);
  box-shadow: 0 0 0 3px rgba(45, 74, 109, 0.12);
}

.demo-form button[type="submit"],
.demo-form .btn-load {
  width: 100%;
  margin-top: 0.25rem;
}

.demo-message {
  font-size: 0.875rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
}

.demo-message--info {
  background: var(--accent-soft);
  color: var(--azul-acero);
}

.demo-message--error {
  background: rgba(220, 53, 69, 0.1);
  color: #b02a37;
}

.demo-message--success {
  background: rgba(59, 170, 99, 0.12);
  color: #2d8a4e;
}

.demo-note {
  margin-top: 1.25rem;
  font-size: 0.8125rem;
  color: var(--text-muted);
  text-align: center;
}

.demo-note a {
  color: var(--azul-acero);
  font-weight: 500;
}

.demo-badge {
  display: inline-block;
  background: rgba(255, 122, 41, 0.12);
  color: var(--naranja-motor);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.25rem 0.625rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
}

.demo-leads-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.demo-leads-meta {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.demo-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
}

.demo-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.demo-table th,
.demo-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border-light);
}

.demo-table th {
  background: var(--bg-muted);
  font-weight: 600;
  color: var(--text-heading);
  white-space: nowrap;
}

.demo-table tbody tr:hover {
  background: var(--accent-soft);
}

.demo-table a {
  color: var(--azul-acero);
  font-weight: 500;
}

.demo-key-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-end;
}

.demo-key-form label {
  flex: 1 1 200px;
}

.demo-key-form input {
  margin-bottom: 0;
}

.demo-key-form button {
  flex: 0 0 auto;
  min-width: 120px;
}

@media (max-width: 640px) {
  .demo-card {
    padding: 1.5rem;
  }

  .demo-key-form button {
    width: 100%;
  }
}
