/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Paleta Alarcos */
  --alarcos-gold:       #EBB06A;   /* oro del icono del logo */
  --alarcos-gold-dark:  #D49450;   /* oro oscurecido para hover */
  --alarcos-gold-light: #F5C88A;   /* oro claro */
  --alarcos-charcoal:   #3A3A3A;   /* carbón del texto ALARCOS */
  --alarcos-charcoal-2: #2A2A2A;   /* carbón más oscuro */
  --alarcos-gray:       #9A9A9A;   /* gris GESTIÓN INMOBILIARIA */
  --alarcos-gray-light: #C8C8C8;
  /* Generales */
  --bg:         #F5F4F2;           /* fondo ligeramente cálido */
  --white:      #FFFFFF;
  --text:       #2E2E2E;
  --text-muted: #6B6B6B;
  --border:     #E4E2DE;
  --success:    #4A8C6A;
  --error:      #C0392B;
  --radius-sm:  8px;
  --radius:     14px;
  --radius-lg:  20px;
  --shadow-sm:  0 1px 4px rgba(0,0,0,0.07);
  --shadow:     0 4px 20px rgba(0,0,0,0.09);
  --shadow-lg:  0 8px 40px rgba(0,0,0,0.13);
}

html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.6;
}

/* ===== UTILS ===== */
.hidden { display: none !important; }
.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.req { color: var(--error); }

/* ===== HEADER ===== */
.header {
  background: var(--alarcos-charcoal-2);
  padding: 12px 0;
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 16px rgba(0,0,0,0.22);
}
.header .container {
  display: flex; align-items: center;
  gap: 16px; justify-content: space-between;
}
.logo { display: flex; align-items: center; text-decoration: none; }
.logo-split { display: flex; flex-direction: column; align-items: center; gap: 1px; }
.header-logo-icono { height: 38px; width: auto; }
.header-logo-texto  { height: 26px; width: auto; }
.header-tagline {
  font-size: 0.78rem; color: rgba(255,255,255,0.5);
  font-weight: 400; letter-spacing: 0.3px;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 24px; border-radius: var(--radius-sm);
  font-size: 1rem; font-weight: 600; cursor: pointer;
  border: 2px solid transparent; transition: all 0.2s ease;
  text-decoration: none; font-family: 'Inter', sans-serif;
}
.btn-primary {
  background: var(--alarcos-gold);
  color: var(--alarcos-charcoal-2);
  border-color: var(--alarcos-gold);
}
.btn-primary:hover {
  background: var(--alarcos-gold-dark);
  border-color: var(--alarcos-gold-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}
.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border-color: var(--border);
}
.btn-ghost:hover { background: var(--white); color: var(--text); }
.btn-hero { padding: 16px 32px; font-size: 1.05rem; border-radius: var(--radius-sm); }

