/* =========================================================
   Tax Studio — estilos
   Paleta de marca: #024F4F (teal) · #D3FFB4 (lima) · #682962 (morado)
   ========================================================= */

:root {
  --teal: #024F4F;
  --lime: #D3FFB4;
  --purple: #682962;
  --purple-dark: #5a234f;
  --white: #ffffff;
  --ink-60: rgba(0, 0, 0, 0.6);
  --ink-70: rgba(0, 0, 0, 0.7);
  --line: rgba(0, 0, 0, 0.08);

  /* Títulos: la marca usa Cocogoose Pro. Si el cliente compra la licencia web,
     agrega el @font-face y pon 'Cocogoose Pro' al inicio de esta lista. */
  --font-heading: 'Fredoka', ui-sans-serif, system-ui, sans-serif;
  --font-body: 'Poppins', ui-sans-serif, system-ui, sans-serif;

  --radius-xl: 2rem;
  --header-h: 64px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
  margin: 0;
  font-family: var(--font-body);
  color: #000;
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  line-height: 1.5;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-heading); margin: 0; }
p { margin: 0; }

::selection { background: var(--lime); color: var(--teal); }

:focus-visible { outline: 3px solid var(--purple); outline-offset: 3px; border-radius: 6px; }

.container { max-width: 80rem; margin: 0 auto; padding: 0 1.25rem; }
.container--narrow { max-width: 48rem; }
.container--cta { max-width: 56rem; text-align: center; position: relative; }

.icon {
  width: 1.25rem; height: 1.25rem; flex-shrink: 0;
  fill: none; stroke: currentColor; stroke-width: 2.2;
  stroke-linecap: round; stroke-linejoin: round;
}
.icon--lg { width: 1.5rem; height: 1.5rem; }

/* ---------- Botones y pills ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font-weight: 600; border-radius: 999px; padding: .875rem 1.75rem;
  white-space: nowrap;
  transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--sm { font-size: .875rem; padding: .625rem 1.25rem; }
.btn--sm .icon { width: 1rem; height: 1rem; }
.btn--lg { padding: 1rem 1.75rem; }
.btn--xl { padding: 1rem 2rem; font-size: 1.125rem; font-weight: 700; }
.btn--block { width: 100%; margin-top: 1rem; }
.btn--purple { background: var(--purple); color: var(--white); }
.btn--purple:hover { background: var(--purple-dark); box-shadow: 0 12px 24px -8px rgba(104, 41, 98, .55); }
.btn--lime { background: var(--lime); color: var(--teal); }
.btn--lime:hover { background: var(--white); }

.pill {
  display: inline-block; font-weight: 600; font-size: .875rem;
  padding: .375rem 1rem; border-radius: 999px; margin-bottom: 1rem;
}
.pill--lime { background: var(--lime); color: var(--teal); }
.pill--teal { background: var(--teal); color: var(--white); }

/* ---------- Header ---------- */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  transition: background-color .3s ease, box-shadow .3s ease;
}
.header__inner { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.header__logo { position: relative; display: block; width: 136px; }
.header__logo img { width: 100%; transition: opacity .3s ease; }
.header__logo .logo-dark { position: absolute; inset: 0; opacity: 0; }

.nav { display: none; gap: 2rem; }
.nav a { color: var(--white); font-size: .875rem; font-weight: 500; transition: color .2s; }
.nav a:hover { color: var(--lime); }

.header__cta { display: none; }

.menu-toggle {
  background: none; border: 0; padding: .5rem; cursor: pointer; color: var(--white);
  display: inline-flex;
}
.menu-toggle .icon-close { display: none; }
.menu-toggle[aria-expanded="true"] .icon-open { display: none; }
.menu-toggle[aria-expanded="true"] .icon-close { display: block; }

/* Header con fondo (al hacer scroll o con el menú abierto) */
.header.is-solid {
  background: rgba(255, 255, 255, .85);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  box-shadow: 0 1px 3px rgba(0, 0, 0, .08);
}
.header.is-solid .logo-light { opacity: 0; }
.header.is-solid .logo-dark { opacity: 1; }
.header.is-solid .nav a, .header.is-solid .menu-toggle { color: var(--teal); }
.header.is-solid .nav a:hover { color: var(--purple); }

.mobile-menu { background: var(--white); border-top: 1px solid var(--line); box-shadow: 0 10px 20px rgba(0, 0, 0, .08); }
.mobile-menu nav { display: flex; flex-direction: column; padding-top: 1rem; padding-bottom: 1rem; }
.mobile-menu nav > a:not(.btn) { padding: .75rem 0; color: var(--teal); font-weight: 500; border-bottom: 1px solid var(--line); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; background: var(--teal); color: var(--white);
  padding: 7rem 0 5rem;
}
.hero__blob1 { position: absolute; top: -6rem; left: -6rem; width: 18rem; height: 18rem; background: rgba(104, 41, 98, .35); filter: blur(40px); }
.hero__blob2 { position: absolute; bottom: 0; right: 0; width: 24rem; height: 24rem; background: rgba(211, 255, 180, .1); filter: blur(40px); }
.hero__grid { position: relative; display: grid; gap: 3rem; align-items: center; }
.hero__copy { text-align: center; }
.hero__copy .pill { font-size: .8rem; margin-bottom: 1.5rem; }
.hero__title { font-weight: 700; line-height: 1.05; letter-spacing: -0.02em; font-size: 2.25rem; text-wrap: balance; }
.hero__lead { margin: 1.5rem auto 0; font-size: 1.125rem; color: rgba(255, 255, 255, .85); max-width: 36rem; }
.hero__actions { margin-top: 2rem; display: flex; flex-wrap: wrap; flex-direction: column; gap: 1rem; justify-content: center; }
.hero__quote { margin-top: 1.5rem; font-size: .875rem; font-style: italic; color: rgba(255, 255, 255, .6); }
.br-sm { display: none; }

.hero__art { position: relative; display: flex; justify-content: center; }
.mascots {
  position: relative; width: min(100%, 26rem); aspect-ratio: 1 / 0.92;
  background: var(--white); border-radius: 42% 58% 63% 37% / 42% 38% 62% 58%;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .35);
}
.mascots img { position: absolute; }
.mascots__nube { width: 30%; left: 33%; top: 6%; animation-delay: -1.5s; }
.mascots__triangulo { width: 34%; right: 6%; top: 34%; }
.mascots__vaquero { width: 29%; left: 9%; top: 32%; transform-origin: 50% 100%; }

