/* ============================================================
   SCROLL ANIMATIONS
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* Hero (dark) */
  --hero-bg:      #0f0f0e;

  /* Sections (light) */
  --bg:           #F4F3F0;
  --bg-alt:       #F4F3F0;

  /* Text on light */
  --text:         #3a3835;
  --text-light:   #1a1916;
  --text-muted:   #8a8679;
  --text-sub:     rgba(30, 28, 26, 0.65);

  /* Hero text (light on dark) */
  --hero-text:        #F4F3F0;
  --hero-text-sub:    rgba(244, 243, 240, 0.80);

  /* Brand */
  --red:          #D50202;
  --border:       rgba(0, 0, 0, 0.10);

  --font-display: 'Fraunces', Georgia, serif;
  --font-body:    'Montserrat', system-ui, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 1rem;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ============================================================
   CONTAINER
   ============================================================ */
.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 2.5rem;
}

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 1.75rem 2.5rem;
  pointer-events: none;
}

.nav__logo {
  display: block;
  line-height: 0;
  opacity: 0;
  pointer-events: none;
}

.nav__logo-img {
  height: 44px;
  width: auto;
  filter: drop-shadow(0 1px 8px rgba(0, 0, 0, 0.7));
}

/* Logo no nav visível após scroll */
body.scrolled .nav {
  pointer-events: auto;
}

body.scrolled .nav__logo {
  opacity: 1;
  pointer-events: auto;
}

/* Logo centralizada no hero */
.hero__logo {
  position: absolute;
  top: 28%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  line-height: 0;
}

.hero__logo-img {
  height: 44px;
  width: auto;
  filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.6));
}

body.scrolled .hero__logo {
  visibility: hidden;
}

/* ============================================================
   HERO (dark)
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-bottom: 10vh;
  text-align: center;
  overflow: hidden;
  background-color: var(--hero-bg);
}

.hero__bg {
  position: absolute;
  inset: 0;
  background: url('Assets/home.jpeg') center 30% / cover no-repeat;
  z-index: 0;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(12, 12, 11, 0.10) 0%,
    rgba(12, 12, 11, 0.30) 40%,
    rgba(12, 12, 11, 0.75) 70%,
    rgba(12, 12, 11, 0.96) 100%
  );
  z-index: 1;
}

.hero__content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 900px;
  padding: 0 2rem;
}

.hero__eyebrow {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(2.6rem, 5.5vw, 4.5rem);
  color: var(--hero-text);
  letter-spacing: -0.01em;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero__title {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.875rem;
  line-height: 1.8;
  letter-spacing: 0.2em;
  color: var(--hero-text-sub);
  text-transform: uppercase;
  white-space: nowrap;
  margin-bottom: 3rem;
}

/* ============================================================
   BUTTON — border-bottom only
   ============================================================ */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.875rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  background: none;
  border: none;
  padding-bottom: 4px;
  cursor: pointer;
  transition: border-color 0.35s ease, color 0.35s ease;
}

/* Botão dentro do hero: claro */
.hero .btn {
  color: var(--hero-text);
  border-bottom: 1px solid rgba(244, 243, 240, 0.30);
}

.hero .btn:hover {
  border-bottom-color: var(--hero-text);
}

/* Botão fora do hero: vermelho sólido */
.section--cta .btn {
  color: #fff;
  background: var(--red);
  border: none;
  padding: 0.75rem 2rem;
  letter-spacing: 0.2em;
}

.section--cta .btn:hover {
  background: #b50000;
}

/* ============================================================
   HERO SCROLL INDICATOR
   ============================================================ */
.hero__scroll {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  font-size: 1rem;
  color: rgba(244, 243, 240, 0.45);
  animation: bounce 2.4s ease-in-out infinite;
  user-select: none;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0);   opacity: 0.45; }
  50%       { transform: translateX(-50%) translateY(8px); opacity: 0.9;  }
}

/* ============================================================
   SECTIONS — BASE (light)
   ============================================================ */
.section {
  padding: 7rem 0;
  background-color: var(--bg);
}

