/* Daqui de Fora | página de links
   Tema replicado do Linktree (custom, luminância escura, fonte Manrope).
   Botão: o vermelho original do Linktree (#e35e59) com texto branco tem contraste 3,5:1,
   abaixo do mínimo WCAG AA (4,5:1). Usamos #c8433e (4,8:1). Para voltar ao original,
   troque --btn. */
:root {
  --bg: #3b2a26;
  --text: #eadbd0;
  --heading: #fbf3ec;
  --btn: #c8433e;
  --btn-hover: #b93a35;
  --btn-shadow: #7a1f1c;
  --btn-text: #ffffff;
  --radius: 16px;
  --max: 580px;
  color-scheme: dark;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.5 Manrope, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; }

/* Fundo "morph" sutil, como no tema do Linktree */
.bg {
  position: fixed;
  inset: -10%;
  z-index: -1;
  background:
    radial-gradient(45% 35% at 18% 12%, #5c3b33 0%, transparent 70%),
    radial-gradient(40% 35% at 85% 35%, #4f2d28 0%, transparent 70%),
    radial-gradient(60% 45% at 50% 100%, #2c1f1c 0%, transparent 70%),
    var(--bg);
  animation: drift 28s ease-in-out infinite alternate;
}
@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(-3%, 2%, 0) scale(1.08); }
}

.page {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px calc(40px + env(safe-area-inset-bottom));
}

/* ---------- Hero ---------- */
.hero { position: relative; text-align: center; }

.hero__media {
  margin: 0 -16px;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
}
.hero__media img { width: 100%; height: 100%; object-fit: cover; }

@media (min-width: 620px) {
  .page { padding-top: 24px; }
  .hero__media { margin: 0; border-radius: 28px 28px 0 0; }
}

.topbar {
  position: absolute;
  top: 14px;
  right: 0;
  z-index: 2;
  display: flex;
  gap: 8px;
}
@media (min-width: 620px) { .topbar { right: 14px; } }

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  background: rgba(20, 12, 10, 0.55);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
}
.pill--icon { width: 40px; padding: 0; }
.pill svg { width: 18px; height: 18px; }
.pill:hover { background: rgba(20, 12, 10, 0.75); }

.hero__title {
  position: relative;
  margin: -72px 0 8px;
  color: var(--heading);
  font-size: clamp(28px, 8vw, 40px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.45);
}

.hero__bio {
  max-width: 46ch;
  margin: 0 auto 16px;
  font-size: 15px;
}

.socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
  margin-bottom: 8px;
}
.social {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: var(--text);
  transition: transform 0.15s ease, color 0.15s ease;
}
.social svg { width: 24px; height: 24px; }
.social:hover { color: var(--heading); transform: translateY(-2px); }

/* ---------- Grupos e links ---------- */
.group { margin-top: 32px; }

.group__title {
  margin: 0 0 14px;
  color: var(--heading);
  font-size: 17px;
  font-weight: 700;
  text-align: center;
}

.links {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.link { position: relative; }

.link__main {
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  align-items: center;
  gap: 8px;
  min-height: 64px;
  padding: 8px;
  border-radius: var(--radius);
  background: var(--btn);
  color: var(--btn-text);
  text-decoration: none;
  box-shadow: 0 2px 0 var(--btn-shadow), 0 8px 18px -10px rgba(0, 0, 0, 0.6);
  transition: transform 0.15s ease, background-color 0.15s ease;
}
.link__main:hover { background: var(--btn-hover); transform: translateY(-2px); }
.link__main:active { transform: scale(0.985); }

.thumb {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.12);
}

.link__text { text-align: center; }
.link__title { display: block; font-size: 15.5px; font-weight: 700; line-height: 1.3; }
.link__sub { display: block; margin-top: 2px; font-size: 13px; opacity: 0.85; }

.link__share {
  position: absolute;
  top: 50%;
  right: 12px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--btn-text);
  cursor: pointer;
  transform: translateY(-50%);
}
.link__share svg { width: 18px; height: 18px; }
.link__share:hover { background: rgba(255, 255, 255, 0.16); }

/* Card em destaque: capa do episódio mais recente do YouTube */
.link__main--feature {
  display: block;
  padding: 8px 8px 14px;
}
.feature__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  margin-bottom: 12px;
  overflow: hidden;
  border-radius: 11px;
  background: rgba(0, 0, 0, 0.25);
}
.feature__media img { width: 100%; height: 100%; object-fit: cover; }
.feature__play {
  position: absolute;
  left: 10px;
  bottom: 10px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(20, 12, 10, 0.65);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  color: #fff;
  transition: transform 0.15s ease, background-color 0.15s ease;
}
.feature__play svg { width: 22px; height: 22px; margin-left: 3px; }
.link__main--feature:hover .feature__play { background: var(--btn); transform: scale(1.06); }
.link--feature .link__text { display: block; padding: 0 40px; }
.link--feature .link__share { top: auto; bottom: 10px; transform: none; }
.link__sub--clamp {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 4px;
}
.badge {
  display: table;
  margin: 6px auto 0;
  padding: 1px 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.disclosure {
  margin: 12px 8px 0;
  font-size: 12.5px;
  text-align: center;
  opacity: 0.8;
}

/* ---------- Rodapé ---------- */
.footer {
  margin-top: 48px;
  font-size: 13px;
  text-align: center;
  opacity: 0.85;
}
.footer p { margin: 8px 0 0; }
.footer__link {
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

/* ---------- Foco acessível ---------- */
:focus-visible {
  outline: 3px solid var(--heading);
  outline-offset: 3px;
  border-radius: 8px;
}
.link__main:focus-visible { border-radius: var(--radius); }

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 20;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--heading);
  color: #2b1e1b;
  font-size: 14px;
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Consentimento ---------- */
.consent {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: calc(12px + env(safe-area-inset-bottom));
  z-index: 30;
  max-width: 560px;
  margin: 0 auto;
  padding: 16px;
  border-radius: var(--radius);
  background: var(--heading);
  color: #2b1e1b;
  font-size: 14px;
  box-shadow: 0 16px 40px -12px rgba(0, 0, 0, 0.6);
}
.consent p { margin: 0 0 12px; }
.consent a { color: #8a2c28; }
.consent__actions { display: flex; justify-content: flex-end; gap: 8px; }
body.has-consent { padding-bottom: 150px; }

.btn {
  min-height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: var(--btn);
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}
.btn--ghost { background: transparent; color: #2b1e1b; box-shadow: inset 0 0 0 1.5px #2b1e1b; }
.consent :focus-visible { outline-color: #2b1e1b; }

/* ---------- Páginas de texto ---------- */
.page--text { padding-top: 40px; line-height: 1.65; }
.page--text h1 { color: var(--heading); font-size: 32px; line-height: 1.15; }
.page--text h2 { margin-top: 28px; color: var(--heading); font-size: 20px; }
.page--text a { color: var(--heading); text-underline-offset: 3px; }
.back { text-decoration: none; }
.muted { opacity: 0.7; font-size: 14px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
