:root {
  --blue: #0b71bf;
  --button-blue: #1351b4;
  --dark: #181818;
  --text: #2f2f2f;
  --muted: #6b6b6b;
  --bubble: #eeeeef;
  --bubble-border: #d8d8da;
  --notice: #9bd3fb;
  --warning: #ffdf3d;
  font-family: Arial, Helvetica, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  width: 100%;
  min-height: 100vh;
  overflow-x: hidden;
  background: #fff;
  color: var(--text);
  padding-top: 95px;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.gov-strip {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: 43px;
  background: var(--dark);
  color: #fff;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
}

.gov-brand {
  font-size: 18px;
  letter-spacing: -1px;
}

.gov-brand span {
  margin-left: 2px;
  color: #f3d43b;
}

.enem-strip {
  position: fixed;
  top: 43px;
  left: 0;
  right: 0;
  z-index: 100;
  height: 52px;
  background: var(--blue);
  color: #fff;
  display: flex;
  align-items: center;
  gap: 30px;
  padding: 0 16px;
}

.menu-button {
  width: 28px;
  display: grid;
  gap: 5px;
  padding: 0;
  border: 0;
  background: transparent;
}

.menu-button span {
  height: 4px;
  border-radius: 2px;
  background: #fff;
}

.enem-logo {
  display: flex;
  align-items: baseline;
  gap: 12px;
  line-height: 1;
}

.enem-logo strong {
  font-size: 34px;
  font-style: italic;
  letter-spacing: -3px;
}

.enem-logo span {
  font-size: 38px;
  font-weight: 300;
  letter-spacing: -2px;
}

.stage {
  min-height: calc(100vh - 95px);
  padding: 20px 0 56px;
  background: #fff;
}

.chat-flow {
  width: min(100%, 720px);
  margin: 0 auto;
}

.message-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 14px 18px 6px;
}

.message-row.user {
  justify-content: flex-end;
  margin-left: 90px;
  margin-right: 18px;
}

.avatar {
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  margin-top: 44px;
  border: 3px solid #d7d7d7;
  border-radius: 50%;
  background: #fff;
  object-fit: contain;
  object-position: center;
  box-shadow: 0 1px 5px rgba(0,0,0,.18);
}

.bubble,
.user-bubble,
.notice,
.warning {
  position: relative;
  border-radius: 4px;
  font-size: 18px;
  line-height: 1.45;
}

.bubble {
  width: min(100%, 560px);
  min-height: 86px;
  padding: 24px 28px;
  background: var(--bubble);
  border-left: 12px solid var(--bubble-border);
}

.bubble::before {
  content: "";
  position: absolute;
  left: -25px;
  top: 72px;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  border-right: 14px solid var(--bubble-border);
}

.bubble p {
  margin: 0 0 18px;
}

.bubble p:last-child {
  margin-bottom: 0;
}

.intro-banner {
  width: 100%;
  display: block;
  margin: 0 0 22px;
  border-radius: 4px;
}

.user-bubble {
  max-width: 360px;
  padding: 14px 18px;
  background: #eeeeef;
  color: #333;
  box-shadow: 9px 0 0 var(--bubble-border);
}

.user-bubble::after {
  content: "";
  position: absolute;
  right: -20px;
  top: 18px;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 12px solid var(--bubble-border);
}

.actions {
  display: grid;
  gap: 14px;
  margin-top: 22px;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 22px;
  margin-top: 26px;
}

.primary,
.secondary {
  min-height: 54px;
  border: 0;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 28px;
  color: #fff;
  background: var(--button-blue);
  font-size: 20px;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
  box-shadow: 0 2px 5px rgba(0,0,0,.25);
}

.pill {
  min-height: 58px;
  border-radius: 32px;
  text-transform: none;
}

.secondary {
  color: #0b5a96;
  background: transparent;
  box-shadow: none;
}

.captcha-grid {
  width: min(100%, 468px);
  margin: 24px auto 10px;
  display: grid;
  grid-template-columns: repeat(5, 84px);
  justify-content: center;
  gap: 12px;
}

