/* ========================================
   JHC Contabilidade - Styles
   ======================================== */

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --azul: #142E4A;
  --azul-light: #1a3a5c;
  --bege: #EBEAE4;
  --rose: #CFB3AA;
  --rose-light: #ddc5be;
  --branco: #FFFFFF;
  --cinza: #4B5563;
  --cinza-claro: #F5F4F0;
}

html {
  scroll-behavior: smooth;
  font-size: 17px;
}

body {
  font-family: 'Poppins', sans-serif;
  color: var(--azul);
  background-color: var(--bege);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: 'Tenor Sans', serif;
  font-weight: 400;
  line-height: 1.3;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.3s ease;
}

img {
  max-width: 100%;
  height: auto;
}

ul {
  list-style: none;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 100px 0;
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  padding: 16px 40px;
  font-family: 'Poppins', sans-serif;
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: none;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-primary {
  background-color: var(--azul);
  color: var(--branco);
}

.btn-primary:hover {
  background-color: var(--azul-light);
  transform: translateY(-1px);
}

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

.btn-outline:hover {
  background-color: var(--azul);
  color: var(--branco);
}

.btn-rose {
  background-color: var(--rose);
  color: var(--azul);
}

.btn-rose:hover {
  background-color: var(--rose-light);
  transform: translateY(-1px);
}

.btn-white {
  background-color: var(--branco);
  color: var(--azul);
}

.btn-white:hover {
  background-color: var(--bege);
  transform: translateY(-1px);
}

/* --- Header / Navbar --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: all 0.4s ease;
}

.header.scrolled {
  background-color: var(--azul);
  box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 18px;
}

.header-logo img {
  height: 60px;
  width: auto;
  transition: height 0.3s ease;
}

.header.scrolled .header-logo img {
  height: 46px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--branco);
  position: relative;
  transition: color 0.3s ease;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--rose);
  transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-links .btn-area-cliente {
  background-color: var(--rose);
  color: var(--azul);
  padding: 10px 24px;
  border-radius: 2px;
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nav-links .btn-area-cliente::after {
  display: none;
}

.nav-links .btn-area-cliente:hover {
  background-color: var(--rose-light);
}

/* Mobile Menu */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  background: none;
  border: none;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--branco);
  transition: all 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background-color: var(--azul);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(207,179,170,0.08) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(255,255,255,0.03) 0%, transparent 50%);
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 40%;
  height: 100%;
  background: linear-gradient(135deg, transparent 30%, rgba(207,179,170,0.04) 100%);
}

.hero .container {
  position: relative;
  z-index: 2;
  max-width: 1100px;
}

.hero-content {
  color: var(--branco);
  text-align: center;
}

.hero-badge {
  display: inline-block;
  font-size: 0.8125rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 32px;
  font-weight: 400;
}

.hero h1 {
  font-size: 3.75rem;
  line-height: 1.15;
  margin-bottom: 24px;
  letter-spacing: -0.01em;
}

.hero .subtitle {
  font-size: 1.25rem;
  color: rgba(255,255,255,0.65);
  margin-bottom: 48px;
  font-weight: 300;
  line-height: 1.7;
}

.hero .support-text {
  font-size: 1.0625rem;
  color: rgba(255,255,255,0.5);
  max-width: 600px;
  margin: 0 auto 48px;
  font-weight: 300;
  line-height: 1.8;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-line {
  position: absolute;
  bottom: 60px;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: 60px;
  background: linear-gradient(to bottom, var(--rose), transparent);
  z-index: 2;
}

/* --- Sobre --- */
.sobre {
  background-color: var(--bege);
}

.section-label {
  font-size: 0.8125rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 16px;
  display: block;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
}

.section-title {
  font-size: 2.75rem;
  color: var(--azul);
  margin-bottom: 40px;
  max-width: 600px;
}

.sobre-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.sobre-text p {
  font-size: 1.0625rem;
  color: var(--cinza);
  margin-bottom: 20px;
  line-height: 1.9;
}

.sobre-text p:last-child {
  margin-bottom: 0;
}

.sobre-detail {
  display: flex;
  flex-direction: column;
  gap: 32px;
  padding-top: 16px;
}

.sobre-stat {
  padding-left: 24px;
  border-left: 2px solid var(--rose);
}

.sobre-stat h3 {
  font-size: 1.125rem;
  color: var(--azul);
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}

.sobre-stat p {
  font-size: 0.9375rem;
  color: var(--cinza);
  line-height: 1.7;
}

/* --- Servicos --- */
.servicos {
  background-color: var(--cinza-claro);
}

.servicos .section-header {
  text-align: center;
  max-width: 650px;
  margin: 0 auto 64px;
}

.servicos .section-header .section-title {
  max-width: none;
}

.servicos .section-header p {
  font-size: 1.0625rem;
  color: var(--cinza);
  margin-top: -16px;
}

.servicos-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.servico-card {
  background-color: var(--branco);
  padding: 40px 32px;
  border-radius: 4px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.servico-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(20,46,74,0.06);
}

.servico-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: var(--rose);
}

