/* ==========================================================================
   BIBLIOTECA PASTORAL — ENCUESTA MINISTERIAL (PALETA OFICIAL DEL ESCUDO / LOGO)
   Azul Marino (#13233a) • Oro Antiguo (#b89146) • Marfil Bíblico (#f6f3ec)
   ========================================================================== */

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

body.gf-body {
  margin: 0;
  padding: 0 0 64px 0;
  background-color: #f6f3ec;
  color: #182940;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 14.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

/* Barra superior institucional en Azul Marino del Escudo con filete Dorado */
.gf-topbar {
  background-color: #13233a;
  border-bottom: 2px solid #b89146;
  padding: 12px 16px;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 10px rgba(14, 27, 46, 0.14);
}

.gf-topbar-inner {
  max-width: 660px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.gf-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fbf9f5;
}

.gf-brand img { width: 30px; height: 30px; border-radius: 6px; border: 1px solid rgba(200, 157, 84, 0.45); }
.gf-brand-title { font-weight: 700; font-size: 14.5px; color: #fbf9f5; letter-spacing: -0.01em; }
.gf-brand-sub { font-size: 12px; color: #d8c398; margin-left: 6px; }

.gf-back-link {
  font-size: 13px;
  font-weight: 500;
  color: #f3e9d2;
  text-decoration: none;
  padding: 6px 12px;
  border: 1px solid rgba(200, 157, 84, 0.45);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.gf-back-link:hover { background-color: rgba(200, 157, 84, 0.18); color: #ffffff; border-color: #b89146; }

/* Contenedor central estilo formulario formal */
.gf-container {
  max-width: 660px;
  margin: 24px auto 0 auto;
  padding: 0 12px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Tarjeta base y encabezado con sello Azul Marino + Oro Antiguo */
.gf-card {
  background-color: #ffffff;
  border: 1px solid #dfd8c8;
  border-radius: 8px;
  padding: 24px 26px;
  box-shadow: 0 1px 3px rgba(14, 27, 46, 0.05);
}

.gf-header-card {
  border-top: 6px solid #13233a;
  box-shadow: inset 0 3px 0 0 #b89146, 0 1px 3px rgba(14, 27, 46, 0.05);
  padding-top: 22px;
}

.gf-kicker {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #8c6826;
  margin-bottom: 6px;
}

.gf-title {
  font-family: 'Lora', Georgia, serif;
  font-size: 23px;
  font-weight: 600;
  color: #0e1b2e;
  margin: 0 0 12px 0;
  line-height: 1.3;
}

.gf-description { font-size: 14px; color: #3e5066; margin: 0 0 14px 0; }

.gf-meta-note {
  font-size: 12.5px;
  color: #627286;
  padding-top: 12px;
  border-top: 1px solid #eae4d7;
  margin: 0;
}

/* Encabezado de cada sección */
.gf-section-header {
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 1px solid #eae4d7;
}

.gf-section-step {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #8c6826;
  display: block;
  margin-bottom: 2px;
}

.gf-section-title {
  font-family: 'Lora', Georgia, serif;
  font-size: 17.5px;
  font-weight: 600;
  color: #0e1b2e;
  margin: 0;
}

/* Bloques de pregunta individuales */
.gf-question { margin-bottom: 22px; }
.gf-question:last-child { margin-bottom: 0; }

.gf-label {
  display: block;
  font-size: 14.5px;
  font-weight: 600;
  color: #0e1b2e;
  margin-bottom: 8px;
}

.gf-label-optional { font-size: 12.5px; font-weight: 400; color: #627286; margin-left: 4px; }
.gf-helper { font-size: 12.5px; color: #627286; margin-top: 5px; }

/* Campos de texto, select y textarea */
.gf-input, .gf-select, .gf-textarea {
  width: 100%;
  padding: 10px 12px;
  font-size: 14px;
  font-family: inherit;
  color: #0e1b2e;
  background-color: #ffffff;
  border: 1px solid #cfc6b4;
  border-radius: 6px;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.gf-input:focus, .gf-select:focus, .gf-textarea:focus {
  border-color: #b89146;
  box-shadow: 0 0 0 2px rgba(184, 145, 70, 0.15);
}

.gf-input::placeholder, .gf-textarea::placeholder { color: #8c98a8; }

.gf-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 20px; }
.gf-phone-row { display: flex; gap: 10px; }
.gf-phone-row .gf-select { width: 190px; flex-shrink: 0; }

/* Listas verticales limpias de opciones (Radio / Checkbox) */
.gf-options-list { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }

.gf-option {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 7px 8px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  color: #182940;
  transition: background-color 0.12s ease;
}

.gf-option:hover { background-color: #fbf8f1; }

.gf-option input[type="radio"], .gf-option input[type="checkbox"] {
  accent-color: #13233a;
  width: 16px;
  height: 16px;
  margin-top: 3px;
  flex-shrink: 0;
  cursor: pointer;
}

/* Escala lineal formal (1 a 5 y 1 a 10) */
.gf-scale-wrapper { margin-top: 10px; }
.gf-scale-buttons { display: flex; gap: 8px; flex-wrap: wrap; }

.gf-scale-btn {
  flex: 1;
  min-width: 40px;
  height: 38px;
  border: 1px solid #cfc6b4;
  background-color: #ffffff;
  color: #182940;
  border-radius: 6px;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.gf-scale-btn:hover { background-color: #faf5ea; border-color: #b89146; }
.gf-scale-btn.active { background-color: #13233a; color: #fbf9f5; border-color: #b89146; }

.gf-scale-captions {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #627286;
  margin-top: 6px;
}

/* Barra inferior de acciones */
.gf-actions-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 6px;
}

.gf-submit-btn {
  background-color: #13233a;
  color: #fbf9f5;
  border: 1px solid #13233a;
  border-radius: 6px;
  padding: 11px 24px;
  font-size: 14.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.gf-submit-btn:hover { background-color: #0e1b2e; border-color: #b89146; }
.gf-submit-btn:disabled { opacity: 0.65; cursor: not-allowed; }

.gf-reset-btn {
  background: transparent;
  border: none;
  color: #627286;
  font-size: 13px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  padding: 8px 10px;
  border-radius: 6px;
}

.gf-reset-btn:hover { color: #0e1b2e; background-color: #eae4d7; }
.gf-footer-credit { text-align: center; font-size: 12px; color: #627286; margin-top: 18px; }

/* Modal sobrio de confirmación */
.gf-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background-color: rgba(14, 27, 46, 0.65);
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 16px;
}

.gf-modal-card {
  background-color: #ffffff;
  border: 1px solid #cfc6b4;
  border-top: 5px solid #13233a;
  box-shadow: inset 0 2px 0 0 #b89146, 0 12px 32px rgba(14, 27, 46, 0.22);
  border-radius: 8px;
  padding: 28px 26px;
  max-width: 460px;
  width: 100%;
}

.gf-modal-title {
  font-family: 'Lora', Georgia, serif;
  font-size: 20px;
  font-weight: 600;
  color: #0e1b2e;
  margin: 0 0 10px 0;
}

.gf-modal-text {
  font-size: 14px;
  color: #3e5066;
  margin: 0 0 20px 0;
  line-height: 1.55;
}

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

@media (max-width: 580px) {
  .gf-card { padding: 20px 18px; }
  .gf-row-2 { grid-template-columns: 1fr; gap: 14px; }
  .gf-phone-row { flex-direction: column; }
  .gf-phone-row .gf-select { width: 100%; }
  .gf-brand-sub { display: none; }
}
