/* =========================================================
   Confecções d'Viann — Design System
   Paleta extraída do logo: azul-marinho + vermelho + carvão
   Tipografia: Montserrat (títulos, como o wordmark) + Source Sans 3 (texto)
   ========================================================= */

:root {
  /* Cores da marca */
  --navy-900: #1B1047;
  --navy-700: #2A1A6E;
  --navy-500: #3F2C9A;
  --red-600: #D8261C;
  --red-700: #B51E16;
  --charcoal-900: #1E1B1A;
  --charcoal-700: #3A3A3A;
  --charcoal-500: #6B6B6B;

  /* Neutros */
  --white: #FFFFFF;
  --paper: #F5F4F8;
  --line: #E4E2EC;

  /* Tipografia */
  --font-display: "Montserrat", "Segoe UI", Arial, sans-serif;
  --font-body: "Source Sans 3", "Segoe UI", Arial, sans-serif;

  /* Escala */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --section-y: clamp(64px, 9vw, 112px);
  --container: 1200px;

  /* Sombras em camadas (profundidade real) */
  --shadow-soft: 0 1px 2px rgba(27, 16, 71, .06), 0 8px 24px rgba(27, 16, 71, .08);
  --shadow-lift: 0 2px 4px rgba(27, 16, 71, .08), 0 18px 40px rgba(27, 16, 71, .16);

  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.7;
  color: var(--charcoal-700);
  background: var(--white);
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--charcoal-900);
  line-height: 1.15;
  margin: 0 0 .5em;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); font-weight: 800; }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }
.container { width: min(100% - 40px, var(--container)); margin-inline: auto; }
.skip-link {
  position: absolute; left: -999px; top: 8px; background: var(--white);
  padding: 8px 12px; z-index: 100; border-radius: var(--radius-sm);
}
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--red-600); outline-offset: 3px; border-radius: 4px; }