.section--alt {
  background-color: var(--bg-alt);
}

/* duas colunas: label | conteúdo */
.section__grid {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 4rem;
  align-items: start;
}

.section__col-label {
  padding-top: 0.2rem;
}

.section__label {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.55em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.section__col-body {
  font-family: var(--font-body);
  font-size: 1.125rem; /* 18px */
  font-weight: 300;
  line-height: 1.8;
  color: #1A1A1ACC;
  max-width: 45ch;
}

.section__col-body p + p {
  margin-top: 2rem;
}

/* quando o col-body precisa de largura maior (ex: O CÓDIGO) */
.section__col-body--full {
  max-width: 100%;
}

/* ============================================================
   BLOCKQUOTE
   ============================================================ */
.quote {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1.5rem, 2.8vw, 2.2rem);
  line-height: 1.3;
  color: var(--text-light);
  text-align: left;
  margin-bottom: 2rem;
  letter-spacing: -0.01em;
}

/* ============================================================
   A FILOSOFIA
   ============================================================ */
.filosofia__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  width: 100%;
}

.filosofia__artwork {
  height: 100%;
  overflow: hidden;
}

.filosofia__img {
  width: 100%;
  height: 592px;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.filosofia__content {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.filosofia__content .section__label {
  display: block;
  margin-bottom: 2.5rem;
}

.filosofia__content .quote {
  margin-bottom: 2rem;
}

.filosofia__content p {
  font-family: var(--font-body);
  font-size: 1.125rem;
  font-weight: 300;
  line-height: 1.8;
  color: #1A1A1ACC;
  max-width: 45ch;
}

.filosofia__content p + p {
  margin-top: 2rem;
}

.sprezzatura {
  color: var(--text-muted);
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1rem;
  margin-top: 2rem;
  letter-spacing: 0.01em;
}

@media (max-width: 768px) {
  .filosofia__grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .filosofia__img {
    max-width: 320px;
    margin: 0 auto;
  }
}

/* ============================================================
   O MUNDO MAREMMANO
   ============================================================ */
.section--mundo {
  padding-bottom: 0;
  background-color: var(--bg);
}

.mundo__header {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 0 1.5rem 0;
  text-align: left;
}

.mundo__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: 340px 280px 280px;
  gap: 4px;
  max-width: 960px;
  margin: 0 auto;
}

.mundo__card {
  position: relative;
  overflow: hidden;
  cursor: default;
  background-size: cover;
  background-position: center;
}

.mundo__card--span2 {
  grid-column: span 2;
}

.mundo__card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(10, 10, 9, 0.90) 0%,
    rgba(10, 10, 9, 0.30) 55%,
    rgba(10, 10, 9, 0.10) 100%
  );
  transition: background 0.5s ease;
}

.mundo__card:hover .mundo__card-overlay {
  background: linear-gradient(
    to top,
    rgba(10, 10, 9, 0.97) 0%,
    rgba(10, 10, 9, 0.65) 60%,
    rgba(10, 10, 9, 0.30) 100%
  );
}

.mundo__card-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2rem 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  z-index: 1;
  border-right: 1px solid rgba(255, 255, 255, 0.07);
  transition: padding 0.4s ease;
}

.mundo__card:last-child .mundo__card-content {
  border-right: none;
}

.mundo__card:hover .mundo__card-content {
  padding-bottom: 2.5rem;
}

.mundo__num {
  font-family: var(--font-body);
  font-size: 0.62rem;
  letter-spacing: 0.38em;
  color: rgba(244, 243, 240, 0.5);
  font-weight: 300;
}

.mundo__name {
  font-family: var(--font-body);
  font-size: 0.72rem;
  letter-spacing: 0.38em;
  color: #F4F3F0;
  font-weight: 500;
  text-transform: uppercase;
}

/* ============================================================
   O CÓDIGO
   ============================================================ */
.codigo__list {
  width: 100%;
}

.codigo__item {
  display: grid;
  grid-template-columns: 2.5rem 1fr 1fr;
  align-items: center;
  gap: 2rem;
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
  transition: gap 0.3s ease;
}

