/* ============================================================
   ALBALORIOS — direcció d'art fidel a references/home_target.png
   ============================================================ */

:root {
  --cream: #f5ede0;
  --cream-2: #efe4ce;
  --kraft: #d8b989;
  --kraft-soft: rgba(216, 185, 137, 0.28);
  --ink: #3a2117;
  --ink-soft: #6b5443;
  --red: #9e2922;
  --red-deep: #7a1f1a;
  --red-bright: #b5342c;
  --wood: #4a2f1c;
  --white: #fffdf8;

  --serif: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --sans: "Work Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1220px;
}

* { box-sizing: border-box; }

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

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

h1, h2, h3 { font-family: var(--serif); font-weight: 600; margin: 0; color: var(--ink); }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

button, select, textarea, input { font-family: inherit; }
button { cursor: pointer; }

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 clamp(20px, 4.5vw, 60px);
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--red-deep);
  color: var(--white);
  padding: 12px 18px;
  z-index: 999;
  border-radius: 0 0 6px 0;
}
.skip-link:focus { left: 0; }

:focus-visible {
  outline: 2px solid var(--red-bright);
  outline-offset: 3px;
  border-radius: 2px;
}

/* -------------------- shared bits -------------------- */

.icon-heart { width: 20px; height: 20px; color: var(--red); flex-shrink: 0; }
.icon-heart--onwood { color: var(--white); margin-bottom: 10px; }

.section-title {
  font-size: clamp(1.8rem, 3.4vw, 2.4rem);
  font-weight: 600;
  line-height: 1.14;
  margin-bottom: 12px;
  color: var(--red-deep);
}
.section-title--centrat { text-align: center; }

.section-lead {
  max-width: 46ch;
  color: var(--ink-soft);
  font-size: 1.02rem;
}
.section-lead--centrat { margin-left: auto; margin-right: auto; text-align: center; }

.br-mobile { display: block; }
@media (min-width: 640px) { .br-mobile { display: none; } }
.br-desktop { display: none; }
@media (min-width: 640px) { .br-desktop { display: block; } }

/* small hand-drawn squiggle used once, as a decorative accent under "Les peces" */
.swash {
  display: inline-block;
  width: 60px;
  height: 13px;
  margin-left: 8px;
  vertical-align: middle;
  background-repeat: no-repeat;
  background-size: contain;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 14'%3E%3Cpath d='M2 8c4-8 8-8 12 0s8 8 12 0 8-8 12 0 8 8 12 0 8-8 12 0' fill='none' stroke='%239e2922' stroke-width='2.2' stroke-linecap='round'/%3E%3C/svg%3E");
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 14px 28px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  transition: background 0.15s ease;
}

.btn--primary {
  background: var(--red);
  color: var(--white);
}
.btn--primary:hover { background: var(--red-bright); }
.btn--primary:active { background: var(--red-deep); }

/* ============================================================
   01 HEADER
   ============================================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--cream);
  border-bottom: 1px solid rgba(58, 33, 23, 0.1);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  padding-top: 12px;
  padding-bottom: 12px;
  position: relative;
}

.logo { display: inline-flex; align-items: center; }
.logo__img { width: clamp(150px, 16vw, 210px); height: auto; }

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  background: transparent;
  border: none;
  padding: 0;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--red-deep);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-principal {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--cream);
  border-bottom: 1px solid rgba(58, 33, 23, 0.1);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 0 clamp(20px, 4.5vw, 60px);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease, padding 0.25s ease;
}
.nav-principal.is-open { max-height: 320px; padding: 10px clamp(20px, 4.5vw, 60px) 22px; }

.nav-principal ul { display: flex; flex-direction: column; width: 100%; }
.nav-principal a {
  display: block;
  padding: 10px 0;
  font-weight: 500;
  font-size: 1rem;
  border-bottom: 1px solid rgba(58, 33, 23, 0.1);
}
.nav-principal li:last-child a { border-bottom: none; }

.nav-ig {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  color: var(--red-deep);
  font-weight: 500;
  font-size: 0.92rem;
}
.icon-ig { width: 19px; height: 19px; }

@media (min-width: 900px) {
  .nav-toggle { display: none; }
  .nav-principal {
    position: static;
    flex-direction: row;
    align-items: center;
    background: transparent;
    border: none;
    padding: 0;
    max-height: none;
    overflow: visible;
    gap: 34px;
    width: auto;
  }
  .nav-principal ul { flex-direction: row; gap: 30px; }
  .nav-principal a {
    border: none;
    padding: 4px 0;
    font-size: 0.98rem;
    position: relative;
  }
  .nav-principal a::after {
    content: "";
    position: absolute;
    left: 0; right: 0; bottom: -4px;
    height: 2px;
    background: var(--red);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.18s ease;
  }
  .nav-principal a:hover::after,
  .nav-principal a:focus-visible::after { transform: scaleX(1); }
  .nav-ig { margin-top: 0; }
}

/* ============================================================
   02 HERO — fotografies reals de la carpeta original
   ============================================================ */