/* ---------- Componentes gerais ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-size: .78rem; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--navy-700); margin-bottom: 14px;
}
.eyebrow::before {
  content: ""; width: 28px; height: 3px; border-radius: 2px; background: var(--red-600);
}
.eyebrow-red { color: var(--red-600); }
.eyebrow-light { color: #C9C4F0; }
.eyebrow-light::before { background: var(--red-600); }

.accent { color: var(--red-600); }
.lead { font-size: 1.15rem; color: var(--charcoal-700); max-width: 56ch; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 26px;
  border-radius: var(--radius-sm);
  font-family: var(--font-display); font-weight: 600; font-size: .98rem;
  text-decoration: none; border: 2px solid transparent; cursor: pointer;
  transition: background-color .25s var(--ease), color .25s var(--ease),
              transform .25s var(--ease), box-shadow .25s var(--ease);
}
.btn:hover { transform: translateY(-2px) scale(1.02); }
.btn:active { transform: translateY(0) scale(.99); }
.btn-primary {
  background: var(--red-600); color: var(--white);
  box-shadow: 0 6px 18px rgba(216, 38, 28, .35);
}
.btn-primary:hover { background: var(--red-700); box-shadow: 0 10px 26px rgba(216, 38, 28, .45); }
.btn-small { min-height: 44px; padding: 0 20px; font-size: .92rem; }
.btn-ghost {
  background: transparent; color: var(--navy-700); border-color: var(--navy-700);
}
.btn-ghost:hover { background: var(--navy-700); color: var(--white); }
.btn-light { background: var(--white); color: var(--navy-900); }
.btn-light:hover { background: #ECEAF6; }
.btn-ghost-light { background: transparent; color: var(--white); border-color: rgba(255,255,255,.6); }
.btn-ghost-light:hover { background: rgba(255,255,255,.12); }

.section { padding: var(--section-y) 0; position: relative; }
.section-light { background: var(--white); }
.section-dark {
  color: #E8E6F2;
  background:
    radial-gradient(900px 500px at 90% 0%, rgba(63, 44, 154, .55), transparent 60%),
    radial-gradient(700px 500px at 0% 100%, rgba(216, 38, 28, .18), transparent 60%),
    linear-gradient(160deg, var(--navy-900), var(--navy-700));
}
.section-dark h2, .section-dark h3 { color: var(--white); }
.section-dark p { color: #CFCBE6; }

.section-head { max-width: 680px; margin: 0 auto 56px; text-align: center; }
.section-head p { font-size: 1.05rem; }
.section-head .eyebrow { justify-content: center; }
.section-head .eyebrow::after {
  content: ""; width: 28px; height: 3px; border-radius: 2px; background: var(--red-600);
}
.section-head .eyebrow::before { display: none; }

.photo-frame {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-lift); background: var(--paper);
}
.photo-frame img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 5; }

/* ---------- Cabeçalho ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(27,16,71,.03);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 80px; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { width: 52px; height: 52px; object-fit: contain; }
.brand-text {
  font-family: var(--font-display); font-size: 1rem; color: var(--charcoal-900);
  letter-spacing: .02em; line-height: 1.1;
}
.brand-text strong { display: block; font-size: 1.15rem; color: var(--navy-700); font-weight: 800; }

.main-nav { display: flex; align-items: center; gap: 4px; }
.main-nav a:not(.btn) {
  font-family: var(--font-display); font-size: .92rem; font-weight: 500;
  color: var(--charcoal-700); text-decoration: none;
  padding: 10px 12px; border-radius: 8px;
  transition: color .2s, background-color .2s;
}
.main-nav a:not(.btn):hover { color: var(--red-600); background: var(--paper); }
.main-nav .btn { margin-left: 10px; color: var(--white); }

.menu-toggle {
  display: none; width: 46px; height: 46px; border: 0; border-radius: 10px;
  background: var(--paper); cursor: pointer; padding: 0;
  flex-direction: column; align-items: center; justify-content: center; gap: 5px;
}
.menu-toggle span {
  width: 22px; height: 2px; background: var(--navy-700); border-radius: 2px;
  transition: transform .3s var(--ease), opacity .3s;
}
.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); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: clamp(48px, 7vw, 96px) 0 clamp(64px, 8vw, 112px);
  background:
    radial-gradient(800px 420px at 100% 0%, rgba(216, 38, 28, .08), transparent 60%),
    linear-gradient(180deg, #FFFFFF 0%, var(--paper) 100%);
}
.hero::before {
  content: ""; position: absolute; inset: auto -10% -120px auto;
  width: 520px; height: 520px; border-radius: 50%;
  background: radial-gradient(circle, rgba(42, 26, 110, .10), transparent 70%);
  pointer-events: none;
}
.hero-grid {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.hero h1 { margin-bottom: 20px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin: 30px 0 40px; }
.hero-stats {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px;
}
.hero-stats li {
  background: var(--white); border: 1px solid var(--line);
  border-left: 4px solid var(--red-600);
  border-radius: var(--radius-md); padding: 16px 16px;
  box-shadow: var(--shadow-soft);
}
.hero-stats strong { display: block; font-family: var(--font-display); color: var(--navy-700); font-size: 1rem; }
.hero-stats span { font-size: .92rem; color: var(--charcoal-500); line-height: 1.4; display: block; }

.hero-media { position: relative; }
.hero-media .photo-frame { border: 8px solid var(--white); }
.hero-media .photo-frame img { aspect-ratio: 4 / 5; }
.floating-card {
  position: absolute; left: -24px; bottom: 32px;
  display: flex; align-items: center; gap: 12px;
  background: var(--white); border-radius: var(--radius-md);
  padding: 14px 18px; box-shadow: var(--shadow-lift);
  font-size: .95rem; line-height: 1.3;
}
.floating-card strong { display: block; font-family: var(--font-display); color: var(--navy-700); font-size: .95rem; }
.floating-card small { color: var(--charcoal-500); }
.floating-dot {
  width: 12px; height: 12px; border-radius: 50%; background: var(--red-600);
  box-shadow: 0 0 0 6px rgba(216, 38, 28, .18);
  animation: pulse 2s var(--ease) infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(216, 38, 28, .25); }
  50% { box-shadow: 0 0 0 10px rgba(216, 38, 28, 0); }
}

/* ---------- Sobre ---------- */
.split {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: center;
}
.split-reverse .split-text { order: 1; }
.split-reverse .map-frame { order: 2; }
.split-text h2 { margin-bottom: 20px; }
.split-text p { color: var(--charcoal-700); }
.photo-frame-tilt { transform: rotate(-1.5deg); transition: transform .6s var(--ease); }
.photo-frame-tilt:hover { transform: rotate(0deg); }
.quote-box {
  margin-top: 26px; padding: 22px 26px;
  border-left: 4px solid var(--red-600);
  background: var(--paper); border-radius: 0 var(--radius-md) var(--radius-md) 0;
}
.quote-box p { margin: 0; font-family: var(--font-display); font-weight: 600; color: var(--navy-700); font-size: 1.05rem; }

