/* ─────────────────────────────────────────────
   María Soldilon — portfolio
   Minimalista: fondo crudo, tinta, 4 acentos.
   ───────────────────────────────────────────── */
:root {
  --bg:   #faf7f2;
  --ink:  #1c1a17;
  --mut:  #8a8478;
  --line: #e6e0d6;
  --acc1: #e2572b;   /* terracota */
  --acc2: #2b5fe2;   /* azul */
  --acc3: #e8b62c;   /* ocre */
  --acc4: #2ba06b;   /* verde */
  --beige: #a68d63;  /* beige para palabras acentuadas */
  --btn:   #6c543c;  /* marrón tierra tomado de los murales de Sol */
  --serif: "Fraunces", Georgia, serif;
  --sans:  "Inter", -apple-system, Helvetica, Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--acc3); color: var(--ink); }

/* ── Nav ── */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; justify-content: space-between; align-items: center;
  padding: 1.1rem 4vw;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s;
}
.nav.is-scrolled { border-color: var(--line); }
.nav__logo {
  font-family: var(--serif); font-weight: 600; font-size: 1.15rem;
  color: var(--ink); text-decoration: none; letter-spacing: .01em;
}
.nav__links { display: flex; align-items: center; gap: 1.8rem; }
.nav__links a {
  color: var(--ink); text-decoration: none; font-size: .85rem;
  font-weight: 400; letter-spacing: .04em;
}
.nav__links a:hover { color: var(--acc1); }
.nav__cta {
  border: 1px solid var(--ink); border-radius: 99px;
  padding: .45rem 1.1rem !important; transition: background .25s, color .25s;
}
.nav__cta:hover { background: var(--ink); color: var(--bg) !important; }

/* ── Hero ── */
.hero {
  min-height: 86svh;
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  text-align: center; padding: 7rem 6vw 5rem; position: relative;
}
.hero__kicker {
  font-size: .8rem; letter-spacing: .35em; text-transform: uppercase;
  color: var(--mut); margin-bottom: 1.1rem;
  animation: rise .9s .1s both cubic-bezier(.2,.7,.2,1);
}
.hero__title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2.8rem, 8.5vw, 6.5rem);
  line-height: 1.04; letter-spacing: -.01em;
  animation: rise .9s .25s both cubic-bezier(.2,.7,.2,1);
}
.hero__title em { font-style: italic; color: var(--beige); }
.hero__sub {
  margin-top: 1.3rem; color: var(--mut); font-size: 1.02rem;
  animation: rise .9s .45s both cubic-bezier(.2,.7,.2,1);
}
@keyframes rise { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }

/* línea de tiempo de personajes bajo el texto del hero */
.hero__timeline {
  margin-top: 3rem;
  display: flex; align-items: flex-end; justify-content: center;
  gap: clamp(.6rem, 2.4vw, 2.6rem);
  padding: 0 3vw .6rem;
  border-bottom: 1px solid var(--line);
  max-width: 96vw;
}
.hero__timeline img {
  height: clamp(58px, 12.5vw, 160px);
  width: auto; display: block;
  opacity: 0; animation: charIn 1s both cubic-bezier(.2,.7,.2,1);
}
.hero__timeline img:nth-child(1) { animation-delay: .55s; }
.hero__timeline img:nth-child(2) { animation-delay: .7s; }
.hero__timeline img:nth-child(3) { animation-delay: .85s; }
.hero__timeline img:nth-child(4) { animation-delay: 1s; }
.hero__timeline img:nth-child(5) { animation-delay: 1.15s; }
.hero__timeline img:nth-child(6) { animation-delay: 1.3s; }
@keyframes charIn {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; }
}

.hero__scroll {
  margin-top: 2.6rem;
  display: flex; flex-direction: column; align-items: center; gap: .7rem;
  color: var(--mut); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase;
  animation: rise .9s .8s both cubic-bezier(.2,.7,.2,1);
}
.hero__arrow {
  width: 1px; height: 44px; background: var(--mut); position: relative; overflow: hidden;
}
.hero__arrow::after {
  content: ""; position: absolute; inset: 0;
  background: var(--ink); transform: translateY(-100%);
  animation: drip 1.8s infinite cubic-bezier(.4,0,.2,1);
}
@keyframes drip { 60%, 100% { transform: translateY(100%); } }

