/* ==========================================================================
   Espaço SAE — Sistema de Design
   ========================================================================== */

/* ---------- Reset básico ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
}

body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a { color: inherit; text-decoration: none; }

ul[role="list"], ol[role="list"] { list-style: none; }

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

input, textarea {
  font: inherit;
  color: inherit;
}

/* ---------- Tokens ---------- */
:root {
  /* Bases */
  --color-bg:          #FFFFFF;
  --color-bg-soft:     #F4F8FB;
  --color-bg-dark:     #0A1628;

  /* Marca */
  --color-sae:         #00AEEF;
  --color-sae-dark:    #007AB8;
  --color-sae-ghost:   #E8F6FD;

  /* Texto */
  --color-text:        #1C2B3A;
  --color-text-mid:    #4A6074;
  --color-text-light:  #7A92A6;
  --color-text-invert: #F4F8FB;

  /* Bordas e divisores */
  --color-border:      #E0EBF3;

  /* Estados */
  --color-success:     #1B7A4E;
  --color-error:       #B91C1C;

  /* Tipografia */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;

  --text-sm:   0.875rem;
  --text-base: 1rem;
  --text-lg:   1.125rem;
  --text-xl:   1.25rem;
  --text-2xl:  1.5rem;
  --text-3xl:  1.875rem;
  --text-4xl:  2.25rem;
  --text-5xl:  3rem;
  --text-6xl:  3.75rem;

  /* Espaçamento */
  --space-xs:   0.5rem;
  --space-sm:   1rem;
  --space-md:   1.5rem;
  --space-lg:   2.5rem;
  --space-xl:   4rem;
  --space-2xl:  6rem;
  --space-3xl:  8rem;

  /* Bordas e sombras */
  --radius-sm:  4px;
  --radius-md:  8px;
  --radius-lg:  16px;
  --radius-xl:  24px;

  --shadow-xs:  0 1px 2px rgba(0, 100, 160, 0.06);
  --shadow-sm:  0 2px 8px rgba(0, 100, 160, 0.08);
  --shadow-md:  0 4px 24px rgba(0, 100, 160, 0.10);

  --container-max: 1200px;
}

/* ---------- Base tipográfica ---------- */
body {
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  color: var(--color-text);
}

h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }

@media (min-width: 768px) {
  h1 { font-size: var(--text-6xl); }
  h2 { font-size: var(--text-4xl); }
  h3 { font-size: var(--text-2xl); }
}

p {
  max-width: 68ch;
  line-height: 1.75;
  color: var(--color-text-mid);
}

.lede {
  font-size: var(--text-lg);
  color: var(--color-text-mid);
  font-weight: 300;
}

article p + p,
article p + h2,
article p + h3,
section p + p {
  margin-top: var(--space-sm);
}

article h2, section h2 { margin-bottom: var(--space-md); }
article h3, section h3 { margin-bottom: var(--space-xs); margin-top: var(--space-md); }

strong { font-weight: 600; }

/* ---------- Layout utilitário ---------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-sm);
}

@media (min-width: 768px) {
  .container { padding-inline: var(--space-lg); }
}

.section {
  padding-block: var(--space-xl);
}

@media (min-width: 768px) {
  .section { padding-block: var(--space-2xl); }
}

.section--soft { background: var(--color-bg-soft); }
.section--dark { background: var(--color-bg-dark); color: var(--color-text-invert); }
.section--dark h2, .section--dark h3 { color: #FFFFFF; }
.section--dark p { color: rgba(244, 248, 251, 0.82); }

.section-intro {
  max-width: 68ch;
  margin-inline: auto;
  text-align: center;
  margin-bottom: var(--space-lg);
}

.section-intro h2 { margin-bottom: var(--space-sm); }

.text-center { text-align: center; }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-sae);
  color: #fff;
  padding: var(--space-xs) var(--space-sm);
  z-index: 1000;
  border-radius: 0 0 var(--radius-sm) 0;
}

.skip-link:focus {
  left: 0;
}

/* ---------- Foco visível ---------- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--color-sae-dark);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* ---------- Botões / CTAs ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  padding: 0.875rem 1.75rem;
  background: var(--color-sae);
  color: #FFFFFF;
  font-weight: 600;
  font-size: var(--text-base);
  border-radius: var(--radius-md);
  transition: background 200ms ease, transform 200ms ease;
  border: none;
  cursor: pointer;
  white-space: nowrap;
}

.btn:hover { background: var(--color-sae-dark); }
.btn:active { transform: scale(0.98); }

.btn--outline {
  background: transparent;
  color: var(--color-sae-dark);
  border: 1.5px solid var(--color-sae);
}

.btn--outline:hover {
  background: var(--color-sae-ghost);
}

.section--dark .btn--outline {
  color: #FFFFFF;
  border-color: rgba(255,255,255,0.4);
}

.section--dark .btn--outline:hover {
  background: rgba(255,255,255,0.08);
}

.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  align-items: center;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  color: var(--color-sae-dark);
  font-weight: 600;
  border-bottom: 1px solid transparent;
  transition: border-color 200ms ease;
}

.link-arrow:hover { border-color: var(--color-sae-dark); }

/* ---------- Header ---------- */
#site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-border);
}

