/* ==========================================================================
   Flor Romero · estilos
   1. Tokens   2. Base   3. Layout   4. Componentes   5. Secciones
   6. Animaciones de scroll   7. Responsive
   ========================================================================== */

/* 1. Tokens: colores y tipografías de la marca ------------------------------ */
:root {
  --principal: #5a2738;
  --principal-hover: #47192a;
  --acento: #d8796f;
  --acento-hover: #e28d84;
  --secundario: #e6d6d1;
  --fondo: #faf6ef;
  --texto: #272727;

  --texto-suave: #55504f;
  --linea: #d6c2bc;
  --linea-oscura: rgba(250, 246, 239, 0.24);

  --font-title: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Manrope", "Segoe UI", system-ui, sans-serif;

  --radius: 26px;
  --radius-sm: 12px;
  --header-h: 68px;
  --container: 1160px;
  --gutter: 20px;
}

/* 2. Base ------------------------------------------------------------------ */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--fondo);
  color: var(--texto);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

main {
  overflow-x: clip;
}

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

h1,
h2,
h3,
h4 {
  margin: 0 0 0.5em;
  color: var(--principal);
  font-family: var(--font-title);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.3rem, 5.4vw, 4.4rem);
  line-height: 1.04;
}

h2 {
  font-size: clamp(1.9rem, 3.8vw, 3rem);
}

h3 {
  font-size: 1.4rem;
}

h4 {
  font-size: 1.25rem;
}

p {
  margin: 0 0 1em;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
}

[hidden] {
  display: none !important;
}

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

.section--dark :focus-visible {
  outline-color: var(--fondo);
}

section[id] {
  scroll-margin-top: calc(var(--header-h) + 12px);
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--principal);
  color: var(--fondo);
  border-radius: var(--radius-sm);
}

.skip-link:focus {
  top: 12px;
}

/* 3. Layout ---------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--narrow {
  max-width: 820px;
}

.section {
  padding-block: 72px;
}

.section--soft {
  background: var(--secundario);
}

.section--dark {
  background: var(--principal);
  color: var(--fondo);
}

.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: var(--fondo);
}

.section-head {
  max-width: 720px;
  margin-bottom: 44px;
}

.section-head h2:last-child {
  margin-bottom: 0;
}

.section-head > p:last-child {
  margin-bottom: 0;
  color: var(--texto-suave);
  font-size: 1.12rem;
}

/* 4. Componentes ----------------------------------------------------------- */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  color: var(--principal);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  flex: 0 0 32px;
  height: 2px;
  background: var(--acento);
}

/* Destacado en itálica: subrayado en color de acento sobre claro,
   texto en color de acento sobre oscuro. */
.resaltado {
  font-style: italic;
  text-decoration: underline;
  text-decoration-color: var(--acento);
  text-decoration-thickness: 0.07em;
  text-underline-offset: 0.14em;
}

.section--dark .resaltado {
  color: var(--acento);
  text-decoration: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 56px;
  padding: 14px 30px;
  border: 0;
  border-radius: 999px;
  background: var(--principal);
  color: var(--fondo);
  font: 700 1.02rem/1.2 var(--font-body);
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.2s;
}

.btn:hover {
  background: var(--principal-hover);
  transform: translateY(-2px);
}

.btn--accent {
  background: var(--acento);
  color: var(--texto);
}

.btn--accent:hover {
  background: var(--acento-hover);
}

.btn--small {
  min-height: 46px;
  padding: 10px 22px;
  font-size: 0.95rem;
}

.btn--block {
  width: 100%;
}

.btn[disabled] {
  opacity: 0.6;
  cursor: progress;
  transform: none;
}

.btn-icon {
  flex: none;
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  margin-top: 32px;
}

.cta--center {
  align-items: center;
  margin-top: 48px;
  text-align: center;
}

.cta-note {
  max-width: 30em;
  margin: 0;
  color: var(--texto-suave);
  font-size: 0.95rem;
}

.section--dark .cta-note {
  color: var(--secundario);
}