.servico-icon svg {
  width: 32px;
  height: 32px;
  stroke: var(--rose);
  stroke-width: 1.5;
  fill: none;
}

.servico-card h3 {
  font-size: 1.25rem;
  color: var(--azul);
  margin-bottom: 12px;
}

.servico-card p {
  font-size: 0.9375rem;
  color: var(--cinza);
  line-height: 1.8;
}

/* --- Diferenciais --- */
.diferenciais {
  background-color: var(--bege);
}

.diferenciais .section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 64px;
}

.diferenciais-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 40px;
}

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

.diferencial-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--rose);
  border-radius: 50%;
}

.diferencial-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--azul);
  stroke-width: 1.5;
  fill: none;
}

.diferencial-item h3 {
  font-size: 1.0625rem;
  color: var(--azul);
  margin-bottom: 8px;
}

.diferencial-item p {
  font-size: 0.9375rem;
  color: var(--cinza);
  line-height: 1.8;
}

/* --- Area do Cliente --- */
.area-cliente {
  background-color: var(--azul);
  padding: 80px 0;
  position: relative;
  overflow: hidden;
}

.area-cliente::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(207,179,170,0.06) 0%, transparent 70%);
}

.area-cliente .container {
  position: relative;
  z-index: 2;
  text-align: center;
}

.area-cliente .section-label {
  color: var(--rose);
}

.area-cliente h2 {
  font-size: 2.5rem;
  color: var(--branco);
  margin-bottom: 16px;
}

.area-cliente p {
  font-size: 1.0625rem;
  color: rgba(255,255,255,0.6);
  max-width: 500px;
  margin: 0 auto 40px;
  line-height: 1.8;
}

/* --- CTA Section --- */
.cta-section {
  background-color: var(--cinza-claro);
  padding: 80px 0;
}

.cta-section .container {
  text-align: center;
}

.cta-section h2 {
  font-size: 2.5rem;
  color: var(--azul);
  margin-bottom: 16px;
}

.cta-section p {
  font-size: 1.0625rem;
  color: var(--cinza);
  max-width: 550px;
  margin: 0 auto 40px;
  line-height: 1.8;
}

/* --- Contato --- */
.contato {
  background-color: var(--bege);
}

.contato-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
}

.contato-info {
  padding-top: 16px;
}

.contato-info .section-title {
  margin-bottom: 16px;
}

.contato-info > p {
  font-size: 1.0625rem;
  color: var(--cinza);
  margin-bottom: 40px;
  line-height: 1.8;
}

.contato-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 28px;
}

.contato-item-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contato-item-icon svg {
  width: 20px;
  height: 20px;
  stroke: var(--rose);
  stroke-width: 1.5;
  fill: none;
}

.contato-item h3 {
  font-size: 1rem;
  color: var(--azul);
  margin-bottom: 2px;
}

.contato-item p,
.contato-item a {
  font-size: 1rem;
  color: var(--cinza);
}

.contato-item a {
  text-decoration: underline;
  text-decoration-color: var(--rose);
  text-underline-offset: 3px;
}

.contato-item a:hover {
  color: var(--azul);
  text-decoration-color: var(--azul);
}

/* --- Form --- */
.contato-form {
  background-color: var(--branco);
  padding: 48px 40px;
  border-radius: 4px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--azul);
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  font-family: 'Poppins', sans-serif;
  font-size: 0.9375rem;
  color: var(--azul);
  background-color: var(--cinza-claro);
  border: 1px solid transparent;
  border-radius: 2px;
  outline: none;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--rose);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.contato-form .btn {
  width: 100%;
  padding: 16px;
  font-size: 0.9375rem;
}