/* ===== HERO ===== */
.hero {
  background: #FFFFFF;
  border-bottom: 1px solid var(--border);
  padding: 72px 0 64px;
  overflow: hidden;
  position: relative;
}
.hero .container {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 48px; align-items: center;
}
.hero-badge {
  display: inline-block;
  background: #FBF5EC; color: var(--alarcos-gold-dark);
  border: 1px solid var(--alarcos-gold-light);
  padding: 6px 14px; border-radius: 100px;
  font-size: 0.82rem; font-weight: 600; margin-bottom: 20px;
}
.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: 3rem; font-weight: 700;
  color: var(--alarcos-charcoal); line-height: 1.15; margin-bottom: 20px;
}
.hero h1 .highlight { color: var(--alarcos-gold-dark); }
.hero-subtitle {
  font-size: 1.05rem; color: var(--text-muted);
  margin-bottom: 28px; max-width: 480px; line-height: 1.7;
}
.hero-features { display: flex; flex-direction: column; gap: 10px; margin-bottom: 36px; }
.feature-item {
  display: flex; align-items: center; gap: 10px;
  color: var(--text); font-size: 0.93rem;
}
.feature-dot {
  width: 8px; height: 8px;
  background: var(--alarcos-gold); border-radius: 50%; flex-shrink: 0;
}
.hero-note { font-size: 0.82rem; color: #B0A898; margin-top: 12px; }

/* Hero visual */
.hero-visual { display: flex; align-items: center; justify-content: center; }
.hero-card-float { display: flex; flex-direction: column; gap: 16px; }
.float-card {
  background: var(--white); border-radius: var(--radius);
  padding: 16px 20px; display: flex; align-items: center; gap: 14px;
  box-shadow: var(--shadow-lg); min-width: 280px;
  border-left: 3px solid var(--alarcos-gold);
  animation: float 3s ease-in-out infinite;
}
.card-2 { animation-delay: 1s; }
.card-3 { animation-delay: 2s; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.float-icon { font-size: 1.8rem; }
.float-card > div { flex: 1; }
.float-card strong { display: block; font-size: 0.88rem; color: var(--alarcos-charcoal); }
.float-card span { font-size: 0.76rem; color: var(--text-muted); }
.float-price { font-size: 1rem; font-weight: 700; color: var(--alarcos-gold-dark); white-space: nowrap; }

/* ===== VALORADOR ===== */
.valorador { padding: 48px 0 80px; }

/* Progress */
.progress-wrapper { margin-bottom: 40px; }
.progress-steps-row {
  display: flex; align-items: center; justify-content: center;
  gap: 0; margin-bottom: 12px;
}
.prog-step { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.prog-circle {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--border); color: var(--text-muted);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.9rem; transition: all 0.3s;
}
.prog-step span { font-size: 0.72rem; color: var(--text-muted); font-weight: 500; white-space: nowrap; }
.prog-step.active .prog-circle {
  background: var(--alarcos-charcoal); color: white;
  box-shadow: 0 0 0 4px rgba(58,58,58,0.12);
}
.prog-step.done .prog-circle { background: var(--alarcos-gold); color: var(--alarcos-charcoal-2); }
.prog-step.done span, .prog-step.active span { color: var(--text); }
.prog-line {
  flex: 1; height: 2px; background: var(--border);
  margin: 0 4px; margin-bottom: 22px; max-width: 80px; transition: background 0.3s;
}
.prog-line.done { background: var(--alarcos-gold); }
.progress-bar-track { height: 4px; background: var(--border); border-radius: 99px; overflow: hidden; }
.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--alarcos-charcoal), var(--alarcos-gold));
  border-radius: 99px; transition: width 0.4s ease;
}

/* Step card */
.step-card {
  background: var(--white); border-radius: var(--radius-lg);
  box-shadow: var(--shadow); padding: 40px;
  max-width: 680px; margin: 0 auto;
  animation: fadeUp 0.3s ease;
  border-top: 3px solid var(--alarcos-gold);
}
@keyframes fadeUp {
  from { opacity:0; transform:translateY(12px); }
  to   { opacity:1; transform:translateY(0); }
}
.step-card h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem; font-weight: 700;
  color: var(--alarcos-charcoal); margin-bottom: 8px;
}
.step-sub { color: var(--text-muted); margin-bottom: 28px; font-size: 0.93rem; }

/* Nav */
.step-nav { display: flex; gap: 12px; margin-top: 32px; }
.step-nav .btn-primary { flex: 1; justify-content: center; }

/* ===== TIPO GRID ===== */
.tipo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tipo-card {
  background: var(--white); border: 2px solid var(--border);
  border-radius: var(--radius); padding: 24px 16px;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  cursor: pointer; transition: all 0.2s; text-align: center;
}
.tipo-card:hover {
  border-color: var(--alarcos-gold);
  box-shadow: var(--shadow); transform: translateY(-2px);
}
.tipo-card.selected {
  border-color: var(--alarcos-charcoal);
  background: #FAF8F5;
  box-shadow: 0 0 0 3px rgba(58,58,58,0.08);
}
.tipo-emoji { font-size: 2.2rem; }
.tipo-card strong { font-size: 0.9rem; color: var(--text); font-weight: 600; }
.tipo-card span { font-size: 0.78rem; color: var(--text-muted); }