/* ── Escena scroll ── */
.scene { height: 340vh; position: relative; }
.scene__sticky {
  position: sticky; top: 0; height: 100svh; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.scene__svg { width: min(1100px, 96vw); height: auto; display: block; }
.scene__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.sc-el { opacity: 0; will-change: transform, opacity; }
.scene__caption {
  position: absolute; bottom: 9vh; left: 50%; transform: translate(-50%, 14px);
  font-family: var(--serif); font-style: italic;
  font-size: clamp(1.2rem, 2.6vw, 1.8rem);
  opacity: 0; transition: opacity .45s, transform .45s;
  white-space: nowrap;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  padding: .15em .7em; border-radius: 99px;
}
.scene__caption.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ── Secciones ── */
.sec-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2rem, 4.5vw, 3.2rem); letter-spacing: -.01em;
}
.sec-sub { color: var(--mut); margin-top: .6rem; }

/* ── Réalisations (masonry) ── */
.works { padding: 8rem 6vw; max-width: 1300px; margin: 0 auto; }
.works__grid {
  margin-top: 3.5rem;
  columns: 3; column-gap: 1.4rem;
}
.work {
  display: flex; flex-direction: column; gap: .7rem;
  break-inside: avoid; margin: 0 0 2.2rem;
}
.work img {
  width: 100%; height: auto; display: block; border-radius: 6px;
  transition: transform .5s cubic-bezier(.2,.7,.2,1);
}
.work:hover img { transform: translateY(-4px); }
.work figcaption { display: flex; flex-direction: column; gap: .1rem; }
.work figcaption strong { font-weight: 500; font-size: .95rem; }
.work figcaption span { color: var(--mut); font-size: .82rem; }

/* ── À propos ── */
.about {
  padding: 7rem 6vw; max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 2fr 3fr; gap: 4rem;
  align-items: center; border-top: 1px solid var(--line);
}
.about__photo { margin: 0; }
.about__photo img { width: 100%; height: auto; display: block; border-radius: 6px; }
.about__text p { color: var(--mut); margin-top: 1.1rem; max-width: 54ch; }
.about__text .sec-title { margin-bottom: .6rem; }

/* ── Servicios ── */
.services { padding: 7rem 6vw 8rem; max-width: 1300px; margin: 0 auto; border-top: 1px solid var(--line); }
.services__grid {
  margin-top: 3.5rem;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem;
}
.service--star { grid-column: 1 / -1; }
.service {
  border: 1px solid var(--line); border-radius: 8px; padding: 2.2rem 1.8rem;
  display: flex; flex-direction: column; gap: .9rem;
}
.service h3 { font-family: var(--serif); font-weight: 500; font-size: 1.35rem; }
.service p { color: var(--mut); font-size: .93rem; }
.service--star { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.service--star p { color: color-mix(in srgb, var(--bg) 72%, transparent); }
.service__tag {
  align-self: flex-start; font-size: .68rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--acc3); border: 1px solid color-mix(in srgb, var(--acc3) 60%, transparent);
  padding: .3rem .8rem; border-radius: 99px;
}

.steps {
  margin-top: 4.5rem; display: flex; justify-content: center; gap: clamp(2rem, 8vw, 7rem);
  text-align: center;
}
.step span {
  font-family: var(--serif); font-style: italic; font-size: 2rem; color: var(--acc1);
  display: block; margin-bottom: .4rem;
}
.step p { font-size: .88rem; color: var(--mut); }

/* ── Contacto ── */
.contact {
  padding: 9rem 6vw; text-align: center;
  border-top: 1px solid var(--line);
}
.contact__title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2.4rem, 6vw, 4.5rem); line-height: 1.1; letter-spacing: -.01em;
}
.contact__sub { color: var(--mut); margin-top: 1.4rem; }
.contact__btn {
  display: inline-block; margin-top: 2.6rem;
  background: var(--btn); color: #fff; text-decoration: none;
  font-weight: 500; font-size: 1rem; letter-spacing: .02em;
  padding: 1.1rem 2.8rem; border-radius: 99px;
  transition: transform .25s, box-shadow .25s;
}
.contact__btn:hover { transform: translateY(-3px); box-shadow: 0 14px 34px color-mix(in srgb, var(--btn) 35%, transparent); }
.contact__links { margin-top: 2.2rem; color: var(--mut); font-size: .9rem; display: flex; gap: .8rem; justify-content: center; }
.contact__links a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line); }
.contact__links a:hover { border-color: var(--ink); }

