/* Cal Codina · estil
   Mateixa estructura i ritme que Cal Teca Rural (titulars gegants esglaonats, etiqueta + línia en serif cursiva, llistes numerades,
   comptadors, cintes de fotos), amb la paleta d'aquesta casa: la pedra de la façana, l'empedrat del pati, la rajola de terracota,
   les bigues de fusta i el verd del jardí (dades/paleta.md). */

@font-face { font-family: "Jakarta"; src: url("fonts/plus-jakarta-sans-normal.woff2") format("woff2"); font-weight: 200 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("fonts/instrument-serif-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("fonts/instrument-serif-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }

:root {
  /* PALETA (k-means sobre les fotos de Cal Codina: vegeu dades/paleta.md) — pedra, empedrat, terracota, bigues i jardí */
  --fons: #F2ECE2;        /* empedrat clar del pati (derivat de #E5DEC2) */
  --fons-2: #E6DCCB;      /* pedra de la façana al sol, aclarida */
  --paper: #FBF8F3;       /* paret blanca de la cuina */
  --tinta: #2D1A15;       /* fusta fosca de les bigues */
  --suau: #6B5646;        /* pedra de la façana a l'ombra (5,9:1 sobre --fons) */
  --linia: rgba(45, 26, 21, .14);
  --fosc: #3A2318;        /* bigues i armaris de la cuina (seccions fosques) */
  --fosc-2: #1E110B;      /* fusta cremada de la llar de foc (peu) */
  --clar-sobre-fosc: #F2E9DB;   /* paret clara */
  --suau-sobre-fosc: #CBB59C;   /* pedra de la façana amb llum (7,4:1 sobre --fosc) */
  --accent: #8A3F18;      /* rajola de terracota de la sala (6,4:1 sobre --fons) */
  --accent-2: #D9955F;    /* teula i fusta clara al sol: decoratiu sobre clar, text sobre fosc (5,9:1) */
  --accent-fosc: #5A331F; /* fusta de la cuina */
  --verd: #55692F;        /* oliveres i gespa del jardí */
  --cel: #6E9BE4;         /* cel sobre el campanar: només decoratiu */
  --wa: #25D366;
  --wa-fosc: #1DA851;
  --wa-bt: #1C7F45;       /* verd de WhatsApp fosc per als botons amb text blanc (contrast 4,9:1) */

  --sans: "Jakarta", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
  --vora: clamp(18px, 4vw, 56px);
  --max: 1680px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --r: 6px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-stopped { overflow: hidden; }
body { margin: 0; background: var(--fons); color: var(--tinta); font-family: var(--sans); font-size: 17px; line-height: 1.6; font-weight: 400; overflow-x: clip; -webkit-font-smoothing: antialiased; }
body.bloc { overflow: hidden; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2, h3, p, ul, ol, figure, blockquote, dl, dd { margin: 0; padding: 0; }
ul, ol { list-style: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.salt { position: absolute; left: -9999px; top: 0; z-index: 100; background: var(--tinta); color: var(--paper); padding: 10px 16px; }
.salt:focus { left: 10px; top: 10px; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--vora); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- tipografia ---------- */
.lbl { display: inline-flex; align-items: center; gap: 10px; font-size: 12px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
.lbl::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; }
.ull { font-family: var(--serif); font-style: italic; font-size: clamp(22px, 2.2vw, 32px); line-height: 1.15; color: var(--suau); letter-spacing: -.005em; }
.cap-sec { display: flex; flex-direction: column; gap: 10px; }

/* titular gegant esglaonat: cada línia puja dins de la seva màscara */
.gegant { font-family: var(--sans); font-weight: 700; text-transform: uppercase; font-size: clamp(42px, 8.4vw, 150px); line-height: .9; letter-spacing: -.035em; margin-top: clamp(22px, 3vw, 44px); }
.gegant .l { display: block; overflow: hidden; padding: .16em 0 .04em; margin: -.16em 0 -.04em; }
.gegant .l > span { display: inline-block; white-space: nowrap; }
.gegant .l--2 { padding-left: 8%; }
.gegant .l--3 { padding-left: 16%; }
.gegant .l--4 { padding-left: 4%; }
.gegant .grad { background: linear-gradient(90deg, var(--accent) 0%, var(--accent-2) 55%, var(--accent-2) 120%); -webkit-background-clip: text; background-clip: text; color: transparent; padding: .2em 0 .06em; margin: -.2em 0 -.06em; }
.gegant .gris { color: var(--suau); opacity: .55; }
.fosc .gegant .gris { color: var(--suau-sobre-fosc); opacity: .6; }
.anima .gegant .l > span { transform: translate3d(0, 135%, 0); transition: transform 1.25s var(--ease); }
.anima .gegant.vist .l > span { transform: none; }
.anima .gegant.vist .l--2 > span { transition-delay: .08s; }
.anima .gegant.vist .l--3 > span { transition-delay: .16s; }
.anima .gegant.vist .l--4 > span { transition-delay: .24s; }

.anima [data-rv] { opacity: 0; transform: translate3d(0, 34px, 0); transition: opacity 1s var(--ease), transform 1.2s var(--ease); }
.anima [data-rv].vist { opacity: 1; transform: none; }
.anima [data-rv="2"] { transition-delay: .12s; }
.anima [data-rv="3"] { transition-delay: .24s; }

.sec { padding: clamp(90px, 12vw, 200px) 0; position: relative; }
.fosc { background: var(--fosc); color: var(--clar-sobre-fosc); }
.fosc .ull { color: var(--suau-sobre-fosc); }
.fosc .lbl::before { background: var(--accent-2); }
.text-gran { font-size: clamp(19px, 1.5vw, 23px); line-height: 1.55; max-width: 34em; }
.text-gran + .text-gran { margin-top: 1.1em; }
.peu-font { font-size: 13px; color: var(--suau); margin-top: 18px; }
.fosc .peu-font { color: var(--suau-sobre-fosc); }

/* ---------- foto genèrica ---------- */
.ph { position: relative; overflow: hidden; background: var(--fons-2); border-radius: var(--r); }
.ph img { width: 100%; height: 100%; object-fit: cover; }
.ph--32 { aspect-ratio: 3 / 2; } .ph--43 { aspect-ratio: 4 / 3; } .ph--45 { aspect-ratio: 4 / 5; } .ph--11 { aspect-ratio: 1; } .ph--21 { aspect-ratio: 2 / 1; }
[data-px] img { transform: scale(1.18); will-change: transform; }
button.zoom { all: unset; position: absolute; inset: 0; cursor: zoom-in; z-index: 2; }
button.zoom:focus-visible { outline: 2px solid var(--paper); outline-offset: -6px; }

/* ---------- botons ---------- */
.bt { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 52px; padding: 0 26px; border-radius: 999px; border: 1px solid currentColor; text-decoration: none; font-size: 14px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; transition: background .35s var(--ease), color .35s var(--ease), border-color .35s, transform .35s var(--ease); background: transparent; }
.bt svg { width: 18px; height: 18px; flex: none; fill: currentColor; }
.bt--ple { background: var(--tinta); color: var(--paper); border-color: var(--tinta); }
.bt--ple:hover { background: var(--accent); border-color: var(--accent); }
.bt--wa { background: var(--wa-bt); border-color: var(--wa-bt); color: #fff; }
.bt--wa:hover { background: #156337; border-color: #156337; }
.bt--clar { color: var(--paper); }
.bt--clar:hover { background: var(--paper); color: var(--tinta); border-color: var(--paper); }
.bt:hover { transform: translateY(-2px); }
.bt__fl { display: inline-block; transition: transform .35s var(--ease); }
.bt:hover .bt__fl { transform: translateX(4px); }

/* ---------- capçalera ---------- */
.cap { position: fixed; inset: 0 0 auto 0; z-index: 50; color: var(--paper); transition: background .5s var(--ease), color .5s var(--ease), box-shadow .5s; }
.cap__in { display: flex; align-items: center; gap: 24px; height: 76px; }
.cap.solid { background: color-mix(in srgb, var(--fons) 88%, transparent); color: var(--tinta); -webkit-backdrop-filter: blur(14px) saturate(1.2); backdrop-filter: blur(14px) saturate(1.2); box-shadow: 0 1px 0 var(--linia); }
.marca { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 14px; letter-spacing: .2em; text-transform: uppercase; white-space: nowrap; }
.marca svg { width: 28px; height: 24px; flex: none; }
.nav { display: flex; gap: clamp(14px, 2vw, 34px); margin-left: auto; }
.nav a { text-decoration: none; font-size: 14px; font-weight: 500; position: relative; padding: 6px 0; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .45s var(--ease); }
.nav a:hover::after { transform: scaleX(1); transform-origin: left; }
.idi { display: flex; gap: 2px; font-size: 12px; font-weight: 600; letter-spacing: .1em; border: 1px solid currentColor; border-radius: 999px; padding: 3px; }
.idi a, .idi span { text-decoration: none; padding: 6px 10px; border-radius: 999px; line-height: 1; }
.idi span[aria-current] { background: currentColor; }
.idi span[aria-current] b { color: var(--tinta); font-weight: 700; }
.cap.solid .idi span[aria-current] b { color: var(--paper); }
.cap__res { min-height: 42px; padding: 0 20px; font-size: 12.5px; }
.cap:not(.solid) .cap__res { background: var(--paper); color: var(--tinta); border-color: var(--paper); }
.menu-bt { display: none; width: 46px; height: 46px; border: 1px solid currentColor; border-radius: 50%; background: none; place-items: center; }
.menu-bt i { display: block; width: 18px; height: 1.5px; background: currentColor; position: relative; transition: transform .35s var(--ease); }
.menu-bt i::before, .menu-bt i::after { content: ""; position: absolute; left: 0; width: 18px; height: 1.5px; background: currentColor; transition: transform .35s var(--ease); }
.menu-bt i::before { top: -6px; } .menu-bt i::after { top: 6px; }
.menu-bt[aria-expanded="true"] i { background: transparent; }
.menu-bt[aria-expanded="true"] i::before { transform: translateY(6px) rotate(45deg); }
.menu-bt[aria-expanded="true"] i::after { transform: translateY(-6px) rotate(-45deg); }
.menu { position: fixed; inset: 0; z-index: 45; background: var(--fosc); color: var(--clar-sobre-fosc); padding: 110px var(--vora) 40px; display: flex; flex-direction: column; justify-content: space-between; opacity: 0; transition: opacity .35s var(--ease); }
.menu.obert { opacity: 1; }
.menu nav { display: flex; flex-direction: column; gap: 4px; }
.menu nav a { text-decoration: none; font-weight: 700; text-transform: uppercase; font-size: clamp(34px, 10vw, 60px); letter-spacing: -.03em; line-height: 1.08; }
.menu nav a span { font-family: var(--serif); font-style: italic; font-weight: 400; text-transform: none; font-size: 16px; letter-spacing: 0; color: var(--suau-sobre-fosc); margin-right: 14px; vertical-align: middle; }
.menu__peu { display: flex; flex-wrap: wrap; gap: 12px; }
body.bloc .cap { color: var(--clar-sobre-fosc); background: transparent; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }

/* ---------- portada ---------- */
.hero { position: relative; height: 100svh; min-height: 620px; color: var(--paper); overflow: hidden; background: var(--fosc-2); }
.hero__foto { position: absolute; inset: 0; }
.hero__foto picture { display: block; width: 100%; height: 100%; }
.hero__foto > img, .hero__foto picture > img { width: 100%; height: 100%; object-fit: cover; will-change: transform; }
.hero__foto::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(18, 18, 17, .84) 0%, rgba(18, 18, 17, .62) 30%, rgba(18, 18, 17, .42) 50%, rgba(18, 18, 17, .86) 100%); }
@media (max-width: 700px) and (orientation: portrait) { .hero__foto::after { background: linear-gradient(180deg, rgba(18, 18, 17, .8) 0%, rgba(18, 18, 17, .66) 38%, rgba(18, 18, 17, .34) 56%, rgba(18, 18, 17, .82) 100%); } }
.hero__in { position: relative; z-index: 2; height: 100%; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr auto; padding-top: 118px; padding-bottom: clamp(26px, 4vw, 54px); }
.hero__dalt { display: flex; justify-content: space-between; align-items: flex-start; gap: 30px; }
.hero__tipus { font-size: clamp(30px, 3.6vw, 56px); font-weight: 500; letter-spacing: -.03em; line-height: 1; }
.hero__tipus small { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; margin-bottom: 14px; opacity: .9; }
.hero__tipus small::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2); }
.hero__adr { margin-top: 16px; font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; line-height: 1.6; opacity: .92; font-style: normal; }
.hero__fets { display: grid; gap: 2px; text-align: left; font-size: clamp(20px, 2vw, 30px); font-weight: 500; letter-spacing: -.02em; line-height: 1.15; }
.hero__fets small { font-size: 11px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; opacity: .85; margin-bottom: 8px; }
.hero__nom { align-self: end; font-weight: 800; text-transform: uppercase; font-size: clamp(50px, 11.6vw, 220px); line-height: .94; letter-spacing: -.045em; margin-top: 0; }
.hero__nom .l { display: block; overflow: hidden; padding: .16em 0 .03em; margin-top: -.16em; }
.hero__nom .l > span { display: inline-block; white-space: nowrap; }
.hero__nom .l--1 { background: linear-gradient(90deg, #D8BF98 0%, #F1E9DC 60%, #fff 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero__nom .pic { display: inline-block; width: .7em; height: .58em; margin-left: .1em; vertical-align: .05em; color: var(--accent-2); }
.hero__peu { display: flex; justify-content: space-between; align-items: end; gap: 20px; margin-top: clamp(16px, 2vw, 26px); font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.hero__baixa { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; }
.hero__baixa i { width: 1px; height: 38px; background: currentColor; position: relative; overflow: hidden; }
.anima .hero__baixa i::after { content: ""; position: absolute; left: 0; top: -40%; width: 1px; height: 40%; background: var(--accent-2); animation: cau 2.2s var(--ease) infinite; }
@keyframes cau { to { top: 110%; } }
.anima .hero__nom .l > span { transform: translate3d(0, 135%, 0); transition: transform 1.5s var(--ease); }
.anima.llest .hero__nom .l > span { transform: none; }
.anima.llest .hero__nom .l--2 > span { transition-delay: .12s; }
.anima .hero__dalt, .anima .hero__peu { opacity: 0; transform: translateY(18px); transition: opacity 1.2s var(--ease) .5s, transform 1.2s var(--ease) .5s; }
.anima.llest .hero__dalt, .anima.llest .hero__peu { opacity: 1; transform: none; }
.anima .hero__foto img { transition: opacity 1.6s ease; opacity: 0; }
.anima.llest .hero__foto img { opacity: 1; }

/* ---------- la casa ---------- */
.casa__g { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(40px, 6vw, 120px); margin-top: clamp(50px, 6vw, 100px); align-items: start; }
.casa__foto { position: sticky; top: 100px; }
.xifres { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--linia); margin-top: clamp(60px, 7vw, 110px); }
.xifres > div { padding: 26px 18px 6px 0; border-right: 1px solid var(--linia); padding-left: 18px; }
.xifres > div:first-child { padding-left: 0; }
.xifres > div:last-child { border-right: 0; }
.xifres dt { font-size: 12px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--suau); order: 2; }
.xifres dd { font-size: clamp(56px, 7.4vw, 128px); font-weight: 700; letter-spacing: -.05em; line-height: 1; }
.xifres > div { display: flex; flex-direction: column-reverse; gap: 10px; }
.dorms { display: grid; grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 24px) clamp(14px, 1.6vw, 24px); margin-top: clamp(60px, 7vw, 110px); }
.dorm h3 { font-size: 13px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; margin-top: 16px; display: flex; justify-content: space-between; gap: 10px; }
.dorm h3 span { color: var(--suau); font-weight: 500; letter-spacing: .06em; text-transform: none; font-size: 14px; }
.dorm p { font-size: 15px; color: var(--suau); margin-top: 4px; }

/* ---------- cintes de fotos ---------- */
.tires { padding: clamp(10px, 2vw, 30px) 0 0; overflow: hidden; }
.tira { overflow: hidden; margin-bottom: clamp(10px, 1.2vw, 18px); }
.tira__in { display: flex; gap: clamp(10px, 1.2vw, 18px); width: max-content; will-change: transform; }
.tira figure { width: clamp(240px, 27vw, 460px); flex: none; }
.tira .ph { aspect-ratio: 3 / 2; }

/* ---------- galeria ---------- */
.gal__cap { display: flex; justify-content: space-between; align-items: end; gap: 40px; flex-wrap: wrap; }
.gal__cap > div { flex: 1 1 100%; min-width: 0; }   /* perquè el titular gegant mesuri l'amplada sencera (ajusta() de app.js) */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: clamp(40px, 5vw, 70px); }
.tabs button { border: 1px solid var(--linia); background: transparent; border-radius: 999px; padding: 10px 18px; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; transition: background .3s, color .3s, border-color .3s; }
.tabs button sup { font-weight: 500; opacity: .6; margin-left: 4px; }
.tabs button:hover { border-color: var(--tinta); }
.tabs button.on { background: var(--tinta); color: var(--paper); border-color: var(--tinta); }
.graella { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(10px, 1.2vw, 18px); margin-top: 26px; }
.graella figure[hidden] { display: none; }
.graella .ph { aspect-ratio: 4 / 3; }
.graella .ph img { transition: transform 1.2s var(--ease); }
.graella figure:hover .ph img { transform: scale(1.04); }
.graella figcaption { font-size: 13px; color: var(--suau); margin-top: 10px; }
.anima .graella figure.entra { animation: entra .9s var(--ease) both; }
@keyframes entra { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

/* ---------- visor ---------- */
.visor { position: fixed; inset: 0; z-index: 80; display: grid; grid-template-rows: auto 1fr auto; background: rgba(14, 17, 15, .96); color: var(--clar-sobre-fosc); opacity: 0; transition: opacity .3s ease; }
.visor.obert { opacity: 1; }
.visor__dalt, .visor__baix { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 16px var(--vora); font-size: 14px; }
.visor__num { font-weight: 600; letter-spacing: .14em; }
.visor__fons { display: grid; place-items: center; padding: 0 clamp(10px, 6vw, 110px); min-height: 0; position: relative; }
.visor__fons img { max-width: 100%; max-height: 100%; object-fit: contain; opacity: 0; transition: opacity .35s ease; border-radius: 3px; }
.visor__fons img.carregat { opacity: 1; }
.visor button { background: none; border: 1px solid rgba(238, 233, 223, .35); border-radius: 50%; width: 50px; height: 50px; display: grid; place-items: center; }
.visor button:hover { border-color: var(--clar-sobre-fosc); }
.visor button svg { width: 20px; height: 20px; fill: currentColor; }
.visor__fl { display: flex; gap: 10px; }

/* ---------- equipament ---------- */
.eq__g { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(40px, 6vw, 110px); margin-top: clamp(50px, 6vw, 100px); align-items: start; }
.eq__ll { border-top: 1px solid var(--linia); }
.eq__ll li { border-bottom: 1px solid var(--linia); }
.eq__ll button { all: unset; box-sizing: border-box; cursor: pointer; display: flex; align-items: baseline; gap: 18px; width: 100%; padding: 18px 0; font-size: clamp(24px, 2.6vw, 42px); font-weight: 600; letter-spacing: -.03em; line-height: 1.1; color: var(--suau); transition: color .35s, padding .45s var(--ease); }
.eq__ll button small { font-size: 12px; font-weight: 600; letter-spacing: .1em; min-width: 2.4em; }
.eq__ll button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.eq__ll li.on button, .eq__ll button:hover { color: var(--tinta); }
.eq__ll li.on button { padding-left: 14px; }
.eq__barra { height: 2px; background: var(--linia); margin-top: 26px; overflow: hidden; }
.eq__barra i { display: block; height: 100%; background: var(--accent); transform-origin: left; transition: transform .7s var(--ease); }
.eq__dre { position: sticky; top: 100px; }
.eq__foto { position: relative; aspect-ratio: 3 / 2; }
.eq__foto figure { position: absolute; inset: 0; opacity: 0; transition: opacity .8s var(--ease); }
.eq__foto figure .ph { height: 100%; }
.eq__foto figure.on { opacity: 1; }
.eq__foto figure img { transform: scale(1.08); transition: transform 1.6s var(--ease); }
.eq__foto figure.on img { transform: none; }
.eq__panells { margin-top: 30px; }
.eq__panells > div.on { animation: entra .7s var(--ease) both; }
.eq__items { columns: 2; column-gap: 40px; }
.eq__items li { break-inside: avoid; padding: 9px 0 9px 26px; position: relative; border-bottom: 1px solid var(--linia); font-size: 16px; }
.eq__items li::before { content: ""; position: absolute; left: 2px; top: 1.05em; width: 10px; height: 1.5px; background: var(--accent); }

/* ---------- opinions ---------- */
.notes { margin-top: clamp(50px, 6vw, 100px); border-top: 1px solid rgba(238, 233, 223, .18); }
.nota { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 4fr) minmax(0, 3fr); gap: 20px; align-items: center; padding: clamp(18px, 2vw, 30px) 0; border-bottom: 1px solid rgba(238, 233, 223, .18); }
.nota__pl { font-size: clamp(18px, 1.7vw, 26px); font-weight: 600; letter-spacing: -.01em; }
.nota__pl small { display: block; font-size: 13px; font-weight: 400; color: var(--suau-sobre-fosc); letter-spacing: 0; margin-top: 2px; }
.nota__n { font-size: clamp(48px, 6.4vw, 112px); font-weight: 700; letter-spacing: -.05em; line-height: .95; }
.nota__n sub { font-size: .26em; font-weight: 500; letter-spacing: 0; vertical-align: baseline; color: var(--suau-sobre-fosc); margin-left: 6px; }
.nota__q { text-align: right; font-size: 14px; color: var(--suau-sobre-fosc); }
.nota__q b { display: block; color: var(--clar-sobre-fosc); font-size: clamp(18px, 1.6vw, 24px); font-weight: 600; }
.nota--sub { padding: clamp(10px, 1.2vw, 16px) 0; }
.nota--sub .nota__pl { font-size: clamp(15px, 1.2vw, 18px); font-weight: 500; color: var(--suau-sobre-fosc); padding-left: 1.2em; position: relative; }
.nota--sub .nota__pl::before { content: ""; position: absolute; left: 0; top: .72em; width: .6em; height: 1px; background: var(--accent-2); }
.nota--sub .nota__n { font-size: clamp(26px, 3vw, 48px); }
.nota--sub .nota__n sub { font-size: .4em; }
.cites { margin-top: clamp(70px, 8vw, 130px); display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 8fr); gap: clamp(30px, 5vw, 90px); }
.cites__cap .ull { margin-top: 10px; }
.cites__ctrl { display: flex; align-items: center; gap: 12px; margin-top: 30px; }
.cites__ctrl button { width: 50px; height: 50px; border-radius: 50%; border: 1px solid rgba(238, 233, 223, .35); background: none; display: grid; place-items: center; }
.cites__ctrl button:hover { border-color: var(--clar-sobre-fosc); }
.cites__ctrl svg { width: 18px; height: 18px; fill: currentColor; }
.cites__num { font-size: 13px; font-weight: 600; letter-spacing: .14em; margin-left: 8px; }
.cites__in { display: grid; }
.cites__in blockquote { grid-area: 1 / 1; opacity: 0; visibility: hidden; transform: translateY(16px); transition: opacity .7s var(--ease), transform .9s var(--ease), visibility 0s .7s; }
.cites__in blockquote.on { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.cites__in blockquote p { font-family: var(--serif); font-size: clamp(28px, 3.4vw, 58px); line-height: 1.12; letter-spacing: -.01em; }
.cites__in footer { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 14px; color: var(--suau-sobre-fosc); }
.cites__in footer b { color: var(--clar-sobre-fosc); font-weight: 600; }

/* ---------- entorn ---------- */
.ent__g { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(40px, 6vw, 110px); margin-top: clamp(50px, 6vw, 100px); align-items: start; }
.ent__llocs { border-top: 1px solid var(--linia); margin-top: 40px; }
.ent__llocs li { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; padding: 14px 0; border-bottom: 1px solid var(--linia); font-size: clamp(17px, 1.4vw, 21px); font-weight: 500; }
.ent__llocs li span { color: var(--suau); font-size: 15px; font-weight: 500; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ent__fotos { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(10px, 1.2vw, 18px); }
.ent__fotos figure:first-child { grid-column: 1 / -1; }
.ent__fotos figcaption { font-size: 12px; color: var(--suau); margin-top: 8px; }

/* ---------- reserva ---------- */
.res__g { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(24px, 3vw, 50px); margin-top: clamp(50px, 6vw, 90px); align-items: start; }
.cal { background: var(--paper); border-radius: 14px; padding: clamp(18px, 2.4vw, 36px); box-shadow: 0 1px 0 var(--linia), 0 30px 60px -40px rgba(46, 34, 27, .35); }
.cal__nav { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 18px; }
.cal__nav strong { font-size: 15px; font-weight: 600; text-align: center; }
.cal__nav button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--linia); background: none; display: grid; place-items: center; }
.cal__nav button:hover:not(:disabled) { border-color: var(--tinta); }
.cal__nav button:disabled { opacity: .3; cursor: default; }
.cal__nav svg { width: 18px; height: 18px; fill: currentColor; }
.cal__mesos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(20px, 3vw, 46px); }
.cal__mt { font-weight: 700; text-transform: uppercase; letter-spacing: .1em; font-size: 13px; margin-bottom: 12px; }
.cal__dow, .cal__dies { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal__dow span { font-size: 11px; font-weight: 600; color: var(--suau); text-align: center; padding: 6px 0; letter-spacing: .06em; text-transform: uppercase; }
.cal__d { aspect-ratio: 1; display: grid; place-items: center; border: 0; background: none; font-size: 15px; font-weight: 500; border-radius: 0; position: relative; padding: 0; font-variant-numeric: tabular-nums; }
button.cal__d:not(:disabled):hover { background: var(--fons-2); border-radius: 50%; }
.cal__d.passat { color: rgba(46, 34, 27, .28); cursor: default; }
.cal__d.avui::after { content: ""; position: absolute; bottom: 14%; left: 50%; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--accent); }
.cal__d.oc { color: rgba(46, 34, 27, .42); text-decoration: line-through; text-decoration-thickness: 1.5px; background: repeating-linear-gradient(135deg, rgba(139, 74, 21, .08) 0 4px, rgba(139, 74, 21, .22) 4px 5px); cursor: not-allowed; }
.cal__d.oc:not(:disabled) { cursor: pointer; color: var(--tinta); text-decoration: none; }
.cal__d.tallat { color: rgba(46, 34, 27, .28); cursor: not-allowed; }
.cal__d.rng { background: color-mix(in srgb, var(--accent) 16%, transparent); }
.cal__d.end { background: var(--tinta); color: var(--paper); border-radius: 50%; text-decoration: none; }
.cal__d.ini.end:not(.fi) { border-radius: 50% 0 0 50%; }
.cal__d.fi.end { border-radius: 0 50% 50% 0; }
.cal__d.ini.fi { border-radius: 50%; }
.cal__peu { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--linia); font-size: 13px; color: var(--suau); }
.cal__peu button { background: none; border: 0; text-decoration: underline; text-underline-offset: 3px; font-size: 13px; color: var(--suau); padding: 6px 0; }
.lleg { display: none; gap: 18px; }
.amb-ocupacio .lleg { display: flex; }
.lleg span { display: inline-flex; align-items: center; gap: 8px; }
.lleg i { width: 16px; height: 16px; border-radius: 3px; border: 1px solid var(--linia); background: var(--paper); }
.lleg i.oc { background: repeating-linear-gradient(135deg, rgba(139, 74, 21, .08) 0 4px, rgba(139, 74, 21, .22) 4px 5px); }
.resum { background: var(--fosc); color: var(--clar-sobre-fosc); border-radius: 14px; padding: clamp(22px, 2.4vw, 36px); position: sticky; top: 100px; }
.resum__dates { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid rgba(238, 233, 223, .2); border-radius: 10px; }
.resum__dates > div { padding: 14px 16px; }
.resum__dates > div + div { border-left: 1px solid rgba(238, 233, 223, .2); }
.resum small { display: block; font-size: 11px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--suau-sobre-fosc); margin-bottom: 4px; }
.resum__dates b { font-size: 16px; font-weight: 600; }
.resum__row { display: flex; justify-content: space-between; align-items: center; padding: 16px 2px; border-bottom: 1px solid rgba(238, 233, 223, .14); }
.resum__row b { font-size: 18px; }
.cnt { display: flex; align-items: center; gap: 14px; }
.cnt button { width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(238, 233, 223, .35); background: none; font-size: 20px; line-height: 1; display: grid; place-items: center; }
.cnt button:disabled { opacity: .3; cursor: default; }
.cnt b { min-width: 1.6em; text-align: center; font-size: 20px; }
.resum__msg { min-height: 1.5em; margin: 14px 0; font-size: 14px; color: var(--accent-2); }
.resum .bt { width: 100%; }
.resum .bt + .bt { margin-top: 10px; }
.resum .bt--wa:not(.preparat) { opacity: .9; }
.prop { display: flex; align-items: center; gap: 14px; margin-top: 22px; padding-top: 18px; border-top: 1px solid rgba(238, 233, 223, .14); }
.prop__ini { width: 46px; height: 46px; border-radius: 50%; background: var(--accent); display: grid; place-items: center; font-weight: 700; letter-spacing: .02em; color: var(--paper); flex: none; }
.prop b { display: block; font-size: 16px; }
.prop span { font-size: 11px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--suau-sobre-fosc); }