/* ---------- Cards / Serviços ---------- */
.cards {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px;
}
.card {
  position: relative; padding: 32px 28px;
  background: linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,.02));
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius-md);
  transition: transform .35s var(--ease), border-color .35s, background-color .35s;
}
.card:hover {
  transform: translateY(-6px);
  border-color: rgba(216, 38, 28, .6);
  background: rgba(255,255,255,.09);
}
.card-icon {
  width: 56px; height: 56px; border-radius: 14px;
  display: grid; place-items: center; margin-bottom: 20px;
  background: var(--red-600); color: var(--white);
  box-shadow: 0 10px 24px rgba(216, 38, 28, .35);
}
.card-icon svg { width: 28px; height: 28px; }
.card h3 { color: var(--white); }
.card p { margin: 0; font-size: 1rem; color: #CFCBE6; }

/* ---------- Processo ---------- */
.steps {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px;
  counter-reset: none;
}
.step {
  position: relative; padding: 30px 26px 28px;
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius-md); box-shadow: var(--shadow-soft);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.step:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
.step-num {
  display: inline-block; font-family: var(--font-display); font-weight: 800;
  font-size: 2.2rem; line-height: 1;
  color: transparent; -webkit-text-stroke: 1.5px var(--navy-700);
  margin-bottom: 14px;
}
.step h3 { font-size: 1.1rem; }
.step p { margin: 0; font-size: 1rem; color: var(--charcoal-500); }

/* ---------- Galeria ---------- */
.gallery {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
}
.gallery-item {
  position: relative; padding: 0; border: 0; cursor: zoom-in;
  border-radius: var(--radius-md); overflow: hidden;
  background: var(--navy-900);
  box-shadow: 0 6px 18px rgba(0,0,0,.25);
  aspect-ratio: 4 / 5;
}
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .6s var(--ease), filter .4s;
}
.gallery-item::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(27,16,71,.55));
  opacity: 0; transition: opacity .4s;
}
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item:hover::after { opacity: 1; }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 200;
  display: grid; place-items: center; padding: 20px;
  background: rgba(15, 10, 40, .92);
  animation: fade .25s var(--ease);
}
.lightbox[hidden] { display: none; }
.lightbox img {
  max-width: min(100%, 900px); max-height: 88vh; width: auto; height: auto;
  border-radius: var(--radius-md); box-shadow: var(--shadow-lift);
}
.lightbox-close {
  position: absolute; top: 16px; right: 18px;
  width: 48px; height: 48px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--red-600); color: var(--white); font-size: 1.8rem; line-height: 1;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Mapa ---------- */
.map-frame {
  border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-lift); border: 8px solid var(--white);
  background: var(--paper); min-height: 380px;
}
.map-frame iframe { width: 100%; height: 100%; min-height: 380px; border: 0; display: block; }

/* ---------- CTA ---------- */
.section-cta {
  padding: clamp(64px, 8vw, 96px) 0;
  color: var(--white); text-align: center;
  background:
    radial-gradient(600px 300px at 15% 0%, rgba(216, 38, 28, .35), transparent 60%),
    linear-gradient(135deg, var(--navy-900), var(--navy-500));
}
.cta-inner { max-width: 760px; margin: 0 auto; }
.section-cta h2 { color: var(--white); }
.section-cta p { color: #DAD6F2; font-size: 1.1rem; }
.section-cta .eyebrow { justify-content: center; }
.section-cta .eyebrow::before { display: none; }
.cta-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 28px; }

