/* ========================================
   0. Design Tokens (Custom Properties)
   ======================================== */
:root {
  /* Colors */
  --clr-primary: #8B3A62;
  --clr-primary-light: #B85C8A;
  --clr-primary-dark: #6B2A4A;
  --clr-accent: #D45E3B;
  --clr-accent-hover: #B84E30;
  --clr-neutral-900: #1A1A2E;
  --clr-neutral-700: #4A4A5A;
  --clr-neutral-400: #9A9AAA;
  --clr-neutral-100: #F5F0EB;
  --clr-neutral-50: #FDFBF9;
  --clr-white: #FFFFFF;
  --clr-whatsapp: #25D366;
  --clr-whatsapp-hover: #1DA851;

  /* Typography */
  --ff-heading: 'Playfair Display', Georgia, serif;
  --ff-body: 'Inter', system-ui, -apple-system, sans-serif;
  --fs-hero: clamp(2rem, 5vw, 3.25rem);
  --fs-h2: clamp(1.625rem, 3.5vw, 2.5rem);
  --fs-h3: clamp(1.25rem, 2.5vw, 1.75rem);
  --fs-body: clamp(1rem, 1.2vw, 1.125rem);
  --fs-small: 0.875rem;
  --fs-caption: 0.75rem;
  --lh-heading: 1.2;
  --lh-body: 1.7;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 3rem;
  --space-xl: 5rem;
  --space-section: clamp(3rem, 8vw, 6rem);

  /* Layout */
  --max-width: 1140px;
  --border-radius: 8px;
  --border-radius-lg: 16px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);

  /* Transitions */
  --transition: 200ms ease;
  --transition-slow: 400ms ease;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: var(--ff-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--clr-neutral-700);
  background-color: var(--clr-neutral-50);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

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

ul {
  list-style: none;
}

strong {
  color: var(--clr-neutral-900);
}

/* ========================================
   2. Typography
   ======================================== */
h1, h2, h3, h4 {
  font-family: var(--ff-heading);
  color: var(--clr-neutral-900);
  line-height: var(--lh-heading);
}

.text-accent {
  color: var(--clr-primary);
}

/* ========================================
   3. Layout Utilities
   ======================================== */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

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

.section--alt {
  background-color: var(--clr-neutral-100);
}

.section__title {
  font-size: var(--fs-h2);
  text-align: center;
  margin-bottom: var(--space-xs);
}

.section__title--left {
  text-align: left;
}

.section__subtitle {
  text-align: center;
  color: var(--clr-neutral-400);
  max-width: 600px;
  margin: 0 auto var(--space-lg);
}

/* ========================================
   4. Buttons
   ======================================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: var(--fs-small);
  transition: all var(--transition);
  white-space: nowrap;
}

.btn--whatsapp {
  background-color: var(--clr-whatsapp);
  color: var(--clr-white);
}

.btn--whatsapp:hover {
  background-color: var(--clr-whatsapp-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn--white {
  background-color: var(--clr-white);
  color: var(--clr-primary-dark);
}

.btn--white:hover {
  background-color: var(--clr-neutral-100);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn--lg {
  padding: 1rem 2rem;
  font-size: 1rem;
}

/* ========================================
   5. Skip Link
   ======================================== */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--clr-primary);
  color: var(--clr-white);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  z-index: 1000;
}

.skip-link:focus {
  top: 1rem;
}

/* ========================================
   6. Header & Navigation
   ======================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background-color: rgba(253, 251, 249, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: box-shadow var(--transition);
}

.header.scrolled {
  box-shadow: var(--shadow-sm);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

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

.header__name {
  font-family: var(--ff-heading);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--clr-primary-dark);
  line-height: 1.2;
}

.header__credential {
  font-size: var(--fs-caption);
  color: var(--clr-neutral-400);
  line-height: 1.2;
}

.header__cta {
  display: none;
}

/* Navigation - Mobile */
.nav {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 320px;
  height: 100vh;
  height: 100dvh;
  background-color: var(--clr-white);
  box-shadow: var(--shadow-lg);
  padding: 5rem 2rem 2rem;
  transition: right var(--transition-slow);
  z-index: 99;
}

.nav.open {
  right: 0;
}

.nav__list {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.nav__link {
  display: block;
  padding: 0.75rem 1rem;
  font-weight: 500;
  color: var(--clr-neutral-700);
  border-radius: var(--border-radius);
  transition: all var(--transition);
}

.nav__link:hover {
  color: var(--clr-primary);
  background-color: var(--clr-neutral-100);
}

/* Hamburger */
.hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 0.5rem;
  z-index: 101;
}

.hamburger__line {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--clr-neutral-900);
  border-radius: 2px;
  transition: all var(--transition);
}

.hamburger.active .hamburger__line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger.active .hamburger__line:nth-child(2) {
  opacity: 0;
}

