/* Morf Estúdio — papel creme, tinta azul, ouro. Inter no texto, Instrument Serif nos títulos. */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/fonts/inter-latin.woff2") format("woff2");
}
@font-face {
  font-family: "Instrument Serif";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/instrument-serif-latin.woff2") format("woff2");
}

:root {
  --tinta: #0B1A3B;
  --tinta-2: #16294f;
  --tinta-suave: #44527a;
  --papel: #F6EBC9;
  --papel-2: #FBF5E2;
  --linha: rgba(11, 26, 59, .14);
  --ouro: #FFC200;
  --ouro-escuro: #E8AE00;
  --erro: #8f1d1d;

  --corpo: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --titulo: "Instrument Serif", Georgia, "Times New Roman", serif;
  --saida: cubic-bezier(.16, 1, .3, 1);

  color-scheme: light;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scrollbar-color: var(--tinta) var(--papel); }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--corpo);
  font-size: 17px;
  line-height: 1.65;
  color: var(--tinta);
  background: var(--papel);
  accent-color: var(--tinta);
  caret-color: var(--tinta);
}

::selection { background: var(--ouro); color: var(--tinta); }

a { color: inherit; text-underline-offset: 4px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; text-decoration-color: var(--ouro-escuro); }

:focus-visible { outline: 3px solid var(--tinta); outline-offset: 3px; }

/* Topo e rodapé ------------------------------------------------------- */

.topo, .rodape {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

.topo { display: flex; align-items: center; padding-top: 22px; padding-bottom: 22px; }
.logo { display: inline-flex; align-items: center; gap: 12px; font-weight: 600; font-size: 15px; letter-spacing: .01em; text-decoration: none; }
.logo img { width: 36px; height: 36px; display: block; border-radius: 10px; }

.rodape {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 24px;
  padding-bottom: 28px;
  border-top: 1px solid var(--linha);
  font-size: 15px;
  color: var(--tinta-suave);
}
.rodape nav { display: flex; gap: 24px; }
.rodape a { color: var(--tinta); }

/* Página inicial ------------------------------------------------------ */

.palco {
  flex: 1;
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(16px, 5vw, 64px) 24px clamp(40px, 7vw, 88px);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: center;
}

h1 {
  margin: 0 0 24px;
  font-family: var(--titulo);
  font-weight: 400;
  font-size: clamp(3.25rem, 9vw, 5.75rem);
  line-height: .95;
  letter-spacing: -.01em;
  text-wrap: balance;
}

p { margin: 0 0 18px; text-wrap: pretty; }
.lead { max-width: 52ch; font-size: 19px; line-height: 1.6; }
.dica { margin: 16px 0 0; font-size: 15px; color: var(--tinta-suave); }

.botao {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 0 28px;
  font: inherit;
  font-weight: 600;
  color: var(--tinta);
  background: var(--ouro);
  border: 0;
  border-radius: 14px;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 1px 0 rgba(11, 26, 59, .25), 0 14px 24px -12px rgba(11, 26, 59, .45);
  transition: transform .25s var(--saida), box-shadow .25s var(--saida), background-color .25s var(--saida);
}
.botao svg { width: 20px; height: 20px; transition: transform .25s var(--saida); }
.botao:hover { background: #FFCD33; transform: translateY(-2px); box-shadow: 0 1px 0 rgba(11, 26, 59, .25), 0 18px 28px -12px rgba(11, 26, 59, .5); }
.botao:hover svg { transform: translateX(3px); }
.botao:active { transform: translateY(0); box-shadow: 0 1px 0 rgba(11, 26, 59, .25), 0 6px 12px -8px rgba(11, 26, 59, .5); }
.botao[disabled] { opacity: .5; cursor: not-allowed; transform: none; }

.botao-claro {
  background: transparent;
  box-shadow: inset 0 0 0 1.5px var(--tinta);
}
.botao-claro:hover { background: var(--tinta); color: var(--papel); box-shadow: inset 0 0 0 1.5px var(--tinta); }

.aviso {
  margin: 0 0 24px;
  padding: 14px 18px;
  color: var(--erro);
  background: var(--papel-2);
  border: 1px solid var(--erro);
  border-radius: 12px;
}
.aviso[hidden] { display: none; }

.selo {
  position: relative;
  width: 100%;
  max-width: 460px;
  justify-self: end;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 40px;
  background:
    radial-gradient(circle at 50% 42%, var(--tinta-2) 0%, var(--tinta) 68%);
  box-shadow: 0 2px 0 rgba(255, 255, 255, .08) inset, 0 40px 60px -36px rgba(11, 26, 59, .6), 0 12px 24px -16px rgba(11, 26, 59, .5);
  overflow: hidden;
}
.selo::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle, transparent 0 55%, rgba(255, 194, 0, .22) 55.2% 55.6%, transparent 55.8% 63%, rgba(255, 194, 0, .14) 63.2% 63.5%, transparent 63.7%) center / 100% 100% no-repeat;
  pointer-events: none;
}
.selo img { position: relative; width: 84%; height: auto; display: block; }

