/* ==========================================================================
   CWB Runner — Grid System & Section Layout
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--wide {
  max-width: 1600px;
}

.container--narrow {
  max-width: 1080px;
}

/* Sections — content-visibility: auto causa stutter perceptível ao revelar
   seções com animações cinematográficas. Aplicar só em seções abaixo da dobra
   que não tenham triggers de scroll (footer). */
.section {
  position: relative;
  padding-block: var(--section-y);
}

.section--tight { padding-block: var(--section-y-tight); }
.section--hero { padding-block: 0; min-height: 100vh; }

/* Footer fica abaixo de tudo — pode usar content-visibility com segurança */
.footer {
  content-visibility: auto;
  contain-intrinsic-size: auto 720px;
}

/* 12-col grid */
.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 24px;
}

@media (max-width: 768px) {
  .grid { grid-template-columns: repeat(6, 1fr); gap: 16px; }
}

/* Section anatomy */
.section__header {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 24px;
  margin-bottom: clamp(60px, 8vh, 120px);
}


.section__header .title {
  grid-column: 1 / 9;
}

.section__header .lede {
  grid-column: 9 / -1;
  align-self: end;
  justify-self: end;   /* borda direita flush com a borda direita do carrossel */
  max-width: 40ch;
}

@media (max-width: 968px) {
  .section__header .title,
  .section__header .lede { grid-column: 1 / -1; }
  .section__header .lede {
    margin-top: 24px;
    justify-self: stretch;   /* reseta o end do desktop — estica até a borda */
    max-width: 100%;
  }
}

/* Divider line — ultra suave, técnico */
.divider {
  height: 1px;
  background: var(--line-soft);
  width: 100%;
}

.divider--full {
  margin-inline: calc(var(--gutter) * -1);
}

/* Index marker — para HUD-feel */
.idx {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  color: var(--text-tertiary);
  letter-spacing: 0.06em;
}

/* Decorative corner ticks — usado em seções HUD */
.tick {
  position: absolute;
  width: 12px;
  height: 12px;
  pointer-events: none;
}
.tick::before,
.tick::after {
  content: "";
  position: absolute;
  background: var(--line-strong);
}
.tick::before { width: 100%; height: 1px; }
.tick::after { width: 1px; height: 100%; }

.tick--tl { top: 0; left: 0; }
.tick--tl::before { top: 0; }
.tick--tl::after { left: 0; }

.tick--tr { top: 0; right: 0; }
.tick--tr::before { top: 0; right: 0; }
.tick--tr::after { right: 0; }

.tick--bl { bottom: 0; left: 0; }
.tick--bl::before { bottom: 0; }
.tick--bl::after { left: 0; bottom: 0; }

.tick--br { bottom: 0; right: 0; }
.tick--br::before { bottom: 0; right: 0; }
.tick--br::after { right: 0; bottom: 0; }