/* ---------- ubicació ---------- */
.ubi__g { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(30px, 5vw, 90px); margin-top: clamp(40px, 5vw, 80px); align-items: stretch; }
.ubi__adr { font-style: normal; font-size: clamp(22px, 2.2vw, 34px); font-weight: 600; letter-spacing: -.02em; line-height: 1.2; }
.ubi__txt .bt { margin-top: 30px; }
.mapa { position: relative; border-radius: 14px; overflow: hidden; min-height: 420px; background: var(--fons-2); }
.mapa__mapa { position: absolute; inset: 0; z-index: 0; background: var(--fons-2); }
.mapa .leaflet-container { font-family: var(--sans); background: var(--fons-2); }
.mapa .leaflet-control-attribution { font-size: 10px; background: color-mix(in srgb, var(--paper) 85%, transparent); }
.mapa .leaflet-control-zoom a { color: var(--tinta); }
.mapa .leaflet-tile-pane { filter: saturate(.75) contrast(1.02); }
.pin-casa { color: var(--accent); filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .28)); }
.pin-casa svg { width: 34px; height: 44px; display: block; }

/* ---------- peu ---------- */
.peu { background: var(--fosc-2); color: var(--clar-sobre-fosc); padding: clamp(80px, 10vw, 160px) 0 30px; overflow: hidden; }
.peu__cta { display: flex; justify-content: space-between; align-items: end; gap: 40px; flex-wrap: wrap; }
.peu__cta .gegant { margin-top: 18px; font-size: clamp(40px, 7vw, 124px); }
.peu__bts { display: flex; flex-wrap: wrap; gap: 12px; }
.peu__g { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 30px; margin-top: clamp(70px, 8vw, 130px); padding-top: 30px; border-top: 1px solid rgba(238, 233, 223, .16); font-size: 15px; }
.peu__g h3 { font-size: 11px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--suau-sobre-fosc); margin-bottom: 12px; }
.peu__g a { text-decoration: none; }
.peu__g a:hover { text-decoration: underline; text-underline-offset: 3px; }
.peu__g address { font-style: normal; }
.peu__nom { font-weight: 800; text-transform: uppercase; letter-spacing: -.05em; line-height: .8; font-size: 7.4vw; white-space: nowrap; margin-top: clamp(60px, 7vw, 120px); color: rgba(238, 233, 223, .08); user-select: none; text-align: center; }
.peu__legal { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-top: 30px; font-size: 13px; color: var(--suau-sobre-fosc); }
.peu__legal a { text-decoration: none; }
.peu__legal a:hover { text-decoration: underline; }