/* El logo es un JPG con fondo blanco: multiply lo funde con el fondo crema. */
.logo {
  display: inline-flex;
  align-items: center;
  background: var(--fondo);
  isolation: isolate;
}

.logo img {
  width: auto;
  height: 46px;
  mix-blend-mode: multiply;
}

.tag {
  display: inline-block;
  margin-bottom: 18px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--secundario);
  color: var(--principal);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

/* 5. Secciones ------------------------------------------------------------- */

/* Encabezado */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding-top: env(safe-area-inset-top, 0px);
  background: var(--fondo);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}

.site-header.is-scrolled,
.site-header.is-open {
  border-bottom-color: var(--linea);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
}

.nav-toggle {
  display: grid;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 11px 9px;
  border: 0;
  background: none;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--principal);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(8.5px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-8.5px) rotate(-45deg);
}

.nav {
  position: absolute;
  inset: 100% 0 auto 0;
  display: none;
  padding: 8px var(--gutter) 24px;
  background: var(--fondo);
  border-bottom: 1px solid var(--linea);
}

.nav.is-open {
  display: block;
}

.nav ul {
  margin-bottom: 18px;
}

.nav li a {
  display: block;
  padding: 14px 0;
  border-bottom: 1px solid var(--linea);
  font-weight: 500;
  text-decoration: none;
}

.nav li a:hover {
  color: var(--principal);
}

/* Sin JavaScript no hay menú desplegable: se muestra siempre */
html:not(.js) .site-header {
  position: static;
}

html:not(.js) .nav-toggle {
  display: none;
}

html:not(.js) .header-inner {
  flex-wrap: wrap;
}

html:not(.js) .nav {
  position: static;
  display: block;
  width: 100%;
  padding-inline: 0;
  border: 0;
}

/* Primera pantalla */
.hero {
  padding: calc(var(--header-h) + 44px) 0 72px;
}

.hero-inner {
  display: grid;
  gap: 48px;
  align-items: center;
}

.hero h1 {
  margin-bottom: 0.45em;
}

.lead {
  max-width: 36em;
  margin-bottom: 0;
  color: var(--texto-suave);
  font-size: 1.15rem;
}

.section--dark .lead {
  color: var(--secundario);
}

.hero-art {
  display: none;
  position: relative;
  width: 100%;
  max-width: 400px;
  margin-inline: auto;
}

.hero-art-arch {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 14px;
  aspect-ratio: 4 / 5;
  padding: 28px;
  background: var(--secundario);
  border-radius: 999px 999px var(--radius) var(--radius);
}

.hero-art-dot {
  position: absolute;
  top: 6%;
  right: -4%;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: var(--acento);
}

.hero-art-chip {
  display: flex;
  flex-direction: column;
  padding: 16px 22px;
  background: var(--fondo);
  border-radius: 18px;
}

.hero-art-chip strong {
  color: var(--principal);
  font: 500 1.35rem/1.2 var(--font-title);
}

.hero-art-chip span {
  color: var(--texto-suave);
  font-size: 0.9rem;
}

/* Situaciones del negocio */
.situations {
  display: grid;
  gap: 18px;
}

.situation {
  padding: 28px;
  background: var(--fondo);
  border-radius: var(--radius);
}

.situation h3 {
  font-size: 1.3rem;
}

.situation p,
.channel p,
.extra p,
.step p {
  margin-bottom: 0;
  color: var(--texto-suave);
}

/* Servicio principal */
.channels {
  display: grid;
  gap: 20px;
}

.channel {
  padding: 32px;
  border: 1px solid var(--linea);
  border-radius: var(--radius);
}

.channel h3 {
  font-size: 1.6rem;
}

.includes {
  margin-top: 24px;
  padding: 36px 24px;
  background: var(--principal);
  border-radius: var(--radius);
  color: var(--secundario);
}

.includes-title {
  margin-bottom: 28px;
  color: var(--fondo);
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  font-style: italic;
}

