/* =========================================================
   HorsePower Media — estilos
   Paleta del logo: crema, tinta y dorado (sin fondos oscuros).
   ========================================================= */

:root {
  --cream: #f5eee8;
  --cream-2: #ede3da;
  --ink: #1d1b19;
  --ink-soft: #4a4541;
  --muted: #655d56;
  --gold: #b0916c;
  --gold-dark: #7a5d3e;
  --line: rgba(29, 27, 25, .14);
  --container: 1160px;
  --font-serif: "Cormorant Garamond", "Times New Roman", serif;
  --font-sans: "Jost", system-ui, -apple-system, "Segoe UI", sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
em { font-style: italic; color: var(--gold-dark); }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

.eyebrow {
  display: inline-block;
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 22px;
}

/* Línea dorada con rombo, como el subrayado de "MEDIA" en el logo */
.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 220px;
  margin: 36px auto;
}
.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--gold);
}
.divider span {
  width: 6px; height: 6px;
  transform: rotate(45deg);
  border: 1px solid var(--gold);
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 38px;
  background: var(--gold-dark);
  color: #fff;
  border: 1px solid var(--gold-dark);
  font-family: var(--font-sans);
  font-size: .82rem;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
  transition: background .3s ease, color .3s ease, border-color .3s ease;
}
.btn:hover { background: #634a30; border-color: #634a30; }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn--ghost:hover { background: transparent; color: var(--gold-dark); border-color: var(--gold-dark); }
.btn--small { padding: 11px 24px; font-size: .74rem; }

/* ---------- Logo ---------- */
/* Arriba del todo el logo grande está en la portada; el de la cabecera aparece al bajar */
.logo {
  display: block;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .4s ease, transform .4s ease, visibility .4s ease;
}
.header.is-scrolled .logo,
.header.menu-open .logo { opacity: 1; visibility: visible; transform: none; }
.logo__img { height: 42px; width: auto; }

/* ---------- Cabecera ---------- */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding: 26px 0;
  border-bottom: 1px solid transparent;
  transition: background .35s ease, padding .35s ease, border-color .35s ease;
}
.header.is-scrolled {
  background: rgba(245, 238, 232, .92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 14px 0;
  border-color: var(--line);
}
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav { display: flex; align-items: center; gap: 40px; margin-left: auto; }

/* Selector de idioma */
.lang {
  display: flex;
  align-items: center;
  margin-left: 32px;
  padding-left: 24px;
  border-left: 1px solid var(--line);
}
.lang button {
  background: none;
  border: 0;
  padding: 6px 7px;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: .74rem;
  font-weight: 500;
  letter-spacing: .12em;
  color: var(--muted);
  transition: color .25s ease;
}
.lang button:hover { color: var(--ink); }
.lang button[aria-pressed="true"] {
  color: var(--gold-dark);
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: 6px;
}
.nav a:not(.btn) {
  position: relative;
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-soft);
  transition: color .25s ease;
}
.nav a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 50%; bottom: -6px;
  width: 0; height: 1px;
  background: var(--gold);
  transition: width .3s ease, left .3s ease;
}
.nav a:not(.btn):hover { color: var(--ink); }
.nav a:not(.btn):hover::after { width: 100%; left: 0; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 7px;
  background: none;
  border: 0;
  padding: 10px 4px;
  cursor: pointer;
}
.nav-toggle span {
  width: 28px; height: 1px;
  background: var(--ink);
  transition: transform .3s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(4px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { transform: translateY(-4px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: 150px 0 120px;
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 30%, rgba(255, 255, 255, .7) 0%, rgba(255, 255, 255, 0) 60%),
    var(--cream);
}
.hero__content { position: relative; }
.hero__logo { margin: 0 auto 56px; max-width: 720px; }
.hero__logo img { width: 100%; height: auto; }
.hero__title {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2.4rem, 5.6vw, 4.6rem);
  line-height: 1.08;
  letter-spacing: -.005em;
  margin-bottom: 26px;
}
.hero__subtitle {
  max-width: 540px;
  margin: 0 auto 44px;
  font-size: 1.08rem;
  font-weight: 300;
  color: var(--ink-soft);
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

.scroll-hint {
  position: absolute;
  left: 50%; bottom: 36px;
  width: 1px; height: 60px;
  background: var(--line);
  overflow: hidden;
}
.scroll-hint span {
  position: absolute;
  left: 0; top: -30px;
  width: 1px; height: 30px;
  background: var(--gold-dark);
  animation: scroll 2.2s ease-in-out infinite;
}
@keyframes scroll {
  to { top: 60px; }
}

/* ---------- Manifiesto ---------- */
.intro {
  background: var(--cream-2);
  color: var(--ink);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 120px 0;
  text-align: center;
}
.intro__text {
  max-width: 860px;
  margin: 0 auto;
  font-family: var(--font-serif);
  font-size: clamp(1.7rem, 3.4vw, 2.6rem);
  font-weight: 400;
  line-height: 1.35;
}
.intro em { color: var(--gold-dark); }

/* ---------- Secciones ---------- */
.section { padding: 140px 0; }
.section--alt { background: var(--cream-2); }
.section__head {
  max-width: 640px;
  margin: 0 auto 80px;
  text-align: center;
}
.section__head--row {
  max-width: none;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  text-align: left;
}
.section__title {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2.3rem, 4.6vw, 3.6rem);
  line-height: 1.1;
}

/* ---------- Servicios ---------- */
.services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.service {
  position: relative;
  padding: 44px 36px 40px;
  border: 1px solid var(--line);
  transition: background .35s ease, border-color .35s ease;
}
.service:hover { background: rgba(255, 255, 255, .55); border-color: var(--gold); }

/* Servicio destacado: venta online */
.service--featured {
  background: #ecdfcf;
  border-color: var(--gold);
}
.service--featured:hover { background: #ecdfcf; }
.service__badge {
  position: absolute;
  top: 40px; right: 32px;
  font-size: .66rem;
  font-weight: 500;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #fff;
  background: var(--gold-dark);
  padding: 6px 11px;
}
.service__num {
  display: block;
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-style: italic;
  color: var(--gold-dark);
  margin-bottom: 28px;
}
.service h3 {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 500;
  line-height: 1.2;
  margin-bottom: 14px;
}
.service p { font-size: .96rem; font-weight: 300; color: var(--ink-soft); }

/* ---------- Método ---------- */
.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
}
.step { text-align: center; }
.step__num {
  display: grid;
  place-items: center;
  width: 64px; height: 64px;
  margin: 0 auto 26px;
  border: 1px solid var(--gold);
  border-radius: 50%;
  font-family: var(--font-serif);
  font-size: 1.3rem;
  color: var(--gold-dark);
}
.step h3 {
  font-family: var(--font-serif);
  font-size: 1.7rem;
  font-weight: 500;
  margin-bottom: 10px;
}
.step p { font-size: .96rem; font-weight: 300; color: var(--ink-soft); max-width: 240px; margin: 0 auto; }

/* ---------- Proyectos ---------- */
.link-arrow {
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gold-dark);
  border-bottom: 1px solid var(--gold);
  padding-bottom: 4px;
  transition: color .25s ease;
}
.link-arrow:hover { color: var(--ink); }