.hamburger.active .hamburger__line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Nav overlay */
.nav-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.4);
  z-index: 98;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-slow);
}

.nav-overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* ========================================
   7. Hero
   ======================================== */
.hero {
  padding-top: calc(72px + var(--space-lg));
  padding-bottom: var(--space-section);
  background: linear-gradient(135deg, var(--clr-neutral-50) 0%, var(--clr-neutral-100) 100%);
}

.hero__inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.hero__content {
  text-align: center;
}

.hero__title {
  font-size: var(--fs-hero);
  margin-bottom: var(--space-md);
}

.hero__subtitle {
  font-size: var(--fs-body);
  color: var(--clr-neutral-700);
  margin-bottom: var(--space-lg);
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.hero__badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
}

.badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: var(--clr-white);
  border-radius: 50px;
  font-size: var(--fs-small);
  color: var(--clr-neutral-700);
  box-shadow: var(--shadow-sm);
}

.badge svg {
  color: var(--clr-primary);
  flex-shrink: 0;
}

/* Hero Image */
.hero__image {
  display: flex;
  justify-content: center;
}

.hero__photo {
  width: 280px;
  height: 340px;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-lg);
}

/* ========================================
   8. Specialties
   ======================================== */
.specialties__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

.specialty-card {
  background-color: var(--clr-white);
  border-radius: var(--border-radius-lg);
  padding: var(--space-md);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}

.specialty-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.specialty-card__icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--clr-neutral-100);
  border-radius: 12px;
  margin-bottom: var(--space-sm);
  color: var(--clr-primary);
}

.specialty-card__title {
  font-size: var(--fs-h3);
  margin-bottom: var(--space-xs);
}

.specialty-card__text {
  color: var(--clr-neutral-700);
  font-size: var(--fs-small);
  line-height: 1.6;
}

.specialties__cta {
  text-align: center;
  margin-top: var(--space-lg);
}

.specialties__cta p {
  font-size: 1.125rem;
  color: var(--clr-neutral-700);
  margin-bottom: var(--space-sm);
}

/* ========================================
   9. About
   ======================================== */
.about__inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  align-items: center;
}

.about__photo {
  width: 280px;
  height: 340px;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-lg);
}

.about__content p {
  margin-bottom: var(--space-sm);
}

.about__credentials {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-top: var(--space-md);
}

.credential {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--fs-small);
  font-weight: 500;
  color: var(--clr-primary-dark);
}

.credential svg {
  color: var(--clr-primary);
  flex-shrink: 0;
}

/* ========================================
   10. Steps (Como Funciona)
   ======================================== */
.steps__grid {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.step {
  text-align: center;
  position: relative;
}

.step__number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background-color: var(--clr-primary);
  color: var(--clr-white);
  font-family: var(--ff-heading);
  font-size: 1rem;
  font-weight: 700;
  border-radius: 50%;
  margin-bottom: var(--space-sm);
}

.step__icon {
  color: var(--clr-primary-light);
  margin-bottom: var(--space-sm);
}

.step__title {
  font-size: var(--fs-h3);
  margin-bottom: var(--space-xs);
}

.step__text {
  color: var(--clr-neutral-700);
  max-width: 320px;
  margin: 0 auto;
  font-size: var(--fs-small);
}

.steps__cta {
  text-align: center;
  margin-top: var(--space-lg);
}

/* ========================================
   11. Testimonials
   ======================================== */
.testimonials__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

.testimonial-card {
  background-color: var(--clr-white);
  border-radius: var(--border-radius-lg);
  padding: var(--space-md);
  box-shadow: var(--shadow-sm);
}

.testimonial-card__stars {
  display: flex;
  gap: 2px;
  color: #F5A623;
  margin-bottom: var(--space-sm);
}

.testimonial-card__text {
  font-style: italic;
  color: var(--clr-neutral-700);
  line-height: 1.7;
  margin-bottom: var(--space-sm);
  border: none;
  padding: 0;
}

.testimonial-card__author {
  font-weight: 600;
  font-size: var(--fs-small);
  color: var(--clr-primary-dark);
}

/* ========================================
   12. FAQ
   ======================================== */
.faq__list {
  max-width: 720px;
  margin: 0 auto;
}

.faq__item {
  border-bottom: 1px solid var(--clr-neutral-100);
}

.faq__item:first-child {
  border-top: 1px solid var(--clr-neutral-100);
}

.faq__question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 0;
  font-weight: 600;
  font-size: 1rem;
  color: var(--clr-neutral-900);
  text-align: left;
  gap: 1rem;
}

.faq__question:hover {
  color: var(--clr-primary);
}

.faq__chevron {
  flex-shrink: 0;
  transition: transform var(--transition);
  color: var(--clr-neutral-400);
}

.faq__question[aria-expanded="true"] .faq__chevron {
  transform: rotate(180deg);
  color: var(--clr-primary);
}

.faq__answer {
  overflow: hidden;
  transition: max-height var(--transition-slow), padding var(--transition-slow);
}

