/* ===========================================================
   LEIA O RÓTULO — Quiz Hugz · Fase movimento (preto e branco)
   =========================================================== */

:root {
  --bg: #000;
  --bg-soft: #0c0c0c;
  --fg: #fff;
  --fg-soft: rgba(255, 255, 255, 0.72);
  --fg-faint: rgba(255, 255, 255, 0.45);
  --line: rgba(255, 255, 255, 0.12);
  --line-strong: rgba(255, 255, 255, 0.25);
  --warn: rgba(255, 170, 170, 0.95);
  --good: rgba(180, 255, 200, 0.85);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
  --radius: 16px;
  --radius-lg: 24px;
  --transition: 320ms cubic-bezier(0.22, 1, 0.36, 1);
  --tap: 56px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--fg);
  line-height: 1.55;
  min-height: 100vh;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
button { font-family: inherit; }

/* ============ BRAND HEADER ============ */
.brand-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 24px;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.brand-logo {
  height: 56px;
  width: auto;
  filter: invert(1);
  opacity: 1;
  pointer-events: none;
  user-select: none;
  display: block;
}

.brand-hashtag {
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2.4px;
  text-transform: uppercase;
  color: var(--fg);
  padding: 7px 16px;
  border: 1.5px solid var(--fg);
  border-radius: 100px;
  white-space: nowrap;
}

/* ============ APP CONTAINER ============ */
#app { position: relative; }

/* ============ SCREENS ============ */
.screen {
  display: none;
  min-height: calc(100vh - 92px);
  min-height: calc(100dvh - 92px);
  padding: 32px 24px 64px;
  opacity: 0;
  animation: fadeIn 380ms ease-out forwards;
}
.screen--active { display: flex; flex-direction: column; }
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.screen-inner {
  max-width: 580px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  flex: 1;
}

/* ============ HERO PHOTO (welcome) ============ */
.hero-photo {
  position: relative;
  width: calc(100% + 48px);
  margin: -32px -24px 32px;
  height: 320px;
  overflow: hidden;
  background: #111;
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  filter: grayscale(1) contrast(1.05) brightness(0.9);
  display: block;
}
.hero-photo__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 35%, rgba(0,0,0,0.7) 80%, var(--bg) 100%);
  pointer-events: none;
}

.welcome-inner { padding-top: 8px; }

/* ============ EYEBROW ============ */
.eyebrow,
.question-eyebrow {
  display: inline-block;
  font-family: 'DM Sans', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--fg-soft);
  margin-bottom: 20px;
}

/* ============ TYPOGRAPHY ============ */
.headline {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 700;
  font-size: clamp(36px, 8.5vw, 56px);
  line-height: 1.02;
  letter-spacing: -1.4px;
  color: var(--fg);
  margin-bottom: 24px;
}
.headline em {
  font-style: italic;
  font-weight: 700;
}
.headline--medium { font-size: clamp(28px, 6.5vw, 40px); }

.subheadline {
  font-size: 17px;
  line-height: 1.55;
  color: var(--fg-soft);
  margin-bottom: 36px;
  max-width: 500px;
}
.subheadline strong { color: var(--fg); font-weight: 700; }

.question-title {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  font-size: clamp(26px, 6vw, 34px);
  line-height: 1.18;
  letter-spacing: -0.7px;
  margin-bottom: 16px;
}
.question-title strong { font-weight: 700; }
.question-helper {
  font-size: 14px;
  color: var(--fg-soft);
  margin-bottom: 28px;
  line-height: 1.5;
}

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: var(--tap);
  padding: 16px 28px;
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.2px;
  border-radius: 100px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform var(--transition), background var(--transition), color var(--transition), border-color var(--transition), opacity var(--transition);
  -webkit-tap-highlight-color: transparent;
  text-align: center;
  appearance: none;
  position: relative;
}
.btn:focus-visible { outline: 3px solid var(--fg); outline-offset: 3px; }
.btn--primary { background: var(--fg); color: var(--bg); }
.btn--primary:hover:not(:disabled),
.btn--primary:active { transform: translateY(-1px); }
.btn--primary:disabled { opacity: 0.35; cursor: not-allowed; transform: none; }

.btn--secondary {
  background: transparent;
  color: var(--fg);
  border-color: var(--line-strong);
}
.btn--secondary:hover:not(:disabled) { border-color: var(--fg); }

.btn--next { margin-top: 32px; }

.btn-loader {
  display: none;
  width: 18px; height: 18px;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}
