:root {
  --navy: #03428e;
  --navy-dark: #03428e;
  --blue-light: #03428e;
  --gold: #ffd200;
  --gold-soft: #fff5bf;
  --green: #08a35a;
  --orange: #f7931e;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e5e7eb;
  --surface: #ffffff;
  --background: #f7f9fc;
  --shadow: 0 18px 44px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--background);
  font-family: "Inter", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

a {
  color: inherit;
}

.section-shell,
.header-shell,
.hero-shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid rgba(0, 43, 92, 0.1);
  backdrop-filter: blur(16px);
}

.header-shell {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.brand img {
  width: 146px;
  height: 50px;
  display: block;
  object-fit: contain;
}

.data-security {
  display: flex;
  align-items: center;
  gap: 12px;
}

.data-security__icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  color: #002B5C;
  border-radius: 14px;
  background: #eef5ff;
}

.data-security__icon svg {
  width: 22px;
  height: 22px;
  stroke-width: 2.2;
}

.data-security strong {
  display: block;
  color: #002B5C;
  font-size: 14px;
  font-weight: 700;
}

.data-security span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.hero {
  padding: 42px 0 28px;
  background:
    radial-gradient(circle at top right, rgba(0, 74, 152, 0.08), transparent 24%),
    linear-gradient(180deg, #ffffff, var(--background));
}

.hero-shell {
  display: grid;
  gap: 38px;
  align-items: start;
}

.hero-copy {
  max-width: 760px;
  padding: 18px 0 0;
}

.eyebrow {
  display: inline-block;
  color: var(--navy);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1.8px;
  text-transform: uppercase;
}

.hero h1,
.steps-aside__header h2,
.result-heading h2 {
  margin: 14px 0 12px;
  color: var(--navy-dark);
  font-family: "Sora", sans-serif;
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1.05;
  letter-spacing: -1.5px;
}

.hero-copy p {
  max-width: 680px;
  margin: 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.hero-main {
  display: grid;
  grid-template-columns: minmax(0, 52%) minmax(340px, 40%);
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
}

.lookup-card,
.step-card,
.empty-result,
.boleto-item,
.results-modal__dialog {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.lookup-card {
  padding: 34px;
  border-radius: 28px;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.06);
}

.card-heading {
  display: flex;
  gap: 16px;
  align-items: center;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}

.card-icon,
.step-number,
.privacy-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  color: var(--navy);
  border-radius: 16px;
  background: #eef5ff;
  font-weight: 800;
}

.card-heading h2 {
  margin: 0 0 4px;
  color: var(--navy-dark);
  font: 700 24px/1.2 "Sora", sans-serif;
  letter-spacing: -0.6px;
}

.card-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

form {
  margin-top: 24px;
}

.field-group {
  margin-bottom: 18px;
}

.field-group label {
  display: block;
  margin-bottom: 8px;
  color: var(--navy-dark);
  font-size: 14px;
  font-weight: 700;
}

.input-wrap input {
  width: 100%;
  height: 56px;
  padding: 0 16px;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 14px;
  outline: none;
  background: #fbfdff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.input-wrap input::placeholder {
  color: #94a3b8;
}

.input-wrap input:focus {
  border-color: var(--blue-light);
  box-shadow: 0 0 0 4px rgba(46, 116, 214, 0.12);
}

.field-group.has-error input {
  border-color: #d74d59;
  box-shadow: 0 0 0 4px rgba(215, 77, 89, 0.08);
}

.primary-button {
  width: 100%;
  min-height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--navy-dark);
  border: 0;
  border-radius: 999px;
  background: var(--gold);
  box-shadow: 0 14px 28px rgba(255, 210, 0, 0.28);
  font-weight: 800;
  transition: filter 0.2s, box-shadow 0.2s;
}

.primary-button:hover {
  filter: brightness(0.98);
}

.primary-button:disabled {
  cursor: wait;
  opacity: 0.75;
}

.privacy-note {
  margin-top: 22px;
  padding-top: 20px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  border-top: 1px solid var(--line);
}

.privacy-icon svg {
  width: 20px;
  height: 20px;
  stroke-width: 2.2;
}

