/* ==========================================================================
   CLV — Site público: cabeçalho, hero, rodapé e páginas
   ========================================================================== */

/* --------------------------------------------------------------------------
   Cabeçalho
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  background: rgba(15, 23, 42, 0.86);
  /* Glassmorphism leve: só aqui, sobre o banner. */
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* Navegador sem suporte a backdrop-filter recebe o fundo sólido. */
@supports not (backdrop-filter: blur(1px)) {
  .site-header {
    background: var(--clv-navy);
  }
}

.site-header__inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  color: var(--clv-white);
  flex-shrink: 0;
}

.brand:hover {
  color: var(--clv-white);
}

.brand__mark {
  /* O escudo é levemente mais alto que largo (128×137). */
  height: 42px;
  width: auto;
  flex-shrink: 0;
}

.brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand__abbr {
  font-size: var(--text-lg);
  font-weight: 800;
  letter-spacing: var(--tracking-tight);
}

.brand__full {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

/* Navegação — desktop */
.nav {
  display: none;
  align-items: center;
  gap: var(--space-1);
}

@media (min-width: 1024px) {
  .nav {
    display: flex;
  }
}

.nav__link {
  position: relative;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-on-dark-muted);
  transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}

.nav__link:hover {
  color: var(--clv-white);
  background: rgba(255, 255, 255, 0.07);
}

.nav__link.is-active {
  color: var(--clv-white);
}

/* Sublinhado do item ativo. */
.nav__link.is-active::after {
  content: '';
  position: absolute;
  left: var(--space-3);
  right: var(--space-3);
  bottom: -1px;
  height: 2px;
  border-radius: 2px;
  background: var(--clv-blue-400);
}

/* Botão hambúrguer */
.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius);
  color: var(--clv-white);
  background: rgba(255, 255, 255, 0.08);
  transition: background var(--dur) var(--ease);
}

.nav-toggle:hover {
  background: rgba(255, 255, 255, 0.16);
}

.nav-toggle svg {
  width: 22px;
  height: 22px;
}

.nav-toggle__close {
  display: none;
}

.nav-toggle[aria-expanded='true'] .nav-toggle__open {
  display: none;
}

.nav-toggle[aria-expanded='true'] .nav-toggle__close {
  display: block;
}

@media (min-width: 1024px) {
  .nav-toggle {
    display: none;
  }
}

/* Menu mobile */
.mobile-nav {
  position: fixed;
  inset: var(--header-h) 0 0 0;
  z-index: var(--z-overlay);
  background: var(--clv-navy);
  padding: var(--space-6) var(--gutter) var(--space-10);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  transform: translateX(100%);
  visibility: hidden;
  transition: transform var(--dur-slow) var(--ease-out), visibility var(--dur-slow);
}

.mobile-nav.is-open {
  transform: translateX(0);
  visibility: visible;
}

@media (min-width: 1024px) {
  .mobile-nav {
    display: none;
  }
}

.mobile-nav__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-4) var(--space-2);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--text-on-dark-muted);
}

.mobile-nav__link:hover,
.mobile-nav__link.is-active {
  color: var(--clv-white);
}

.mobile-nav__link svg {
  width: 18px;
  height: 18px;
  opacity: 0.4;
}

/* Trava a rolagem do fundo com o menu aberto. */
body.nav-open {
  overflow: hidden;
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  background: var(--clv-navy);
  color: var(--clv-white);
  overflow: hidden;
  isolation: isolate;
}

/* Malha de gradientes: dá profundidade sem depender de imagem. */
.hero::before {
  content: '';
  position: absolute;
  inset: -30% -10% auto -10%;
  height: 150%;
  background:
    radial-gradient(60% 55% at 78% 18%, rgba(37, 99, 235, 0.45), transparent 62%),
    radial-gradient(48% 48% at 12% 82%, rgba(96, 165, 250, 0.22), transparent 66%);
  z-index: -1;
  pointer-events: none;
}