.ring { position: absolute; width: 6rem; height: 6rem; top: -1rem; left: max(0px, calc(50% - 15rem)); filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .25)); }

.hero__curve { position: absolute; bottom: -1px; left: 0; width: 100%; height: 40px; }

/* ---------- Secciones ---------- */
.section { padding: 5rem 0; position: relative; }
.section--lime { background: var(--lime); overflow: hidden; }
.section--teal { background: var(--teal); color: var(--white); }
.section__head { text-align: center; max-width: 42rem; margin: 0 auto 3.5rem; }
.section__title { font-weight: 700; font-size: 1.875rem; line-height: 1.15; letter-spacing: -0.02em; color: var(--teal); text-wrap: balance; }
.section--teal .section__title, .cta .section__title { color: var(--white); }
.section__lead { margin-top: 1rem; font-size: 1.125rem; color: var(--ink-60); }

.grid { display: grid; gap: 1.5rem; }

/* Servicios */
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-xl);
  padding: 1.75rem; transition: transform .3s ease, box-shadow .3s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 20px 40px -12px rgba(2, 79, 79, .18); }
.card__icon {
  width: 4rem; height: 4rem; border-radius: 50%; background: var(--lime); color: var(--teal);
  display: flex; align-items: center; justify-content: center; margin-bottom: 1.25rem;
  transition: transform .3s ease;
}
.card:hover .card__icon { transform: scale(1.1); }
.card__icon .icon { width: 2rem; height: 2rem; }
.card h3 { font-weight: 600; font-size: 1.25rem; color: var(--teal); margin-bottom: .5rem; }
.card p { color: var(--ink-60); line-height: 1.65; }