/* ===== FORMS ===== */
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block; font-weight: 500;
  font-size: 0.88rem; color: var(--alarcos-charcoal); margin-bottom: 6px;
}
.form-input, .form-select {
  width: 100%; padding: 12px 14px;
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  font-size: 1rem; font-family: 'Inter', sans-serif;
  color: var(--text); background: var(--white);
  outline: none; transition: border-color 0.2s; appearance: none;
}
.form-input:focus, .form-select:focus {
  border-color: var(--alarcos-gold);
  box-shadow: 0 0 0 3px rgba(235,176,106,0.15);
}
.form-input::placeholder { color: #C0BAB2; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field-hint { font-size: 0.78rem; color: var(--text-muted); margin-top: 4px; display: block; }
.form-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236B6B6B' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px;
}

/* Phone input */
.phone-wrapper {
  display: flex; align-items: center;
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  overflow: hidden; transition: border-color 0.2s;
}
.phone-wrapper:focus-within {
  border-color: var(--alarcos-gold);
  box-shadow: 0 0 0 3px rgba(235,176,106,0.15);
}
.phone-flag {
  padding: 12px 14px; background: #FAF8F5;
  font-size: 0.9rem; white-space: nowrap; color: var(--text-muted);
  border-right: 1.5px solid var(--border);
}
.phone-input { border: none !important; box-shadow: none !important; flex: 1; }