#site-header nav {
  max-width: var(--container-max);
  margin-inline: auto;
  padding: var(--space-xs) var(--space-sm);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  position: relative;
}

#site-header img { height: 56px; width: 56px; object-fit: contain; }

.menu-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-xs);
  order: 3;
}

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

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  transition: transform 200ms ease, opacity 200ms ease;
}

.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

#menu-principal {
  display: none;
  width: 100%;
  order: 4;
  flex-direction: column;
  gap: var(--space-xs);
  padding-top: var(--space-sm);
  border-top: 1px solid var(--color-border);
  margin-top: var(--space-xs);
}

#menu-principal.aberto { display: flex; }

#menu-principal > li > a,
#menu-principal > li > button {
  display: block;
  width: 100%;
  text-align: left;
  padding: var(--space-xs) 0;
  font-weight: 500;
  font-size: var(--text-base);
}

#menu-principal > li > button {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

#menu-principal > li > button::after {
  content: '+';
  font-size: var(--text-lg);
  color: var(--color-text-light);
}

#menu-principal > li > button[aria-expanded="true"]::after { content: '−'; }

#menu-principal ul {
  display: none;
  padding-left: var(--space-sm);
  border-left: 2px solid var(--color-sae-ghost);
}

#menu-principal li > button[aria-expanded="true"] + ul { display: block; }

#menu-principal ul li a {
  display: block;
  padding: var(--space-xs) 0;
  color: var(--color-text-mid);
}

#menu-principal a:hover,
#menu-principal button:hover {
  color: var(--color-sae-dark);
}

.btn-header-cta {
  order: 2;
  padding: 0.625rem 1.25rem;
  background: var(--color-sae);
  color: #fff;
  font-weight: 600;
  font-size: var(--text-sm);
  border-radius: var(--radius-md);
  transition: background 200ms ease;
}

.btn-header-cta:hover { background: var(--color-sae-dark); }

@media (min-width: 1024px) {
  #site-header nav { padding: var(--space-sm) var(--space-lg); }

  #menu-principal {
    display: flex;
    flex-direction: row;
    width: auto;
    order: 2;
    border: none;
    padding: 0;
    margin: 0;
    align-items: center;
    gap: var(--space-md);
  }

  #menu-principal > li { position: relative; }

  #menu-principal > li > a,
  #menu-principal > li > button {
    width: auto;
    padding: var(--space-xs) 0;
    font-size: var(--text-sm);
  }

  #menu-principal > li > button::after { content: '▾'; font-size: 0.6em; }

  #menu-principal ul {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background: #fff;
    border: 1px solid var(--color-border);
    border-left: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    padding: var(--space-xs);
    opacity: 0;
    pointer-events: none;
    transform: translateY(6px);
    transition: opacity 200ms ease, transform 200ms ease;
  }

  #menu-principal li > button[aria-expanded="true"] + ul {
    display: block;
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  #menu-principal ul li a { padding: var(--space-xs) var(--space-xs); border-radius: var(--radius-sm); }
  #menu-principal ul li a:hover { background: var(--color-sae-ghost); }

  .btn-header-cta { order: 3; }
}

/* ---------- Modal WhatsApp ---------- */
#modal-whatsapp[hidden] { display: none; }

#modal-whatsapp {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-sm);
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 22, 40, 0.55);
}

.modal-box {
  position: relative;
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: var(--space-lg);
  max-width: 440px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-box h2 {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-xs);
}

.modal-box > p {
  margin-bottom: var(--space-md);
  color: var(--color-text-mid);
}

.modal-fechar {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  font-size: var(--text-2xl);
  line-height: 1;
  color: var(--color-text-light);
  padding: var(--space-xs);
}

.modal-fechar:hover { color: var(--color-text); }

#form-whatsapp {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

#form-whatsapp label {
  display: block;
  font-size: var(--text-sm);
  font-weight: 500;
  margin-bottom: 0.35rem;
}

#form-whatsapp input[type="text"],
#form-whatsapp input[type="tel"] {
  width: 100%;
  padding: 0.75rem var(--space-sm);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg-soft);
}

