:root {
  --bg-deep: #0a0d12;
  --bg-night: #0f172a;
  --bg-ink: #121824;
  --gold: #c89b3c;
  --gold-light: #e0b85c;
  --ivory: #f3ede2;
  --warm-gray: #cfc7ba;
  --muted: #978f84;
  --cyan: #06b6d4;
  --green: #22c55e;
  --amber: #f59e0b;
  --line: rgba(224, 184, 92, .26);
  --panel: rgba(15, 23, 42, .72);
  --panel-soft: rgba(243, 237, 226, .055);
  --shadow: 0 26px 90px rgba(0, 0, 0, .5);
  --max: 1180px;
  --display: Georgia, "Times New Roman", serif;
  --sans: Inter, Manrope, "IBM Plex Sans", Arial, sans-serif;
  --mono: "SFMono-Regular", Consolas, "IBM Plex Mono", monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--bg-deep);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ivory);
  background:
    radial-gradient(circle at 18% 0%, rgba(6, 182, 212, .12), transparent 28rem),
    radial-gradient(circle at 88% 4%, rgba(200, 155, 60, .13), transparent 24rem),
    linear-gradient(160deg, #07090d 0%, var(--bg-deep) 42%, #101827 100%);
  font-family: var(--sans);
  line-height: 1.6;
  overflow-x: hidden;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  content: "";
  background-image:
    linear-gradient(rgba(243, 237, 226, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(243, 237, 226, .028) 1px, transparent 1px),
    url("../marketing/pagina-venda/assets/metatron-pattern.svg");
  background-position: center top, center top, 90% 4%;
  background-size: 72px 72px, 72px 72px, 560px 560px;
  background-repeat: repeat, repeat, no-repeat;
  opacity: .38;
  pointer-events: none;
}

body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  background: linear-gradient(180deg, rgba(10, 13, 18, .18), rgba(10, 13, 18, .86));
  pointer-events: none;
}

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

a,
button,
h1,
h2,
h3 {
  overflow-wrap: break-word;
}

a {
  color: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

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

.skip-link {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 100;
  transform: translateY(-200%);
  padding: .7rem 1rem;
  border: 1px solid var(--gold);
  background: var(--bg-deep);
  color: var(--ivory);
  text-decoration: none;
}

.skip-link:focus {
  transform: translateY(0);
}

.read-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 90;
  width: 100%;
  height: 3px;
  background: rgba(243, 237, 226, .08);
}

.read-progress span {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--cyan));
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: calc(var(--max) + 48px);
  margin: 0 auto;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid rgba(243, 237, 226, .08);
  background: rgba(10, 13, 18, .78);
  backdrop-filter: blur(18px);
}

.brand,
.top-nav,
.site-footer nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: .75rem;
  color: var(--ivory);
  font-family: var(--mono);
  font-size: .78rem;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: .12em;
}

.brand img,
.site-footer img {
  filter: drop-shadow(0 0 18px rgba(224, 184, 92, .24));
}

.top-nav {
  gap: .35rem;
  color: var(--warm-gray);
  font-size: .88rem;
}

.top-nav a {
  padding: .55rem .72rem;
  border-radius: 999px;
  text-decoration: none;
}

.top-nav a:hover,
.top-nav a:focus-visible {
  background: rgba(243, 237, 226, .08);
  color: var(--ivory);
}

.top-nav .nav-cta {
  border: 1px solid var(--line);
  color: var(--gold-light);
}

.section,
.section-frame {
  max-width: var(--max);
  margin: 0 auto;
  padding: 6.5rem 1.5rem;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, .92fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 5.5rem);
  min-height: calc(100vh - 68px);
  padding-top: 3rem;
}

.eyebrow {
  margin: 0 0 .9rem;
  color: var(--gold-light);
  font-family: var(--mono);
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .14em;
}

h1,
h2,
h3,
p,
blockquote {
  margin-top: 0;
}

h1,
h2 {
  max-width: 980px;
  font-family: var(--display);
  font-weight: 600;
  line-height: .98;
}

h1 {
  margin-bottom: 1.2rem;
  font-size: clamp(4rem, 9vw, 7.8rem);
  letter-spacing: 0;
}

h1 span {
  display: block;
}

h2 {
  margin-bottom: 1.25rem;
  font-size: clamp(2.25rem, 5vw, 4.7rem);
  letter-spacing: 0;
}

h3 {
  margin-bottom: .65rem;
  color: var(--ivory);
  font-size: 1.05rem;
  line-height: 1.25;
}

.hero-subtitle {
  color: var(--gold-light);
  font-family: var(--display);
  font-size: clamp(1.6rem, 3vw, 2.8rem);
  line-height: 1.05;
}

.hero-support {
  max-width: 720px;
  color: var(--warm-gray);
  font-size: clamp(1.05rem, 2vw, 1.35rem);
}