.hero { position: relative; }

.hero__bg {
  position: relative;
  min-height: 560px;
  background:
    radial-gradient(circle at 18% 35%, rgba(255,255,255,.08), transparent 32%),
    linear-gradient(135deg, #6f2b22 0%, #4b201b 100%);
  overflow: hidden;
}

.hero__inner {
  min-height: 560px;
  display: grid;
  grid-template-columns: minmax(290px, 0.86fr) minmax(0, 1.4fr);
  gap: clamp(24px, 5vw, 74px);
  align-items: center;
  padding: 56px 0 62px;
}

.hero__text { max-width: 510px; position: relative; z-index: 3; }

.hero h1 {
  color: var(--white);
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(2.6rem, 6.2vw, 4.6rem);
  line-height: 0.98;
  margin: 0 0 18px;
}

.hero__sub {
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  line-height: 1.45;
  color: rgba(255, 253, 248, 0.94);
  max-width: 40ch;
  margin-bottom: 28px;
}

.hero__real-gallery { position: relative; min-height: 470px; z-index: 2; }
.hero__real-gallery figure {
  margin: 0;
  overflow: hidden;
  box-shadow: 0 20px 45px rgba(22, 10, 8, 0.30);
  background: #fff;
}
.hero__real-gallery img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero__real-main {
  position: absolute;
  inset: 0 7% 0 11%;
  border-radius: 2px;
  transform: rotate(1.2deg);
}
.hero__real-main img { object-position: 50% 68%; }

.hero__real-card {
  position: absolute;
  width: 31%;
  aspect-ratio: 4 / 5;
  border: 7px solid rgba(255, 250, 242, 0.96);
}
.hero__real-card--ous { left: -2%; bottom: -5%; transform: rotate(-5deg); }
.hero__real-card--alvocat { right: -1%; top: 7%; transform: rotate(5deg); }
.hero__real-card--fuet { right: 4%; bottom: -7%; transform: rotate(-3deg); }

@media (max-width: 899px) {
  .hero__bg { min-height: auto; }
  .hero__inner { min-height: auto; grid-template-columns: 1fr; padding: 46px 0 44px; }
  .hero__text { max-width: 560px; }
  .hero__real-gallery { min-height: 430px; margin-top: 12px; }
  .hero__real-main { inset: 0 9% 0 9%; }
  .hero__real-card { width: 32%; border-width: 5px; }
}

@media (max-width: 560px) {
  .hero__inner { padding-top: 38px; }
  .hero__real-gallery { min-height: 360px; }
  .hero__real-main { inset: 0 4% 0 4%; }
  .hero__real-card { width: 35%; }
}

/* paper trencat -------------------------------------------- */

.franja {
  width: clamp(240px, 34vw, 400px);
  margin: -34px 0 34px;
  transform: rotate(-3deg);
  filter: drop-shadow(0 10px 16px rgba(58,33,23,0.25));
}

@media (min-width: 900px) {
  .franja { margin: -46px 0 44px; }
}

/* ============================================================
   03 PECES
   ============================================================ */

.peces { padding: 30px 0 56px; }

.peces .section-lead { margin-bottom: 36px; }

.graella-peces {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px 18px;
}

.peça__enllaç {
  display: block;
  background: var(--white);
  border: 1px solid rgba(58, 33, 23, 0.1);
  border-radius: 5px;
  padding: 12px 12px 16px;
  box-shadow: 0 3px 12px -8px rgba(58, 33, 23, 0.22);
  transition: box-shadow 0.18s ease, transform 0.18s ease;
}
.peça__enllaç:hover,
.peça__enllaç:focus-visible {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px -12px rgba(58, 33, 23, 0.32);
}

.peça__foto {
  margin: 0 0 12px;
  border-radius: 3px;
  overflow: hidden;
  background: var(--cream-2);
}
.peça__foto img { aspect-ratio: 4 / 5; object-fit: cover; width: 100%; height: auto; }

.peça__etiqueta {
  display: block;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.15rem;
  line-height: 1.25;
  color: var(--ink);
}

.peça__cta {
  display: flex;
  align-items: center;
  gap: 5px;
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--red);
  margin-top: 6px;
}
.peça__enllaç:hover .peça__cta span { transform: translateX(3px); }
.peça__cta span { display: inline-block; transition: transform 0.15s ease; }