/* ---------- contacte flotant: una sola peça a la cantonada, WhatsApp + trucar a la mateixa alçada ----------
   WhatsApp = píndola verda amb el logotip oficial (Simple Icons) en blanc; trucar = cercle del color fosc de la casa amb el
   telèfon de Feather (traç i farciment arrodonits, centrat òpticament) que en passar-hi per sobre desplega el número.
   L'onada és una ombra que creix dins la pròpia píndola: no surt de la caixa ni es retalla. A mòbil, dos cercles iguals.
   Apareix passada la portada i s'amaga sobre la reserva i el peu, que ja porten els mateixos botons. */
.flot { position: fixed; right: clamp(14px, 2.4vw, 28px); bottom: calc(clamp(14px, 2.4vw, 28px) + env(safe-area-inset-bottom, 0px)); z-index: 40; display: flex; align-items: center; gap: 10px; transform: translateY(150%); opacity: 0; transition: transform .6s var(--ease), opacity .4s; }
.flot.vist { transform: none; opacity: 1; }
/* widget v4: píndola de WhatsApp (logotip oficial) + cercle de trucar (telèfon de Phosphor) que desplega el número; mateixa alçada, mateixa ombra, reflex intern d'1 px */
.flot a { --h: 58px; position: relative; display: inline-flex; align-items: center; height: var(--h); border-radius: 999px; text-decoration: none; color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16), 0 14px 30px -14px rgba(0, 0, 0, .6), 0 2px 6px rgba(0, 0, 0, .14); transition: transform .35s var(--ease), box-shadow .35s, background .3s; -webkit-tap-highlight-color: transparent; }
.flot a:hover { transform: translateY(-3px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16), 0 22px 38px -16px rgba(0, 0, 0, .62), 0 2px 6px rgba(0, 0, 0, .14); }
.flot a:active { transform: translateY(0) scale(.97); }
.flot a:focus-visible { outline: 3px solid var(--accent-2); outline-offset: 3px; }
.flot__ico { width: var(--h); height: var(--h); display: grid; place-items: center; flex: none; }
.flot__ico svg { display: block; fill: currentColor; }
.flot__wa { background: var(--wa-bt); padding-right: 24px; }
.flot__wa:hover { background: #156337; }
.flot__wa .flot__ico svg { width: 28px; height: 28px; }
.flot__txt { display: flex; flex-direction: column; justify-content: center; line-height: 1.1; font-size: 15.5px; font-weight: 700; letter-spacing: -.01em; white-space: nowrap; margin-left: -5px; }
.flot__txt small { font-size: 11.5px; font-weight: 500; letter-spacing: .01em; opacity: .88; margin-top: 3px; }
.flot__tel { background: var(--fosc); overflow: hidden; max-width: var(--h); transition: max-width .55s var(--ease), transform .35s var(--ease), box-shadow .35s, background .3s; }
.flot__tel:hover { background: var(--accent-fosc); }
.flot__tel .flot__ico svg { width: 25px; height: 25px; }
.flot__tel .flot__num { padding-right: 22px; margin-left: -6px; font-size: 15.5px; font-weight: 700; letter-spacing: -.005em; white-space: nowrap; font-variant-numeric: tabular-nums; opacity: 0; transition: opacity .3s; }
@media (hover: hover) and (min-width: 621px) {
  .flot__tel:hover, .flot__tel:focus-visible { max-width: 260px; }
  .flot__tel:hover .flot__num, .flot__tel:focus-visible .flot__num { opacity: 1; transition-delay: .12s; }
}
.anima .flot.vist .flot__wa { animation: ona 3.2s ease-out 1.4s infinite; }
@keyframes ona {
  0% { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16), 0 14px 30px -14px rgba(0, 0, 0, .6), 0 0 0 0 rgba(37, 211, 102, .5); }
  60%, 100% { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16), 0 14px 30px -14px rgba(0, 0, 0, .6), 0 0 0 14px rgba(37, 211, 102, 0); }
}