#form-whatsapp input[type="text"]:focus,
#form-whatsapp input[type="tel"]:focus {
  outline: 2px solid var(--color-sae);
  outline-offset: 1px;
  background: #fff;
}

.lgpd-label {
  display: flex !important;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: var(--text-sm);
  font-weight: 400 !important;
  color: var(--color-text-mid);
}

.lgpd-label input { margin-top: 3px; }
.lgpd-label a { color: var(--color-sae-dark); text-decoration: underline; }

#form-whatsapp button[type="submit"] {
  margin-top: var(--space-xs);
  padding: 0.875rem;
  background: var(--color-sae);
  color: #fff;
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: background 200ms ease;
}

#form-whatsapp button[type="submit"]:hover { background: var(--color-sae-dark); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding-block: var(--space-2xl) var(--space-xl);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: -2;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10,22,40,0.55) 0%, rgba(10,22,40,0.35) 55%, rgba(10,22,40,0.65) 100%);
}

@media (min-width: 768px) {
  .hero-bg { background-attachment: fixed; }
}

.hero--imagem { color: #fff; min-height: 60vh; display: flex; align-items: center; }
.hero--imagem h1 { color: #fff; }
.hero--imagem .lede { color: rgba(255,255,255,0.9); }
.hero--imagem p:not(.lede) { color: rgba(255,255,255,0.85); }

.hero-conteudo { max-width: 640px; }
.hero-conteudo h1 { margin-bottom: var(--space-sm); }
.hero-conteudo .lede { margin-bottom: var(--space-sm); }
.hero-conteudo > p { margin-bottom: var(--space-md); }

.hero--simples {
  background: var(--color-bg-soft);
  padding-block: var(--space-xl);
}

.hero--simples .hero-conteudo { max-width: 68ch; }

/* ---------- Cards ---------- */
.grid-cards {
  display: grid;
  gap: var(--space-md);
  grid-template-columns: 1fr;
  margin-top: var(--space-lg);
}

@media (min-width: 768px) {
  .grid-cards--3 { grid-template-columns: repeat(3, 1fr); }
  .grid-cards--2 { grid-template-columns: repeat(2, 1fr); }
}

.card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.card h3 { margin: 0; }
.card p { margin-bottom: var(--space-xs); }
.card .link-arrow { margin-top: auto; }

/* ---------- FAQ ---------- */
.faq-lista { margin-top: var(--space-lg); }

.faq-item {
  border-bottom: 1px solid var(--color-border);
}

.faq-pergunta {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding: var(--space-sm) 0;
  text-align: left;
  font-weight: 600;
  font-size: var(--text-lg);
  color: var(--color-text);
}

.faq-pergunta::after {
  content: '+';
  flex-shrink: 0;
  font-size: var(--text-xl);
  color: var(--color-sae-dark);
}

.faq-pergunta[aria-expanded="true"]::after { content: '−'; }

.faq-resposta {
  padding-bottom: var(--space-sm);
}

.faq-resposta[hidden] { display: none; }

/* ---------- Timeline (DRT) ---------- */
.timeline {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
}

@media (min-width: 768px) {
  .timeline { flex-direction: row; align-items: stretch; }
}

.timeline-passo {
  flex: 1;
  background: var(--color-bg-soft);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  position: relative;
  text-align: center;
}

.timeline-passo .num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--color-sae);
  color: #fff;
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

@media (min-width: 768px) {
  .timeline-passo:not(:last-child)::after {
    content: '→';
    position: absolute;
    right: -1.4rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-text-light);
    font-size: var(--text-xl);
  }
}

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  padding-block: var(--space-sm);
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  font-size: var(--text-sm);
  color: var(--color-text-light);
}

.breadcrumb a { color: var(--color-text-mid); }
.breadcrumb a:hover { color: var(--color-sae-dark); }
.breadcrumb li:not(:last-child)::after { content: '/'; margin-left: 0.4rem; color: var(--color-text-light); }

/* ---------- Mapa ---------- */
.mapa-container {
  height: 280px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--color-border);
  margin-top: var(--space-md);
}

@media (min-width: 768px) {
  .mapa-container { height: 400px; }
}

/* ---------- Localização / endereço ---------- */
.localizacao-grid {
  display: grid;
  gap: var(--space-lg);
  margin-top: var(--space-lg);
}

@media (min-width: 1024px) {
  .localizacao-grid { grid-template-columns: 1fr 1.3fr; align-items: start; }
}

address {
  font-style: normal;
  color: var(--color-text-mid);
  line-height: 1.9;
}

.horarios-lista {
  margin-top: var(--space-md);
  border-top: 1px solid var(--color-border);
  padding-top: var(--space-md);
}

.horarios-lista dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.4rem var(--space-sm);
  font-size: var(--text-sm);
}