.includes-grid {
  display: grid;
  gap: 28px;
  margin-bottom: 36px;
}

.include {
  padding-top: 20px;
  border-top: 1px solid var(--linea-oscura);
}

.include h4 {
  color: var(--fondo);
}

.include p {
  margin-bottom: 0;
}

/* Testimonios (sección desactivada en el HTML hasta tener contenido real) */
.quotes {
  display: grid;
  gap: 20px;
}

.quote {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
  margin: 0;
  padding: 32px;
  border: 1px solid var(--linea);
  border-radius: var(--radius);
}

.quote blockquote {
  margin: 0;
  color: var(--principal);
  font: italic 500 1.3rem/1.35 var(--font-title);
}

.quote figcaption strong,
.quote figcaption span {
  display: block;
}

.quote figcaption span {
  color: var(--texto-suave);
  font-size: 0.92rem;
}

/* Sobre Flor */
.about {
  display: grid;
  gap: 40px;
  align-items: center;
}

.about-photo {
  width: 100%;
  max-width: 380px;
  margin: 0 auto;
}

.about-photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 28% center;
  border-radius: 999px 999px var(--radius) var(--radius);
}

.about-text p:not(.eyebrow) {
  color: var(--texto-suave);
}

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

/* Servicios complementarios: menor protagonismo, sin tarjetas llenas */
.extras {
  display: grid;
  gap: 32px;
}

.extra {
  padding-top: 20px;
  border-top: 1px solid var(--linea);
}

.extra h3 {
  font-size: 1.3rem;
}

.extras-note {
  margin: 36px 0 0;
  color: var(--texto-suave);
  font-size: 0.95rem;
  font-style: italic;
}

/* Cómo empezamos */
.steps {
  display: grid;
  gap: 36px;
}

.step-num {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 18px;
  border-radius: 50%;
  background: var(--acento);
  color: var(--texto);
  font: 500 1.5rem/1 var(--font-title);
}

/* Preguntas frecuentes */
.faq details {
  border-bottom: 1px solid var(--linea);
}

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

.faq summary {
  position: relative;
  padding: 22px 48px 22px 0;
  color: var(--principal);
  font: 500 1.25rem/1.3 var(--font-title);
  cursor: pointer;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  translate: 0 -50%;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--secundario);
  color: var(--principal);
  font: 400 1.4rem/1 var(--font-body);
  transition: rotate 0.25s;
}

.faq details[open] summary::after {
  rotate: 45deg;
}

.faq-body {
  padding: 0 48px 24px 0;
  color: var(--texto-suave);
}

.faq-body p:last-child {
  margin-bottom: 0;
}

/* Contacto final */
.contact {
  display: grid;
  gap: 44px;
}

.contact-text h2 {
  font-size: clamp(2rem, 4.2vw, 3.3rem);
}

.form-card {
  padding: 28px 22px;
  background: var(--fondo);
  border-radius: var(--radius);
  color: var(--texto);
}

.form {
  display: grid;
  gap: 18px;
}

.form h3 {
  margin: 0;
  color: var(--principal);
  font-size: 1.7rem;
}

.form-intro {
  margin: -8px 0 4px;
  color: var(--texto-suave);
}

.field {
  display: grid;
  gap: 6px;
}

.field label {
  font-size: 0.95rem;
  font-weight: 700;
}

.optional {
  color: var(--texto-suave);
  font-weight: 400;
}

.field input,
.field textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--linea);
  border-radius: var(--radius-sm);
  color: var(--texto);
  font: inherit;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--principal);
  box-shadow: 0 0 0 3px rgba(90, 39, 56, 0.18);
}

.hp {
  display: none;
}

.form-demo {
  margin: 0;
  color: var(--texto-suave);
  font-size: 0.9rem;
  text-align: center;
}

.form-error {
  margin: 0;
  color: #8a1f1f;
  font-size: 0.95rem;
  font-weight: 500;
}

.form-success {
  margin: 0;
  padding: 28px 8px;
  color: var(--principal);
  font: italic 500 1.5rem/1.35 var(--font-title);
  text-align: center;
}

