/* VOICE: cercano y profesional, el de un freelance con muchos años de oficio
   IDEA: la tarjeta de visita de un taller: cálida, ordenada, con un sello naranja
   PICTURE: retrato sobre el gran círculo naranja; ilustraciones con formas orgánicas
   COLOUR and TYPE: blanco cálido, tinta casi negra, naranja como acento; Plus Jakarta Sans
   LAYOUT: bandas a todo el ancho, contenido a 1240px, una columna en móvil */
:root {
  color-scheme: light;
  --bg: #fbf7f6;
  --ink: #16161a;
  --muted: #4e4a47;
  --soft: #f5eee9;
  --line: #e6ddd6;
  --orange: #ff7a1a;
  --orange-t: #e0560a;
  --btn: #cf4507;
  --btn-h: #b23b05;
  --card: #ffffff;
  --r: 20px;
}
* {
  box-sizing: border-box;
  min-width: 0;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font:
    16px/1.6 "Plus Jakarta Sans",
    system-ui,
    -apple-system,
    "Segoe UI",
    sans-serif;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}
img {
  max-width: 100%;
  display: block;
}
a {
  color: inherit;
  text-decoration: none;
}
h1,
h2,
h3 {
  margin: 0;
  letter-spacing: -0.035em;
  line-height: 1.08;
  text-wrap: balance;
}
p {
  margin: 0;
}
:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
  border-radius: 6px;
}
.wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px;
}
.band {
  padding: clamp(44px, 6vw, 80px) 0;
}
.band.flush {
  padding-top: 0;
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.eyebrow::before {
  content: "";
  width: 24px;
  height: 2px;
  background: var(--orange);
}
.eyebrow.rev {
  flex-direction: row-reverse;
  justify-content: flex-end;
}
.h2 {
  font-size: clamp(32px, 3.6vw, 46px);
  font-weight: 800;
}
.head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px 32px;
  margin-bottom: 32px;
}
.head > p {
  color: var(--muted);
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 999px;
  border: 0;
  background: var(--btn);
  color: #fff;
  font-family: inherit;
  font-weight: 700;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(207, 69, 7, 0.22);
  transition:
    background 0.2s,
    transform 0.2s;
}
.btn:hover {
  background: var(--btn-h);
  transform: translateY(-1px);
}
.btn.ghost {
  background: #fff;
  color: var(--ink);
  border: 1.5px solid #cfc6be;
  box-shadow: none;
}
.btn.ghost:hover {
  border-color: var(--ink);
}
.btn svg {
  width: 18px;
  height: 18px;
  flex: none;
}
.ico {
  width: 44px;
  height: 44px;
  stroke: var(--orange-t);
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Cabecera */
.top {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 247, 246, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.top.scrolled {
  border-color: var(--line);
}
.top .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 76px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 21px;
  letter-spacing: -0.02em;
}
.brand img {
  width: 30px;
  height: auto;
}
.nav {
  display: flex;
  align-items: center;
  gap: 34px;
  margin-left: auto;
  font-size: 15px;
  font-weight: 600;
}
/* Selector de idioma (ES | CA): a la derecha del menú en escritorio, junto a la hamburguesa en móvil */
.lang {
  order: 1;
  display: flex;
  align-items: center;
  gap: 2px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.lang a {
  padding: 6px 8px;
  border-radius: 8px;
  color: var(--muted);
}
.lang a:hover {
  color: var(--ink);
}
.lang a[aria-current="page"] {
  color: var(--ink);
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--line);
}
.nav a:not(.btn) {
  color: var(--muted);
  padding: 6px 0;
  border-bottom: 2px solid transparent;
}
.nav a:not(.btn):hover,
.nav a.on {
  color: var(--ink);
  border-color: var(--orange);
}
.nav .btn {
  min-height: 44px;
  padding: 0 22px;
  font-size: 15px;
}
.burger {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.burger svg {
  width: 22px;
  height: 22px;
  stroke: var(--ink);
  stroke-width: 2;
  stroke-linecap: round;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
}
.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  align-items: center;
  gap: 40px;
  padding-top: 24px;
}
.hero-txt {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 40px 0 56px;
}
.hero-txt .eyebrow {
  margin-bottom: -6px;
}
.hero .hero-name {
  font-size: clamp(52px, 7vw, 88px);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1;
}
.hero .role {
  font-size: clamp(28px, 3.2vw, 40px);
  font-weight: 800;
  color: var(--orange-t);
  line-height: 1.1;
  letter-spacing: -0.03em;
}
.hero .lead {
  font-size: clamp(17px, 1.5vw, 19px);
  max-width: 520px;
  color: #2f2c29;
}
.hero .ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 10px;
}
.hero-pic {
  align-self: center;
  position: relative;
  top: 25px;
}
.hero-pic img {
  width: 100%;
  height: auto;
  border-radius: 0 var(--r) var(--r) 0;
}