/* Nosotros */
.why__blob { position: absolute; top: -5rem; right: 0; width: 20rem; height: 20rem; background: rgba(2, 79, 79, .06); filter: blur(40px); }
.why__grid { position: relative; display: grid; gap: 3rem; align-items: center; }
.why__copy { order: 2; }
.why__copy .section__title { margin-bottom: 2rem; }
.benefits { display: grid; gap: 1.5rem; }
.benefit { display: flex; gap: 1rem; }
.benefit__icon {
  flex-shrink: 0; width: 3rem; height: 3rem; border-radius: 50%; background: var(--teal); color: var(--lime);
  display: flex; align-items: center; justify-content: center;
}
.benefit__icon .icon { width: 1.5rem; height: 1.5rem; }
.benefit h3 { font-weight: 600; font-size: 1.125rem; color: var(--teal); }
.benefit p { margin-top: .25rem; font-size: .875rem; line-height: 1.6; color: rgba(2, 79, 79, .75); }
.why__art { order: 1; position: relative; display: flex; justify-content: center; }
.why__halo { position: absolute; width: 18rem; height: 18rem; top: 50%; left: 50%; translate: -50% -50%; background: rgba(255, 255, 255, .6); filter: blur(24px); }
.why__art img { position: relative; width: 11rem; }