/* ---------- xip groc de dada pendent (només a la previsualització; la web no es publica amb cap) ---------- */
.pendent { display: inline-block; background: #F6D86B; color: #3A2F00; padding: 6px 10px; border-radius: 6px; font-size: 12.5px; line-height: 1.4; margin-top: 10px; font-weight: 500; }

/* ---------- legals ---------- */
.legal { padding: 150px 0 100px; }
.legal h1 { font-size: clamp(40px, 6vw, 90px); font-weight: 700; text-transform: uppercase; letter-spacing: -.04em; line-height: .95; }
.legal h2 { font-size: 20px; margin-top: 40px; }
.legal p, .legal li { max-width: 46em; margin-top: 12px; }
.legal ul { list-style: disc; padding-left: 1.2em; }

/* cinc dormitoris: una fila de cinc a escriptori; a tauleta 2 + 2 i el cinquè a tota l'amplada; a mòbil, un per fila */
@media (max-width: 1100px) and (min-width: 621px) {
  .dorms--5 { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .dorms--5 > .dorm:nth-child(5) .ph { aspect-ratio: 2 / 1; }
  .dorms--5 > .dorm:nth-child(5) { grid-column: 1 / -1; }
}

/* ---------- idiomes dins del menú (mòbil) ---------- */
.idi--menu { display: none; align-self: flex-start; margin-top: 26px; color: var(--clar-sobre-fosc); }
.idi--menu span[aria-current] b { color: var(--fosc); }

/* ---------- pantalles ---------- */
@media (max-width: 1100px) {
  .nav { display: none; }
  .menu-bt { display: grid; }
  .idi { margin-left: auto; }
  .cap__res { display: none; }
}
@media (max-width: 900px) {
  .casa__g, .eq__g, .ent__g, .res__g, .ubi__g, .cites { grid-template-columns: 1fr; }
  .casa__foto, .eq__dre, .resum { position: static; }
  .xifres { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .xifres > div:nth-child(2) { border-right: 0; }
  .xifres > div:nth-child(3) { padding-left: 0; }
  .xifres > div:nth-child(n+3) { border-top: 1px solid var(--linia); }
  .dorms { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .graella { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cal__mesos { grid-template-columns: 1fr; }
  .peu__g { grid-template-columns: 1fr 1fr; }
  .nota { grid-template-columns: 1fr auto; }
  .nota__pl { grid-column: 1 / -1; }
  .nota__q { text-align: right; }
  .nota--sub { grid-template-columns: 1fr auto; }
  .nota--sub .nota__pl { grid-column: auto; }
  .eq__dre { order: -1; }
  .mapa { min-height: 340px; }
}
@media (max-width: 620px) {
  body { font-size: 16px; }
  .cap__in { height: 66px; gap: 12px; }
  .marca { font-size: 11.5px; letter-spacing: .14em; }
  .marca span { max-width: 150px; white-space: normal; line-height: 1.2; }
  .idi a, .idi span { padding: 6px 8px; }
  .hero { min-height: 560px; }
  .hero__in { padding-top: 96px; }
  .hero__dalt { flex-direction: column; gap: 22px; }
  .hero__fets { display: none; }
  .hero__nom { font-size: 15.2vw; }
  .hero__nom .pic { width: .62em; height: .52em; }
  .cap__in > .idi { display: none; }
  .menu-bt { margin-left: auto; }
  .hero__in > div { min-width: 0; }
  .idi--menu { display: flex; }
  .marca span { max-width: none !important; white-space: nowrap !important; }
  .gegant { font-size: 12.6vw; letter-spacing: -.03em; }
  .gegant .l--2, .gegant .l--3, .gegant .l--4 { padding-left: 0; }
  .gegant .l--3 { padding-left: 6%; }
  .dorms { grid-template-columns: 1fr; }
  .graella { grid-template-columns: 1fr; }
  .eq__items { columns: 1; }
  .ent__fotos { grid-template-columns: 1fr; }
  .peu__g { grid-template-columns: 1fr; }
  .peu__bts .bt, .peu__bts { width: 100%; }
  .resum__dates b { font-size: 15px; }
  .tabs { flex-wrap: nowrap; overflow-x: auto; margin-left: calc(-1 * var(--vora)); margin-right: calc(-1 * var(--vora)); padding: 0 var(--vora) 4px; scrollbar-width: none; }
  .tabs button { flex: none; }
  .visor__fons { padding: 0; }
  .flot { gap: 10px; }
  .flot a { --h: 56px; }
  .flot__wa .flot__ico svg { width: 29px; height: 29px; }
  .flot__wa { padding-right: 0; }
  .flot__txt, .flot__num { display: none; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; } }

/* nou dormitoris (Cal Codina, com Mas la Portella): 3 × 3 a escriptori; a tauleta i a mòbil, dues columnes i el novè a tota l'amplada */
@media (max-width: 900px) {
  .dorms--9 { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .dorms--9 > .dorm:nth-child(9) { grid-column: 1 / -1; }
  .dorms--9 > .dorm:nth-child(9) .ph { aspect-ratio: 2 / 1; }
}
@media (max-width: 620px) {
  .dorms--9 { gap: 26px 12px; }
  .dorms--9 .dorm h3 { font-size: 11.5px; letter-spacing: .1em; flex-direction: column; gap: 2px; }
  .dorms--9 .dorm h3 span { font-size: 13px; }
  .dorms--9 .dorm p { font-size: 13.5px; }
}

/* ---------- revisió del propietari (10-11-2026) ---------- */
.resum__senyal { font-size: 13.5px; line-height: 1.5; color: var(--suau-sobre-fosc); margin: 12px 2px 0; }

/* vídeo del camp (entorn): només es carrega a escriptori, quan entra a la pantalla; al mòbil, el fotograma fix */
.vid { margin-top: clamp(60px, 7vw, 110px); }
.vid__v { display: block; width: 100%; aspect-ratio: 21 / 9; object-fit: cover; border-radius: var(--r); background: var(--fons-2); }
@media (max-width: 700px) { .vid__v { aspect-ratio: 4 / 3; } }

/* extres: quatre targetes iguals */
.extres { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 24px); margin-top: clamp(40px, 5vw, 80px); }
.extra h3 { font-size: 13px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; margin-top: 16px; }
.extra p { font-size: 15px; color: var(--suau); margin-top: 6px; line-height: 1.5; }
.extra__ico { display: grid; place-items: center; background: var(--fosc); color: var(--accent-2); }
.extra__ico svg { width: 38%; height: auto; }
.normes { margin-top: clamp(50px, 6vw, 90px); border-top: 1px solid var(--linia); padding-top: 26px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 3fr); gap: 20px; }
.normes h3 { font-family: var(--serif); font-style: italic; font-weight: 400; font-size: clamp(24px, 2.4vw, 34px); line-height: 1.1; }
.normes ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 30px; }
.normes li { font-size: 15.5px; line-height: 1.5; padding-left: 1.1em; position: relative; }
.normes li::before { content: ""; position: absolute; left: 0; top: .7em; width: .5em; height: 1px; background: var(--accent); }
@media (max-width: 900px) { .extres { grid-template-columns: repeat(2, minmax(0, 1fr)); } .normes { grid-template-columns: 1fr; } }
@media (max-width: 620px) { .normes ul { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .extres { gap: 22px 12px; } .extra p { font-size: 14px; } .extra h3 { font-size: 11.5px; letter-spacing: .1em; } }

/* casaments: text, sis fotos (3 × 2) i els comptes d'Instagram */
.cas__p { margin-top: clamp(30px, 3vw, 50px); }
.cas__fotos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(10px, 1.2vw, 18px); margin-top: clamp(40px, 5vw, 70px); }
.cas__fotos .ph { aspect-ratio: 4 / 3; }
.igs { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 12px; margin-top: 30px; }
.ig { display: grid; grid-template-columns: 46px minmax(0, 1fr) auto; align-items: center; gap: 16px; padding: 18px 20px; border: 1px solid rgba(238, 233, 223, .18); border-radius: 12px; text-decoration: none; transition: background .35s var(--ease), border-color .35s; }
.ig:hover, .ig:focus-visible { background: rgba(238, 233, 223, .06); border-color: var(--accent-2); }
.ig__ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: linear-gradient(45deg, #F58529, #DD2A7B 55%, #8134AF); }
.ig__ico svg { width: 22px; height: 22px; fill: #fff; }
.ig__txt { display: flex; flex-direction: column; min-width: 0; }
.ig__txt b { font-size: 16px; font-weight: 600; }
.ig__txt small { font-size: 12.5px; color: var(--accent-2); margin-top: 1px; overflow: hidden; text-overflow: ellipsis; }
.ig__txt span { font-size: 13.5px; color: var(--suau-sobre-fosc); margin-top: 4px; }
.ig__fl { font-size: 18px; color: var(--suau-sobre-fosc); transition: transform .35s var(--ease); }
.ig:hover .ig__fl { transform: translate(3px, -3px); color: var(--accent-2); }
@media (max-width: 620px) { .cas__fotos { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* cartell legal: la placa verda oficial («TR · Allotjament rural · Casa de poble independent») redibuixada, i les dades */
.lg__g { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: clamp(30px, 5vw, 90px); align-items: center; margin-top: clamp(30px, 4vw, 60px); }
.placa { aspect-ratio: 1; max-width: 440px; width: 100%; background: #77A34F; border: clamp(8px, 1.2vw, 14px) solid #5E8F3A; border-radius: 6px; color: #161A12; display: flex; flex-direction: column; padding: 9% 7% 0; font-family: var(--sans); box-shadow: 0 30px 60px -30px rgba(30, 40, 20, .45); }
.placa__tr { font-size: clamp(84px, 11vw, 170px); line-height: .82; font-weight: 700; letter-spacing: .02em; text-align: center; color: #EFE6D2; -webkit-text-stroke: 2px #161A12; }
.placa__t1 { font-size: clamp(17px, 2vw, 28px); font-weight: 800; text-transform: uppercase; letter-spacing: .02em; text-align: center; margin-top: 8%; }
.placa__t2 { font-size: clamp(14px, 1.6vw, 22px); text-align: center; margin-top: 2px; }
.placa__baix { margin: auto -7% 0; background: #F2F2EF; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 4%; padding: 5% 6%; }
.placa__reg { writing-mode: vertical-rl; transform: rotate(180deg); font-size: clamp(9px, .9vw, 12px); font-weight: 700; letter-spacing: .06em; }
.placa__nom { font-size: clamp(15px, 1.8vw, 26px); font-weight: 800; text-transform: uppercase; letter-spacing: .02em; }
.placa__cat { background: #F2C200; color: #2A2A2A; font-size: clamp(8px, .8vw, 11px); font-weight: 800; letter-spacing: .08em; text-transform: uppercase; padding: 10px 8px; border-radius: 2px; }
.lg__dades { display: grid; gap: 0; }
.lg__dades div { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--linia); }
.lg__dades dt { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--suau); }
.lg__dades dd { font-size: 16px; overflow-wrap: anywhere; }
@media (max-width: 900px) { .lg__g { grid-template-columns: 1fr; } .placa { margin: 0 auto; } }
@media (max-width: 520px) { .lg__dades div { grid-template-columns: 1fr; gap: 4px; } }

/* vídeos (dades/videos.py) */
.hero__vid { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.4s ease; }
.hero__vid.corre { opacity: 1; }
.hero__foto::after { z-index: 1; }
.ph--vid video { display: block; width: 100%; height: 100%; object-fit: cover; }

/* ---------- segona revisió (11-11-2026) ---------- */
/* portada: només la façana, amb un apropament molt lent en una sola direcció (sense talls ni tornades) */
.hero__foto picture { overflow: hidden; }
.anima .hero__foto picture { transform-origin: 62% 55%; }
.anima.llest .hero__foto picture { animation: apropa 30s cubic-bezier(.25, .1, .25, 1) forwards; }
@keyframes apropa { from { transform: scale(1); } to { transform: scale(1.1); } }

/* visor: la foto sempre sencera */
.visor__fons img { width: auto; height: auto; max-width: 100%; max-height: calc(100svh - 170px); }

/* dormitoris: targetes 3 × 3 amb totes les fotos de cada habitació (carrusel) */
.habs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(26px, 3vw, 44px) clamp(14px, 1.6vw, 24px); margin-top: 30px; }
.hab__foto { position: relative; border-radius: var(--r); overflow: hidden; }
.hab__pista { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.hab__pista::-webkit-scrollbar { display: none; }
.hab__pista figure { flex: 0 0 100%; scroll-snap-align: start; }
.hab__pista .ph { border-radius: 0; }
.hab__ctrl { position: absolute; left: 12px; right: 12px; bottom: 12px; display: flex; align-items: center; justify-content: space-between; pointer-events: none; }
.hab__ctrl button { pointer-events: auto; width: 40px; height: 40px; border-radius: 50%; border: 0; display: grid; place-items: center; background: rgba(251, 248, 243, .92); color: var(--tinta); box-shadow: 0 6px 18px -8px rgba(0, 0, 0, .4); transition: transform .3s var(--ease), opacity .3s; }
.hab__ctrl button:hover { transform: scale(1.06); }
.hab__ctrl button[disabled] { opacity: .35; }
.hab__ctrl svg { width: 18px; height: 18px; fill: currentColor; }
.hab__num { pointer-events: none; font-size: 12px; font-weight: 600; letter-spacing: .12em; color: #fff; background: rgba(20, 14, 10, .55); padding: 6px 12px; border-radius: 999px; }
.hab__txt { padding-top: 18px; }
.hab__planta { font-size: 11.5px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--accent); }
.hab__txt h3 { font-size: clamp(22px, 1.8vw, 28px); font-weight: 600; letter-spacing: -.01em; margin-top: 6px; }
.hab__llits { font-size: 15.5px; color: var(--suau); margin-top: 4px; }
.hab__xips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.hab__xips li { font-size: 12.5px; padding: 5px 11px; border: 1px solid var(--linia); border-radius: 999px; color: var(--tinta); background: var(--paper); }
@media (max-width: 1100px) { .habs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .habs { grid-template-columns: 1fr; } }

/* foc i brasa: text, el vídeo del foc i la barbacoa */
.foc { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 4fr) minmax(0, 3fr); gap: clamp(14px, 1.6vw, 24px); align-items: end; margin-top: clamp(80px, 10vw, 160px); }
.foc__txt { align-self: center; padding-right: clamp(0px, 3vw, 50px); }
.foc__txt .text-gran { margin-top: 26px; }
.foc__foto .ph { aspect-ratio: 4 / 5; }
@media (max-width: 900px) { .foc { grid-template-columns: 1fr 1fr; } .foc__txt { grid-column: 1 / -1; } }

/* normes de la casa: sis targetes amb icona */
.normes { display: block; border-top: 0; padding-top: 0; margin-top: clamp(60px, 7vw, 110px); }
.normes h3 { font-family: var(--serif); font-style: italic; font-weight: 400; font-size: clamp(28px, 2.6vw, 40px); line-height: 1.1; }
.normes ul { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 26px; }
.normes li { display: grid; grid-template-columns: 44px minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 16px; row-gap: 4px; padding: 22px 22px 24px; background: var(--paper); border: 1px solid var(--linia); border-radius: 12px; font-size: 15px; line-height: 1.5; }
.normes li::before { display: none; }
.normes li svg { grid-row: 1 / 3; width: 44px; height: 44px; padding: 10px; border-radius: 50%; background: var(--fons-2); color: var(--accent); }
.normes li b { font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; align-self: end; }
.normes li span { color: var(--suau); }
@media (max-width: 1000px) { .normes ul { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .normes ul { grid-template-columns: 1fr; } }

/* casaments: cinta de fotos de Can Gabarró Vell */
.tires--cas { margin-top: clamp(40px, 5vw, 70px); }
.tires--cas .tira figure { width: clamp(260px, 30vw, 460px); }

/* placa oficial: la foto */
.placa { aspect-ratio: auto; background: none; border: 0; padding: 0; box-shadow: none; max-width: 460px; }
.placa .ph { aspect-ratio: 1; }

/* ---------- 4a revisió (12-11-2026) ---------- */
/* les fotos que es mouen, just a sota del calendari i sobre el mateix fons */
#reserva { padding-bottom: clamp(40px, 5vw, 80px); }
.tires-res { background: var(--fons-2); padding-bottom: clamp(60px, 7vw, 120px); }
.tires-res .tires { padding-top: 0; }
/* portada: la foto nova és més oberta; sense ampliar-la (només un apropament mínim) */
.hero__foto > img, .hero__foto picture > img { transform: none; }
@keyframes apropa { from { transform: scale(1); } to { transform: scale(1.035); } }
/* dormitoris: un vídeo per targeta */
.hab__foto .ph--vid { border-radius: 0; }
/* entorn: la cascada gran i, a sota, tres peces verticals (torre, gronxador, blat) */
.ph--34 { aspect-ratio: 3 / 4; }
.ent__tres { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(10px, 1.2vw, 18px); }
@media (max-width: 700px) {
  .ent__tres { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin-right: -16px; padding-right: 16px; }
  .ent__tres::-webkit-scrollbar { display: none; }
  .ent__tres > figure { flex: 0 0 62%; scroll-snap-align: start; }
}
.ent__tres figure:first-child { grid-column: auto; }

/* portada sencera (12-11-2026): la foto vertical no es retalla mai. En pantalles apaïsades va a la dreta a tota l'alçada,
   amb un fons de la mateixa foto desenfocada i enfosquida; sense cap apropament. */
.anima.llest .hero__foto picture, .hero__foto picture { animation: none; transform: none; }
.hero__fons { display: none; }
/* 17-11-2026: la foto nova de la façana (facana-wa, vertical) a tot arreu; a l'ordinador a pantalla completa, sense cap escala. */
.hero__foto > img, .hero__foto picture > img { object-position: 50% 53%; transform: none; }

/* ---------- 5a revisió (17-11-2026) ---------- */
/* galeria en carrusel: al mòbil es passa amb el dit, a l'ordinador amb fletxes */
.gal-car { position: relative; margin-top: 26px; }
.gal-car .graella { display: flex; grid-template-columns: none; margin-top: 0; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; scrollbar-width: none; padding-bottom: 4px; }
.gal-car .graella::-webkit-scrollbar { display: none; }
.gal-car .graella figure { flex: 0 0 calc((100% - 2 * clamp(10px, 1.2vw, 18px)) / 3); scroll-snap-align: start; min-width: 0; }
.gal-car .graella figure[hidden] { display: none; }
.gal-car__bt { position: absolute; top: calc((100% - 34px) / 2); z-index: 3; width: 54px; height: 54px; margin-top: -27px; border-radius: 50%; border: 0;
  display: grid; place-items: center; background: var(--paper); color: var(--tinta); box-shadow: 0 8px 26px rgba(18, 18, 17, .18); cursor: pointer;
  transition: opacity .3s, transform .3s; }
.gal-car__bt svg { width: 24px; height: 24px; }
.gal-car__bt:hover { transform: scale(1.06); }
.gal-car__bt[disabled] { opacity: 0; pointer-events: none; }
.gal-car__bt--ant { left: -20px; }
.gal-car__bt--seg { right: -20px; }
@media (max-width: 1000px) { .gal-car .graella figure { flex-basis: calc((100% - clamp(10px, 1.2vw, 18px)) / 2); } }
@media (max-width: 700px), (hover: none) {
  .gal-car__bt { display: none; }
}
@media (max-width: 700px) {
  .gal-car { margin-right: calc(-1 * var(--vora)); }
  .gal-car .graella { padding-right: var(--vora); scroll-padding-left: 0; }
  .gal-car .graella figure { flex-basis: 84%; }
}
/* Instagram de la casa: botó al contacte i enllaç al peu */
.bt--ig svg { fill: currentColor; }
.peu__ig { display: inline-flex; align-items: center; gap: 8px; }
.peu__ig svg { width: 16px; height: 16px; fill: currentColor; flex: none; }
.bt--ig { color: #fff; border-color: transparent; background: linear-gradient(45deg, #F58529, #DD2A7B 55%, #8134AF); }
.bt--ig:hover { filter: brightness(1.08); }

/* 18-11-2026: amb ratolí o trackpad, l'imant «mandatory» tornava la galeria enrere a cada moviment petit del trackpad */
@media (hover: hover) and (pointer: fine) { .gal-car .graella { scroll-snap-type: none; scroll-behavior: auto; } }
.gal-car .graella.arrossega, .gal-car .graella.arrossega button.zoom { cursor: grabbing; user-select: none; }
.gal-car .graella img { -webkit-user-drag: none; user-select: none; }
/* 18-11-2026: les cintes es poden arrossegar; amb el dit, el gest vertical continua baixant la pàgina */
.tira { touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none; }
.tira.arrossega { cursor: grabbing; }
.tira img { -webkit-user-drag: none; pointer-events: none; }

/* ---------- Enric 19-11: persones en una línia, Instagram a la reserva, dies lliures en verd ---------- */
.resum__pers { font-size: inherit; color: inherit; white-space: nowrap; }
.resum__ig { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 18px; color: var(--paper); font-size: 15px; font-weight: 500; letter-spacing: .02em; }
.resum__ig svg { width: 24px; height: 24px; fill: currentColor; flex: none; }
.resum__ig:hover span { text-decoration: underline; text-underline-offset: 3px; }
.cal__d.lliure { background: rgba(46, 125, 72, .16); color: #1d5a32; }
button.cal__d.lliure:not(:disabled):hover { background: rgba(46, 125, 72, .3); }
.cal__d.lliure.tallat { background: none; color: rgba(46, 34, 27, .28); }
.cal__d.lliure.rng { background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--tinta); }
.cal__d.lliure.end { background: var(--tinta); color: var(--paper); }
.lleg i:not(.oc) { background: rgba(46, 125, 72, .16); border-color: rgba(46, 125, 72, .35); }

/* ---------- 23-11: habitacions individuals en lloc de «Trieu el dia d'entrada», marc lila a l'Instagram ---------- */
#calMsg:empty { display: none; }

/* ---------- 25-11: totes les icones d'Instagram com la de casaments (quadrat arrodonit amb el degradat i el logo blanc), a escala ---------- */
.resum__ig .ig__ico { width: 36px; height: 36px; border-radius: 9.4px; flex: none; }
.resum__ig .ig__ico svg { width: 17px; height: 17px; fill: #fff; }
.peu__ig .ig__ico { width: 22px; height: 22px; border-radius: 5.7px; flex: none; }
.peu__ig .ig__ico svg { width: 10.5px; height: 10.5px; fill: #fff; }