/* Servicios */
#servicios {
  margin-top: -40px;
}
.grid4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}
.svc {
  background: var(--soft);
  border-radius: var(--r);
  padding: 30px 26px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition:
    transform 0.25s,
    box-shadow 0.25s;
}
.svc:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(60, 30, 10, 0.09);
}
.svc h3 {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-top: 6px;
}
.svc p {
  color: var(--muted);
  font-size: 15px;
}

/* Quién soy */
.about {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 48px;
  align-items: center;
}
.about-pic {
  position: relative;
  margin-top: 20px;
}
.about-pic img {
  width: calc(103.75% + 15px);
  max-width: none;
  height: auto;
  /* la imagen trae ~30px de 800 de fondo claro a la izquierda */
  margin-left: -3.75%;
  border-radius: 0 0 0 var(--r);
}
.badge {
  position: absolute;
  right: 8%;
  bottom: -18px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: 999px;
  background: #fde9dc;
  color: var(--btn);
  font-weight: 700;
  font-size: 15px;
  box-shadow: 0 8px 20px rgba(207, 69, 7, 0.12);
}
.badge svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
}
.about-txt {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-left: 40px;
  border-left: 1px solid var(--line);
  color: #2f2c29;
}

/* Tecnologías */
.tech {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(116px, 1fr));
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.tech li {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 60px;
  padding: 10px 16px;
  background: var(--soft);
  border-radius: 14px;
  font-weight: 700;
  font-size: 15px;
}
.tech img {
  width: 28px;
  height: 28px;
}

/* Samínter */
.sam {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 48px;
  align-items: center;
  padding: clamp(28px, 4vw, 52px);
  border-radius: 28px;
  background: linear-gradient(135deg, #fff5ee, #fce8da);
}
.sam::after {
  content: "";
  position: absolute;
  right: -170px;
  bottom: -235px;
  width: 470px;
  height: 300px;
  border-radius: 50%;
  border-top: 60px solid var(--orange);
  transform: rotate(-14deg);
  opacity: 0.85;
  pointer-events: none;
}
.sam-pic {
  position: relative;
  z-index: 1;
  width: 80%;
  margin: 0 auto;
}
.sam-pic img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 18px 40px -18px rgba(20, 30, 50, 0.45);
}
.sam-txt {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  z-index: 1;
  color: #2f2c29;
  font-size: 15.5px;
}
.sam-txt h2 {
  font-size: 28px;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 4px;
}
.sam-txt .btn {
  align-self: flex-start;
  margin-top: 10px;
}

/* Aficiones */
.hobby-txt .eyebrow {
  position: relative;
  top: 10px;
}
.hobby {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
}
.hobby-txt {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-right: 40px;
  border-right: 1px solid var(--line);
  color: #2f2c29;
}
.hobby-txt h2 {
  margin-bottom: 6px;
}
.hobby-pic {
  width: 100%;
  height: auto;
}