/* Cómo trabajamos */
.steps { position: relative; display: grid; gap: 2.5rem; }
.steps__line { display: none; position: absolute; top: 1rem; left: 0; width: 100%; height: 8rem; color: rgba(104, 41, 98, .3); }
.step { position: relative; text-align: center; }
.step__icon { position: relative; width: 5rem; height: 5rem; margin: 0 auto 1.25rem; }
.step__icon img { width: 100%; height: 100%; }
.step__icon span {
  position: absolute; top: -.5rem; right: -.25rem; width: 1.75rem; height: 1.75rem; border-radius: 50%;
  background: var(--purple); color: var(--white); font-size: .75rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.step h3 { font-weight: 600; font-size: 1.25rem; color: var(--teal); margin-bottom: .5rem; }
.step p { font-size: .875rem; color: var(--ink-60); line-height: 1.65; max-width: 15rem; margin: 0 auto; }
.steps__mascot { margin-top: 3.5rem; display: flex; justify-content: center; }
.steps__mascot img { width: 6.5rem; transform-origin: 50% 100%; }

/* Testimonios */
.testimonials { gap: 2.5rem 1.5rem; }
.bubble {
  position: relative; margin: 0; background: var(--white); color: var(--teal);
  border-radius: var(--radius-xl); padding: 1.75rem; box-shadow: 0 20px 40px -12px rgba(0, 0, 0, .3);
}
.bubble::after {
  content: ""; position: absolute; bottom: -.5rem; left: 2.5rem; width: 1rem; height: 1rem;
  background: var(--white); transform: rotate(45deg);
}
.stars { position: absolute; top: -.75rem; left: 1.75rem; display: flex; gap: 2px; background: var(--white); padding: .25rem .5rem; border-radius: 999px; }
.stars .icon { width: 1rem; height: 1rem; fill: var(--purple); stroke: var(--purple); stroke-width: 1.5; }
.bubble__who { display: flex; align-items: flex-start; gap: .75rem; margin-top: .5rem; }
.bubble__who strong { display: block; font-weight: 600; }
.bubble__who small { display: block; font-size: .875rem; color: rgba(0, 0, 0, .5); }
.avatar {
  flex-shrink: 0; width: 2.5rem; height: 2.5rem; border-radius: 50%; background: var(--lime);
  display: flex; align-items: center; justify-content: center; font-family: var(--font-heading); font-weight: 700;
}
.bubble blockquote { margin: 1rem 0 0; line-height: 1.65; }

/* FAQ */
.faq { display: grid; gap: 1rem; }
.faq details {
  border: 1px solid rgba(0, 0, 0, .1); border-radius: 1rem; background: rgba(211, 255, 180, .3);
  padding: 0 1.25rem; transition: background-color .2s;
}
.faq details[open] { background: rgba(211, 255, 180, .55); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.25rem 0; font-family: var(--font-heading); font-weight: 600; font-size: 1.125rem; color: var(--teal);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .icon { transition: transform .2s ease; }
.faq details[open] summary .icon { transform: rotate(180deg); }
.faq details p { padding-bottom: 1.25rem; color: var(--ink-70); line-height: 1.65; }

/* CTA final */
.cta { position: relative; overflow: hidden; background: var(--purple); color: var(--white); padding: 5rem 0; }
.cta__blob1 { position: absolute; top: -5rem; left: -5rem; width: 18rem; height: 18rem; background: rgba(211, 255, 180, .15); filter: blur(40px); }
.cta__blob2 { position: absolute; bottom: 0; right: 0; width: 20rem; height: 20rem; background: rgba(2, 79, 79, .3); filter: blur(40px); }
.cta__sello { width: 13rem; margin: 0 auto 2.5rem; }
.cta .lime { color: var(--lime); }
.cta__lead { margin: 1.25rem auto 2rem; font-size: 1.125rem; color: rgba(255, 255, 255, .85); max-width: 36rem; }

/* Footer */
.footer { background: var(--teal); color: var(--white); padding: 5rem 0 2.5rem; }
.footer__grid { display: grid; gap: 2.5rem; padding-bottom: 3rem; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.footer__logo { width: 13rem; margin-bottom: 1.25rem; }
.footer__about { color: rgba(255, 255, 255, .7); font-size: .875rem; line-height: 1.65; max-width: 20rem; }
.footer h3 { font-weight: 600; font-size: 1.125rem; color: var(--lime); margin-bottom: 1rem; }
.footer__list { list-style: none; margin: 0; padding: 0; display: grid; gap: .75rem; font-size: .875rem; }
.footer__list--plain { gap: .5rem; }
.footer__list a { display: inline-flex; align-items: center; gap: .75rem; transition: color .2s; word-break: break-all; }
.footer__list a:hover { color: var(--lime); }
.footer__list .icon { color: var(--lime); }
.footer__bottom {
  padding-top: 2rem; display: flex; flex-direction: column; align-items: center; gap: 1rem;
  font-size: .75rem; color: rgba(255, 255, 255, .5);
}
.footer__bottom a:hover { color: var(--lime); }

/* Franja de crédito CSSoftware */
.credit {
  display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 2px 10px;
  background: var(--purple); color: var(--white);
  padding: 1.25rem 1rem; border-top: 3px solid var(--lime);
  font-size: .95rem; letter-spacing: .06em; transition: background-color .25s ease;
}
.credit__by { font-weight: 500; opacity: .9; }
.credit__brand { display: inline-flex; align-items: center; gap: .5rem; white-space: nowrap; color: var(--lime); }
.credit__name { font-family: var(--font-heading); font-weight: 700; font-size: 1.2em; letter-spacing: .03em; text-transform: uppercase; }
.credit svg { width: 1.15rem; height: 1.15rem; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; transition: transform .25s ease; }
.credit:hover { background: var(--purple-dark); }
.credit:hover .credit__name { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 2px; }
.credit:hover svg { transform: translate(2px, -2px); }

/* Botón flotante de WhatsApp */
@keyframes wa-ring {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, .55); }
  70% { box-shadow: 0 0 0 18px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}
.wa-float {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 40;
  width: 3.5rem; height: 3.5rem; border-radius: 50%; background: #25D366; color: var(--white);
  display: flex; align-items: center; justify-content: center;
  animation: wa-ring 2.2s ease-out infinite; transition: transform .2s ease, background-color .2s ease;
}
.wa-float:hover { transform: scale(1.1); background: #1ebe5a; }
.wa-float .icon { width: 1.9rem; height: 1.9rem; }

/* ---------- Formas y animaciones ---------- */
.blob { border-radius: 42% 58% 63% 37% / 42% 38% 62% 58%; }
.blob-2 { border-radius: 63% 37% 38% 62% / 55% 45% 55% 45%; }

@keyframes float-slow { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
@keyframes float-soft { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-10px) rotate(2deg); } }
@keyframes sway { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(3deg); } }
@keyframes spin-slow { to { transform: rotate(360deg); } }
@keyframes pulse-ring {
  0% { box-shadow: 0 0 0 0 rgba(211, 255, 180, .7); }
  70% { box-shadow: 0 0 0 18px rgba(211, 255, 180, 0); }
  100% { box-shadow: 0 0 0 0 rgba(211, 255, 180, 0); }
}
@keyframes shimmer { from { background-position: 200% center; } to { background-position: -200% center; } }

.animate-float-slow { animation: float-slow 5s ease-in-out infinite; }
.animate-float-soft { animation: float-soft 6s ease-in-out infinite; }
.animate-sway { animation: sway 4s ease-in-out infinite; }
.animate-spin-slow { animation: spin-slow 22s linear infinite; }
.animate-pulse-ring { animation: pulse-ring 2.2s ease-out infinite; }

/* "SAT" del hero: entrada tipo sello, subrayado a mano, brillo y rebote periódico */
.sat {
  position: relative; display: inline-block; transform-origin: 50% 70%;
  filter: drop-shadow(0 0 18px rgba(211, 255, 180, .45));
  animation: sat-stamp .9s cubic-bezier(.2, .8, .2, 1) .3s both, sat-bounce 4.5s ease-in-out 2s infinite;
}
.sat__text {
  /* el padding evita que el brillo recorte la "T" */
  display: inline-block; padding: 0 .14em .06em .04em; margin: 0 -.14em -.06em -.04em;
  background: linear-gradient(100deg, var(--lime) 0%, var(--lime) 38%, #fff 47%, #fff 53%, var(--lime) 62%, var(--lime) 100%);
  background-size: 250% auto;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: var(--lime);
  animation: shimmer 2.6s linear 1.2s infinite;
}
.sat__underline {
  position: absolute; left: -2%; bottom: -.16em; width: 104%; height: .32em; overflow: visible;
}
.sat__underline path {
  fill: none; stroke: var(--lime); stroke-width: 5; stroke-linecap: round;
  stroke-dasharray: 112; stroke-dashoffset: 112;
  animation: sat-draw .7s ease-out 1.1s forwards;
}
@keyframes sat-stamp {
  0% { opacity: 0; transform: scale(2.6) rotate(-14deg); }
  55% { opacity: 1; transform: scale(.88) rotate(4deg); }
  75% { transform: scale(1.08) rotate(-2deg); }
  100% { opacity: 1; transform: scale(1) rotate(0); }
}
@keyframes sat-bounce {
  0%, 78%, 100% { transform: scale(1) rotate(0); }
  83% { transform: scale(1.16) rotate(-5deg); }
  88% { transform: scale(.95) rotate(3deg); }
  93% { transform: scale(1.05) rotate(-1deg); }
}
@keyframes sat-draw { to { stroke-dashoffset: 0; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .sat__underline path { stroke-dashoffset: 0; }
}

/* ---------- Responsive ---------- */
@media (min-width: 640px) {
  :root { --header-h: 80px; }
  .container { padding: 0 2rem; }
  .header__logo { width: 168px; }
  .header__cta { display: inline-flex; }
  .hero { padding: 8rem 0 7rem; }
  .hero__title { font-size: 3rem; }
  .hero__lead { font-size: 1.25rem; }
  .hero__actions { flex-direction: row; }
  .br-sm { display: inline; }
  .ring { width: 7rem; height: 7rem; }
  .hero__curve { height: 80px; }
  .section, .cta { padding: 7rem 0; }
  .section__title { font-size: 2.25rem; }
  .grid--3, .benefits { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .why__art img { width: 14rem; }
  .steps__mascot img { width: 8rem; }
  .cta__sello { width: 16rem; }
  .wa-float { width: 4rem; height: 4rem; }
  .wa-float .icon { width: 2.2rem; height: 2.2rem; }
  .footer__bottom { flex-direction: row; justify-content: space-between; }
  .credit { padding: 1.5rem 1rem; font-size: 1.05rem; }
}

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

@media (min-width: 1024px) {
  .nav { display: flex; }
  .menu-toggle, .mobile-menu { display: none !important; }
  .hero__grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .hero__copy { text-align: left; }
  .hero__lead { margin-left: 0; }
  .hero__actions { justify-content: flex-start; }
  .hero__title { font-size: 3.75rem; }
  .hero__art { justify-content: flex-end; }
  .ring { left: auto; right: calc(min(100%, 26rem) - 5rem); }
  .section__title { font-size: 3rem; }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .why__grid { grid-template-columns: 1fr 1fr; }
  .why__copy { order: 1; }
  .why__art { order: 2; }
  .why__art img { width: 17rem; }
  .steps { grid-template-columns: repeat(4, 1fr); gap: 2rem; }
  .steps__line { display: block; }
}