/* ---------- Rodapé ---------- */
.site-footer { background: var(--charcoal-900); color: #B9B5C9; padding: 56px 0 28px; }
.footer-inner {
  display: grid; grid-template-columns: 2fr 1.4fr; gap: 32px 48px; align-items: start;
}
.footer-brand { display: flex; gap: 16px; align-items: center; }
.footer-brand img { background: var(--white); border-radius: 12px; padding: 4px; }
.footer-brand strong { color: var(--white); font-family: var(--font-display); font-size: 1.05rem; }
.footer-brand p { margin: 4px 0 0; font-size: .95rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; justify-content: flex-end; }
.site-footer nav a { color: #D9D6E8; text-decoration: none; font-size: .95rem; }
.site-footer nav a:hover { color: var(--white); text-decoration: underline; text-underline-offset: 4px; }
.copy {
  grid-column: 1 / -1; margin: 28px 0 0; padding-top: 22px;
  border-top: 1px solid rgba(255,255,255,.1); font-size: .88rem; color: #8F8BA6;
}

/* ---------- Popup de saída ---------- */
.exit-popup {
  position: fixed; inset: 0; z-index: 180;
  display: grid; place-items: center; padding: 20px;
  background: rgba(15, 10, 40, .72);
  backdrop-filter: blur(4px);
  animation: fade .3s var(--ease);
}
.exit-popup[hidden] { display: none; }
.exit-card {
  position: relative; width: min(100%, 480px);
  padding: 40px 32px 30px; text-align: center;
  background: var(--white); border-radius: var(--radius-lg);
  box-shadow: 0 2px 6px rgba(27,16,71,.1), 0 30px 70px rgba(15,10,40,.45);
  border-top: 6px solid var(--red-600);
  animation: popIn .45s var(--ease);
}
@keyframes popIn {
  from { opacity: 0; transform: translateY(24px) scale(.96); }
  to { opacity: 1; transform: none; }
}
.exit-card h2 { font-size: clamp(1.4rem, 4vw, 1.75rem); margin-bottom: 12px; }
.exit-card p { color: var(--charcoal-500); font-size: 1rem; margin-bottom: 24px; }
.exit-card .eyebrow { justify-content: center; }
.exit-card .eyebrow::before { display: none; }
.exit-badge {
  width: 84px; height: 84px; margin: -82px auto 16px;
  display: grid; place-items: center;
  background: var(--white); border-radius: 50%;
  box-shadow: var(--shadow-lift);
}
.exit-badge img { width: 64px; height: 64px; object-fit: contain; }
.exit-close {
  position: absolute; top: 14px; right: 14px;
  width: 40px; height: 40px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--paper); color: var(--navy-700); font-size: 1.5rem; line-height: 1;
}
.exit-close:hover { background: var(--line); }
.exit-actions { display: flex; flex-direction: column; gap: 12px; }
.exit-actions .btn { width: 100%; }
@media (max-width: 480px) {
  .exit-card { padding: 36px 22px 24px; }
}

/* ---------- WhatsApp flutuante ---------- */
.whatsapp-float {
  position: fixed; right: 20px; bottom: 20px; z-index: 60;
  width: 60px; height: 60px; border-radius: 50%;
  display: grid; place-items: center;
  background: #25D366; color: var(--white);
  box-shadow: 0 10px 28px rgba(37, 211, 102, .45);
  transition: transform .3s var(--ease);
}
.whatsapp-float svg { width: 32px; height: 32px; }
.whatsapp-float:hover { transform: scale(1.08); }

/* ---------- Animação de entrada ---------- */
.reveal {
  opacity: 0; transform: translateY(24px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
  transition-delay: var(--delay, 0ms);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.photo-frame-tilt.reveal.is-visible { transform: rotate(-1.5deg); }
.photo-frame-tilt.reveal.is-visible:hover { transform: rotate(0deg); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* =========================================================
   RESPONSIVO
   ========================================================= */

/* Notebooks / tablets grandes */
@media (max-width: 1080px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: repeat(3, 1fr); }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .main-nav a:not(.btn) { padding: 10px 8px; font-size: .86rem; }
}

/* Tablets */
@media (max-width: 900px) {
  body { font-size: 17px; }
  .hero-grid, .split, .split-reverse .split-text, .split-reverse .map-frame { grid-template-columns: 1fr; }
  .split-reverse .split-text, .split-reverse .map-frame { order: initial; }
  .hero-media { max-width: 520px; width: 100%; margin: 0 auto; }
  .floating-card { left: 12px; bottom: 16px; }
  .split-media { max-width: 520px; width: 100%; margin: 0 auto; }
  .map-frame { min-height: 320px; }
  .map-frame iframe { min-height: 320px; }
  .footer-inner { grid-template-columns: 1fr; }
  .site-footer nav { justify-content: flex-start; }
}

/* Menu mobile */
@media (max-width: 860px) {
  .menu-toggle { display: inline-flex; }
  .main-nav {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--white); padding: 14px 20px 22px;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 18px 30px rgba(27,16,71,.12);
    transform: translateY(-12px); opacity: 0; visibility: hidden;
    transition: transform .35s var(--ease), opacity .35s, visibility .35s;
  }
  .main-nav.is-open { transform: translateY(0); opacity: 1; visibility: visible; }
  .main-nav a:not(.btn) { padding: 14px 10px; font-size: 1rem; border-bottom: 1px solid var(--line); border-radius: 0; }
  .main-nav .btn { margin: 14px 0 0; width: 100%; min-height: 50px; }
  .brand-text { font-size: .9rem; }
  .brand-text strong { font-size: 1.02rem; }
}

/* Celulares */
@media (max-width: 640px) {
  body { font-size: 16.5px; }
  .container { width: min(100% - 32px, var(--container)); }
  .header-inner { min-height: 72px; }
  .brand img { width: 44px; height: 44px; }
  .brand-text { display: none; }
  .hero-actions .btn { flex: 1 1 100%; }
  .hero-stats { grid-template-columns: 1fr; gap: 10px; }
  .hero-stats li { display: flex; flex-direction: column; }
  .cards { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .gallery-item { aspect-ratio: 4 / 5; }
  .section-head { margin-bottom: 40px; }
  .cta-actions .btn { width: 100%; }
  .whatsapp-float { width: 56px; height: 56px; right: 16px; bottom: 16px; }
  .hero-media .photo-frame { border-width: 5px; }
  .photo-frame-tilt { transform: none; }
  .photo-frame-tilt.reveal.is-visible { transform: none; }
}

/* Telas muito pequenas */
@media (max-width: 360px) {
  .hero-stats strong { font-size: .95rem; }
  .floating-card { display: none; }
}