/* Carrusel de proyectos */
.carousel {
  position: relative;
}
.track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 48px) / 3);
  gap: 24px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding: 6px 2px 24px;
  margin: -6px -2px 0;
  overscroll-behavior-x: contain;
}
.track::-webkit-scrollbar {
  display: none;
}
.card {
  scroll-snap-align: start;
  background: var(--card);
  border: 1px solid #efe7e1;
  border-radius: 18px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition:
    transform 0.25s,
    box-shadow 0.25s;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(60, 30, 10, 0.1);
}
.card figure {
  margin: 0;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: var(--soft);
}
.card figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}
.card:hover figure img {
  transform: scale(1.04);
}
.card-body {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 20px 22px 24px;
}
.card .cat {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--btn);
  margin-bottom: 4px;
}
.card h3 {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.015em;
}
.card p {
  font-size: 14.5px;
  color: var(--muted);
  margin-top: 4px;
  line-height: 1.5;
}
.card .ext {
  flex: none;
  width: 20px;
  height: 20px;
  stroke: var(--orange-t);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  margin-top: 3px;
}
.c-ctrl {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 8px;
}
.dots {
  display: flex;
  gap: 8px;
}
.dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #dcd2ca;
  cursor: pointer;
  transition:
    width 0.25s,
    background 0.25s;
  position: relative;
}
.dot::after {
  content: "";
  position: absolute;
  inset: -17px -6px;
}
.dot[aria-current="true"] {
  width: 28px;
  background: var(--orange-t);
}
.c-btns {
  display: flex;
  align-items: center;
  gap: 10px;
}
.c-count {
  font-size: 14px;
  color: var(--muted);
  margin-right: 6px;
  white-space: nowrap;
}
.arrow {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1.5px solid #cfc6be;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    border-color 0.2s,
    background 0.2s,
    color 0.2s;
  color: var(--ink);
}
.arrow:hover:not(:disabled) {
  background: var(--btn);
  border-color: var(--btn);
  color: #fff;
}
.arrow:disabled {
  opacity: 0.35;
  cursor: default;
}
.arrow svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Clientes: slide de logos */
.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  padding: 6px 0;
}
.m-track {
  display: flex;
  width: max-content;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
  animation: marquee var(--dur, 60s) linear infinite;
}
.marquee:hover .m-track,
.marquee:focus-within .m-track {
  animation-play-state: paused;
}
.m-track li {
  flex: none;
  width: 200px;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px 22px;
  background: #fff;
  border: 1px solid #efe7e1;
  border-radius: 16px;
}
.m-track img {
  max-width: 100%;
  max-height: 60px;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: grayscale(1);
  opacity: 0.75;
  transition:
    filter 0.3s,
    opacity 0.3s;
}
.m-track li:hover img {
  filter: none;
  opacity: 1;
}
@keyframes marquee {
  to {
    transform: translateX(calc(-50% - 9px));
  }
}
@media (max-width: 600px) {
  .m-track li {
    width: 150px;
    height: 80px;
    padding: 12px 16px;
  }
  .m-track img {
    max-height: 46px;
  }
}

/* Contacto */
.contact {
  position: relative;
  overflow: hidden;
  padding-bottom: clamp(64px, 8vw, 110px);
}
.contact::after {
  content: "";
  position: absolute;
  right: -180px;
  bottom: -240px;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: linear-gradient(150deg, #ffb067, var(--orange) 60%);
  pointer-events: none;
}
.contact .wrap {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 48px;
  align-items: start;
}
.c-info {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-right: 40px;
  border-right: 1px solid var(--line);
}
.c-info .eyebrow {
  margin-bottom: -6px;
}
.c-info > p {
  color: #2f2c29;
}
.c-list {
  list-style: none;
  margin: 10px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  font-weight: 600;
}
.c-list li {
  display: flex;
  align-items: center;
  gap: 14px;
}
.c-list svg {
  width: 22px;
  height: 22px;
  stroke: var(--orange-t);
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.form {
  background: #fff;
  border-radius: 24px;
  padding: clamp(24px, 3vw, 36px);
  box-shadow: 0 24px 60px rgba(60, 30, 10, 0.1);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.field.full,
.form .full {
  grid-column: 1/-1;
}
.field label {
  font-size: 14px;
  font-weight: 700;
}
.field label span {
  color: var(--btn);
}
.field input,
.field textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 16px;
  border: 1px solid #dcd3cb;
  border-radius: 10px;
  background: #faf8f6;
  color: var(--ink);
  font-family: inherit;
  font-size: 16px;
  line-height: 1.4;
  transition:
    border-color 0.2s,
    background 0.2s;
}
.field textarea {
  min-height: 130px;
  resize: vertical;
}
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--orange-t);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255, 122, 26, 0.18);
}
.field.err input,
.field.err textarea {
  border-color: #c0262d;
}
.field .msg {
  font-size: 13px;
  color: #b3232a;
  display: none;
}
.field.err .msg {
  display: block;
}
.check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: var(--muted);
}
.check a {
  color: var(--btn);
  text-decoration: underline;
}
.check input {
  width: 20px;
  height: 20px;
  margin: 1px 0 0;
  accent-color: var(--btn);
  flex: none;
}
.form .btn {
  width: 100%;
}
.ok {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 12px;
  background: #e8f5ec;
  color: #14532d;
  font-weight: 600;
  font-size: 15px;
}
.ok.show {
  display: flex;
}
.ok.error {
  background: #fdecec;
  color: #8a1c22;
}
.form .btn:disabled {
  opacity: 0.7;
  cursor: progress;
  transform: none;
}
/* Campo trampa para bots: invisible para las personas */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