.form-success:focus {
  outline: none;
}

/* Pie de página */
.site-footer {
  padding-block: 48px 32px;
  font-size: 0.98rem;
}

.footer-inner {
  display: grid;
  gap: 28px;
}

.footer-brand p {
  max-width: 22em;
  margin: 14px 0 0;
  color: var(--texto-suave);
}

.footer-col h2 {
  margin-bottom: 6px;
  color: var(--principal);
  font: 700 0.82rem/1.4 var(--font-body);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.footer-col a {
  overflow-wrap: anywhere;
  text-underline-offset: 4px;
}

.site-footer a:hover {
  color: var(--principal);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 24px;
  border-top: 1px solid var(--linea);
  color: var(--texto-suave);
  font-size: 0.92rem;
}

/* Página de política de privacidad */
.legal {
  padding: 56px 0 72px;
}

.legal h1 {
  font-size: clamp(2rem, 4.4vw, 3.2rem);
}

.legal h2 {
  margin-top: 1.6em;
  font-size: 1.5rem;
}

.legal ul {
  margin: 0 0 1em;
  padding-left: 1.2em;
  list-style: disc;
}

.legal li {
  margin-bottom: 0.4em;
}

.legal-meta {
  color: var(--texto-suave);
  font-size: 0.95rem;
}

.back-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 700;
  text-underline-offset: 4px;
}

/* 6. Animaciones de scroll ------------------------------------------------- */
/* Solo se oculta contenido si hay JS (clase .js en <html>).
   main.js agrega .is-visible cuando el elemento entra en pantalla;
   --i es el orden dentro del grupo que entra junto y genera el escalonado. */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity 0.65s ease-out,
    transform 0.65s cubic-bezier(0.2, 0.7, 0.2, 1);
  transition-delay: calc(var(--i, 0) * 90ms);
  will-change: opacity, transform;
}

.js [data-reveal="left"] {
  transform: translateX(-36px);
}

.js [data-reveal="right"] {
  transform: translateX(36px);
}

.js [data-reveal="zoom"] {
  transform: scale(0.94);
}

.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .js [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .btn {
    transition: none;
  }

  .btn:hover {
    transform: none;
  }
}

/* 7. Responsive ------------------------------------------------------------ */
@media (min-width: 640px) {
  :root {
    --gutter: 28px;
  }

  .section {
    padding-block: 104px;
  }

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

  .includes {
    padding: 52px 48px;
  }

  .form-card {
    padding: 40px;
  }

  .footer-inner {
    grid-template-columns: 1.4fr 1fr 1fr;
  }

  .footer-bottom {
    grid-column: 1 / -1;
  }
}

@media (min-width: 1024px) {
  :root {
    --header-h: 80px;
  }

  .logo img {
    height: 54px;
  }

  .nav-toggle {
    display: none;
  }

  .nav,
  html:not(.js) .nav {
    position: static;
    display: flex;
    align-items: center;
    gap: 32px;
    width: auto;
    padding: 0;
    background: none;
    border: 0;
  }

  .nav ul {
    display: flex;
    gap: 32px;
    margin: 0;
  }

  .nav li a {
    padding: 6px 0;
    border: 0;
    font-size: 0.98rem;
  }

  .hero {
    padding: calc(var(--header-h) + 64px) 0 104px;
  }

  .hero-inner {
    grid-template-columns: 1.25fr 0.75fr;
    gap: 72px;
  }

  .hero-art {
    display: block;
  }

  .situations {
    grid-template-columns: repeat(4, 1fr);
  }

  .includes-grid,
  .extras,
  .steps,
  .quotes {
    grid-template-columns: repeat(3, 1fr);
  }

  .extras,
  .steps {
    gap: 48px;
  }

  .about {
    grid-template-columns: 0.75fr 1.25fr;
    gap: 80px;
  }

  .contact {
    grid-template-columns: 1fr 1fr;
    gap: 72px;
    align-items: start;
  }
}