.horarios-lista dt { color: var(--color-text); font-weight: 500; }
.horarios-lista dd { color: var(--color-text-mid); }

/* ---------- Formulário de contato ---------- */
.form-contato {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  max-width: 480px;
}

.form-contato label {
  display: block;
  font-size: var(--text-sm);
  font-weight: 500;
  margin-bottom: 0.35rem;
}

.form-contato input[type="text"],
.form-contato input[type="tel"] {
  width: 100%;
  padding: 0.75rem var(--space-sm);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg-soft);
}

/* ---------- Cidades: lista cruzada ---------- */
.outras-cidades {
  margin-top: var(--space-lg);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
}

.outras-cidades h2 { font-size: var(--text-xl); margin-bottom: var(--space-sm); }

.outras-cidades ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem var(--space-sm);
  font-size: var(--text-sm);
}

.outras-cidades a { color: var(--color-sae-dark); }
.outras-cidades a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */
footer {
  background: var(--color-bg-dark);
  color: rgba(244, 248, 251, 0.75);
  padding-block: var(--space-xl) var(--space-md);
}

.footer-inner {
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-sm);
  display: grid;
  gap: var(--space-lg);
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .footer-inner {
    padding-inline: var(--space-lg);
    grid-template-columns: 1fr 1.2fr 1fr;
  }
}

.footer-marca img { height: 48px; width: 48px; margin-bottom: var(--space-xs); }
.footer-marca p { color: rgba(244, 248, 251, 0.6); font-size: var(--text-sm); }

footer nav ul {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: var(--text-sm);
}

footer nav a:hover { color: #fff; }

footer address a { color: rgba(244, 248, 251, 0.85); }
footer address a:hover { color: #fff; }

.footer-horarios p {
  font-size: var(--text-sm);
  color: rgba(244, 248, 251, 0.7);
  max-width: none;
}

.footer-bottom {
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-sm);
  margin-top: var(--space-lg);
  padding-top: var(--space-md);
  border-top: 1px solid rgba(244, 248, 251, 0.12);
  font-size: var(--text-sm);
  color: rgba(244, 248, 251, 0.5);
}

@media (min-width: 768px) {
  .footer-bottom { padding-inline: var(--space-lg); }
}

/* ---------- Figuras ---------- */
figure { margin: 0; }

figcaption {
  font-size: var(--text-sm);
  color: var(--color-text-light);
  margin-top: var(--space-xs);
}

.img-rounded img {
  border-radius: var(--radius-lg);
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* ---------- Utilitários (substituem estilos inline, exigido pela CSP sem 'unsafe-inline') ---------- */
.hp-field { display: none; }

.u-prose-60 { max-width: 60ch; margin-inline: auto; }
.u-prose-68 { max-width: 68ch; }
.u-prose-72 { max-width: 72ch; }
.u-prose-800 { max-width: 800px; margin-inline: auto; }

.u-mt-sm { margin-top: var(--space-sm); }
.u-mt-md { margin-top: var(--space-md); }
.u-mt-lg { margin-top: var(--space-lg); }
.u-mb-0 { margin-bottom: 0; }
.u-m-0 { margin: 0; }
.u-center { justify-content: center; }
.u-text-lg { font-size: var(--text-lg); }

.localizacao-grid--single { grid-template-columns: 1fr; }

/* ---------- Imagens de hero (fundo), por página ---------- */
.hero-bg--home { background-image: url('/assets/img/hero-home.webp'); }
.hero-bg--teatro { background-image: url('/assets/img/hero-teatro.webp'); }
.hero-bg--drt { background-image: url('/assets/img/hero-drt.webp'); }
.hero-bg--danca { background-image: url('/assets/img/hero-danca.webp'); }
.hero-bg--espaco-arte { background-image: url('/assets/img/hero-espaco-arte.webp'); }
.hero-bg--espaco-saude { background-image: url('/assets/img/hero-espaco-saude.webp'); }
.hero-bg--espiritualidade { background-image: url('/assets/img/hero-espiritualidade.webp'); }
.hero-bg--coworking { background-image: url('/assets/img/hero-coworking.webp'); }
.hero-bg--sobre { background-image: url('/assets/img/hero-sobre.webp'); }

/* ---------- Elementos sobre imagem de hero ---------- */
.hero--imagem .breadcrumb a,
.hero--imagem .breadcrumb li { color: rgba(255, 255, 255, 0.85); }
.hero--imagem .breadcrumb li:not(:last-child)::after { color: rgba(255, 255, 255, 0.5); }
.hero--imagem .btn--outline { color: #fff; border-color: rgba(255, 255, 255, 0.6); }

/* ---------- Animação de entrada ---------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