/* --- Footer --- */
.footer {
  background-color: var(--azul);
  padding: 48px 0 32px;
}

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

.footer-logo img {
  height: 100px;
  width: auto;
  margin-bottom: 24px;
}

.footer-name {
  font-family: 'Tenor Sans', serif;
  font-size: 1rem;
  color: rgba(255,255,255,0.5);
  margin-bottom: 4px;
  letter-spacing: 0.05em;
}

.footer-location {
  font-size: 0.9375rem;
  color: rgba(255,255,255,0.35);
  margin-bottom: 32px;
}

.footer-divider {
  width: 60px;
  height: 1px;
  background-color: rgba(255,255,255,0.1);
  margin: 0 auto 24px;
}

.footer-copy {
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.3);
  margin-bottom: 8px;
}

.footer-credit {
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.2);
}

.footer-credit a {
  color: rgba(255,255,255,0.4);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.3s ease;
}

.footer-credit a:hover {
  color: var(--rose);
}

/* --- WhatsApp Float --- */
.whatsapp-float {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 56px;
  height: 56px;
  background-color: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  box-shadow: 0 4px 16px rgba(37,211,102,0.3);
  transition: transform 0.3s ease;
}

.whatsapp-float:hover {
  transform: scale(1.08);
}

.whatsapp-float svg {
  width: 28px;
  height: 28px;
  fill: #fff;
}

/* --- Animations --- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes slideFromLeft {
  from { opacity: 0; transform: translateX(-24px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes slideFromRight {
  from { opacity: 0; transform: translateX(24px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* Elements start hidden, animate when .is-visible is added */
.anim-fade-up,
.anim-fade-in,
.anim-slide-left,
.anim-slide-right {
  opacity: 0;
}

.anim-fade-up.is-visible {
  animation: fadeUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.anim-fade-in.is-visible {
  animation: fadeIn 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.anim-slide-left.is-visible {
  animation: slideFromLeft 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.anim-slide-right.is-visible {
  animation: slideFromRight 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Hero entrance — plays immediately on load */
.hero .hero-badge {
  opacity: 0;
  animation: fadeUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.15s forwards;
}

.hero h1 {
  opacity: 0;
  animation: fadeUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.3s forwards;
}

.hero .subtitle {
  opacity: 0;
  animation: fadeUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.45s forwards;
}

.hero .support-text {
  opacity: 0;
  animation: fadeUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.55s forwards;
}

.hero-buttons {
  opacity: 0;
  animation: fadeUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.65s forwards;
}

.hero-line {
  opacity: 0;
  animation: fadeIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) 1s forwards;
}

/* Stagger delays for grid children */
.is-visible.anim-delay-1 { animation-delay: 0.08s; }
.is-visible.anim-delay-2 { animation-delay: 0.16s; }
.is-visible.anim-delay-3 { animation-delay: 0.24s; }
.is-visible.anim-delay-4 { animation-delay: 0.32s; }
.is-visible.anim-delay-5 { animation-delay: 0.40s; }
.is-visible.anim-delay-6 { animation-delay: 0.48s; }
.is-visible.anim-delay-7 { animation-delay: 0.56s; }

/* Respect prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  .anim-fade-up,
  .anim-fade-in,
  .anim-slide-left,
  .anim-slide-right {
    opacity: 1;
  }

  .hero .hero-badge,
  .hero h1,
  .hero .subtitle,
  .hero .support-text,
  .hero-buttons,
  .hero-line {
    opacity: 1;
  }
}

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 1024px) {
  .diferenciais-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .servicos-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  section {
    padding: 72px 0;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: var(--azul);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 32px;
    z-index: 998;
  }

  .nav-links.active {
    display: flex;
  }

  .menu-toggle {
    display: flex;
    z-index: 999;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .hero .subtitle {
    font-size: 1.0625rem;
  }

  .desktop-only {
    display: none;
  }

  .section-title {
    font-size: 2.125rem;
  }

  .sobre-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .servicos-grid {
    grid-template-columns: 1fr;
  }

  .diferenciais-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }

  .contato-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }

  .hero-line {
    display: none;
  }

  .area-cliente h2,
  .cta-section h2 {
    font-size: 2rem;
  }

  .contato-form {
    padding: 32px 24px;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }

  .diferenciais-grid {
    grid-template-columns: 1fr;
  }

  .container {
    padding: 0 20px;
  }
}