.footer { padding: 2rem 6vw; text-align: center; color: var(--mut); font-size: .78rem; border-top: 1px solid var(--line); }

/* ── Page devis ── */
.devis { max-width: 760px; margin: 0 auto; padding: 10rem 6vw 7rem; }
.devis .sec-title { text-align: center; }
.devis .sec-title em { font-style: italic; color: var(--beige); }
.devis__sub { text-align: center; color: var(--mut); margin: 1.2rem 0 3.5rem; }
.devis__form { display: flex; flex-direction: column; gap: 1.4rem; }
.devis__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; }
.devis__form label {
  display: flex; flex-direction: column; gap: .45rem;
  font-size: .85rem; font-weight: 500; letter-spacing: .02em;
}
.devis__opt { color: var(--mut); font-weight: 300; }
.devis__form input, .devis__form select, .devis__form textarea {
  font: inherit; font-weight: 300; color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  padding: .8rem 1rem; outline: none; transition: border-color .2s;
}
.devis__form input:focus, .devis__form select:focus, .devis__form textarea:focus {
  border-color: var(--acc1);
}
.devis__form textarea { resize: vertical; }
.devis__submit { align-self: center; margin-top: 1.2rem; border: none; cursor: pointer; font-family: var(--sans); }
.devis__result { text-align: center; }
.devis__result h2 { font-family: var(--serif); font-weight: 500; font-size: 1.8rem; margin-bottom: 1rem; }
.devis__result p { color: var(--mut); max-width: 46ch; margin: 0 auto 1.6rem; }
.devis__result textarea {
  width: 100%; font: inherit; font-weight: 300; font-size: .9rem; color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  padding: 1rem 1.2rem; resize: vertical;
}
.devis__actions { margin-top: 1.6rem; display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.devis__actions .contact__btn { margin-top: 0; border: none; cursor: pointer; font-family: var(--sans); }
.devis__mailto { color: var(--mut); font-size: .85rem; }
.devis__copy-mini {
  font: inherit; font-size: .75rem; color: var(--acc2);
  background: none; border: 1px solid var(--line); border-radius: 99px;
  padding: .15rem .7rem; cursor: pointer; margin: 0 .3rem;
}
.devis__copied { color: var(--acc4); font-weight: 500; margin-top: 1rem; }
.devis__form input[type="file"] {
  padding: .6rem; background: transparent; border-style: dashed; cursor: pointer;
}
.devis__form input[type="file"]::file-selector-button {
  font: inherit; font-size: .82rem; color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: 99px;
  padding: .4rem 1rem; margin-right: 1rem; cursor: pointer;
}
.devis__files { color: var(--mut); font-weight: 300; font-size: .8rem; min-height: 1em; }
.devis__error {
  text-align: center; color: var(--acc1); font-size: .9rem;
  border: 1px solid color-mix(in srgb, var(--acc1) 40%, transparent);
  border-radius: 8px; padding: .8rem 1.2rem;
}

/* ── Reveal on scroll ── */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.is-in { opacity: 1; transform: none; }

/* ── Responsive ── */
@media (max-width: 1100px) {
  .works__grid { columns: 2; }
}
@media (max-width: 820px) {
  .nav__links a:not(.nav__cta) { display: none; }
  .hero__sub br { display: none; }
  .works__grid { columns: 1; }
  .services__grid { grid-template-columns: 1fr; }
  .about { grid-template-columns: 1fr; gap: 2.5rem; }
  .about__photo { max-width: 420px; }
  .devis__row { grid-template-columns: 1fr; }
  .scene { height: 260vh; }
  .steps { flex-direction: column; gap: 2rem; }
  .scene__caption { white-space: normal; text-align: center; width: 90vw; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal, .hero__kicker, .hero__title, .hero__sub { animation: none; transition: none; opacity: 1; transform: none; }
}