.peces__nota {
  margin-top: 30px;
  font-size: 0.9rem;
  color: var(--ink-soft);
  font-style: italic;
  max-width: 52ch;
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

@media (min-width: 640px) {
  .graella-peces { grid-template-columns: repeat(4, 1fr); }
}

/* ============================================================
   04 FRANJA DE VALORS
   ============================================================ */

.segells { margin: 8px 0 64px; }

.segells__inner {
  background: var(--kraft-soft);
  border-radius: 6px;
  padding: 28px 26px;
  display: grid;
  gap: 24px;
}

.segell { display: flex; align-items: flex-start; gap: 14px; }
.segell__icona { width: 30px; height: 30px; color: var(--red-deep); flex-shrink: 0; margin-top: 2px; }
.segell h3 { font-size: 1.1rem; margin-bottom: 3px; }
.segell p { font-size: 0.9rem; color: var(--ink-soft); }

@media (min-width: 760px) {
  .segells__inner { grid-template-columns: repeat(3, 1fr); }
  .segell { position: relative; padding-left: 24px; }
  .segell:first-child { padding-left: 0; }
  .segell::before {
    content: "";
    position: absolute;
    left: 0; top: 2px; bottom: 2px;
    border-left: 1px dashed rgba(58, 33, 23, 0.28);
  }
  .segell:first-child::before { display: none; }
}

/* ============================================================
   05 COM FUNCIONA
   ============================================================ */

.com-funciona { padding: 20px 0 64px; text-align: center; }
.com-funciona .wrap { display: flex; flex-direction: column; align-items: center; }

.passos {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin: 34px 0 0;
  max-width: 720px;
  width: 100%;
}

.pas { display: flex; align-items: center; justify-content: center; gap: 14px; }
.pas__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1.5px solid var(--red);
  color: var(--red-deep);
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.05rem;
  flex-shrink: 0;
}
.pas p { font-size: 1.05rem; color: var(--ink); margin: 0; }

