body[data-purchaser-guide] {
  --purchaser-navy: #102e54;
  --purchaser-orange: #ff7214;
  --purchaser-line: #c1d7eb;
  --purchaser-guide-offset: 80px;
  --purchaser-float-width: 172px;
  --purchaser-float-height: 48px;
  --purchaser-float-right: 16px;
  --purchaser-float-bottom: calc(16px + env(safe-area-inset-bottom));
}

body[data-purchaser-guide] :is(#iris-open, #f9-interest-float, .guide-scroll-shortcut) {
  display: none !important;
}

body[data-purchaser-guide] main [id] {
  scroll-margin-top: calc(var(--purchaser-guide-offset) + 16px);
}

.purchaser-reader-bar {
  position: fixed;
  z-index: 35;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 9px 12px;
  background: var(--purchaser-navy);
  box-shadow: 0 3px 10px #102e5425;
}

.purchaser-reader-bar[hidden] { display: none; }

.purchaser-reader-bar :is(a, button) {
  display: grid;
  place-items: center;
  box-sizing: border-box;
  min-height: 42px;
  padding: 7px 14px;
  border: 1px solid #9eb8d0;
  border-radius: 6px;
  background: transparent;
  color: #fff;
  font: 700 .875rem/1.25 "DM Sans", sans-serif;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.purchaser-reader-bar :is(a, button):hover { background: #234970; }
.purchaser-reader-bar :is(a, button):focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.purchaser-reader-bar .purchaser-recommend { color: #ffdb72; border-color: #ffb15b; }
.purchaser-reader-bar:not([hidden]) .purchaser-recommend { animation: purchaser-border-pulse 1.35s ease-in-out 3; }

@keyframes purchaser-border-pulse {
  50% { border-color: #ff812a; box-shadow: 0 0 0 2px #ff812a; }
}

.purchaser-register-float {
  position: fixed;
  z-index: 40;
  bottom: calc(var(--purchaser-float-bottom) + var(--purchaser-float-height) + 10px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 8px 16px;
  border: 1px solid #ec630c;
  border-radius: 999px;
  background: var(--purchaser-orange);
  color: #0b203a;
  font: 800 .8125rem/1.25 "DM Sans", sans-serif;
  box-shadow: 0 5px 18px #102e5438;
  cursor: pointer;
}

body[data-purchaser-guide] > :is(.purchaser-register-float, .whatsapp-float) {
  box-sizing: border-box;
  right: var(--purchaser-float-right);
  width: var(--purchaser-float-width);
  height: var(--purchaser-float-height);
  min-height: var(--purchaser-float-height);
  z-index: 40;
}
html body[data-purchaser-guide] > a.whatsapp-float {
  /* Older content pages set these dimensions with important declarations. */
  width: var(--purchaser-float-width) !important;
  min-width: var(--purchaser-float-width) !important;
  max-width: var(--purchaser-float-width) !important;
  height: var(--purchaser-float-height) !important;
  min-height: var(--purchaser-float-height) !important;
  max-height: var(--purchaser-float-height) !important;
  right: var(--purchaser-float-right) !important;
  bottom: var(--purchaser-float-bottom) !important;
  justify-content: space-between;
  padding: 4px 6px 4px 14px;
}
body[data-purchaser-guide] > .whatsapp-float span { display: block; }
body[data-purchaser-guide] > .whatsapp-float .willy-portrait {
  box-sizing: border-box;
  width: 36px;
  height: 36px;
  flex-basis: 36px;
}

.purchaser-register-icon { font-size: 1.25rem; }
.purchaser-register-dialog {
  box-sizing: border-box;
  width: min(94vw, 610px);
  max-height: 86vh;
  padding: 0;
  border: 1px solid var(--purchaser-line);
  border-radius: 16px;
  color: var(--purchaser-navy);
  background: #f6faff;
  box-shadow: 0 20px 60px #0a234e55;
}
.purchaser-register-dialog::backdrop { background: #102e5480; }
.purchaser-register-dialog > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 15px 20px;
  background: var(--purchaser-navy);
  color: #fff;
}
.purchaser-register-dialog > header h2 { color: inherit; margin: 0; font-size: 1.38rem; }
.purchaser-register-dialog > header button {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 8px;
  background: var(--purchaser-orange);
  color: #102e54;
  font-size: 1.4rem;
  cursor: pointer;
}
.purchaser-register-body { padding: 4px 20px 20px; }
.purchaser-register-body .f9-interest { display: grid; gap: 13px; }
.purchaser-register-body label { font-weight: 650; }
.purchaser-register-body .f9-contact-fields { display: grid; gap: 10px; }
.purchaser-register-body :is(input:not([type=checkbox],[type=hidden],[hidden]), textarea) {
  box-sizing: border-box;
  display: block;
  width: 100%;
  min-height: 42px;
  margin-top: 4px;
  padding: 8px;
  border: 1px solid #a7c1d9;
  border-radius: 7px;
  background: #fff;
  color: var(--purchaser-navy);
  font: inherit;
}
.purchaser-register-body textarea { resize: vertical; }
.purchaser-register-body button[type=submit] {
  min-height: 44px;
  padding: 9px 14px;
  background: var(--purchaser-orange);
  color: #102e54;
  border: 1px solid #ec630c;
  border-radius: 8px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.purchaser-register-body [role=status]:empty { margin: 0; }
.purchaser-register-body .fg-location-options { min-inline-size: 0; padding: 8px 10px; }
.purchaser-register-body .fg-location-options > div { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,165px),1fr)); gap: 8px; }

.purchaser-country-card {
  display: grid;
  align-content: start;
  gap: 7px;
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--purchaser-line);
  border-top: 3px solid #0079a5;
  border-radius: 12px;
  background: #f3f8fd;
  color: var(--purchaser-navy);
  text-decoration: none;
}
.purchaser-country-card:hover { background: #e5f1ff; text-decoration: none; }
.purchaser-country-card > span { color: #006a91; font-size: .8rem; font-weight: 750; }
.purchaser-country-card strong { color: var(--purchaser-navy); font-size: 1.08rem; }
.purchaser-country-card small { color: #36516c; font-size: .92rem; line-height: 1.45; }

.purchaser-rule-list {
  margin: 14px 0;
  border: 1px solid var(--purchaser-line);
  border-radius: 12px;
  overflow: hidden;
}
.purchaser-rule-list > div {
  display: grid;
  grid-template-columns: minmax(10rem, 1fr) 2.5fr;
  gap: 12px;
  padding: 11px 14px;
  background: #fff;
}
.purchaser-rule-list > div:nth-child(even) { background: #ecf5fc; }
.purchaser-rule-list > div + div { border-top: 1px solid var(--purchaser-line); }
.purchaser-rule-list dt { color: var(--purchaser-navy); font-weight: 800; }
.purchaser-rule-list dd { margin: 0; color: #243e57; }

.purchaser-account-grid, .purchaser-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 14px 0 20px;
}
.purchaser-account-grid article, .purchaser-steps > li, .purchaser-equation {
  min-width: 0;
  padding: 15px;
  border: 1px solid var(--purchaser-line);
  border-radius: 10px;
  background: #eef6fe;
}
.purchaser-account-grid h3, .purchaser-account-grid p, .purchaser-steps p { margin: 4px 0 0; }
.purchaser-account-grid article:nth-child(2) { border-color: #edc38e; background: #fff3df; }
.purchaser-steps { list-style: none; padding: 0 !important; counter-reset: purchaser-step; }
.purchaser-steps > li { counter-increment: purchaser-step; margin: 0 !important; }
.purchaser-steps > li::before {
  content: counter(purchaser-step);
  display: inline-grid;
  place-items: center;
  width: 1.65rem;
  height: 1.65rem;
  margin-right: 8px;
  border-radius: 50%;
  color: #fff;
  background: var(--purchaser-navy);
  font-size: .8rem;
  font-weight: 800;
}
.purchaser-equation { margin: 18px 0; background: #fff; }
.purchaser-equation figcaption { font-weight: 800; margin-bottom: 12px; }
.purchaser-amounts { display: flex; align-items: center; gap: 6px; }
.purchaser-amounts div { flex: 1; padding: 8px 6px; background: #edf6fd; border-radius: 7px; text-align: center; }
.purchaser-amounts :is(small, strong) { display: block; }
.purchaser-equation p:last-child { margin-bottom: 0; }
.purchaser-document-list { margin: 0; padding-left: 1.1rem; }
.purchaser-document-list li + li { margin-top: 5px; }
.purchaser-faq { border-bottom: 1px solid var(--purchaser-line); padding: 10px 0; }
.purchaser-faq summary { cursor: pointer; font-weight: 750; }
.purchaser-faq p { margin-bottom: 2px; }
.purchaser-project-grid {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 14px;
  margin: 14px 0 20px;
}
.purchaser-project-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--purchaser-line);
  border-radius: 12px;
  background: #f3f8fd;
}
.purchaser-project-banner { display: block; }
.purchaser-project-banner img { display: block; width: 100%; height: auto; aspect-ratio: 16/9; object-fit: cover; }
.purchaser-project-details { padding: 12px 14px 14px; }
.purchaser-project-details h3 { margin: 0 0 5px; font-size: 1.12rem; }
.purchaser-project-details p { margin: 5px 0 0; }

@media (max-width: 650px) {
  body[data-purchaser-guide] {
    --purchaser-float-width: 48px;
    --purchaser-float-right: 12px;
    --purchaser-float-bottom: calc(12px + env(safe-area-inset-bottom));
  }
  .purchaser-reader-bar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; padding: 5px 10px; }
  .purchaser-reader-bar :is(a, button) { font-size: .75rem; padding: 5px; min-height: 34px; }
  .purchaser-register-float { padding: 0; }
  .purchaser-register-float > span:last-child { display: none; }
  html body[data-purchaser-guide] > a.whatsapp-float { justify-content: center; padding: 0; }
  body[data-purchaser-guide] > .whatsapp-float span { display: none; }
  .purchaser-rule-list > div { grid-template-columns: 1fr; gap: 2px; }
  .purchaser-account-grid, .purchaser-steps { grid-template-columns: 1fr; }
  .purchaser-amounts strong { font-size: .8rem; }
  .purchaser-project-grid { grid-template-columns: 1fr; }
  #currency table { table-layout: fixed; }
  #currency table :is(th,td) { padding: 6px 4px; font-size: .75rem; overflow-wrap: anywhere; }
  #currency table thead th:first-child { width: 18%; }
  #documents table :is(th,td) { overflow-wrap: anywhere; }
  body[data-purchaser-guide] .fg-main #buying-costs .purchaser-tax-table table { min-width: 0; }
  body[data-purchaser-guide] .fg-main #buying-costs .purchaser-tax-table :is(th,td) { padding: 7px 5px; font-size: .77rem; }
  body[data-purchaser-guide] .fg-main #mm2h-tiers .fg-table table { min-width: 0; table-layout: fixed; }
  body[data-purchaser-guide] .fg-main #mm2h-tiers .fg-table :is(th,td) {
    padding: 7px 4px;
    font-size: .75rem;
    overflow-wrap: anywhere;
  }
}

@media (prefers-reduced-motion: reduce) {
  .purchaser-reader-bar:not([hidden]) .purchaser-recommend { animation: none; }
}
