/* Formulario transversal: superficie neutra y acento del recorrido anfitrión. */
.interes-drawer {
  --interes-soft: var(--ui-accent-soft, var(--pos-100, #bee7cf));
  --interes-error: var(--rose-700, #a31545);
  --interes-primary: var(--pos-700, #1b7a43);
  --interes-on-primary: #fff;
  position: fixed; inset: 0 0 0 auto; margin: 0; padding: 0;
  width: min(560px, 100vw); max-width: 100vw;
  height: 100vh; height: 100dvh; max-height: 100vh; max-height: 100dvh;
  border: 1px solid var(--ui-border); border-radius: 20px 0 0 20px;
  background: var(--ui-surface-1); color: var(--ui-text);
  box-shadow: var(--ui-shadow-modal); overflow: hidden;
  font: 400 1rem/1.55 var(--font-body, var(--font-ui, "Rubik", Arial, sans-serif));
}
.interes-drawer[open] { display: grid; grid-template-rows: auto minmax(0, 1fr); animation: interes-enter .3s cubic-bezier(.2,.75,.2,1); }
.interes-drawer:not([open]), .interes-drawer [hidden] { display: none !important; }
.interes-drawer::backdrop { background: rgb(6 6 6 / .55); backdrop-filter: blur(3px); }
.interes-drawer *, .interes-drawer *::before, .interes-drawer *::after { box-sizing: border-box; }
body.interes-open { overflow: hidden; }
.interes-drawer :focus-visible, .interes-trigger:focus-visible { outline: 3px solid var(--ui-focus, var(--pos-700)); outline-offset: 3px; }
.interes-drawer h2, .interes-drawer p, .interes-drawer fieldset { margin: 0; }
.interes-drawer a { color: var(--ui-accent-strong); text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }
.interes-header { display: flex; align-items: start; gap: 16px; padding: 26px 28px; background: var(--interes-soft); color: var(--pos-900); }
.interes-header > div { min-width: 0; flex: 1; }
.interes-header .interes-eyebrow { margin: 0 0 12px; font: 500 .7rem/1.5 var(--font-code); letter-spacing: .07em; text-transform: uppercase; }
.interes-header h2 { color: inherit; font: 700 clamp(1.5rem, 3vw, 2rem)/1.18 var(--font-display); letter-spacing: -.04em; }
.interes-drawer .interes-close { display: grid; place-items: center; flex: 0 0 44px; width: 44px; height: 44px; padding: 0; border: 1px solid currentColor; border-radius: 12px; color: inherit; background: transparent; cursor: pointer; }
.interes-close svg { width: 20px; height: 20px; }
#interes-form { min-height: 0; display: grid; grid-template-rows: minmax(0, 1fr) auto; }
.interes-body { min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 28px; scroll-padding: 20px; }
.interes-drawer .interes-intro { margin-bottom: 12px; color: var(--ui-text); }
.interes-drawer .interes-hint { color: var(--ui-muted); font-size: .85rem; line-height: 1.55; }
.interes-drawer .interes-notice { margin: 22px 0; padding: 14px 16px; border: 1px solid var(--ui-border); border-left: 3px solid var(--ui-accent); border-radius: 12px; background: var(--ui-surface-2); font-size: .9rem; }
.interes-notice strong { display: block; margin-bottom: 4px; color: var(--ui-accent-strong); font-weight: 560; }
.interes-notice p { color: var(--ui-text); }
.interes-drawer .interes-section { min-width: 0; padding: 26px 0 8px; border: 0; border-top: 1px solid var(--ui-border); margin-top: 30px; }
.interes-section > legend { float: left; width: 100%; margin: 0 0 22px; padding: 0; color: var(--ui-text); font: 650 1.1rem/1.45 var(--font-display); }
.interes-section > legend + * { clear: both; }
.interes-section > legend span { display: inline-block; margin-right: 12px; color: var(--ui-accent-strong); font: 500 .75rem/1.5 var(--font-code); }
.interes-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 16px; }
.interes-full { grid-column: 1 / -1; }
.interes-drawer .interes-field { min-width: 0; margin-bottom: 20px; }
.interes-field > label, .interes-choice-field > legend { display: block; margin: 0 0 8px; padding: 0; color: var(--ui-text); font-size: .85rem; line-height: 1.5; font-weight: 500; }
.interes-drawer input:not([type="radio"]):not([type="checkbox"]):not([type="hidden"]), .interes-drawer select {
  display: block; width: 100%; min-width: 0; min-height: 48px; margin: 0; padding: 11px 12px;
  border: 1px solid var(--ui-border-strong); border-radius: 12px;
  background: var(--ui-surface-1); color: var(--ui-text); font: inherit; font-size: 1rem;
}
.interes-drawer select { padding-right: 26px; }
.interes-drawer input::placeholder { color: var(--ui-muted); opacity: 1; }
.interes-field > .interes-hint { margin-top: 8px; }
.interes-drawer .interes-choice-field { min-width: 0; padding: 0; border: 0; margin: 18px 0 22px; }
.interes-choices { display: flex; flex-wrap: wrap; gap: 12px; }
.interes-choices label { display: flex; align-items: center; gap: 10px; min-width: 88px; min-height: 44px; padding: 8px 14px; border: 1px solid var(--ui-border-strong); border-radius: 12px; cursor: pointer; font-size: .9rem; }
.interes-choices label:has(input:checked) { border-color: var(--ui-accent); background: var(--interes-soft); }
.interes-drawer input[type="radio"], .interes-drawer input[type="checkbox"] { flex: 0 0 18px; width: 18px; height: 18px; margin: 0; accent-color: var(--ui-accent-strong); }
.interes-drawer .interes-guardian { min-width: 0; padding: 18px; border: 1px solid var(--ui-border); border-radius: 12px; background: var(--ui-surface-2); }
.interes-guardian > legend { padding: 0 8px; color: var(--ui-text); font-weight: 500; }
.interes-guardian > .interes-hint { margin-bottom: 20px; }
.interes-guardian .interes-grid { display: block; }
.interes-guardian .interes-field:last-child { margin-bottom: 0; }
.interes-terms { display: flex; align-items: start; gap: 12px; min-height: 44px; margin-top: 24px; }
.interes-terms input { margin-top: 5px !important; }
.interes-terms label { color: var(--ui-text); font-size: .9rem; line-height: 1.65; cursor: pointer; }
.interes-drawer .interes-error { color: var(--interes-error); margin-top: 8px; font-size: .85rem; }
.interes-drawer [aria-invalid="true"] { border-color: var(--interes-error) !important; }
.interes-drawer .interes-success { border-left-color: var(--interes-primary); }
.interes-success strong { color: var(--interes-primary); }
/* El iframe solo transporta el envio a Salesforce; nunca se muestra. */
iframe[name="interes-salesforce"] { display: none; }
.interes-drawer .interes-error-summary { border-left-color: var(--interes-error); }
.interes-error-summary strong, .interes-error-summary a { color: var(--interes-error); }
.interes-error-summary ul { margin: 8px 0 0; padding-left: 20px; }
.interes-error-summary a { display: inline-flex; align-items: center; min-height: 44px; }
.interes-program-options { max-height: 244px; overflow-y: auto; overscroll-behavior: contain; margin: 8px 0; border: 1px solid var(--ui-border-strong); border-radius: 12px; background: var(--ui-surface-1); }
.interes-program-options [role="option"] { min-height: 52px; padding: 12px; border-bottom: 1px solid var(--ui-border); color: var(--ui-text); cursor: pointer; }
.interes-program-options [role="option"]:last-child { border-bottom: 0; }
.interes-program-options [role="option"] strong { display: block; font-size: .9rem; font-weight: 500; }
.interes-program-options [role="option"] span { display: block; margin-top: 4px; color: var(--ui-muted); font: 400 .75rem/1.5 var(--font-code); }
.interes-program-options [role="option"][aria-selected="true"], .interes-program-options [role="option"]:hover { background: var(--interes-soft); box-shadow: inset 3px 0 var(--ui-accent); }
.interes-footer { padding: 16px 28px max(16px, env(safe-area-inset-bottom)); border-top: 1px solid var(--ui-border); background: var(--ui-surface-1); }
.interes-footer-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; }
.interes-footer button { min-height: 44px; padding: 12px 16px; border: 1px solid var(--ui-border-strong); border-radius: 12px; font: 560 .8rem/1.4 var(--font-body, var(--font-ui, "Rubik", Arial, sans-serif)); cursor: pointer; }
.interes-footer .interes-secondary { color: var(--ui-text); background: var(--ui-surface-1); }
.interes-footer .interes-submit { color: var(--interes-on-primary); background: var(--interes-primary); border-color: var(--interes-primary); }
.interes-footer .interes-submit:disabled { color: var(--ui-muted); background: var(--ui-surface-3); border-color: var(--ui-border); cursor: not-allowed; }
.interes-floating-actions { position: fixed; right: 18px; bottom: 18px; z-index: 90; display: grid; gap: 8px; justify-items: end; }
.floating-actions { justify-items: end; }
.floating-actions:not(.visible), .interes-floating-actions:not(.visible) { visibility: hidden; }
.floating-actions .interes-trigger, .interes-floating-actions .interes-trigger {
  width: auto; height: auto; min-height: 48px; display: flex; align-items: center; gap: 9px;
  padding: 12px 16px; border: 1px solid var(--ui-border-strong); border-radius: 12px;
  background: var(--ui-surface-1); color: var(--ui-accent-strong); box-shadow: var(--ui-shadow-soft);
  font: 560 .8rem/1.3 var(--font-body, var(--font-ui, "Rubik", Arial, sans-serif)); cursor: pointer;
}
.interes-trigger svg { flex: 0 0 20px; width: 20px; height: 20px; }
.interes-trigger:hover { border-color: var(--ui-accent); }
.interes-program-apply { width: 48px; height: 48px; display: grid; place-items: center; border: 1px solid var(--ui-accent); border-radius: 50%; background: var(--ui-accent); color: var(--ui-on-accent, #fff); box-shadow: var(--ui-shadow-soft); }
.interes-program-apply svg { width: 20px; height: 20px; }
.interes-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
[data-theme="dark"] .interes-drawer { --interes-soft: var(--ui-accent-soft, #123322); --interes-error: var(--rose-300, #f06292); --interes-primary: var(--pos-300, #68c690); --interes-on-primary: var(--pos-900, #0c341d); }
[data-theme="dark"] .interes-header { color: var(--pos-200); }
[data-theme="dark"] .interes-program-apply { color: var(--pos-900); }
@keyframes interes-enter { from { transform: translateX(32px); opacity: .5; } to { transform: none; opacity: 1; } }
@media (max-width: 560px) {
  .interes-drawer { width: 100vw; border-radius: 0; }
  .interes-header { padding: max(18px, env(safe-area-inset-top)) 18px 20px; }
  .interes-body { padding: 22px 18px; }
  .interes-grid { grid-template-columns: minmax(0, 1fr); }
  .interes-footer { padding-inline: 18px; }
  .interes-footer-actions { gap: 8px; }
  .interes-footer button { padding-inline: 10px; }
  .interes-floating-actions { right: 8px; bottom: 10px; }
}
@media (max-height: 700px) {
  .floating-actions, .interes-floating-actions { display: flex; align-items: center; gap: 8px; }
  .interes-header { padding-block: 14px; }
  .interes-header .interes-eyebrow { margin-bottom: 6px; }
  .interes-header h2 { font-size: 1.5rem; }
  .interes-footer { padding-block: 10px; }
  .interes-footer .interes-hint { font-size: .75rem; }
}
@media (prefers-reduced-motion: reduce) { .interes-drawer[open] { animation: none; } }
@media print { .interes-drawer, .interes-floating-actions, .interes-trigger { display: none !important; } }