.btn--loading .btn-label { opacity: 0; }
.btn--loading .btn-loader {
  display: block;
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
}
@keyframes spin { to { transform: translate(-50%, -50%) rotate(360deg); } }

/* ============ WELCOME ============ */
#screen-welcome .btn { margin-bottom: 20px; }
.social-proof {
  font-size: 14px;
  color: var(--fg-soft);
  margin-bottom: 6px;
}
.social-proof strong {
  color: var(--fg);
  font-family: 'Fraunces', serif;
  font-weight: 700;
}
.meta-line {
  font-size: 13px;
  color: var(--fg-faint);
  letter-spacing: 0.3px;
}

/* ============ PROGRESS ============ */
.progress-bar {
  height: 3px;
  background: var(--line);
  border-radius: 100px;
  overflow: hidden;
  margin: 0 auto 12px;
  max-width: 580px;
  width: 100%;
}
.progress-bar__fill {
  height: 100%;
  background: var(--fg);
  width: 14.3%;
  transition: width 420ms cubic-bezier(0.22, 1, 0.36, 1);
}
.progress-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--fg-faint);
  text-align: center;
  margin-bottom: 32px;
}

/* ============ QUESTIONS ============ */
.question { display: none; animation: fadeIn 360ms ease-out forwards; }
.question--active { display: block; }
.qbranch { display: none; }
.qbranch--active { display: block; margin-top: 20px; }

/* ============ INPUT TEXT (single line large) ============ */
.input-text {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 2px solid var(--line-strong);
  padding: 12px 0 16px;
  font-family: 'Fraunces', Georgia, serif;
  font-size: 28px;
  font-weight: 500;
  color: var(--fg);
  outline: none;
  transition: border-color var(--transition);
  caret-color: var(--fg);
  -webkit-appearance: none;
  border-radius: 0;
}
.input-text::placeholder { color: var(--fg-faint); font-weight: 400; }
.input-text:focus { border-bottom-color: var(--fg); }
.input-text--medium { font-size: 22px; }

/* ============ OPTIONS ============ */
.options { display: flex; flex-direction: column; gap: 12px; }

.option {
  width: 100%;
  min-height: var(--tap);
  padding: 18px 22px;
  background: transparent;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius);
  color: var(--fg);
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: border-color var(--transition), background var(--transition), transform var(--transition);
  -webkit-tap-highlight-color: transparent;
  line-height: 1.4;
}
.option small {
  display: inline;
  font-size: 13px;
  font-weight: 400;
  color: var(--fg-soft);
  margin-left: 4px;
}
.option:hover,
.option:focus-visible {
  border-color: var(--fg);
  background: rgba(255, 255, 255, 0.04);
  outline: none;
}
.option:active { transform: scale(0.985); }
.option--selected {
  border-color: var(--fg);
  background: var(--fg);
  color: var(--bg);
}
.option--selected small { color: rgba(0, 0, 0, 0.65); }

/* Option cards (Q4 method picker) */
.options--big { gap: 14px; }
.options--compact {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.option--card {
  display: flex;
  gap: 18px;
  padding: 22px;
  align-items: center;
}
.option--card .option-icon {
  font-size: 32px;
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.06);
  border-radius: 14px;
  transition: background var(--transition);
}
.option--card .option-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}
.option--card .option-body strong {
  font-family: 'Fraunces', serif;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.3px;
}
.option--card .option-body small {
  font-size: 13px;
  font-weight: 400;
  color: var(--fg-soft);
  margin-left: 0;
  display: block;
  line-height: 1.4;
}
.option--card.option--selected .option-icon { background: rgba(0,0,0,0.08); }
.option--card.option--selected .option-body small { color: rgba(0,0,0,0.65); }
.option--ghost { opacity: 0.7; }
.option--ghost:hover { opacity: 1; }

@media (max-width: 430px) {
  .options--compact { grid-template-columns: 1fr; }
}

/* ============ UPLOAD ============ */
.upload-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 40px 24px;
  border: 2px dashed var(--line-strong);
  border-radius: var(--radius);
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
  text-align: center;
}
.upload-area:hover { border-color: var(--fg); background: rgba(255,255,255,0.03); }
.upload-icon { font-size: 40px; }
.upload-text strong {
  display: block;
  font-family: 'Fraunces', serif;
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 4px;
}
.upload-text small {
  display: block;
  font-size: 13px;
  color: var(--fg-soft);
}

