@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;600;700;800&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy: #1B2A4A;
  --salmon: #E8704A;
  --bg: #F5F7FA;
  --white: #FFFFFF;
  --gray: #6B7280;
  --gray-light: #E5E7EB;
  --green: #10B981;
  --red: #EF4444;
  --blue-soft: #DEEAF6;
  --salmon-soft: #FBC7BF;
  --sky: #97CDF1;
  --radius: 10px;
  --radius-sm: 6px;
  --radius-lg: 16px;
}

body {
  font-family: 'Plus Jakarta Sans', sans-serif;
  background: var(--bg);
  color: var(--navy);
  font-size: 16px;
  line-height: 1.6;
}

/* ── HERO ── */
.hero {
  min-height: 100vh;
  background: radial-gradient(ellipse at 30% 50%, var(--blue-soft) 0%, var(--salmon-soft) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px 80px;
}

.hero .logo-wrap {
  margin-bottom: 40px;
}

.hero .logo-wrap img {
  height: 72px;
  width: auto;
}

.hero .logo-placeholder {
  display: inline-block;
  background: var(--navy);
  color: var(--white);
  font-weight: 800;
  font-size: 22px;
  letter-spacing: -0.5px;
  padding: 14px 28px;
}

.hero h1 {
  font-size: clamp(36px, 6vw, 72px);
  font-weight: 800;
  color: var(--navy);
  line-height: 1.1;
  max-width: 760px;
  margin-bottom: 20px;
}

.hero p {
  font-size: clamp(16px, 2vw, 20px);
  color: var(--navy);
  opacity: 0.7;
  max-width: 520px;
  margin-bottom: 16px;
}

.urgency-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--salmon);
  color: var(--white);
  font-weight: 700;
  font-size: 14px;
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  margin-bottom: 40px;
  letter-spacing: 0.3px;
}

.btn-primary {
  background: var(--navy);
  color: var(--white);
  font-family: inherit;
  font-weight: 600;
  font-size: 16px;
  padding: 14px 32px;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s;
}

.btn-primary:hover { background: var(--salmon); }

.btn-outline {
  background: transparent;
  color: var(--navy);
  font-family: inherit;
  font-weight: 600;
  font-size: 16px;
  padding: 13px 32px;
  border: 1.5px solid var(--navy);
  border-radius: var(--radius-sm);
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: all 0.2s;
}

.btn-outline:hover { background: var(--navy); color: var(--white); }

.hero-ctas { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }

/* ── SECCIÓN GENÉRICA ── */
.section {
  padding: 80px 24px;
  max-width: 1100px;
  margin: 0 auto;
}

.section-inner {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 48px;
  align-items: start;
}

.section-num {
  font-size: 13px;
  color: var(--gray);
  font-weight: 400;
  padding-top: 8px;
}

.section h2 {
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
}

.section p {
  color: var(--gray);
  font-size: 17px;
  max-width: 600px;
}

/* ── CARDS BENEFICIOS ── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  margin-top: 48px;
}

.card {
  background: var(--white);
  padding: 32px 28px;
  border-radius: var(--radius);
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.card-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--salmon);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 10px;
}

.card p { font-size: 15px; color: var(--gray); }

/* ── TIMELINE ── */
.timeline {
  display: flex;
  gap: 0;
  margin-top: 48px;
  overflow-x: auto;
  padding-bottom: 16px;
}

.timeline-step {
  flex: 1;
  min-width: 180px;
  padding: 24px 20px;
  border-top: 3px solid var(--gray-light);
  position: relative;
}

.timeline-step.active { border-top-color: var(--navy); }

.timeline-step .step-num {
  font-size: 12px;
  font-weight: 700;
  color: var(--gray);
  margin-bottom: 8px;
}

.timeline-step.active .step-num { color: var(--navy); }

.timeline-step h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
}

.timeline-step p { font-size: 14px; color: var(--gray); }

/* ── SPLIT SECTION ── */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 480px;
}