.codigo__item:first-child {
  border-top: 1px solid var(--border);
}

.codigo__item:hover {
  gap: 2.8rem;
}

.codigo__num {
  font-family: var(--font-body);
  font-size: 0.6rem;
  letter-spacing: 0.3em;
  color: var(--text-muted);
  font-weight: 400;
}

.codigo__valor {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1.6rem, 2.5vw, 2.4rem);
  color: var(--text-light);
  letter-spacing: -0.01em;
}

.codigo__desc {
  font-family: var(--font-body);
  font-size: 0.6rem;
  letter-spacing: 0.4em;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 400;
  text-align: right;
}

/* ============================================================
   A IRMANDADE
   ============================================================ */
.irmandade__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: center;
}

.irmandade__photo {
  width: 100%;
  height: 580px;
  object-fit: cover;
  object-position: center;
  display: block;
}

.irmandade__content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.irmandade__content .section__label {
  display: block;
}

.irmandade__content p {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 300;
  line-height: 2;
  color: var(--text-sub);
}

/* ============================================================
   CTA FINAL
   ============================================================ */
.section--cta {
  text-align: center;
  padding: 7rem 0;
  background-color: var(--bg-alt);
}

.cta__epigraph {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: 1.75rem;
  color: var(--text-light);
  line-height: 1.8;
  margin-bottom: 4rem;
  letter-spacing: -0.01em;
}

.btn--large {
  font-size: 0.78rem;
  letter-spacing: 0.35em;
  padding-bottom: 6px;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  border-top: 1px solid var(--border);
  padding: 4.5rem 0 3.5rem;
  text-align: center;
  background-color: var(--bg);
}

.footer__wordmark {
  margin-bottom: 1.5rem;
  line-height: 0;
}

.footer__svg {
  width: 100%;
  max-width: 400px;
  height: auto;
  opacity: 0.35;
}

.footer__tagline {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: 1rem;
  color: var(--text-light);
  letter-spacing: 0.02em;
  margin-bottom: 2rem;
}

.footer__copy {
  font-family: var(--font-body);
  font-size: 0.6rem;
  letter-spacing: 0.3em;
  color: var(--text-muted);
  opacity: 0.6;
  text-transform: uppercase;
}

/* ============================================================
   MODAL
   ============================================================ */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(15, 14, 13, 0.75);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.modal-backdrop.is-open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  position: relative;
  background: #F4F3F0;
  width: 100%;
  max-width: 480px;
  padding: 3.5rem 3rem;
  transform: translateY(24px);
  transition: transform 0.4s ease;
}

.modal-backdrop.is-open .modal {
  transform: translateY(0);
}

.modal__close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: none;
  border: none;
  font-size: 0.85rem;
  color: var(--text-muted);
  cursor: pointer;
  line-height: 1;
  padding: 0.25rem;
  transition: color 0.25s ease;
}

.modal__close:hover {
  color: var(--text-light);
}

.modal__header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.modal__logo {
  height: 22px;
  width: auto;
  margin-bottom: 1.75rem;
  opacity: 0.85;
}

.modal__title {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: 1.75rem;
  color: var(--text-light);
  letter-spacing: -0.01em;
  margin-bottom: 0.6rem;
}

.modal__subtitle {
  font-family: var(--font-body);
  font-size: 0.72rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 400;
}

/* Form */
.modal__form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form__group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form__label {
  font-family: var(--font-body);
  font-size: 0.6rem;
  letter-spacing: 0.45em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 500;
}

.form__input {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 300;
  color: var(--text-light);
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(30, 28, 26, 0.20);
  padding: 0.6rem 0;
  outline: none;
  transition: border-color 0.3s ease;
  letter-spacing: 0.02em;
}

.form__input::placeholder {
  color: rgba(30, 28, 26, 0.25);
}

.form__input:focus {
  border-bottom-color: var(--text-light);
}