.photo-preview {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 10px;
  margin-top: 16px;
}
.photo-preview:empty { display: none; }
.photo-thumb {
  position: relative;
  aspect-ratio: 1;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-soft);
  border: 1px solid var(--line);
}
.photo-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.photo-thumb__remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(0,0,0,0.85);
  color: var(--fg);
  border: none;
  font-size: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* ============ SLIDER ============ */
.slider-wrap {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 8px 0 16px;
}
.slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  background: var(--line-strong);
  border-radius: 100px;
  outline: none;
  margin: 24px 0 4px;
}
.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--fg);
  cursor: pointer;
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 2px var(--fg);
  transition: transform var(--transition);
}
.slider::-webkit-slider-thumb:active { transform: scale(1.15); }
.slider::-moz-range-thumb {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--fg);
  cursor: pointer;
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 2px var(--fg);
}
.slider-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--fg-soft);
}
.slider-value {
  text-align: center;
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-size: 56px;
  line-height: 1;
  margin-top: 16px;
  letter-spacing: -2px;
}
.slider-value small {
  font-size: 22px;
  color: var(--fg-soft);
  letter-spacing: 0;
}

/* ============ CAPTURE FORM ============ */
.capture-form { display: flex; flex-direction: column; gap: 20px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--fg-soft);
}
.field input {
  width: 100%;
  min-height: var(--tap);
  padding: 14px 18px;
  background: transparent;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius);
  color: var(--fg);
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  font-weight: 500;
  outline: none;
  transition: border-color var(--transition);
  -webkit-appearance: none;
}
.field input::placeholder { color: var(--fg-faint); }
.field input:focus { border-color: var(--fg); }

.checkbox {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 8px 0;
  cursor: pointer;
  font-size: 13px;
  color: var(--fg-soft);
  line-height: 1.45;
}
.checkbox input {
  appearance: none;
  -webkit-appearance: none;
  width: 22px; height: 22px;
  border: 1.5px solid var(--line-strong);
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 1px;
  transition: border-color var(--transition), background var(--transition);
  position: relative;
}
.checkbox input:checked { border-color: var(--fg); background: var(--fg); }
.checkbox input:checked::after {
  content: '';
  position: absolute;
  left: 6px; top: 2px;
  width: 6px; height: 11px;
  border: solid var(--bg);
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(45deg);
}
#capture-submit { margin-top: 8px; }
.trust-line {
  font-size: 12px;
  color: var(--fg-faint);
  text-align: center;
  margin-top: 4px;
  letter-spacing: 0.3px;
}
.error-line {
  font-size: 13px;
  color: var(--warn);
  text-align: center;
  min-height: 18px;
  margin-top: 4px;
}

/* ============ LOADING ============ */
.loading-inner {
  align-items: center;
  text-align: center;
  justify-content: center;
  padding-top: 12vh;
}
.loading-inner .headline { text-align: center; }
.loading-inner .subheadline { text-align: center; margin-left: auto; margin-right: auto; }

.loading-spinner {
  display: flex;
  gap: 12px;
  margin-bottom: 36px;
}
.loading-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--fg);
  animation: dotPulse 1.2s ease-in-out infinite;
}
.loading-dot:nth-child(2) { animation-delay: 0.15s; }
.loading-dot:nth-child(3) { animation-delay: 0.3s; }
@keyframes dotPulse {
  0%, 100% { transform: scale(0.85); opacity: 0.35; }
  40% { transform: scale(1.15); opacity: 1; }
}
.loading-dots::after {
  content: '';
  animation: dotsAnim 1.4s steps(4) infinite;
}
@keyframes dotsAnim {
  0%   { content: ''; }
  25%  { content: '.'; }
  50%  { content: '..'; }
  75%  { content: '...'; }
}

.loading-checks {
  list-style: none;
  padding: 24px 0 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
}
.loading-checks li {
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 14px;
  color: var(--fg-faint);
  text-align: left;
  position: relative;
  padding-left: 44px;
  transition: color var(--transition), border-color var(--transition);
}
.loading-checks li::before {
  content: '○';
  position: absolute;
  left: 16px;
  top: 12px;
  font-size: 16px;
}
.loading-checks li.done {
  color: var(--fg);
  border-color: var(--line-strong);
}
.loading-checks li.done::before { content: '✓'; }
.loading-checks li.active {
  color: var(--fg);
  border-color: var(--fg);
}
.loading-checks li.active::before {
  content: '●';
  animation: dotPulse 1.2s ease-in-out infinite;
}