.captcha-choice {
  width: 84px;
  height: 84px;
  border: 2px solid #d6d6d6;
  background: #f7f7f7;
  color: #111;
  display: grid;
  place-items: center;
}

.captcha-choice svg {
  width: 52px;
  height: 52px;
  display: block;
  fill: currentColor;
}

.captcha-choice svg [fill="none"] {
  fill: none;
}

.captcha-choice.selected {
  outline: 2px dashed #39607b;
  outline-offset: 4px;
  background: #d8eefc;
}

.form-grid {
  display: grid;
  gap: 18px;
  margin-top: 26px;
}

.field {
  display: grid;
  gap: 6px;
}

.field label {
  color: var(--muted);
  font-size: 15px;
}

.field input,
.field select {
  width: 100%;
  min-height: 50px;
  border: 0;
  border-bottom: 2px solid #999;
  border-radius: 0;
  padding: 8px 4px;
  background: #fff;
  color: #333;
  font-size: 18px;
}

.field input:focus,
.field select:focus {
  outline: 2px solid #9bd3fb;
  outline-offset: 2px;
}

.check-row {
  min-height: 52px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
  color: #333;
}

.check-row input {
  width: 24px;
  height: 24px;
}

.question-section {
  margin: 0 0 14px;
  color: var(--button-blue);
  font-size: 16px;
  font-weight: 800;
  text-transform: uppercase;
}

.choice-list,
.card-options {
  display: grid;
  gap: 12px;
  margin-top: 22px;
}

.choice-list label,
.card-options label {
  min-height: 68px;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  background: #f0f0f2;
  border: 1px solid #e6e6e8;
  border-radius: 4px;
  font-size: 17px;
}