.privacy-note p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.privacy-note strong {
  color: var(--navy-dark);
}

.text-button {
  min-height: 42px;
  padding: 0 16px;
  color: var(--navy);
  border: 1px solid rgba(0, 74, 152, 0.16);
  border-radius: 999px;
  background: white;
  font-size: 14px;
  font-weight: 700;
}

.back-button {
  margin: 0 0 18px;
}

#code-step .card-heading {
  margin-top: 0;
}

.dev-code,
.notice {
  margin: 14px 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--gold-soft);
  color: #725500;
  font-size: 13px;
}

.form-error,
.field-error {
  min-height: 18px;
  margin-top: 6px;
  color: #b42318;
  font-size: 12px;
}

.code-input {
  letter-spacing: 0.45em;
  font-size: 22px !important;
  font-weight: 700;
  text-align: center;
}

.expires-note {
  display: block;
  margin-top: 12px;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
}

.steps-aside__header h2,
.result-heading h2 {
  font-size: clamp(28px, 3vw, 38px);
}

.steps-aside {
  padding-top: 4px;
}

.steps-aside__header h2 {
  margin-top: 10px;
  margin-bottom: 10px;
  font-size: 28px;
}

.steps-aside__header p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.steps-stack {
  margin-top: 22px;
  display: grid;
  gap: 16px;
  position: relative;
}

.steps-stack::before {
  content: "";
  position: absolute;
  top: 24px;
  bottom: 24px;
  left: 23px;
  width: 1px;
  background: linear-gradient(180deg, rgba(0, 74, 152, 0.12), rgba(0, 74, 152, 0.02));
  pointer-events: none;
}

.step-card {
  padding: 24px;
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 18px;
  align-items: start;
}

.step-card strong {
  display: block;
  margin: 0 0 8px;
  color: var(--navy-dark);
  font-size: 18px;
}

.step-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.step-card .step-number {
  width: 56px;
  height: 56px;
}

.step-card--compact {
  padding: 20px 20px 20px 18px;
  grid-template-columns: 46px 1fr;
  gap: 14px;
  position: relative;
  z-index: 1;
}

.step-card--compact strong {
  font-size: 16px;
}

.step-card--compact p {
  font-size: 13px;
}

.step-card--compact .step-number {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: #f0f6ff;
}

.result-panel {
  padding: 22px 0 18px;
}

.result-panel[hidden] {
  display: none;
}

.result-heading {
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.result-heading h2 {
  margin-bottom: 0;
}

.result-heading .eyebrow {
  color: var(--navy);
}

.results-modal {
  position: fixed;
  inset: 0;
  z-index: 30;
}

.results-modal[hidden] {
  display: none;
}

.results-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.52);
  backdrop-filter: blur(4px);
}

.results-modal__dialog {
  width: min(1120px, calc(100% - 32px));
  max-height: calc(100vh - 48px);
  padding: 26px;
  position: relative;
  z-index: 1;
  margin: 24px auto;
  overflow: auto;
}

.results-modal__actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.icon-button {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(0, 74, 152, 0.16);
  border-radius: 999px;
  background: white;
  color: var(--navy-dark);
  font-size: 24px;
  line-height: 1;
}

.result-list {
  display: grid;
  gap: 18px;
}

.boleto-item {
  padding: 28px;
  display: grid;
  grid-template-columns: minmax(220px, 1.45fr) minmax(140px, 0.8fr) minmax(140px, 0.8fr) auto;
  gap: 20px;
  align-items: stretch;
}

.boleto-item + .boleto-item {
  margin-top: 18px;
}

.boleto-main,
.boleto-data {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.boleto-main strong,
.boleto-data strong {
  display: block;
  color: var(--navy-dark);
  font-size: 20px;
  line-height: 1.2;
}

.boleto-main span,
.boleto-data span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
}

.boleto-label {
  margin-top: 0 !important;
  margin-bottom: 10px;
  color: var(--navy) !important;
  font-size: 11px !important;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}

.status {
  width: fit-content;
  margin-top: 16px;
  padding: 7px 12px;
  color: #0b7a59;
  border-radius: 999px;
  background: #ddf7ee;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.status.overdue {
  background: #fff1f0;
  color: #b42318;
}