.split-left {
  background: radial-gradient(ellipse at 30% 60%, var(--blue-soft), var(--salmon-soft));
  padding: 64px 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.split-right {
  background: var(--white);
  padding: 64px 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.split h2 {
  font-size: clamp(28px, 3vw, 42px);
  font-weight: 800;
  margin-bottom: 16px;
}

.split p { color: var(--gray); font-size: 17px; }

/* ── ALIADOS ── */
.aliados {
  background: var(--white);
  padding: 60px 24px;
  text-align: center;
}

.aliados h3 {
  font-size: 13px;
  font-weight: 700;
  color: var(--gray);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 40px;
}

.aliados-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  max-width: 800px;
  margin: 0 auto;
}

.aliados-logos {
  display: flex;
  flex-wrap: wrap;
  gap: 32px 48px;
  justify-content: center;
  align-items: center;
  max-width: 900px;
  margin: 0 auto;
}

.aliados-logos img {
  height: 48px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
  filter: grayscale(20%);
  opacity: 0.85;
  transition: opacity 0.2s, filter 0.2s;
}

.aliados-logos img:hover {
  opacity: 1;
  filter: grayscale(0%);
}

.aliado-badge {
  background: var(--bg);
  color: var(--navy);
  font-weight: 600;
  font-size: 14px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.3px;
}

/* ── FORMULARIO ── */
.form-section {
  background: var(--white);
  padding: 80px 24px;
}

.form-wrap {
  max-width: 680px;
  margin: 0 auto;
}

.form-header {
  margin-bottom: 48px;
}

.form-header .section-num { font-size: 13px; color: var(--gray); margin-bottom: 12px; }

.form-header h2 {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  margin-bottom: 12px;
}

.form-header p { color: var(--gray); font-size: 17px; }

/* Pasos del formulario */
.steps-indicator {
  display: flex;
  gap: 0;
  margin-bottom: 48px;
}

.step-tab {
  flex: 1;
  padding: 14px 16px;
  border-bottom: 3px solid var(--gray-light);
  font-size: 14px;
  font-weight: 600;
  color: var(--gray);
  text-align: center;
  cursor: default;
}

.step-tab.active {
  border-bottom-color: var(--navy);
  color: var(--navy);
}

.step-tab.done {
  border-bottom-color: var(--green);
  color: var(--green);
}

/* Inputs */
.field {
  margin-bottom: 24px;
}

.field label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 8px;
  letter-spacing: 0.2px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 13px 16px;
  border: 1.5px solid var(--gray-light);
  border-radius: var(--radius-sm);
  background: var(--bg);
  font-family: inherit;
  font-size: 15px;
  color: var(--navy);
  outline: none;
  transition: border-color 0.2s;
  appearance: none;
}

.field input:focus,
.field select:focus {
  border-color: var(--navy);
  background: var(--white);
}

.field input.error,
.field select.error {
  border-color: var(--red);
}

.field .hint {
  font-size: 12px;
  color: var(--gray);
  margin-top: 6px;
}

.field .error-msg {
  font-size: 12px;
  color: var(--red);
  margin-top: 6px;
  display: none;
}

.field .error-msg.show { display: block; }

/* WhatsApp prefix */
.phone-wrap { display: flex; }
.phone-prefix {
  background: var(--gray-light);
  border: 1.5px solid var(--gray-light);
  border-right: none;
  padding: 13px 14px;
  font-size: 15px;
  font-weight: 600;
  color: var(--navy);
  white-space: nowrap;
}
.phone-wrap input { border-left: none; }

/* Upload */
.upload-area {
  border: 2px dashed var(--gray-light);
  border-radius: var(--radius);
  padding: 28px;
  text-align: center;
  cursor: pointer;
  background: var(--bg);
  transition: border-color 0.2s;
  position: relative;
}
.upload-area:hover { border-color: var(--navy); }
.upload-area input[type="file"] {
  position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%;
}
.upload-area .upload-icon { font-size: 24px; margin-bottom: 8px; color: var(--gray); }
.upload-area p { font-size: 14px; color: var(--gray); margin: 0; }
.upload-area .upload-name { font-size: 13px; font-weight: 600; color: var(--green); margin-top: 6px; }