.hero-note,
.copy-block,
.section-heading p,
.identity-copy p,
.tab-panel p,
.site-footer p {
  color: var(--warm-gray);
}

.hero-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
  gap: .75rem;
  max-width: 760px;
  margin-top: 2rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: .78rem 1.05rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none;
  transition: transform .22s ease, border-color .22s ease, background .22s ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  border-color: rgba(224, 184, 92, .72);
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  color: #0a0d12;
}

.button-secondary {
  background: rgba(243, 237, 226, .08);
  color: var(--ivory);
}

.button-ghost {
  color: var(--gold-light);
}

.hero-visual {
  position: relative;
  margin: 0;
}

.hero-visual::before {
  position: absolute;
  inset: 8% -3% -7%;
  z-index: -1;
  content: "";
  border: 1px solid var(--line);
  background: linear-gradient(145deg, rgba(243, 237, 226, .08), rgba(6, 182, 212, .04));
  box-shadow: var(--shadow);
}

.hero-visual img {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border: 1px solid rgba(243, 237, 226, .16);
  box-shadow: 0 22px 80px rgba(0, 0, 0, .46);
}

.hero-visual figcaption {
  margin-top: .8rem;
  color: var(--muted);
  font-size: .82rem;
}

.section-index {
  position: sticky;
  top: 72px;
  z-index: 50;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .5rem;
  max-width: var(--max);
  margin: 0 auto;
  padding: .9rem 1.5rem;
  border-top: 1px solid rgba(243, 237, 226, .08);
  border-bottom: 1px solid rgba(243, 237, 226, .08);
  background: rgba(10, 13, 18, .66);
  backdrop-filter: blur(14px);
}

.section-index a {
  padding: .45rem .7rem;
  color: var(--warm-gray);
  font-size: .82rem;
  text-decoration: none;
}

.section-index a:hover {
  color: var(--gold-light);
}

.two-column,
.identity,
.author {
  display: grid;
  grid-template-columns: minmax(260px, .82fr) minmax(0, 1.18fr);
  align-items: start;
  gap: clamp(2rem, 6vw, 5rem);
}

.two-column h2,
.author h2 {
  max-width: 9.5ch;
  font-size: clamp(2.5rem, 4.3vw, 4rem);
  line-height: 1.04;
  overflow-wrap: normal;
}

.copy-block {
  max-width: 760px;
  font-size: 1.08rem;
}

.copy-block strong {
  color: var(--ivory);
}

.project-notes,
.author-notes {
  display: grid;
  gap: .75rem;
  margin-top: 1.35rem;
}