.boleto-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  min-width: 220px;
  align-self: center;
}

.boleto-help {
  grid-column: 1 / -1;
  padding: 14px 16px;
  border-left: 4px solid var(--orange);
  border-radius: 14px;
  background: #fff6eb;
  color: #7a3d00;
  font-size: 13px;
  line-height: 1.5;
}

.boleto-item--manual .boleto-help {
  grid-column: 1 / 4;
}

.boleto-item--manual .boleto-actions {
  grid-column: 4;
  grid-row: 1 / span 2;
  justify-content: flex-end;
  align-self: center;
}

.action-button {
  min-height: 44px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--navy);
  border: 1px solid rgba(0, 74, 152, 0.16);
  border-radius: 999px;
  background: white;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}

.action-button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.action-button.primary {
  color: var(--navy-dark);
  border-color: transparent;
  background: var(--gold);
}

.whatsapp-button {
  color: white;
  background: #25d366;
}

.empty-result {
  padding: 26px;
}

.empty-result strong {
  display: block;
  margin-bottom: 8px;
  color: var(--navy-dark);
  font-size: 16px;
}

.empty-result span {
  color: var(--muted);
  font-size: 14px;
}

.site-footer {
  margin-top: 28px;
  padding: 42px 0 34px;
  color: rgba(255, 255, 255, 0.82);
  background: #002B5C;
}

.footer-shell {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(240px, 320px);
  gap: 44px;
  align-items: start;
}

.footer-brand img {
  width: 126px;
  height: auto;
  display: block;
  filter: brightness(0) invert(1);
}

.footer-contact strong,
.footer-contact a {
  color: white;
  font-size: 18px;
  font-weight: 700;
}

.footer-brand p,
.footer-contact span {
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15px;
  line-height: 1.8;
}

.footer-contact {
  display: grid;
  gap: 10px;
  justify-items: start;
}

.footer-contact a {
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.45;
}

.toast {
  max-width: calc(100% - 32px);
  padding: 12px 17px;
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 60;
  color: white;
  border-radius: 8px;
  background: var(--navy-dark);
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.22);
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.25s, transform 0.25s;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.boleto-actions a {
  text-decoration: none;
}

@media (max-width: 1080px) {
  .header-shell {
    padding: 18px 0;
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-copy {
    padding-top: 0;
  }

  .hero-main {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .lookup-card {
    order: 1;
  }

  .steps-aside {
    order: 2;
  }

  .footer-shell {
    grid-template-columns: 1fr;
    justify-items: start;
    gap: 28px;
  }
}

@media (max-width: 760px) {
  .section-shell,
  .header-shell,
  .hero-shell {
    width: min(1180px, calc(100% - 28px));
  }

  .site-header {
    position: static;
  }

  .hero {
    padding-top: 26px;
  }

  .lookup-card,
  .step-card,
  .boleto-item,
  .results-modal__dialog {
    border-radius: 18px;
  }

  .result-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero-main {
    grid-template-columns: 1fr;
  }

  .back-button {
    margin-bottom: 16px;
  }

  .site-footer {
    padding-top: 34px;
  }

  .boleto-item {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .boleto-actions {
    justify-content: flex-start;
  }

  .boleto-item--manual .boleto-help,
  .boleto-item--manual .boleto-actions {
    grid-column: auto;
    grid-row: auto;
  }
}

@media (max-width: 520px) {
  .header-shell {
    gap: 14px;
  }

  .data-security {
    width: 100%;
  }

  .brand img {
    width: 122px;
    height: 42px;
  }

  .text-button,
  .action-button {
    width: 100%;
  }

  .hero-copy p {
    font-size: 15px;
  }

  .card-heading {
    align-items: flex-start;
  }

  .card-heading h2 {
    font-size: 21px;
  }

  .lookup-card,
  .step-card,
  .boleto-item,
  .results-modal__dialog {
    padding: 22px;
  }

  .step-card {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .steps-stack::before {
    display: none;
  }

  .boleto-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .footer-shell,
  .footer-contact {
    justify-items: center;
  }

  .footer-brand {
    text-align: center;
  }

  .footer-contact {
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