/* Linhas diagonais discretas, referência à marcação de quadra. */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    115deg,
    rgba(255, 255, 255, 0.03) 0px,
    rgba(255, 255, 255, 0.03) 1px,
    transparent 1px,
    transparent 42px
  );
  z-index: -1;
  pointer-events: none;
}

.hero__inner {
  padding-block: var(--space-16) var(--space-20);
  max-width: 720px;
}

@media (min-width: 768px) {
  .hero__inner {
    padding-block: var(--space-24);
  }
}

.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--clv-white);
  margin-bottom: var(--space-6);
  white-space: nowrap;
}

.hero__eyebrow svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

.hero__title {
  font-size: clamp(2.25rem, 7vw, 3.75rem);
  font-weight: 800;
  line-height: 1.03;
  letter-spacing: -0.03em;
  color: var(--clv-white);
  margin-bottom: var(--space-5);
}

.hero__title em {
  font-style: normal;
  color: var(--clv-blue-400);
}

.hero__lead {
  font-size: var(--text-lg);
  line-height: var(--leading-normal);
  color: var(--text-on-dark-muted);
  margin-bottom: var(--space-8);
  max-width: 54ch;
}

.hero__actions {
  display: flex;
  gap: var(--space-3);
  flex-wrap: wrap;
}

/* Faixa de números logo abaixo do hero. */
.hero-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--border);
  border-block: 1px solid var(--border);
}

@media (min-width: 768px) {
  .hero-stats {
    grid-template-columns: repeat(4, 1fr);
  }
}

.hero-stat {
  background: var(--bg-surface);
  padding: var(--space-6) var(--space-4);
  text-align: center;
}

.hero-stat__value {
  display: block;
  font-size: var(--text-3xl);
  font-weight: 800;
  color: var(--text-strong);
  letter-spacing: var(--tracking-tight);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.hero-stat__label {
  display: block;
  margin-top: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   Cabeçalho interno das páginas
   -------------------------------------------------------------------------- */

.page-head {
  background: var(--clv-navy);
  color: var(--clv-white);
  padding-block: var(--space-10) var(--space-12);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.page-head::before {
  content: '';
  position: absolute;
  inset: -50% -20% auto auto;
  width: 60%;
  height: 200%;
  background: radial-gradient(closest-side, rgba(37, 99, 235, 0.4), transparent);
  z-index: -1;
}

.page-head__title {
  font-size: clamp(1.75rem, 5vw, var(--text-3xl));
  color: var(--clv-white);
  margin-bottom: var(--space-2);
}

.page-head__lead {
  color: var(--text-on-dark-muted);
  font-size: var(--text-md);
  max-width: 60ch;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--text-on-dark-muted);
  margin-bottom: var(--space-4);
  flex-wrap: wrap;
}

.breadcrumb a {
  color: var(--text-on-dark-muted);
}

.breadcrumb a:hover {
  color: var(--clv-white);
}

.breadcrumb svg {
  width: 13px;
  height: 13px;
  opacity: 0.5;
}

/* --------------------------------------------------------------------------
   Home — duas classificações lado a lado
   -------------------------------------------------------------------------- */

.split-2 {
  display: grid;
  gap: var(--space-8);
  grid-template-columns: 1fr;
}

@media (min-width: 1024px) {
  .split-2 {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-6);
  }
}

/* Versão compacta da tabela usada na home. */
.standings--compact {
  min-width: 460px;
  font-size: var(--text-sm);
}

.standings--compact thead th,
.standings--compact tbody td {
  padding: var(--space-2) var(--space-2);
}

/* --------------------------------------------------------------------------
   Página do time
   -------------------------------------------------------------------------- */

.team-hero {
  display: flex;
  align-items: center;
  gap: var(--space-6);
  flex-wrap: wrap;
}

.team-hero__crest {
  width: 96px;
  height: 96px;
  object-fit: contain;
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .team-hero__crest {
    width: 128px;
    height: 128px;
  }
}

.team-photo {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--clv-gray-100);
}