footer {
  border-top: 1px solid var(--line);
  font-size: 14px;
  color: var(--muted);
}
footer .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding-top: 26px;
  padding-bottom: 26px;
}
footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  font-weight: 700;
}
footer a:hover {
  color: var(--ink);
}
footer .foot-seo {
  font-size: 10px;
  line-height: 1.6;
}

/* Aviso legal */
.legal {
  padding-top: calc(clamp(44px, 6vw, 80px) - 40px);
}
.legal h1 {
  margin-bottom: 28px;
}
.legal h2 {
  font-size: clamp(22px, 2.4vw, 28px);
  font-weight: 800;
  margin: 44px 0 14px;
}
.legal h3 {
  font-size: 18px;
  font-weight: 700;
  margin: 30px 0 10px;
}
.legal h4 {
  font-size: 16px;
  margin: 22px 0 8px;
}
.legal p,
.legal ul {
  color: var(--muted);
  margin: 0 0 12px;
}
.legal ul {
  padding-left: 22px;
}
.legal p a {
  color: var(--orange-t);
  text-decoration: underline;
}
.legal .legal-back {
  margin-top: 44px;
}
.legal .legal-back a {
  font-weight: 700;
  text-decoration: none;
}

/* Responsive */
@media (max-width: 1080px) {
  .grid4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sam {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 960px) {
  .burger {
    display: flex;
  }
  .lang {
    order: 0;
    margin-left: auto;
  }
  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px max(4vw, 16px) 20px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    display: none;
  }
  .nav.open {
    display: flex;
  }
  .nav a:not(.btn) {
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
  }
  .nav a.on {
    border-color: var(--line);
    color: var(--orange-t);
  }
  .nav .btn {
    margin-top: 14px;
  }
  .hero .wrap,
  .about,
  .hobby,
  .contact .wrap {
    grid-template-columns: minmax(0, 1fr);
  }
  .hero-txt {
    padding: 24px 0 0;
  }
  .hero-pic {
    margin: 0 calc(-1 * 20px);
    top: 0;
  }
  #servicios {
    margin-top: 0;
  }
  .hero .wrap {
    padding-top: 4px;
  }
  footer nav {
    width: 100%;
    justify-content: center;
  }
  footer .foot-seo {
    width: 100%;
    text-align: center;
  }
  .about-txt {
    padding-left: 0;
    border-left: 0;
  }
  .hobby-txt {
    padding-right: 0;
    border-right: 0;
  }
  .c-info {
    padding-right: 0;
    border-right: 0;
  }
  .track {
    grid-auto-columns: calc((100% - 24px) / 2);
  }
}
@media (max-width: 600px) {
  .grid4 {
    grid-template-columns: minmax(0, 1fr);
  }
  .track {
    grid-auto-columns: 86%;
    gap: 16px;
  }
  .form {
    grid-template-columns: minmax(0, 1fr);
  }
  .c-count {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    transition: none !important;
  }
  .m-track {
    animation-duration: calc(var(--dur, 60s) * 3);
  }
}
