:root {
  --bg: #fff;
  --card-bg: #ffffff;
  --text: #1a1d23;
  --text-muted: #6b7280;
  --primary: #2f6fed;
  --primary-hover: #2558c4;
  --primary-disabled: #a9bfe8;
  --error: #d33c3c;
  --border: #e2e4e9;
  --radius: 14px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #f1f2f4;
  color: var(--text);
  font-family: "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

.container {
  width: 100%;
  min-height: 100vh;
  position: relative;
  display: flex;
  flex-direction: column;
}

@media (min-width: 480px) {
  .container {
    max-width: 440px;
    margin: 0 auto;
  }
}

.header {
  background: #000D3C;
  padding: 16px 20px;
  height: 80px;
  display: flex;
  align-items: center;
}

.header--transparent {
  background: transparent;
}

.logo {
  max-width: 48px;
  display: block;
}

.hero {
  flex: 1;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.wrap--plain .hero {
  flex: 0 0 auto;
}

.wrap--full .hero {
  display: none !important;
  flex: 0 0 0 !important;
  height: 0 !important;
  width: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  border: none !important;
  overflow: hidden !important;
}

.hero:empty {
  display: none;
}

.hero-content {
  padding: 32px 22px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
}

.landing-info-card {
  background: #fff;
  border-radius: 14px;
  margin: 12px 22px 20px;
  padding: 6px 18px;
  display: flex;
  flex-direction: column;
}

.landing-info-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 0;
}

.landing-info-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: #000D3C;
}

.landing-info-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.landing-info-line {
  color: #000;
  font-family: "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1.25rem;
}

.landing-info-line--muted {
  font-weight: 400;
  color: #6b7280;
}

.landing-info-line--value {
  font-family: "Display", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 700;
  font-size: 1.75rem;
  line-height: 2.25rem;
  color: #ff6200;
}

.landing-info-icon--brand {
  color: #ff6200;
}

.landing-info-card--brand {
  background: linear-gradient(135deg, rgba(255, 98, 0, 0.07), rgba(255, 98, 0, 0.02));
  border: 1px solid rgba(255, 98, 0, 0.18);
}

.landing-info-divider {
  height: 1px;
  background: var(--border);
}

.wrap {
  width: 100%;
  flex: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 8px 20px 32px;
}

.card {
  width: 100%;
  padding: 24px;
  overflow: visible;
  border-radius: 18px;
  background: #fff;
}

.wrap--plain {
  padding-top: 16px;
}

.wrap--plain .hero {
  display: none !important;
}

.wrap--plain .hero-title {
  color: #000 !important;
}

.wrap--full {
  padding: 0;
  align-items: stretch;
  justify-content: stretch;
  flex: 1;
}

.wrap--full .hero {
  display: none !important;
}