.project-notes {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.project-notes span,
.author-notes span {
  min-width: 0;
  padding: .9rem;
  border: 1px solid rgba(224, 184, 92, .2);
  background: rgba(243, 237, 226, .045);
  color: var(--warm-gray);
  font-size: .9rem;
}

.project-notes strong {
  display: block;
  margin-bottom: .25rem;
  color: var(--gold-light);
  font-family: var(--mono);
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .12em;
}

.thesis {
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: linear-gradient(135deg, rgba(200, 155, 60, .1), rgba(6, 182, 212, .06));
}

.thesis::before {
  position: absolute;
  inset: 10% auto auto 58%;
  width: 22rem;
  height: 22rem;
  content: "";
  background: radial-gradient(circle, rgba(6, 182, 212, .16), transparent 68%);
  filter: blur(8px);
  pointer-events: none;
}

.thesis-shell {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}

.thesis blockquote {
  max-width: 860px;
  color: var(--ivory);
  font-family: var(--display);
  font-size: clamp(2.2rem, 4vw, 4rem);
  line-height: 1.08;
}

.thesis-support {
  max-width: 720px;
  margin-bottom: 0;
  color: var(--warm-gray);
  font-size: 1.08rem;
}

.thesis-points {
  display: grid;
  gap: .8rem;
}

.thesis-points article {
  position: relative;
  min-width: 0;
  padding: 1rem;
  border: 1px solid rgba(243, 237, 226, .12);
  background: rgba(10, 13, 18, .46);
  transition: transform .22s ease, border-color .22s ease, background .22s ease;
}

.thesis-points article:hover,
.thesis-points article:focus-visible {
  transform: translateX(8px);
  border-color: rgba(224, 184, 92, .56);
  background: rgba(200, 155, 60, .11);
}

.thesis-points span {
  color: var(--cyan);
  font-family: var(--mono);
  font-size: .72rem;
  font-weight: 800;
}

.thesis-points strong {
  display: block;
  margin: .35rem 0 .25rem;
  color: var(--ivory);
  font-size: 1.05rem;
}

.thesis-points p {
  margin-bottom: 0;
  color: var(--warm-gray);
  font-size: .94rem;
}

.section-heading {
  max-width: 840px;
  margin-bottom: 2.2rem;
}

.timeline,
.profile-grid,
.topic-grid,
.part-grid,
.tool-grid,
.doc-grid,
.difference-grid,
.explore-grid {
  display: grid;
  gap: 1rem;
}

.timeline {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.timeline article,
.profile-grid article,
.part-grid article,
.tool-grid article,
.difference-grid article,
.release-tabs,
.doc-grid article,
.explore-grid a {
  position: relative;
  min-width: 0;
  border: 1px solid rgba(243, 237, 226, .11);
  background: linear-gradient(150deg, var(--panel), rgba(15, 23, 42, .42));
  box-shadow: 0 18px 50px rgba(0, 0, 0, .2);
  transition: transform .22s ease, border-color .22s ease, background .22s ease;
}

.timeline article,
.profile-grid article,
.part-grid article,
.tool-grid article,
.difference-grid article,
.doc-grid article {
  padding: 1.1rem;
}

.timeline article:hover,
.profile-grid article:hover,
.part-grid article:hover,
.tool-grid article:hover,
.difference-grid article:hover,
.explore-grid a:hover {
  transform: translateY(-4px);
  border-color: rgba(224, 184, 92, .48);
  background: linear-gradient(150deg, rgba(31, 41, 55, .82), rgba(15, 23, 42, .5));
}

.timeline span,
.part-grid small,
.doc-grid span,
.explore-grid span {
  display: inline-flex;
  margin-bottom: .8rem;
  color: var(--cyan);
  font-family: var(--mono);
  font-size: .74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .12em;
}

.timeline p,
.profile-grid p,
.part-grid p,
.tool-grid p,
.difference-grid p,
.explore-grid em {
  margin-bottom: 0;
  color: var(--warm-gray);
  font-size: .94rem;
}

.profile-grid,
.tool-grid,
.difference-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.topic-grid {
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.topic-grid span {
  display: grid;
  min-height: 86px;
  place-items: center;
  padding: .9rem;
  border: 1px solid rgba(6, 182, 212, .24);
  background: rgba(6, 182, 212, .065);
  color: var(--ivory);
  font-family: var(--mono);
  font-size: .78rem;
  text-align: center;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-bottom: 1rem;
}

.metrics strong {
  padding: 1.2rem;
  border: 1px solid var(--line);
  background: rgba(200, 155, 60, .08);
  color: var(--warm-gray);
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: .1em;
}

.metrics span {
  display: block;
  color: var(--gold-light);
  font-family: var(--display);
  font-size: 4rem;
  line-height: .85;
  letter-spacing: 0;
}

.part-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.appendix-strip {
  display: flex;
  flex-wrap: wrap;
  gap: .7rem;
  margin-top: 1rem;
}

.appendix-strip span {
  padding: .7rem .9rem;
  border: 1px solid rgba(34, 197, 94, .28);
  background: rgba(34, 197, 94, .07);
  color: #dffbea;
  font-family: var(--mono);
  font-size: .82rem;
}

.pipeline {
  display: flex;
  flex-wrap: wrap;
  gap: .65rem;
  margin: 0 0 1.4rem;
  padding: 0;
  list-style: none;
}

.pipeline li {
  position: relative;
  padding: .72rem .9rem;
  border: 1px solid rgba(243, 237, 226, .12);
  background: rgba(243, 237, 226, .055);
  color: var(--ivory);
  font-family: var(--mono);
  font-size: .78rem;
}

.pipeline li:not(:last-child)::after {
  content: "→";
  margin-left: .65rem;
  color: var(--gold-light);
}

.release-tabs {
  max-width: 820px;
  padding: 1rem;
}

.tab-list {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-bottom: 1rem;
}

.tab-list button {
  min-height: 42px;
  padding: .65rem .9rem;
  border: 1px solid rgba(243, 237, 226, .13);
  border-radius: 999px;
  background: rgba(243, 237, 226, .06);
  color: var(--warm-gray);
  cursor: pointer;
  font-weight: 800;
}

.tab-list button[aria-selected="true"] {
  border-color: rgba(224, 184, 92, .7);
  background: rgba(200, 155, 60, .18);
  color: var(--gold-light);
}

.tab-panel {
  padding: 1rem;
  border: 1px solid rgba(243, 237, 226, .08);
  background: rgba(10, 13, 18, .36);
}

.visual-mosaic {
  position: relative;
  overflow: visible;
  margin: 0;
  padding: .7rem;
  border: 1px solid rgba(224, 184, 92, .28);
  background:
    linear-gradient(135deg, rgba(224, 184, 92, .16), transparent 34%),
    linear-gradient(160deg, rgba(15, 23, 42, .8), rgba(10, 13, 18, .92));
  box-shadow: var(--shadow);
}

.visual-mosaic img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: clamp(420px, calc(100vh - 230px), 680px);
  margin: 0 auto;
  aspect-ratio: 1122 / 1402;
  border: 1px solid rgba(243, 237, 226, .12);
  object-fit: contain;
}

.visual-mosaic figcaption {
  padding: .9rem 1rem 1rem;
  border-top: 1px solid rgba(243, 237, 226, .12);
  background: rgba(10, 13, 18, .52);
  color: var(--warm-gray);
  font-size: .86rem;
  line-height: 1.45;
}

.doc-grid,
.explore-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.doc-grid article,
.explore-grid a {
  display: flex;
  min-height: 170px;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.1rem;
  text-decoration: none;
}

.doc-grid strong,
.explore-grid strong {
  display: block;
  color: var(--ivory);
  font-size: 1.05rem;
}

.explore-grid em {
  display: block;
  font-style: normal;
}

.signature {
  color: var(--gold-light);
  font-family: var(--mono);
  font-weight: 800;
}

.author-copy {
  padding-top: .35rem;
}

.author-notes {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.author-notes span {
  color: var(--ivory);
  font-family: var(--mono);
  font-size: .74rem;
  text-transform: uppercase;
  letter-spacing: .1em;
}

.site-footer {
  max-width: var(--max);
  margin: 0 auto;
  padding: 4rem 1.5rem 5rem;
  border-top: 1px solid rgba(243, 237, 226, .12);
}

.site-footer p {
  max-width: 720px;
}

.support-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 760px;
  margin: 1.35rem 0 1.2rem;
  padding: 1rem;
  border: 1px solid rgba(224, 184, 92, .28);
  background: rgba(200, 155, 60, .075);
}

.support-box span {
  display: block;
  color: var(--warm-gray);
  font-size: .86rem;
}

.support-box strong {
  display: block;
  color: var(--ivory);
  font-family: var(--mono);
  overflow-wrap: anywhere;
}

.support-box em {
  display: block;
  max-width: 48ch;
  margin-top: .45rem;
  color: var(--gold-light);
  font-style: normal;
  font-size: .9rem;
  line-height: 1.45;
}

.site-footer nav {
  flex-wrap: wrap;
  gap: .8rem;
}

.site-footer a {
  color: var(--gold-light);
  text-decoration: none;
}

[data-reveal] {
  transform: none;
  opacity: 1;
}

[data-reveal].is-visible {
  animation: reveal-in .65s ease both;
}

@keyframes reveal-in {
  from {
    transform: translateY(14px);
    opacity: 1;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }

  [data-reveal] {
    transform: none;
    opacity: 1;
  }
}

@media (max-width: 1080px) {
  .hero,
  .two-column,
  .identity,
  .author,
  .thesis-shell {
    grid-template-columns: 1fr;
  }

  .timeline,
  .topic-grid,
  .part-grid,
  .doc-grid,
  .explore-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .two-column h2,
  .author h2 {
    max-width: 12ch;
  }
}

@media (max-width: 780px) {
  .site-header {
    position: relative;
    align-items: flex-start;
    flex-direction: column;
  }

  .top-nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, max-content));
    width: 100%;
    gap: .2rem;
    overflow-x: visible;
    padding-bottom: .2rem;
  }

  .top-nav a {
    padding: .45rem .55rem;
    font-size: .82rem;
  }

  .section,
  .section-frame {
    width: 100%;
    max-width: 100vw;
    padding: 4.5rem 1rem;
  }

  .hero {
    min-height: auto;
    padding-top: 2rem;
  }

  .hero-copy,
  .hero-support,
  .hero-note {
    width: 100%;
    max-width: calc(100vw - 3rem);
  }

  .hero-actions {
    width: 100%;
    max-width: calc(100vw - 3rem);
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: clamp(2.75rem, 13vw, 4rem);
  }

  .section-index {
    position: relative;
    top: auto;
    justify-content: flex-start;
    overflow-x: auto;
  }

  .profile-grid,
  .tool-grid,
  .difference-grid,
  .project-notes,
  .author-notes,
  .metrics {
    grid-template-columns: 1fr;
  }

  .visual-mosaic {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .brand span {
    max-width: 220px;
  }

  .hero-copy,
  .hero-support,
  .hero-note,
  .hero-actions {
    max-width: 31ch;
  }

  .hero-support,
  .hero-note {
    font-size: 1rem;
  }

  .hero-actions {
    align-items: stretch;
  }

  .button {
    width: 100%;
    text-align: center;
  }

  .support-box {
    align-items: stretch;
    flex-direction: column;
  }

  .timeline,
  .topic-grid,
  .part-grid,
  .doc-grid,
  .explore-grid {
    grid-template-columns: 1fr;
  }

  .metrics span {
    font-size: 3rem;
  }
}