/* Radio cards */
.radio-stack { display: flex; flex-direction: column; gap: 10px; }
.radio-card {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 14px 16px; border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); cursor: pointer; transition: all 0.2s;
}
.radio-card:hover { border-color: var(--alarcos-gold); background: #FBF8F3; }
.radio-card input[type="radio"] { margin-top: 3px; accent-color: var(--alarcos-charcoal); width: 18px; height: 18px; flex-shrink: 0; }
.radio-card:has(input:checked) { border-color: var(--alarcos-charcoal); background: #FAF8F5; }
.radio-card:has(input:checked) .radio-body strong { color: var(--alarcos-charcoal); }
.radio-body strong { display: block; font-size: 0.9rem; color: var(--text); font-weight: 600; }
.radio-body span { font-size: 0.8rem; color: var(--text-muted); }

/* Checkbox cards */
.checkbox-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.checkbox-card {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); cursor: pointer; transition: all 0.2s;
}
.checkbox-card:hover { border-color: var(--alarcos-gold); }
.checkbox-card:has(input:checked) { border-color: var(--alarcos-charcoal); background: #FAF8F5; }
.checkbox-card input[type="checkbox"] { accent-color: var(--alarcos-charcoal); width: 18px; height: 18px; flex-shrink: 0; }
.checkbox-body strong { font-size: 0.85rem; color: var(--text); display: block; }
.checkbox-body span { font-size: 0.78rem; color: var(--text-muted); }
.privacy-check { display: flex; gap: 12px; padding: 14px 16px; }
.privacy-check .checkbox-body { font-size: 0.84rem; color: var(--text-muted); }
.link-inline { color: var(--alarcos-gold-dark); text-decoration: underline; }

/* Estado grid */
.estado-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-bottom: 8px; }
.estado-btn {
  background: var(--white); border: 2px solid var(--border);
  border-radius: var(--radius-sm); padding: 14px 8px;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  cursor: pointer; transition: all 0.2s; text-align: center;
}
.estado-btn:hover { border-color: var(--alarcos-gold); background: #FBF8F3; }
.estado-btn.selected { border-color: var(--alarcos-charcoal); background: #FAF8F5; }
.estado-btn span { font-size: 1.5rem; }
.estado-btn strong { font-size: 0.78rem; color: var(--text); line-height: 1.3; }
.estado-btn small { font-size: 0.7rem; color: var(--text-muted); line-height: 1.3; }

/* Contact step */
.contact-intro { text-align: center; margin-bottom: 32px; }
.contact-badge {
  display: inline-block;
  background: #F0F9F4; color: var(--success);
  border: 1px solid #A8D5BC;
  padding: 8px 18px; border-radius: 100px;
  font-weight: 600; font-size: 0.9rem; margin-bottom: 16px;
}

/* Error */
.error-box {
  background: #FDF0EF; border: 1px solid var(--error);
  color: var(--error); border-radius: var(--radius-sm);
  padding: 12px 16px; font-size: 0.9rem; margin-top: 12px;
}

/* ===== ZONA DINÁMICA ===== */
.field-optional { font-size: 0.78rem; color: var(--text-muted); font-weight: 400; }
.zona-pending-hint {
  background: #FAF8F5; border: 1.5px dashed var(--border);
  border-radius: var(--radius-sm); padding: 14px 18px;
  color: var(--text-muted); font-size: 0.9rem; text-align: center;
  margin-bottom: 20px;
}
.zona-badge {
  margin-top: 8px; display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px; border-radius: 100px; font-size: 0.8rem; font-weight: 600;
}
.zona-badge.premium  { background: #FBF5EC; color: var(--alarcos-gold-dark); border: 1px solid var(--alarcos-gold-light); }
.zona-badge.estandar { background: #F5F4F2; color: var(--alarcos-charcoal); border: 1px solid var(--alarcos-gray-light); }
.zona-badge.economico{ background: #F2F2F2; color: #666; border: 1px solid #DDD; }

/* Calle opcional */
.calle-row { display: grid; grid-template-columns: 1fr 80px; gap: 10px; }
.calle-main { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.calle-combobox { position: relative; }
.calle-autocomplete { cursor: text; }
.calle-suggestions {
  position: absolute;
  z-index: 30;
  top: calc(100% - 1px);
  left: 0;
  right: 0;
  max-height: 230px;
  overflow-y: auto;
  background: var(--white);
  border: 1.5px solid var(--alarcos-gold);
  border-top-color: var(--border);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  box-shadow: var(--shadow-lg);
  padding: 6px;
}
.calle-option {
  display: block;
  width: 100%;
  border: none;
  background: transparent;
  text-align: left;
  font-family: 'Inter', sans-serif;
  padding: 10px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.95rem;
  color: var(--text);
}
.calle-option:hover,
.calle-option.active {
  background: #FAF8F5;
  color: var(--alarcos-charcoal);
}
.calle-option-empty {
  padding: 10px 12px;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.calle-numero { text-align: center; }
.calle-aviso {
  display: flex; align-items: flex-start; gap: 8px;
  margin-top: 10px; padding: 10px 14px;
  background: #FBF5EC; border: 1px solid var(--alarcos-gold-light);
  border-radius: var(--radius-sm); font-size: 0.82rem;
  color: #7A5C2A; line-height: 1.5;
}
.calle-aviso-icon { flex-shrink: 0; font-size: 1rem; }
.calle-zona-aviso {
  display: flex; align-items: flex-start; gap: 8px;
  margin-top: 8px; padding: 10px 14px;
  background: #FFF8EC; border: 1px solid #E8A020;
  border-radius: var(--radius-sm); font-size: 0.82rem;
  color: #7A4F00; line-height: 1.5;
}

/* ===== RESULTADO ===== */
.loading-state {
  display: flex; flex-direction: column; align-items: center;
  gap: 20px; padding: 48px 0; color: var(--text-muted);
}
.spinner {
  width: 48px; height: 48px;
  border: 4px solid var(--border);
  border-top-color: var(--alarcos-gold);
  border-radius: 50%; animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.result-header { text-align: center; margin-bottom: 28px; }
.result-label {
  font-size: 0.8rem; text-transform: uppercase;
  letter-spacing: 1.5px; color: var(--alarcos-gray); margin-bottom: 6px;
}
.result-desc { font-size: 0.95rem; color: var(--text-muted); }
.result-address { font-size: 0.88rem; color: var(--alarcos-gold); margin-top: 5px; font-weight: 500; }

.price-main-card {
  background: linear-gradient(135deg, var(--alarcos-charcoal) 0%, var(--alarcos-charcoal-2) 100%);
  border-radius: var(--radius); padding: 32px; text-align: center;
  margin-bottom: 20px; color: white; position: relative; overflow: hidden;
}
.price-main-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--alarcos-gold-light), var(--alarcos-gold), var(--alarcos-gold-light));
}
.price-label {
  font-size: 0.8rem; opacity: 0.65; margin-bottom: 12px;
  text-transform: uppercase; letter-spacing: 1.5px;
}
.price-range-row {
  display: flex; align-items: center; justify-content: center;
  gap: 12px; margin-bottom: 12px;
}
.price-min, .price-max { font-size: 2.2rem; font-weight: 800; font-family: 'Playfair Display', serif; }
.price-dash { font-size: 1.5rem; opacity: 0.4; }
.price-center-row { font-size: 1rem; opacity: 0.8; }
.price-center-row strong { color: var(--alarcos-gold-light); }

.result-meta-row { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 20px; }
.meta-pill {
  display: flex; align-items: center; gap: 8px;
  background: var(--white); border: 1px solid var(--border);
  border-radius: 100px; padding: 8px 14px; font-size: 0.85rem; color: var(--text);
}

.expert-call-card {
  display: flex; align-items: flex-start; gap: 16px;
  background: #FBF5EC; border: 1px solid var(--alarcos-gold-light);
  border-radius: var(--radius); padding: 20px 24px; margin-bottom: 20px;
}
.expert-icon { font-size: 2rem; flex-shrink: 0; }
.expert-call-card strong { display: block; font-size: 1rem; color: var(--alarcos-charcoal); margin-bottom: 4px; }
.expert-call-card p { font-size: 0.9rem; color: var(--text-muted); }

.disclaimer {
  font-size: 0.78rem; color: #B0A898; line-height: 1.6; margin-bottom: 24px;
  padding: 12px; background: #FAF8F5; border-radius: var(--radius-sm);
}
.result-actions { display: flex; justify-content: center; }

/* ===== FOOTER ===== */
.footer {
  background: var(--alarcos-charcoal-2);
  color: rgba(255,255,255,0.65);
  padding: 48px 0 32px; text-align: center;
}
.footer-logo {
  height: 56px; width: auto; margin-bottom: 16px;
  filter: brightness(0) invert(1); opacity: 0.9;
}
.footer-nombre {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem; color: rgba(255,255,255,0.9);
  letter-spacing: 0.5px; margin-bottom: 10px;
}
.footer-contacto {
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 6px;
  font-size: 0.85rem; margin-bottom: 14px;
}
.footer-sep { color: rgba(255,255,255,0.3); }
.footer-links { margin: 10px 0 6px; font-size: 0.82rem; }
.footer-small { font-size: 0.75rem; opacity: 0.4; margin-top: 4px; }
.link-footer { color: rgba(255,255,255,0.55); text-decoration: underline; }
.link-footer:hover { color: var(--alarcos-gold-light); }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .hero h1 { font-size: 2.2rem; }
  .estado-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-contacto { flex-direction: column; gap: 4px; }
  .footer-sep { display: none; }
}

@media (max-width: 600px) {
  .step-card { padding: 24px 18px; }
  .tipo-grid { grid-template-columns: repeat(2, 1fr); }
  .form-row { grid-template-columns: 1fr; }
  .estado-grid { grid-template-columns: repeat(2, 1fr); }
  .checkbox-grid { grid-template-columns: 1fr; }
  .prog-step span { display: none; }
  .prog-line { max-width: 40px; }
  .price-min, .price-max { font-size: 1.6rem; }
  .result-meta-row { flex-direction: column; }
  .hero h1 { font-size: 1.9rem; }
  .header-tagline { display: none; }
  .calle-row { grid-template-columns: 1fr; }
}

/* Mensaje de confirmación de envío */
.lead-confirmacion {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 14px 18px;
  background: #f0fdf4;
  border: 1px solid #86efac;
  border-radius: 10px;
  color: #166534;
  font-size: 0.95rem;
  font-weight: 500;
}
.lead-confirmacion-icon { font-size: 1.2rem; }