.form__submit {
  margin-top: 1rem;
  font-family: var(--font-body);
  font-size: 0.75rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  font-weight: 500;
  color: #F4F3F0;
  background: var(--text-light);
  border: none;
  padding: 1.1rem 2rem;
  cursor: pointer;
  transition: background 0.3s ease, color 0.3s ease;
}

.form__submit:hover {
  background: #2e2c29;
}

.form__privacy {
  font-family: var(--font-body);
  font-size: 0.65rem;
  color: var(--text-muted);
  text-align: center;
  letter-spacing: 0.03em;
  line-height: 1.6;
}

/* ============================================================
   RESPONSIVE — TABLET (≤ 900px)
   ============================================================ */
@media (max-width: 900px) {
  .container {
    padding: 0 2rem;
  }

  .section {
    padding: 6rem 0;
  }

  .section--cta {
    padding: 6rem 0;
  }

  .section__grid {
    grid-template-columns: 130px 1fr;
    gap: 2rem;
  }

  .mundo__grid {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: auto;
    height: auto;
  }

  .mundo__card {
    height: 300px;
  }

  .mundo__card-content {
    border-right: none;
  }

  .mundo__card:nth-child(odd) .mundo__card-content {
    border-right: 1px solid rgba(255, 255, 255, 0.07);
  }

  .codigo__item {
    padding: 1.5rem 0;
    gap: 1rem;
  }

  .filosofia__grid {
    width: 100%;
    height: auto;
    gap: 2rem;
  }

  .filosofia__img {
    height: 420px;
  }

  .irmandade__grid {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
  }

  .irmandade__photo {
    height: 420px;
  }
}

/* ============================================================
   RESPONSIVE — TABLET PEQUENO (≤ 768px)
   ============================================================ */
@media (max-width: 768px) {
  .hero__title {
    white-space: normal;
    font-size: 0.78rem;
    letter-spacing: 0.15em;
  }

  .filosofia__grid {
    grid-template-columns: 1fr;
    width: 100%;
    height: auto;
  }

  .filosofia__img {
    height: auto;
    object-fit: contain;
    width: 100%;
  }

  .irmandade__grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .irmandade__photo {
    height: 340px;
  }

  .codigo__item {
    grid-template-columns: 2rem 1fr;
    gap: 1.2rem;
  }

  .codigo__desc {
    display: none;
  }

  .modal {
    padding: 2.5rem 2rem;
  }
}

/* ============================================================
   RESPONSIVE — MOBILE (≤ 560px)
   ============================================================ */
@media (max-width: 560px) {
  .container {
    padding: 0 1.25rem;
  }

  .section {
    padding: 4rem 0;
  }

  .section--cta {
    padding: 4rem 0;
  }

  .hero__eyebrow {
    font-size: clamp(1.8rem, 8vw, 2.4rem);
  }

  .hero__title {
    white-space: normal;
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    margin-bottom: 2rem;
  }

  .hero__logo-img,
  .nav__logo-img {
    height: 32px;
  }

  .quote {
    font-size: 1.3rem;
  }

  .section__grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .filosofia__img {
    height: auto;
    object-fit: contain;
    object-position: center;
  }

  .irmandade__photo {
    height: 260px;
  }

  .mundo__grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }

  .mundo__card {
    height: 260px;
  }

  .mundo__card--span2 {
    grid-column: span 1;
  }

  .mundo__card:nth-child(odd) .mundo__card-content {
    border-right: none;
  }

  .mundo__card + .mundo__card {
    border-top: 1px solid rgba(255, 255, 255, 0.07);
  }

  .codigo__item {
    grid-template-columns: 2rem 1fr;
    padding: 1.2rem 0;
    gap: 1rem;
  }

  .codigo__desc {
    display: none;
  }

  .codigo__valor {
    font-size: 1.4rem;
  }

  .cta__epigraph {
    font-size: 1.3rem;
  }

  .modal {
    padding: 2rem 1.5rem;
    margin: 1rem;
    max-width: calc(100vw - 2rem);
  }

  .form__input {
    font-size: 1rem;
  }
}