.card--full {
  padding: 0;
  border-radius: 0;
  background: transparent;
  overflow: visible;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card--full .step {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 40px 20px;
}

/* Último step - resgate-obrigado */
.wrap--full .step h2,
.wrap--full .step h1 {
  color: #fff;
  margin-top: 0;
}

.wrap--full .step p {
  color: #fff;
}

.wrap--full .step img {
  max-width: 150px;
  height: auto;
  margin: 0 auto 40px;
}

.card--plain {
  padding: 0;
  border-radius: 0;
  background: transparent;
  overflow: visible;
}

.step {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.box-title {
  color: #000;
  font-family: "Display", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 400;
  font-size: 20px;
  line-height: 28px;
  margin: 0 0 3.5rem;
}

.box-title--tight {
  margin-bottom: 8px;
}

.box-title--landing {
  margin-bottom: 2rem;
}

.hero-icon-wrap {
  position: relative;
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-icon-ping {
  position: absolute;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #CC000066;
  opacity: 0;
  animation: hero-icon-ping 3.1s ease-out infinite;
}

.hero-icon-ping--2 {
  animation-delay: 0.7s;
}

.hero-icon-ping--3 {
  animation-delay: 1.4s;
}

.hero-icon-ping--brand {
  background: #ff620066;
}

@keyframes hero-icon-ping {
  0% { transform: scale(1); opacity: .7; }
  100% { transform: scale(1.8); opacity: 0; }
}

.hero-icon {
  position: relative;
  z-index: 1;
  width: 48px;
  height: auto;
  display: block;
}

.hero-icon--brand {
  color: #ff6200;
  stroke-width: 1.25;
}

.hero-title {
  color: #000;
  font-family: "Display", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 700;
  font-size: 2rem;
  line-height: 2.5rem;
  margin: 0;
}

.step h2 {
  color: #000;
  font-family: "Display", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 2rem;
  margin: 0;
}

.step h2.hero-title {
  font-size: 2rem;
  line-height: 2.5rem;
}

.step p,
.hero-content p {
  color: #4c4c4c;
  font-weight: 400;
  font-size: 1.125rem;
  line-height: 1.5rem;
  margin: 0;
}

.step p.field-intro {
  margin-bottom: 3.5rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.field-box {
  position: relative;
  min-height: calc(2.1875rem + calc(1 * 1.25rem + 0.6875rem));
  padding-top: 0.5rem;
}

.field-label {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  font: 400 0.875rem / 1.25rem "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  min-height: calc(1 * 1.25rem + 0.6875rem);
  padding: 0.5rem calc(0rem + 0rem) .1875rem 0.5rem;
  margin: 0;
  color: #6b7280;
  pointer-events: none;
  transform-origin: left top;
  transition: transform .25s ease, font-size .25s ease, color .25s ease;
}

.field-box:not(.is-active) .field-label {
  transform: translateY(calc(1 * 1.25rem + 0.6875rem));
  font-size: 1.25rem;
  line-height: 1.625rem;
}

.field-box.is-invalid .field-label {
  color: #CC0000;
}

.field-input {
  position: relative;
  margin-top: calc(1 * 1.25rem + 0.6875rem);
  border: 0;
  display: block;
  width: 100%;
  --ids-input-border-color: var(--border);
  border-bottom: 0.0625rem solid var(--border);
  border-radius: 0.25rem 0.25rem 0 0;
  background: transparent;
  caret-color: #E91E63;
  color: #000;
  font: 400 1.25rem / 1.625rem "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  min-height: 2.1875rem;
  outline: none;
  padding: 0 0 0.5rem 0.5rem;
  text-align: start;
  transition: border-color .25s, border-bottom-width .25s;
}

.field-box.is-invalid .field-input {
  border-bottom-color: #CC0000;
}

.field-box.is-invalid .field-input:focus {
  border-bottom-color: var(--border);
}

.field-input:focus {
  border-bottom-width: 0.125rem;
}

.field-message {
  display: flex;
  align-items: center;
  gap: 4px;
}

.field-message-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.field-message-text {
  color: #CC0000;
  font-family: "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 600;
  font-size: 14px;
  line-height: 1.3;
}

.spacer {
  flex: 1;
}

.step-back-toast {
  position: fixed;
  z-index: 1000;
  top: 16px;
  left: 50%;
  transform: translate(-50%, -8px);
  max-width: calc(100% - 32px);
  background: #1a1d23;
  color: #fff;
  font-family: "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  padding: 10px 16px;
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.step-back-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.landing-map {
  position: relative;
  width: 100%;
  height: 180px;
  overflow: hidden;
  background: #e5e3df;
}

.landing-map-tiles {
  position: absolute;
  display: grid;
  grid-template-columns: repeat(3, 256px);
  grid-template-rows: repeat(3, 256px);
}

.landing-map-tiles img {
  width: 256px;
  height: 256px;
  display: block;
}

.landing-map-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, calc(-100% - 20px));
  background: #fff;
  border-radius: 8px;
  padding: 6px 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  white-space: nowrap;
  z-index: 2;
}

.landing-map-badge::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -6px;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 6px solid #fff;
}

.landing-map-location {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  text-align: center;
}

.landing-map-caption {
  margin-top: 2px;
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
}

.landing-map-pin {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 16px;
  height: 16px;
  transform: translate(-50%, -50%);
  background: var(--primary);
  border: 3px solid #fff;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

button.primary {
  width: 100%;
  min-height: 50px;
  padding: 14px;
  font-family: "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5rem;
  font-weight: 700;
  color: #fff;
  background: #E91E63;
  border: none;
  border-radius: 24px;
  cursor: pointer;
  transition: background 0.15s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

button.primary:hover:not(:disabled) {
  background: #c2185b;
}

button.primary:disabled {
  color: #999;
  background: #cfd1d3;
  cursor: not-allowed;
}

button.secondary {
  width: 100%;
  min-height: 3.125rem;
  padding: 0.625rem;
  font-family: "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.5rem;
  font-weight: 700;
  color: #006;
  background: transparent;
  border: 1px solid #006;
  border-radius: 0.75rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-spinner {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: btn-spin 0.6s linear infinite;
}

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

.photo-modal {
  position: fixed;
  inset: 0;
  z-index: 998;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow-y: auto;
  padding: 32px 24px;
  opacity: 0;
  transition: opacity .2s ease;
}

.photo-modal.is-visible {
  opacity: 1;
}

.photo-modal-close {
  align-self: flex-end;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  background: transparent;
  color: #000D3C;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.photo-modal-close svg {
  width: 22px;
  height: 22px;
}

.photo-modal-content {
  position: relative;
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  padding: 32px 24px;
  height: 100%;
  justify-content: center;
}

.photo-modal-corner {
  position: absolute;
  width: 26px;
  height: 26px;
  border: 2px solid #d5d8de;
}

.photo-modal-corner--tl { top: 0; left: 0; border-right: none; border-bottom: none; border-radius: 8px 0 0 0; }
.photo-modal-corner--tr { top: 0; right: 0; border-left: none; border-bottom: none; border-radius: 0 8px 0 0; }
.photo-modal-corner--bl { bottom: 0; left: 0; border-right: none; border-top: none; border-radius: 0 0 0 8px; }
.photo-modal-corner--br { bottom: 0; right: 0; border-left: none; border-top: none; border-radius: 0 0 8px 0; }

.photo-modal-header {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.photo-modal-title {
  width: 100%;
  margin: 0;
  color: #000;
  font-family: "Display", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 2rem;
  text-align: center;
}

.photo-frame {
  width: 300px;
  height: 380px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 10px solid #E91E63;
  overflow: hidden;
  background: #f1f2f4;
}

.photo-frame-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-modal-text {
  margin: 0;
  color: #000;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.5rem;
  text-align: center;
}

.photo-modal-actions {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.step-image {
  max-width: 280px;
  width: 100%;
  display: block;
  border-radius: 10px;
  margin: 2rem auto;
}

.identity-notices {
  display: flex;
  flex-direction: column;
}

.identity-notice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 0;
}

.identity-notice-icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  margin-top: 1px;
  color: #000D3C;
}

.identity-notice-text {
  color: #4c4c4c;
  font-family: "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 400;
  font-size: 0.9375rem;
  line-height: 1.3125rem;
}

.identity-notice-divider {
  height: 1px;
  background: #b5b8c0;
}

.hidden {
  display: none !important;
}

.step-footer {
  width: 100%;
  background: #4C4C4C;
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.step-footer-logo {
  width: 46px;
  height: auto;
  display: block;
}

.step-footer-text {
  margin: 0;
  color: #fff;
  font-family: "Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.5rem;
  text-align: left;
}

.center-icon {
  font-size: 48px;
  text-align: center;
}

.loading-screen {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000D3C;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease;
}

.loading-screen.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.loading-spinner {
  width: 72px;
  height: 72px;
  border: 3px solid rgba(255, 255, 255, 0.25);
  border-top-color: #fff;
  border-radius: 50%;
  animation: btn-spin 0.8s linear infinite;
}