.upload-progress {
  height: 4px;
  background: var(--gray-light);
  margin-top: 10px;
  display: none;
}
.upload-progress-bar {
  height: 100%;
  background: var(--navy);
  transition: width 0.3s;
  width: 0%;
}

/* Min empleados warning */
.warning-box {
  background: #FEF3C7;
  border-left: 4px solid #F59E0B;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 14px 18px;
  font-size: 14px;
  color: #92400E;
  margin-top: 8px;
  display: none;
}
.warning-box.show { display: block; }

/* Aviso legal */
.aviso-legal {
  background: var(--bg);
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 32px 0;
  font-size: 14px;
  color: var(--navy);
  line-height: 1.6;
}

.aviso-legal strong { display: block; margin-bottom: 6px; font-size: 13px; letter-spacing: 1px; text-transform: uppercase; }

/* Botón submit */
.btn-submit {
  width: 100%;
  background: var(--navy);
  color: var(--white);
  font-family: inherit;
  font-weight: 700;
  font-size: 17px;
  padding: 18px;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.btn-submit:hover:not(:disabled) { background: var(--salmon); }
.btn-submit:disabled { opacity: 0.6; cursor: not-allowed; }

.btn-back {
  background: transparent;
  border: 1.5px solid var(--navy);
  border-radius: var(--radius-sm);
  color: var(--navy);
  font-family: inherit;
  font-weight: 600;
  font-size: 15px;
  padding: 12px 24px;
  cursor: pointer;
  margin-bottom: 16px;
  transition: all 0.2s;
}
.btn-back:hover { background: var(--navy); color: var(--white); }

/* Spinner */
.spinner {
  width: 20px; height: 20px;
  border: 2.5px solid rgba(255,255,255,0.4);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: none;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Éxito */
.success-panel {
  text-align: center;
  padding: 60px 24px;
  display: none;
}
.success-panel .check { font-size: 56px; margin-bottom: 20px; color: var(--green); }
.success-panel h2 { font-size: 32px; font-weight: 800; margin-bottom: 12px; }
.success-panel p { color: var(--gray); font-size: 17px; margin-bottom: 24px; }

.btn-resend {
  background: transparent;
  border: 1.5px solid var(--navy);
  color: var(--navy);
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 20px;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-resend:hover { background: var(--navy); color: var(--white); }

/* ── FOOTER ── */
footer {
  background: var(--navy);
  color: rgba(255,255,255,0.6);
  padding: 48px 24px;
  text-align: center;
  font-size: 14px;
}
footer .footer-logo { font-weight: 800; color: var(--white); font-size: 18px; margin-bottom: 12px; }
footer a { color: var(--salmon); text-decoration: none; }

/* ── ADMIN ── */
.admin-header {
  background: var(--navy);
  color: var(--white);
  padding: 20px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.admin-header h1 { font-size: 20px; font-weight: 800; }
.admin-header span { font-size: 14px; opacity: 0.7; }

.stats-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  background: var(--white);
  border-bottom: 1px solid var(--gray-light);
}

.stat-card {
  padding: 24px 32px;
  border-right: 1px solid var(--gray-light);
}
.stat-card:last-child { border-right: none; }
.stat-card .num { font-size: 36px; font-weight: 800; color: var(--navy); }
.stat-card .label { font-size: 13px; color: var(--gray); font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }

.admin-controls {
  padding: 20px 32px;
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  background: var(--bg);
  border-bottom: 1px solid var(--gray-light);
}

.filter-btn {
  background: var(--white);
  border: 1.5px solid var(--gray-light);
  color: var(--navy);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 18px;
  cursor: pointer;
  transition: all 0.2s;
}
.filter-btn.active, .filter-btn:hover { background: var(--navy); color: var(--white); border-color: var(--navy); }

.search-input {
  flex: 1;
  min-width: 200px;
  padding: 9px 14px;
  border: 1.5px solid var(--gray-light);
  font-family: inherit;
  font-size: 14px;
  outline: none;
  background: var(--white);
}
.search-input:focus { border-color: var(--navy); }

/* Tabla admin */
.table-wrap { overflow-x: auto; padding: 24px 32px; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th {
  text-align: left;
  padding: 10px 14px;
  font-size: 12px;
  font-weight: 700;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 2px solid var(--gray-light);
}

td {
  padding: 14px 14px;
  border-bottom: 1px solid var(--gray-light);
  vertical-align: middle;
}

tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--bg); }

.badge {
  display: inline-block;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 700;
  border-radius: var(--radius-sm);
}
.badge-pendiente { background: #FEF3C7; color: #92400E; }
.badge-aceptada { background: #D1FAE5; color: #065F46; }
.badge-rechazada { background: #FEE2E2; color: #991B1B; }

.action-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.btn-accept { background: var(--green); color: white; border: none; padding: 6px 12px; font-family: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.btn-reject { background: var(--red); color: white; border: none; padding: 6px 12px; font-family: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.btn-docs { background: var(--navy); color: white; border: none; padding: 6px 12px; font-family: inherit; font-size: 12px; font-weight: 700; cursor: pointer; text-decoration: none; display: inline-block; }
.btn-accept:hover { opacity: 0.85; }
.btn-reject:hover { opacity: 0.85; }

/* Modal rechazo */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.5);
  display: none; align-items: center; justify-content: center;
  z-index: 1000;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--white);
  padding: 40px;
  max-width: 500px;
  width: 90%;
  border-radius: var(--radius-lg);
}
.modal h3 { font-size: 22px; font-weight: 800; margin-bottom: 20px; }
.modal textarea {
  width: 100%; height: 120px; padding: 12px; border: 1.5px solid var(--gray-light);
  font-family: inherit; font-size: 14px; resize: vertical; outline: none;
  margin-bottom: 16px;
}
.modal textarea:focus { border-color: var(--navy); }
.modal-btns { display: flex; gap: 12px; }

/* Login admin */
.login-wrap {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg);
}
.login-box {
  background: var(--white);
  padding: 56px 48px;
  width: 100%;
  max-width: 440px;
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
}
.login-box h2 { font-size: 28px; font-weight: 800; margin-bottom: 8px; }
.login-box p { color: var(--gray); font-size: 15px; margin-bottom: 32px; }

/* Confirmar page */
.confirm-wrap {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(ellipse at 30% 50%, var(--blue-soft) 0%, var(--salmon-soft) 100%);
  padding: 40px 24px;
}
.confirm-box {
  background: var(--white);
  padding: 64px 48px;
  max-width: 560px;
  width: 100%;
  text-align: center;
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 32px rgba(0,0,0,0.1);
}
.confirm-box .icon { font-size: 56px; margin-bottom: 24px; }
.confirm-box h1 { font-size: 32px; font-weight: 800; margin-bottom: 16px; }
.confirm-box p { color: var(--gray); font-size: 16px; margin-bottom: 12px; }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .section-inner { grid-template-columns: 1fr; gap: 16px; }
  .section-num { display: none; }
  .split { grid-template-columns: 1fr; }
  .split-left { padding: 48px 24px; }
  .split-right { padding: 48px 24px; }
  .stats-bar { grid-template-columns: repeat(2, 1fr); }
  .admin-controls { padding: 16px; }
  .table-wrap { padding: 16px; }
  .timeline { flex-direction: column; }
  .timeline-step { border-top: none; border-left: 3px solid var(--gray-light); padding-left: 20px; }
  .timeline-step.active { border-left-color: var(--navy); }
  .login-box { padding: 40px 28px; }
  .confirm-box { padding: 48px 28px; }
  .aliados-logos { gap: 20px 32px; }
  .aliados-logos img { height: 36px; max-width: 110px; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 32px; }
  .hero-ctas { flex-direction: column; align-items: stretch; }
  .btn-primary, .btn-outline { text-align: center; }
  .stat-card { padding: 16px 20px; }
  .stat-card .num { font-size: 28px; }
  .aliados-logos { gap: 16px 24px; }
  .aliados-logos img { height: 28px; max-width: 90px; }
}