/* Tela de conta conectada (provisória até a Tarefa 10) ----------------- */

.coluna {
  flex: 1;
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(16px, 5vw, 56px) 24px clamp(40px, 7vw, 88px);
}
.coluna > * { max-width: 640px; }
.coluna h1 { font-size: clamp(2.5rem, 7vw, 3.75rem); margin-bottom: 28px; }

.conta {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 4px 18px;
  margin: 0 0 24px;
  padding: 22px 24px;
  background: var(--papel-2);
  border: 1px solid var(--linha);
  border-radius: 20px;
  box-shadow: 0 18px 30px -24px rgba(11, 26, 59, .45);
}
.avatar {
  grid-row: span 2;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  font-family: var(--titulo);
  font-size: 30px;
  line-height: 1;
  color: var(--ouro);
  background: var(--tinta);
  border-radius: 50%;
}
.conta-nome { margin: 0; font-weight: 600; font-size: 19px; line-height: 1.3; align-self: end; overflow-wrap: anywhere; }
.conta-estado { margin: 0; font-size: 15px; color: var(--tinta-suave); align-self: start; display: flex; align-items: center; gap: 8px; }
.conta-estado::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--ouro-escuro); flex: none; }
.conta[data-estado="carregando"] .conta-estado::before { animation: pulso 1.2s ease-in-out infinite; }
.conta[data-estado="erro"] .conta-estado { color: var(--erro); }
.conta[data-estado="erro"] .conta-estado::before { background: var(--erro); }

.opcoes { margin: 0 0 28px; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.opcoes[hidden] { display: none; }
.opcoes li { margin: 0; padding: 4px 14px; font-size: 14px; font-weight: 500; background: var(--papel-2); border: 1px solid var(--linha); border-radius: 999px; }
.rotulo { margin: 0 0 10px; font-size: 14px; font-weight: 600; letter-spacing: .02em; color: var(--tinta-suave); }
.rotulo[hidden] { display: none; }

/* Movimento: uma entrada só, ao abrir a página -------------------------- */

@keyframes sobe { from { opacity: 0; transform: translateY(14px); } }
@keyframes surge { from { opacity: 0; transform: scale(.94); } }
@keyframes pulso { 50% { opacity: .3; } }

@media (prefers-reduced-motion: no-preference) {
  .palco .texto > * { animation: sobe .8s var(--saida) backwards; }
  .palco .texto > :nth-child(2) { animation-delay: .08s; }
  .palco .texto > :nth-child(3) { animation-delay: .16s; }
  .palco .texto > :nth-child(4) { animation-delay: .24s; }
  .selo img { animation: surge 1.2s var(--saida) .1s backwards; }
}

/* Telas estreitas ------------------------------------------------------ */

@media (max-width: 820px) {
  .palco { grid-template-columns: 1fr; gap: 40px; }
  .selo { justify-self: center; max-width: 340px; border-radius: 32px; }
  .rodape { flex-direction: column; }
}