/* ============ RESULT ============ */
#screen-result .eyebrow {
  margin-bottom: 16px;
  align-self: center;
  text-align: center;
}

.result-card {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02)),
    var(--bg-soft);
  border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-lg);
  padding: 34px 26px 30px;
  margin-bottom: 40px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.result-card__kicker {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2.4px;
  text-transform: uppercase;
  color: var(--fg-faint);
}
.result-card__title {
  max-width: 380px;
  margin: 0 auto 4px;
  font-family: 'Fraunces', serif;
  font-size: clamp(24px, 7vw, 36px);
  font-weight: 900;
  line-height: 1.02;
  letter-spacing: 0;
}
.result-card__logo-img {
  height: 30px;
  filter: invert(1);
}
.result-card__pet {
  font-size: 13px;
  color: var(--fg-soft);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  font-weight: 600;
}
.result-card__context {
  max-width: 340px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--fg-soft);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.35;
}
.result-card__score {
  display: flex;
  align-items: baseline;
  justify-content: center;
  font-family: 'Fraunces', serif;
  line-height: 1;
  margin: 2px 0;
}
.result-card__score-num {
  font-size: clamp(88px, 24vw, 132px);
  font-weight: 900;
  letter-spacing: 0;
}
.result-card__score-of {
  font-size: 32px;
  font-weight: 500;
  color: var(--fg-soft);
  margin-left: 4px;
}
.result-card__badge {
  display: inline-block;
  padding: 8px 18px;
  border: 1.5px solid var(--line-strong);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}
.result-card__tagline {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: 17px;
  color: var(--fg);
  max-width: 320px;
  line-height: 1.4;
}
.result-card__cta {
  margin-top: 4px;
  padding: 10px 14px;
  background: var(--fg);
  color: var(--bg);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.4px;
}
.result-card__hashtag {
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2.5px;
  color: var(--fg-faint);
  margin-top: 8px;
}

.result-content { margin-bottom: 32px; }
.result-block { margin-top: 28px; }
.result-block:first-child { margin-top: 0; }

.result-section-title {
  font-family: 'Fraunces', serif;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.3px;
  margin-bottom: 14px;
}
.result-meaning {
  font-size: 16px;
  color: var(--fg-soft);
  line-height: 1.6;
}

.result-items { list-style: none; padding: 0; }
.result-items--problems li {
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--warn);
  border-radius: 10px;
  margin-bottom: 10px;
  font-size: 14px;
  line-height: 1.5;
}
.result-items--problems li strong {
  display: block;
  font-family: 'Fraunces', serif;
  font-size: 15px;
  color: var(--fg);
  margin-bottom: 4px;
}
.result-items--problems li span {
  color: var(--fg-soft);
}

.result-items--naturais {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.result-items--naturais li {
  padding: 8px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 100px;
  font-size: 13px;
  color: var(--fg);
}

.result-actions {
  list-style: none;
  counter-reset: action;
  padding: 0;
}
.result-actions li {
  counter-increment: action;
  position: relative;
  padding: 16px 0 16px 48px;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
  color: var(--fg-soft);
  line-height: 1.5;
}
.result-actions li:last-child { border-bottom: none; }
.result-actions li::before {
  content: counter(action, decimal-leading-zero);
  position: absolute;
  left: 0; top: 14px;
  font-family: 'Fraunces', serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--fg);
  opacity: 0.4;
}

.result-ctas {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 40px;
}
.movement-line {
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2.5px;
  color: var(--fg-faint);
  text-transform: uppercase;
  padding-bottom: 16px;
}

/* ============ UTILS ============ */
.ref-petname { font-style: italic; }
::selection { background: var(--fg); color: var(--bg); }

/* ============ DESKTOP ============ */
@media (min-width: 720px) {
  .brand-header { padding: 24px 36px; }
  .brand-logo { height: 64px; }
  .brand-hashtag { font-size: 14px; padding: 9px 20px; }
  .screen { padding: 48px 32px 80px; }
  .hero-photo { height: 380px; margin-left: -32px; margin-right: -32px; width: calc(100% + 64px); margin-top: -48px; }
  .result-card { padding: 48px 36px 40px; }
  .result-ctas { flex-direction: row; gap: 16px; }
  .result-ctas .btn { flex: 1; }
}

@media (min-width: 960px) {
  .headline { font-size: 64px; }
  .question-title { font-size: 36px; }
}

/* ============ REDUCED MOTION ============ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