.faq__answer[hidden] {
  display: block;
  max-height: 0;
  padding-bottom: 0;
  visibility: hidden;
}

.faq__answer:not([hidden]) {
  max-height: 300px;
  padding-bottom: 1.25rem;
  visibility: visible;
}

.faq__answer p {
  color: var(--clr-neutral-700);
  line-height: 1.7;
}

/* ========================================
   13. Final CTA
   ======================================== */
.final-cta {
  background: linear-gradient(135deg, var(--clr-primary) 0%, var(--clr-primary-dark) 100%);
  padding: var(--space-section) 0;
}

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

.final-cta__title {
  font-size: var(--fs-h2);
  color: var(--clr-white);
  margin-bottom: var(--space-sm);
}

.final-cta__text {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.125rem;
  margin-bottom: var(--space-lg);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* ========================================
   14. Footer
   ======================================== */
.footer {
  background-color: var(--clr-neutral-900);
  padding: var(--space-lg) 0;
}

.footer__inner {
  text-align: center;
}

.footer__brand {
  margin-bottom: var(--space-sm);
}

.footer__name {
  display: block;
  font-family: var(--ff-heading);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--clr-white);
}

.footer__credential {
  display: block;
  font-size: var(--fs-small);
  color: var(--clr-neutral-400);
}

.footer__privacy {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: var(--fs-small);
  color: var(--clr-neutral-400);
  margin-bottom: var(--space-sm);
}

.footer__privacy svg {
  flex-shrink: 0;
}

.footer__copy {
  font-size: var(--fs-caption);
  color: var(--clr-neutral-400);
  opacity: 0.7;
}

/* ========================================
   15. Floating WhatsApp Button
   ======================================== */
.floating-whatsapp {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 56px;
  height: 56px;
  background-color: var(--clr-whatsapp);
  color: var(--clr-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.4);
  z-index: 90;
  transition: all var(--transition);
  opacity: 0;
  transform: scale(0.8);
  pointer-events: none;
}

.floating-whatsapp.visible {
  opacity: 1;
  transform: scale(1);
  pointer-events: all;
}

.floating-whatsapp:hover {
  background-color: var(--clr-whatsapp-hover);
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

/* ========================================
   16. Animations (Scroll Reveal)
   ======================================== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

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

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

/* ========================================
   17. Focus Styles
   ======================================== */
:focus-visible {
  outline: 2px solid var(--clr-primary);
  outline-offset: 3px;
}

button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--clr-primary);
  outline-offset: 3px;
}

/* ========================================
   18. Responsive - Tablets (600px+)
   ======================================== */
@media (min-width: 600px) {
  .specialties__grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

  .testimonials__grid .testimonial-card:last-child {
    grid-column: 1 / -1;
    max-width: 50%;
    justify-self: center;
  }

  .steps__grid {
    flex-direction: row;
    justify-content: center;
  }

  .step {
    flex: 1;
    max-width: 280px;
  }

  .hero__photo,
  .about__photo {
    width: 320px;
    height: 400px;
  }
}

/* ========================================
   19. Responsive - Desktop (900px+)
   ======================================== */
@media (min-width: 900px) {
  .container {
    padding: 0 2rem;
  }

  /* Header desktop */
  .hamburger {
    display: none;
  }

  .nav {
    position: static;
    width: auto;
    height: auto;
    background: transparent;
    box-shadow: none;
    padding: 0;
  }

  .nav__list {
    flex-direction: row;
    align-items: center;
    gap: 0.25rem;
  }

  .nav__link {
    padding: 0.5rem 0.625rem;
    font-size: var(--fs-small);
    white-space: nowrap;
  }

  .header__cta {
    display: inline-flex;
    margin-left: 1rem;
    flex-shrink: 0;
  }

  /* Hero desktop */
  .hero__inner {
    flex-direction: row;
    align-items: center;
    gap: var(--space-xl);
  }

  .hero__content {
    text-align: left;
    flex: 1;
  }

  .hero__subtitle {
    margin-left: 0;
    margin-right: 0;
  }

  .hero__badges {
    justify-content: flex-start;
  }

  .hero__image {
    flex-shrink: 0;
  }

  /* Specialties desktop */
  .specialties__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  /* About desktop */
  .about__inner {
    flex-direction: row;
    gap: var(--space-xl);
  }

  .about__image {
    flex-shrink: 0;
  }

  /* Testimonials desktop */
  .testimonials__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .testimonials__grid .testimonial-card:last-child {
    grid-column: auto;
    max-width: 100%;
    justify-self: auto;
  }
}

/* ========================================
   20. Responsive - Large Desktop (1200px+)
   ======================================== */
@media (min-width: 1200px) {
  .hero__photo,
  .about__photo {
    width: 380px;
    height: 460px;
  }

  .specialty-card {
    padding: var(--space-lg);
  }
}