.works {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.work { display: block; }
.work__media {
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--line);
  transition: opacity .4s ease;
}
/* Fondos provisionales: sustitúyelos por imágenes reales */
.work__media--1 { background-image: linear-gradient(160deg, #d9c6b0 0%, #8a6c4b 100%); }
.work__media--2 { background-image: linear-gradient(140deg, #efe6dc 0%, #c9b296 100%); }
.work__media--3 { background-image: linear-gradient(200deg, #e8ddd2 0%, #b0916c 120%); }
.work__media img { width: 100%; height: 100%; object-fit: cover; }
.work:hover .work__media { opacity: .85; }
.work__info { padding-top: 20px; }
.work__tag {
  display: block;
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 6px;
}
.work:hover h3 { color: var(--gold-dark); }
.work h3 {
  font-family: var(--font-serif);
  font-size: 1.9rem;
  font-weight: 400;
  line-height: 1.15;
}

/* ---------- Contacto ---------- */
.cta {
  padding: 150px 0;
  text-align: center;
  border-top: 1px solid var(--line);
  background:
    radial-gradient(ellipse at 50% 100%, rgba(176, 145, 108, .18) 0%, rgba(176, 145, 108, 0) 60%),
    var(--cream);
}
.cta__inner { display: flex; flex-direction: column; align-items: center; }
.cta__title {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2.3rem, 5.4vw, 4.2rem);
  line-height: 1.1;
}
.cta .divider { margin: 32px auto; }
.cta__text { font-weight: 300; color: var(--ink-soft); margin-bottom: 36px; }
.btn--email { text-transform: none; letter-spacing: .06em; font-size: .95rem; }

/* ---------- Pie ---------- */
.footer {
  background: var(--cream-2);
  color: var(--ink);
  border-top: 1px solid var(--line);
  padding: 70px 0 40px;
}
.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 34px;
  text-align: center;
}
.footer__logo img { width: 280px; max-width: 70vw; height: auto; }
.footer__social { display: flex; flex-wrap: wrap; justify-content: center; gap: 34px; }
.footer__social a {
  font-size: .76rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-soft);
  transition: color .25s ease;
}
.footer__social a:hover { color: var(--gold-dark); }
.footer__copy {
  width: 100%;
  padding-top: 30px;
  border-top: 1px solid var(--line);
  font-size: .8rem;
  letter-spacing: .08em;
  color: var(--muted);
}

/* ---------- Animación de aparición ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 1s ease, transform 1s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }

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

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .services { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); row-gap: 60px; }
}

@media (max-width: 820px) {
  .nav-toggle { display: flex; }
  .logo, .lang, .nav-toggle { position: relative; z-index: 101; }
  .lang { margin-left: auto; margin-right: 12px; padding-left: 0; border-left: 0; }
  .nav {
    position: fixed;
    inset: 0;
    flex-direction: column;
    justify-content: center;
    gap: 34px;
    margin: 0;
    background: var(--cream);
    opacity: 0;
    visibility: hidden;
    transition: opacity .35s ease, visibility .35s ease;
  }
  .nav.is-open { opacity: 1; visibility: visible; }
  .nav a:not(.btn) { font-size: 1rem; color: var(--ink); }

  .hero__logo { margin-bottom: 40px; }
  .section, .cta { padding: 100px 0; }
  .intro { padding: 90px 0; }
  .section__head { margin-bottom: 56px; }
  .works { grid-template-columns: 1fr; gap: 40px; }
  .work__media { aspect-ratio: 4 / 3; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .header { padding: 18px 0; }
  .logo__img { height: 30px; }
  .lang { margin-right: 4px; }
  .lang button { padding: 6px 4px; font-size: .7rem; }
  .services, .steps { grid-template-columns: 1fr; }
  .service { padding: 36px 24px 32px; }
  .service__badge { position: static; display: inline-block; margin-bottom: 20px; }
  .hero__actions .btn { width: 100%; }
  .btn--email { font-size: .82rem; letter-spacing: .02em; padding: 16px 18px; }
}