.com-funciona__nota {
  margin-top: 34px;
  max-width: 46ch;
  font-style: italic;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

@media (min-width: 760px) {
  .passos { flex-direction: row; align-items: flex-start; justify-content: space-between; gap: 12px; }
  .pas { flex-direction: column; text-align: center; flex: 1; }
}

/* ============================================================
   06 DARRERE D'ALBALORIOS + FORMULARI
   ============================================================ */

.taller { padding: 24px 0 70px; }

.taller__grid { display: flex; flex-direction: column; gap: 46px; }

.taller__fotos { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 24px; }
.taller__foto { margin: 0; border-radius: 5px; overflow: hidden; box-shadow: 0 8px 18px -12px rgba(58,33,23,0.35); }
.taller__foto img { aspect-ratio: 4/3.4; object-fit: cover; }

.taller__form {
  background: var(--white);
  border-radius: 6px;
  padding: 30px 26px;
  border: 1px solid rgba(58, 33, 23, 0.12);
}

.formulari__titol { font-size: 1.5rem; margin-bottom: 18px; }

.camp-fila { display: grid; grid-template-columns: 1fr; gap: 0; }

.camp { margin-bottom: 16px; }
.camp label {
  display: block;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.88rem;
  margin-bottom: 6px;
  color: var(--ink);
}
.camp input,
.camp select,
.camp textarea {
  width: 100%;
  font-family: var(--sans);
  font-size: 1rem;
  padding: 12px 14px;
  border: 1px solid rgba(58, 33, 23, 0.25);
  border-radius: 4px;
  background: var(--cream);
  color: var(--ink);
  resize: vertical;
  appearance: none;
}
.camp select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%237a1f1a' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}
.camp input:focus,
.camp select:focus,
.camp textarea:focus { border-color: var(--red); }

.camp-honeypot {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.camp-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 20px;
  font-size: 0.85rem;
  color: var(--ink-soft);
  cursor: pointer;
}
.camp-checkbox input {
  margin-top: 3px;
  width: 16px;
  height: 16px;
  accent-color: var(--red);
  flex-shrink: 0;
}

.btn--form { width: 100%; justify-content: center; border: none; }

.formulari__confirmacio {
  margin-top: 16px;
  padding: 12px 14px;
  background: rgba(158, 41, 34, 0.07);
  border: 1px solid rgba(158, 41, 34, 0.3);
  border-radius: 4px;
  font-size: 0.9rem;
  color: var(--red-deep);
}

.formulari__confirmacio.es-error {
  background: rgba(58, 33, 23, 0.06);
  border-color: rgba(58, 33, 23, 0.3);
  color: var(--ink);
}

@media (min-width: 640px) {
  .camp-fila { grid-template-columns: 1fr 1fr; gap: 0 16px; }
}

@media (min-width: 960px) {
  .taller__grid { flex-direction: row; gap: 60px; align-items: flex-start; }
  .taller__bio { flex: 0 0 42%; }
  .taller__form { flex: 1; }
}

/* ============================================================
   07 TANCAMENT VISUAL
   ============================================================ */

.final { padding: 0 0 70px; }

.final__foto { position: relative; }
.final__foto img:not(.final__tag) { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
@media (min-width: 700px) { .final__foto img:not(.final__tag) { aspect-ratio: 21/9; } }

.final__tag {
  position: absolute;
  width: clamp(96px, 11vw, 150px);
  height: auto;
  right: 6%;
  bottom: -10%;
  transform: rotate(6deg);
  filter: drop-shadow(0 8px 14px rgba(0,0,0,0.3));
}

.final__grid { padding-top: 34px; }
.final__cta { max-width: 60ch; }
.final__cta .section-lead { margin-bottom: 22px; }

/* ============================================================
   08 FAQ
   ============================================================ */

.faq { padding: 20px 0 70px; }

.faq__llista {
  max-width: 760px;
  margin: 30px auto 0;
  border-top: 1px solid rgba(58, 33, 23, 0.15);
}

.faq__item { border-bottom: 1px solid rgba(58, 33, 23, 0.15); padding: 16px 2px; }

.faq__item summary {
  cursor: pointer;
  list-style: none;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--ink);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.faq__item summary::-webkit-details-marker { display: none; }

.faq__chevron { width: 17px; height: 17px; color: var(--red); flex-shrink: 0; transition: transform 0.2s ease; }
.faq__item[open] .faq__chevron { transform: rotate(180deg); }

.faq__item p { margin-top: 10px; color: var(--ink-soft); font-size: 0.95rem; }

/* ============================================================
   09 FOOTER
   ============================================================ */

.site-footer { background: var(--wood); color: var(--cream-2); padding: 48px 0 0; }

.site-footer__inner {
  display: flex;
  flex-direction: column;
  gap: 30px;
  padding-bottom: 34px;
  border-bottom: 1px solid rgba(247, 237, 224, 0.14);
}

.logo__img--footer { width: 168px; margin-bottom: 8px; filter: brightness(0) invert(1); opacity: 0.95; }

.site-footer__marca p { margin: 2px 0; color: rgba(247,237,224,0.7); }

.site-footer__nav { display: flex; flex-wrap: wrap; gap: 14px 20px; }
.site-footer__nav a:hover { color: var(--white); }

.site-footer__titol { font-family: var(--serif); font-weight: 600; font-size: 1.1rem; color: var(--white); margin-bottom: 8px; }

.site-footer__contacte { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.site-footer__contacte .nav-ig { color: rgba(247,237,224,0.85); }

.site-footer__legal { padding: 16px clamp(20px, 4.5vw, 60px) 0; font-size: 0.8rem; color: rgba(247,237,224,0.45); }

.site-footer__closing {
  margin: 22px 0 0;
  background: var(--red-deep);
  color: var(--white);
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.05rem;
  padding: 12px 20px;
}

@media (min-width: 900px) {
  .site-footer__inner { flex-direction: row; justify-content: space-between; }
}

/* ============================================================
   V2 REAL — producte real + arquitectura recuperada
   Manté el sistema visual aprovat i reforça el gest "taula/cassola".
   ============================================================ */

.section-kicker {
  margin: 0 0 8px;
  color: var(--red);
  font-family: var(--sans);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
}

/* Les fotos reals tenen proporcions diferents. El crop editorial les unifica
   sense tornar-les a convertir en "product shot" genèric. */
.peça__foto img {
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center;
}

/* Una mica menys "card ecommerce", una mica més foto impresa sobre taula. */
.peça__enllaç {
  background: rgba(255,253,248,.76);
  box-shadow: 0 5px 16px -12px rgba(58,33,23,.38);
}
.peça:nth-child(4n+1) .peça__foto { transform: rotate(-.35deg); }
.peça:nth-child(4n+2) .peça__foto { transform: rotate(.25deg); }

.taller--proces {
  padding: 42px 0 76px;
  background: linear-gradient(180deg, rgba(216,185,137,.18), rgba(245,237,224,0));
}

.taller__grid--proces {
  gap: 34px;
}

.proces__nota {
  position: relative;
  align-self: stretch;
  background: var(--red-deep);
  color: var(--cream);
  border-radius: 6px;
  padding: clamp(28px,4vw,48px);
  overflow: hidden;
}
.proces__nota::after {
  content: "";
  position: absolute;
  width: 160px;
  height: 160px;
  right: -55px;
  bottom: -55px;
  border: 1px solid rgba(255,253,248,.24);
  border-radius: 50%;
  box-shadow: inset 0 0 0 18px rgba(255,253,248,.03), inset 0 0 0 36px rgba(255,253,248,.025);
}
.proces__nota-gran {
  position: relative;
  z-index: 1;
  max-width: 8ch;
  margin: 0 0 18px;
  color: var(--white);
  font-family: var(--serif);
  font-size: clamp(2rem,4vw,3rem);
  font-weight: 600;
  line-height: .98;
}
.proces__nota p:not(.proces__nota-gran) {
  position: relative;
  z-index: 1;
  max-width: 38ch;
  color: rgba(255,253,248,.82);
}

.encarrecs {
  padding: 74px 0;
}
.encarrecs__grid {
  display: grid;
  gap: 38px;
  align-items: start;
}
.encarrecs__copy {
  max-width: 56ch;
}
.encarrecs__form {
  box-shadow: 0 18px 40px -30px rgba(58,33,23,.45);
}

@media (min-width: 960px) {
  .taller__grid--proces {
    display: grid;
    grid-template-columns: 1.2fr .8fr;
    align-items: stretch;
  }
  .encarrecs__grid {
    grid-template-columns: .85fr 1.15fr;
    gap: 64px;
  }
}