.card-options {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.card-options label {
  min-height: 148px;
  justify-content: center;
  flex-direction: column;
  background: #fff;
  border-color: #cfcfd3;
}

.choice-list input,
.card-options input {
  width: 30px;
  height: 30px;
  margin: 0;
  accent-color: var(--blue);
}

.notice,
.warning {
  margin-top: 22px;
  padding: 20px 24px;
  border-left: 12px solid #0872c7;
  background: var(--notice);
  color: #253747;
}

.warning {
  border-left-color: #e8a000;
  background: var(--warning);
}

.progress {
  margin-top: 18px;
  color: #666;
  text-align: right;
  font-size: 16px;
}

.verification-card {
  min-height: 220px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  text-align: center;
}

.spinner {
  width: 54px;
  height: 54px;
  border: 6px solid #d2e8ff;
  border-top-color: var(--button-blue);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.payment-page {
  width: min(100%, 760px);
  min-height: calc(100vh - 96px);
  margin: -20px auto -56px;
  background: #fff;
  color: #333;
  border-right: 7px solid var(--button-blue);
}

.payment-header {
  min-height: 116px;
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 18px 24px;
  border-bottom: 2px solid #b7d4e7;
}

.payment-header h1 {
  margin: 0 0 8px;
  color: var(--button-blue);
  font-size: 26px;
  line-height: 1.1;
}

.payment-header p {
  margin: 0;
  color: var(--button-blue);
  font-size: 20px;
}

.payment-back {
  border: 0;
  background: transparent;
  color: var(--button-blue);
  font-size: 48px;
  line-height: 1;
  box-shadow: none;
}

.payment-avatar,
.beto-avatar {
  width: 86px;
  height: 86px;
  flex: 0 0 86px;
  border-radius: 50%;
  border: 6px solid #d9d9d9;
  background: #fff url("./assets/nanda-avatar-thumb.jpg") center/cover no-repeat;
  object-fit: cover;
  object-position: center;
  display: block;
  box-shadow: 0 1px 4px rgba(0,0,0,.22);
}

.payment-avatar.small,
.beto-avatar.small {
  width: 56px;
  height: 56px;
  flex-basis: 56px;
  border-width: 4px;
}

.payment-chat-row {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin: 28px 28px 72px;
}

.payment-bubble {
  width: min(100%, 560px);
  position: relative;
  padding: 26px 34px;
  border-left: 12px solid var(--bubble-border);
  border-radius: 4px;
  background: var(--bubble);
  font-size: 22px;
  line-height: 1.45;
}

.payment-bubble::before {
  content: "";
  position: absolute;
  left: -28px;
  top: 96px;
  border-top: 16px solid transparent;
  border-bottom: 16px solid transparent;
  border-right: 16px solid var(--bubble-border);
}

.payment-bubble p {
  margin: 0 0 28px;
}

.payment-options {
  display: grid;
  justify-items: center;
}

.payment-options p {
  width: 100%;
}

.payment-button {
  width: min(100%, 465px);
  min-height: 86px;
  margin: 16px 0;
  border: 0;
  border-radius: 6px;
  background: var(--blue);
  color: #fff;
  box-shadow: 0 3px 7px rgba(0,0,0,.28);
  font-size: 28px;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: .4px;
}

.payment-button.short {
  width: 270px;
  min-height: 64px;
}

.payment-button span {
  margin-left: 22px;
}

.card-mark {
  font-size: 14px;
}

.payment-button:disabled {
  opacity: .75;
  cursor: wait;
}

.pix-result {
  width: 100%;
}

.pix-status {
  text-align: center;
}

.pix-card {
  width: min(100%, 420px);
  display: grid;
  justify-items: center;
  gap: 14px;
  margin: 8px auto 0;
  padding: 18px;
  border: 1px solid #d7d7d7;
  border-radius: 6px;
  background: #fff;
}

.pix-qr {
  width: 260px;
  max-width: 100%;
  height: auto;
  display: block;
}

.pix-code {
  width: 100%;
  min-height: 92px;
  resize: vertical;
  border: 1px solid #b8b8b8;
  border-radius: 4px;
  padding: 10px;
  font-size: 13px;
  line-height: 1.35;
}

.copy-pix {
  min-height: 48px;
  border: 0;
  border-radius: 4px;
  padding: 0 22px;
  background: var(--button-blue);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
}

@media (max-width: 520px) {
  .gov-strip {
    gap: 14px;
    font-size: 10px;
  }

  .enem-logo strong {
    font-size: 30px;
  }

  .enem-logo span {
    font-size: 34px;
  }

  .stage {
    padding-top: 18px;
  }

  .avatar {
    width: 52px;
    height: 52px;
    flex-basis: 52px;
    margin-top: 56px;
  }

  .bubble {
    padding: 22px 22px;
    font-size: 17px;
  }

  .button-row {
    justify-content: flex-start;
  }

  .primary,
  .secondary {
    min-height: 50px;
    padding: 0 22px;
    font-size: 17px;
  }

  .captcha-grid {
    width: min(100%, 302px);
    grid-template-columns: repeat(5, 54px);
    gap: 8px;
  }

  .captcha-choice {
    width: 54px;
    height: 54px;
  }

  .captcha-choice svg {
    width: 34px;
    height: 34px;
  }

  .card-options {
    grid-template-columns: 1fr 1fr;
  }

  .payment-page {
    margin-left: 0;
    margin-right: 0;
  }

  .payment-header {
    min-height: 92px;
    gap: 12px;
    padding: 14px 12px;
  }

  .payment-header h1 {
    font-size: 21px;
  }

  .payment-header p {
    font-size: 16px;
  }

  .payment-back {
    font-size: 38px;
  }

  .payment-avatar,
  .beto-avatar {
    width: 64px;
    height: 64px;
    flex-basis: 64px;
  }

  .payment-chat-row {
    gap: 10px;
    margin: 22px 10px 46px;
  }

  .payment-avatar.small,
  .beto-avatar.small {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }

  .payment-bubble {
    padding: 22px 20px;
    font-size: 18px;
  }

  .payment-button {
    min-height: 72px;
    font-size: 22px;
  }

  .payment-button.short {
    width: 220px;
  }
}