/* Elenco */
.roster {
  display: grid;
  gap: var(--space-3);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr));
}

.player {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3);
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}

.player:hover {
  border-color: var(--clv-gray-300);
  box-shadow: var(--shadow-xs);
}

.player__number {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: var(--radius-sm);
  background: var(--clv-navy);
  color: var(--clv-white);
  font-weight: 800;
  font-size: var(--text-md);
  font-variant-numeric: tabular-nums;
}

.player__photo {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: var(--clv-gray-100);
}

.player__info {
  min-width: 0;
}

.player__name {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-strong);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.player__position {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* Comissão técnica */
.staff {
  display: grid;
  gap: var(--space-3);
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.staff__item {
  padding: var(--space-4);
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.staff__role {
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-1);
}

.staff__name {
  font-size: var(--text-md);
  font-weight: 600;
  color: var(--text-strong);
}

/* --------------------------------------------------------------------------
   Notícia — corpo do texto
   -------------------------------------------------------------------------- */

.article {
  font-size: var(--text-md);
  line-height: var(--leading-relaxed);
  color: var(--text-body);
}

.article > * + * {
  margin-top: var(--space-5);
}

.article h2 {
  font-size: var(--text-xl);
  margin-top: var(--space-10);
}

.article h3 {
  font-size: var(--text-lg);
  margin-top: var(--space-8);
}

.article ul,
.article ol {
  padding-left: var(--space-6);
}

.article li + li {
  margin-top: var(--space-2);
}

.article blockquote {
  border-left: 3px solid var(--accent);
  padding-left: var(--space-5);
  color: var(--text-strong);
  font-size: var(--text-lg);
  font-style: italic;
}

.article a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.article__cover {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-8);
}

/* --------------------------------------------------------------------------
   Patrocinadores
   -------------------------------------------------------------------------- */

.sponsors {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-6) var(--space-10);
}

.sponsor {
  display: grid;
  place-items: center;
  min-width: 120px;
  min-height: 56px;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius);
  color: var(--text-muted);
  font-weight: 600;
  font-size: var(--text-sm);
  text-align: center;
  /* Logos coloridos distraem numa faixa: cor só no hover. */
  filter: grayscale(1);
  opacity: 0.7;
  transition: filter var(--dur) var(--ease), opacity var(--dur) var(--ease);
}

.sponsor:hover {
  filter: grayscale(0);
  opacity: 1;
}

.sponsor img {
  max-height: 52px;
  width: auto;
  object-fit: contain;
}

/* --------------------------------------------------------------------------
   Rodapé
   -------------------------------------------------------------------------- */

.site-footer {
  margin-top: auto;
  background: var(--clv-navy);
  color: var(--text-on-dark-muted);
  padding-block: var(--space-12) var(--space-6);
  font-size: var(--text-sm);
}

.site-footer__grid {
  display: grid;
  gap: var(--space-8);
  grid-template-columns: 1fr;
  padding-bottom: var(--space-8);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 768px) {
  .site-footer__grid {
    grid-template-columns: 1.6fr 1fr 1fr;
    gap: var(--space-10);
  }
}

.site-footer h4 {
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--clv-white);
  margin-bottom: var(--space-4);
}

.site-footer a {
  color: var(--text-on-dark-muted);
}

.site-footer a:hover {
  color: var(--clv-white);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer-about p {
  max-width: 46ch;
  line-height: var(--leading-normal);
  margin-top: var(--space-4);
}

.socials {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-5);
}

.social {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
  color: var(--clv-white);
  transition: background var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.social:hover {
  background: var(--accent);
  color: var(--clv-white);
  transform: translateY(-2px);
}

.social svg {
  width: 18px;
  height: 18px;
}

.site-footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
  padding-top: var(--space-6);
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.5);
}
