/* Baliera · venda de la collita 2026–2027.
   Pròpia: NO és xalanda.css. Colors de l'etiqueta (paper kraft i vidre verd fosc) i de l'oli acabat de premsar.
   Pensada primer per al mòbil: s'hi arriba des d'un WhatsApp. */

@font-face { font-family: "Fraunces"; src: url("/static/fonts/fraunces-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/static/fonts/inter-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900; font-display: swap; }

:root {
  --ampolla: #1b2414;      /* vidre verd fosc */
  --ampolla-2: #2a3620;
  --oliva: #5d6b2f;
  --oli: #d4b33c;          /* oli del raig */
  --oli-clar: #f1e08a;
  --kraft: #d9bd8f;
  --kraft-clar: #f3e8d2;
  --paper: #fbf7ee;
  --tinta: #1f2219;
  --suau: #5f6152;
  --linia: #e6dcc6;
  --vermell: #b2412b;
  --bizum: #05c3c8;
  --whatsapp: #1fa855;
  --radi: 18px;
  --ombra: 0 1px 2px rgb(30 35 20 / .06), 0 8px 24px rgb(30 35 20 / .08);
  --serif: "Fraunces", "Iowan Old Style", Georgia, "Noto Serif SC", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 72px; }
body { margin: 0; background: var(--paper); color: var(--tinta); font: 16px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; display: block; }
a { color: var(--oliva); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.12; letter-spacing: -.01em; margin: 0 0 .5em; }
h2 { font-size: clamp(1.6rem, 6vw, 2.3rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
small { color: var(--suau); }
.petit { font-size: .85rem; color: var(--suau); }
.centrat { text-align: center; }
.buit { color: var(--suau); font-style: italic; }
[hidden] { display: none !important; }

/* ---------- Barra superior ---------- */
.barra { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between;
  padding: 10px 16px; padding-top: max(10px, env(safe-area-inset-top));
  background: rgb(27 36 20 / .92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: var(--kraft-clar); }
.marca { display: flex; align-items: baseline; gap: 8px; color: inherit; text-decoration: none; }
.marca-nom { font-family: var(--mono); font-weight: 700; font-size: 1.25rem; letter-spacing: .02em; }
.marca-sig { font-size: .75rem; opacity: .7; font-style: italic; }
.idiomes { position: relative; }
.idiomes summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 4px; font-weight: 600;
  font-size: .85rem; padding: 6px 10px; border: 1px solid rgb(243 232 210 / .3); border-radius: 999px; }
.idiomes summary::-webkit-details-marker { display: none; }
.idiomes summary svg { width: 14px; fill: none; stroke: currentColor; stroke-width: 2.5; }
.idiomes ul { position: absolute; right: 0; top: calc(100% + 6px); margin: 0; padding: 6px; list-style: none;
  background: #fff; border-radius: 12px; box-shadow: var(--ombra); min-width: 140px; }
.idiomes li a { display: block; padding: 10px 12px; border-radius: 8px; color: var(--tinta); text-decoration: none; }
.idiomes li a:hover, .idiomes li a[aria-current] { background: var(--kraft-clar); }

/* ---------- Hero ---------- */
.hero { position: relative; background: var(--ampolla); color: #fff; overflow: hidden; }
.hero-foto img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 45%; }
.hero::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgb(27 36 20 / .55) 55%, var(--ampolla) 92%); pointer-events: none; }
.hero-text { position: relative; z-index: 1; padding: 0 20px 28px; margin-top: -34%; }
.hero h1 { font-size: clamp(2rem, 9vw, 3.6rem); color: #fff; text-wrap: balance; }
.hero p { color: rgb(255 255 255 / .85); max-width: 34em; font-size: 1.05rem; }
.xip { display: inline-block; font-family: var(--mono); font-size: .78rem; letter-spacing: .04em; text-transform: uppercase;
  background: var(--kraft); color: var(--ampolla); padding: 5px 10px; border-radius: 6px; margin-bottom: 14px; font-weight: 700; }

.avis-general { margin: 16px; padding: 12px 16px; background: var(--oli-clar); border-radius: 12px; font-weight: 600; }

/* ---------- Comptadors d'estoc ---------- */
.comptadors { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; padding: 0 16px;
  margin-top: -6px; position: relative; z-index: 2; }
.hero + .comptadors, .avis-general + .comptadors { margin-top: 16px; }
.comptador { display: flex; gap: 8px; align-items: center; background: #fff; border-radius: var(--radi); padding: 12px;
  box-shadow: var(--ombra); border: 1px solid var(--linia); }
.comptador .garrafa { width: 34px; flex: none; }
.comptador-dades { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.comptador-etiqueta { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--suau); font-weight: 600; }
.comptador-num { white-space: nowrap; }
.comptador-num b { font-family: var(--mono); font-size: 2.1rem; line-height: 1; color: var(--ampolla); }
.comptador-num small { font-family: var(--mono); font-size: .8rem; }
.comptador-nom { font-size: .85rem; color: var(--suau); }
.barra-estoc { display: block; height: 6px; background: var(--kraft-clar); border-radius: 9px; margin-top: 6px; overflow: hidden; }
.barra-estoc i { display: block; height: 100%; background: linear-gradient(90deg, var(--oliva), var(--oli)); border-radius: 9px;
  transition: width .6s ease; }
.comptador.poques .barra-estoc i { background: linear-gradient(90deg, #c96a2b, var(--oli)); }
.comptador.esgotat { opacity: .6; }
.comptador .pindola { align-self: flex-start; margin-top: 6px; }

.pindola { display: inline-block; font-size: .72rem; font-weight: 700; padding: 3px 9px; border-radius: 999px;
  text-transform: uppercase; letter-spacing: .04em; }
.pindola-fosca { background: var(--ampolla); color: var(--kraft-clar); }
.pindola-calenta { background: #f7d9c4; color: #8a3a12; animation: batec 2s ease-in-out infinite; }
@keyframes batec { 50% { transform: scale(1.05); } }

/* ---------- Botons ---------- */
.boto { display: inline-flex; align-items: center; justify-content: center; gap: 10px; border: 0; cursor: pointer;
  background: var(--ampolla); color: #fff; font: 600 1rem var(--sans); padding: 12px 20px; border-radius: 14px;
  text-decoration: none; transition: transform .1s, filter .2s; min-height: 48px; }
.boto:active { transform: scale(.97); }
.boto:hover { filter: brightness(1.12); }
.boto-gran { width: 100%; padding: 16px 20px; font-size: 1.08rem; border-radius: 16px; min-height: 58px; }
.boto-cta { display: flex; margin: 18px 16px 0; width: auto; background: var(--oli); color: var(--ampolla);
  box-shadow: 0 6px 20px rgb(212 179 60 / .45); font-size: 1.15rem; }
.boto-secundari { background: transparent; color: var(--ampolla); border: 1.5px solid var(--ampolla); }
.boto-perill { background: transparent; color: var(--vermell); border: 1.5px solid var(--vermell); }
.boto-bizum { background: var(--ampolla); justify-content: space-between; }
.total-boto { font-family: var(--mono); background: var(--oli); color: var(--ampolla); padding: 4px 10px; border-radius: 9px; }
.boto-whatsapp { background: var(--whatsapp); margin-top: 18px; }
.boto-whatsapp svg { width: 24px; fill: currentColor; }

/* ---------- Blocs ---------- */
.bloc { padding: 40px 16px; max-width: 760px; margin: 0 auto; }
.estret { max-width: 560px; margin: 0 auto; padding: 20px 16px 40px; }
.error { background: #fbe4dd; color: #7d2614; padding: 12px 16px; border-radius: 12px; font-weight: 600; }
.exit { background: #e3f1d8; color: #2f5214; padding: 12px 16px; border-radius: 12px; font-weight: 600; }
.tancada { text-align: center; padding: 30px 20px; background: var(--kraft-clar); border-radius: var(--radi);
  font-family: var(--serif); font-size: 1.3rem; }
.tancada p { margin: 0; }

/* ---------- Productes ---------- */
.productes { display: grid; gap: 14px; }
.producte { display: grid; grid-template-columns: 92px 1fr; grid-template-areas: "foto info" "foto comptagotes" "foto maxim";
  column-gap: 16px; align-items: center; background: #fff; border: 1px solid var(--linia); border-radius: var(--radi);
  padding: 16px; box-shadow: var(--ombra); transition: border-color .2s, box-shadow .2s; }
.producte.triat { border-color: var(--oli); box-shadow: 0 0 0 3px rgb(212 179 60 / .35), var(--ombra); }
.producte.esgotat { opacity: .55; }
.producte-foto { grid-area: foto; }
.producte-info { grid-area: info; }
.producte h3 { margin: 0 0 2px; }
.preu { font-family: var(--mono); font-size: 1.6rem; font-weight: 700; margin: 0; color: var(--ampolla); }
.preu-litre { font-size: .8rem; color: var(--suau); margin: 0; }
.comptagotes { grid-area: comptagotes; display: flex; align-items: center; gap: 6px; margin-top: 10px; }
.comptagotes button { width: 48px; height: 48px; border-radius: 50%; border: 1.5px solid var(--ampolla); background: #fff;
  font-size: 1.5rem; line-height: 1; cursor: pointer; color: var(--ampolla); touch-action: manipulation; }
.comptagotes button.mes { background: var(--ampolla); color: #fff; }
.comptagotes button:disabled { opacity: .3; cursor: default; }
.comptagotes input { width: 52px; text-align: center; font: 700 1.4rem var(--mono); border: 0; background: transparent;
  -moz-appearance: textfield; color: var(--tinta); }
.comptagotes input::-webkit-inner-spin-button { -webkit-appearance: none; }
.maxim { grid-area: maxim; font-size: .78rem; color: var(--suau); margin: 4px 0 0; }

/* La garrafa dibuixada */
.garrafa-nansa { stroke: #e9e4d4; }
.garrafa-tap { fill: var(--ampolla); }
.garrafa-coll { fill: #efeadb; }
.garrafa-cos { fill: rgb(240 236 222 / .55); stroke: #cfc6ad; stroke-width: 1.5; }
.garrafa-brill { stroke: rgb(255 255 255 / .8); }
.garrafa-etiqueta { fill: var(--kraft); stroke: #b99a68; stroke-width: .8; }
.garrafa-text-marca { font: 700 8px var(--mono); fill: var(--ampolla); }
.garrafa-text-litres { font: 700 19px var(--mono); fill: var(--ampolla); }
.garrafa { filter: drop-shadow(0 4px 6px rgb(30 35 20 / .18)); }

/* ---------- Formulari ---------- */
.dades { border: 0; padding: 0; margin: 28px 0 0; }
.dades legend { font-family: var(--serif); font-size: 1.6rem; font-weight: 600; margin-bottom: 12px; padding: 0; }
.camp { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: .92rem; margin-bottom: 16px; }
.camp small { font-weight: 400; }
.camp input, .camp textarea, .g-nota-interna input { font: 400 1.05rem var(--sans); padding: 14px; border: 1.5px solid var(--linia);
  border-radius: 12px; background: #fff; color: var(--tinta); width: 100%; }
.camp input:focus, .camp textarea:focus { outline: none; border-color: var(--oliva); box-shadow: 0 0 0 3px rgb(93 107 47 / .2); }
.camp-titol { font-weight: 600; font-size: .92rem; margin-bottom: 8px; }
.opcions { display: grid; gap: 10px; margin-bottom: 16px; }
.opcio { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border: 1.5px solid var(--linia); border-radius: 14px;
  background: #fff; cursor: pointer; }
.opcio:has(input:checked) { border-color: var(--oliva); background: #f5f6ea; }
.opcio input { margin-top: 4px; accent-color: var(--oliva); width: 20px; height: 20px; flex: none; }
.opcio b { display: block; }
.opcio small { display: block; }
.parany { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.privacitat { font-size: .82rem; color: var(--suau); }

/* Barra fixa amb el total, al mòbil */
.barra-total { position: fixed; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 10px 10px 18px;
  background: var(--ampolla); color: #fff; border-radius: 18px; box-shadow: 0 10px 30px rgb(0 0 0 / .3);
  animation: puja .25s ease-out; }
.barra-total small { color: rgb(255 255 255 / .7); display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; }
.barra-total b { font-family: var(--mono); font-size: 1.35rem; }
.barra-total .boto { background: var(--oli); color: var(--ampolla); }
@keyframes puja { from { transform: translateY(120%); } }

/* ---------- Com funciona ---------- */
.passos { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.passos li { display: flex; gap: 14px; align-items: center; background: var(--kraft-clar); padding: 14px 16px; border-radius: 14px; }
.passos span { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center;
  background: var(--ampolla); color: var(--oli); font: 700 1rem var(--mono); }

/* ---------- Història ---------- */
.historia { background: var(--ampolla); color: var(--kraft-clar); max-width: none; }
.historia > * { max-width: 760px; margin-left: auto; margin-right: auto; }
.historia h2 { color: #fff; }
.entradeta { font-size: 1.1rem; color: rgb(243 232 210 / .85); }
.punts { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 24px; }
.punt { border-top: 1px solid rgb(217 189 143 / .3); padding-top: 14px; }
.punt-num { font: 700 .8rem var(--mono); color: var(--oli); }
.punt h3 { color: #fff; margin: 4px 0 6px; }
.punt p { color: rgb(243 232 210 / .75); margin: 0; font-size: .95rem; }

/* ---------- Laboratori ---------- */
.mesures { display: grid; gap: 18px; margin: 22px 0; }
.mesura-cap { display: flex; justify-content: space-between; align-items: baseline; font-weight: 600; }
.mesura-cap b { font: 700 1.35rem var(--mono); color: var(--ampolla); }
.mesura-barra { height: 10px; background: var(--kraft-clar); border-radius: 9px; margin: 6px 0; position: relative; overflow: hidden; }
.mesura-barra i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, var(--oliva), #8fa043); border-radius: 9px; }
.mesura-peu { display: flex; justify-content: space-between; gap: 12px; font-size: .8rem; color: var(--suau); }
.mesura-peu span:last-child { white-space: nowrap; font-family: var(--mono); }
.lab-segell { display: flex; gap: 14px; align-items: center; background: #fff; border: 1px solid var(--linia); border-radius: 14px; padding: 12px; }
.lab-segell img { width: 64px; height: auto; border-radius: 6px; }
.lab-segell p { margin: 0; font-size: .85rem; }

/* ---------- Tast ---------- */
.tast { background: var(--kraft-clar); max-width: none; }
.tast > * { max-width: 760px; margin-left: auto; margin-right: auto; }
.tast-notes { font-family: var(--serif); font-size: 1.3rem; line-height: 1.4; }
.intensitats { display: grid; gap: 10px; margin: 20px auto; }
.intensitat { display: flex; justify-content: space-between; align-items: center; font-weight: 600; }
.punts-int { display: flex; gap: 6px; }
.punts-int i { width: 22px; height: 22px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: #e7dbbf; }
.punts-int i.ple { background: var(--oli); }
.consell { font-style: italic; }

/* ---------- Valoracions ---------- */
.estrelles { --v: 0; font-size: 1.1rem; letter-spacing: 2px; background: linear-gradient(90deg, var(--oli) calc(var(--v) * 20%), #ddd3bc 0);
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.mitjana { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.mitjana b { font: 700 2.4rem var(--mono); }
.mitjana .estrelles { font-size: 1.5rem; }
.opinions { display: grid; gap: 12px; margin: 16px 0 22px; }
.opinio { margin: 0; background: #fff; border: 1px solid var(--linia); border-radius: 14px; padding: 14px 16px; }
.opinio blockquote { margin: 6px 0; font-family: var(--serif); font-size: 1.05rem; }
.opinio figcaption { font-size: .85rem; color: var(--suau); }
.valoracions .boto { margin-top: 8px; }

.la-meva { position: fixed; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); z-index: 25; background: var(--oli);
  color: var(--ampolla); font-weight: 700; padding: 10px 16px; border-radius: 999px; text-decoration: none; box-shadow: var(--ombra); }
body:has(.barra-total:not([hidden])) .la-meva { display: none; }

/* ---------- Peu ---------- */
.peu { background: var(--ampolla); color: rgb(243 232 210 / .75); padding: 32px 20px calc(96px + env(safe-area-inset-bottom));
  text-align: center; font-size: .9rem; }
.peu-marca { font: 700 1.4rem var(--mono); color: var(--kraft-clar); }
.peu-marca span { font: italic 400 .8rem var(--sans); opacity: .7; }
.peu-bizum { color: var(--bizum); font-weight: 600; }
.peu-petit { font-size: .75rem; opacity: .6; }

/* ---------- Pàgina de comanda ---------- */
.targeta { background: #fff; border: 1px solid var(--linia); border-radius: 22px; padding: 22px 20px; box-shadow: var(--ombra); margin-bottom: 16px; }
.targeta h1 { font-size: 1.7rem; }
.comanda-cap { text-align: center; background: linear-gradient(180deg, var(--kraft-clar), #fff); }
.garrafes-cap { display: flex; justify-content: center; gap: 6px; }
.garrafes-cap .garrafa { width: 64px; }
.codi-gran { font: 700 2rem var(--mono); letter-spacing: .06em; margin: 10px 0 4px; color: var(--ampolla); }
.estat { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: .85rem; padding: 6px 12px;
  border-radius: 999px; background: #f7ecc6; color: #725c0c; }
.punt-estat { width: 9px; height: 9px; border-radius: 50%; background: currentColor; }
.estat-pendent .punt-estat { animation: batec 1.4s infinite; }
.estat-pagada { background: #e3f1d8; color: #2f5214; }
.estat-entregada { background: var(--ampolla); color: var(--oli-clar); }
.estat-anullada { background: #eee; color: #666; }
.bizum { border: 2px solid var(--bizum); }
.bizum-logo { font: 800 1.6rem/1 var(--sans); color: var(--bizum); letter-spacing: -.03em; margin-bottom: 14px; }
.bizum-passos { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.bizum-passos li { display: flex; gap: 12px; }
.bizum-passos li > span { flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--bizum); color: #fff;
  display: grid; place-items: center; font-weight: 800; font-size: .9rem; }
.bizum-passos li > div { flex: 1; min-width: 0; }
.bizum-passos p { margin: 3px 0 6px; font-weight: 600; }
.copiable { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--paper);
  border: 1.5px dashed var(--kraft); border-radius: 12px; padding: 8px 8px 8px 14px; }
.copiable b, .copiable code { font: 700 1.3rem var(--mono); overflow-wrap: anywhere; }
.copiable code { font-size: .85rem; font-weight: 500; }
.copia { flex: none; border: 0; background: var(--ampolla); color: #fff; font: 600 .85rem var(--sans); padding: 10px 14px;
  border-radius: 10px; cursor: pointer; min-height: 40px; }
.copia.fet { background: var(--oliva); }
.resum dl { margin: 0; }
.resum dl div { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--linia); }
.resum dd { margin: 0; font-family: var(--mono); font-weight: 600; }
.resum-total { font-weight: 800; font-size: 1.15rem; border-bottom: 0 !important; }
.resum .petit { margin: 10px 0 0; }
.tria-estrelles { border: 0; padding: 0; margin: 0 0 16px; display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 4px; }
.tria-estrelles legend { font-weight: 600; font-size: .92rem; margin-bottom: 6px; width: 100%; }
.tria-estrelles input { position: absolute; opacity: 0; pointer-events: none; }
.tria-estrelles label { font-size: 2.4rem; color: #ddd3bc; cursor: pointer; line-height: 1; padding: 2px; transition: color .15s, transform .15s; }
.tria-estrelles input:checked ~ label, .tria-estrelles label:hover, .tria-estrelles label:hover ~ label { color: var(--oli); }
.tria-estrelles input:focus-visible + label { outline: 2px solid var(--oliva); border-radius: 6px; }

/* ---------- Pantalles grans ---------- */
@media (min-width: 900px) {
  .hero { display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; min-height: 560px; }
  .hero::after { background: linear-gradient(90deg, transparent 40%, var(--ampolla) 58%); }
  .hero-foto { grid-column: 1 / -1; grid-row: 1; height: 100%; }
  .hero-foto img { height: 100%; aspect-ratio: auto; }
  .hero-text { grid-column: 2; grid-row: 1; margin: 0; padding: 40px 48px 40px 0; }
  .comptadors { max-width: 760px; margin: -48px auto 0; }
  .boto-cta { max-width: 728px; margin: 18px auto 0; }
  .productes { grid-template-columns: 1fr 1fr; }
  .barra-total { left: auto; width: 360px; }
}

/* ---------- Panell de gestió ---------- */
.gestio { background: #f4f1ea; }
.g-nav { display: flex; gap: 14px; }
.g-nav a { color: var(--kraft-clar); text-decoration: none; font-weight: 600; font-size: .9rem; }
.g-pestanyes { position: sticky; top: 52px; z-index: 15; display: flex; gap: 6px; overflow-x: auto; padding: 10px 16px;
  background: #f4f1ea; border-bottom: 1px solid var(--linia); scrollbar-width: none; }
.g-pestanyes a { flex: none; padding: 8px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--linia);
  color: var(--tinta); text-decoration: none; font-weight: 600; font-size: .88rem; }
.g-main { max-width: 1100px; margin: 0 auto; padding: 16px; }
.g-bloc { background: #fff; border-radius: 20px; padding: 20px 16px; margin-bottom: 18px; border: 1px solid var(--linia); }
.g-bloc h2 { font-size: 1.5rem; }
.g-bloc h3 { font-family: var(--sans); font-size: .95rem; margin-top: 18px; }
.g-xifres { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.g-xifres div { background: var(--paper); border-radius: 14px; padding: 12px 14px; display: flex; flex-direction: column; }
.g-xifres small { font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; font-weight: 600; }
.g-xifres b { font: 700 1.7rem var(--mono); color: var(--ampolla); }
.g-xifres span { font-size: .8rem; color: var(--suau); }
.g-xifres .g-alerta { background: #fbf0cf; }
.g-filtres { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.g-filtres a { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--linia); text-decoration: none; color: var(--tinta); font-size: .85rem; }
.g-filtres a[aria-current] { background: var(--ampolla); color: #fff; border-color: var(--ampolla); }
.g-comanda { border: 1px solid var(--linia); border-left: 5px solid var(--oli); border-radius: 14px; padding: 14px; margin-bottom: 12px; }
.g-comanda.estat-pagada { border-left-color: #6a9a3a; }
.g-comanda.estat-entregada { border-left-color: var(--ampolla); opacity: .8; }
.g-comanda.estat-anullada { border-left-color: #bbb; opacity: .55; }
.g-comanda header { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.g-codi { font: 700 1.15rem var(--mono); }
.g-total { margin-left: auto; font: 700 1.15rem var(--mono); }
.g-comanda p { margin: 0 0 6px; }
.g-nota { font-style: italic; background: var(--paper); padding: 8px 10px; border-radius: 8px; }
.p-pendent { background: #fbf0cf; color: #725c0c; }
.p-pagada { background: #e3f1d8; color: #2f5214; }
.p-entregada { background: var(--ampolla); color: var(--oli-clar); }
.p-anullada { background: #eee; color: #666; }
.g-accions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.g-accions form { margin: 0; }
.g-accions .boto { min-height: 44px; padding: 10px 14px; }
.g-nota-interna { display: flex; gap: 8px; margin-top: 10px; }
.g-nota-interna input { padding: 10px; font-size: .9rem; }
.g-nota-interna .boto { min-height: 44px; padding: 8px 14px; }
.g-form fieldset { border: 1px solid var(--linia); border-radius: 14px; padding: 14px; margin: 0; }
.g-form legend { font-weight: 700; padding: 0 6px; }
.g-graella { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); margin: 14px 0; }
.g-interruptor { display: inline-flex; align-items: center; gap: 12px; font-weight: 700; font-size: 1.1rem; cursor: pointer; }
.g-interruptor input { width: 52px; height: 30px; appearance: none; background: #ccc; border-radius: 999px; position: relative; cursor: pointer; transition: background .2s; }
.g-interruptor input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; transition: left .2s; }
.g-interruptor input:checked { background: #6a9a3a; }
.g-interruptor input:checked::after { left: 25px; }
.g-dies { display: flex; align-items: flex-end; gap: 4px; height: 150px; overflow-x: auto; padding-bottom: 4px; }
.g-dia { flex: 1 0 26px; max-width: 48px; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 2px; }
.g-dia i { width: 100%; background: linear-gradient(180deg, var(--oli), var(--oliva)); border-radius: 6px 6px 2px 2px; min-height: 3px; }
.g-dia b { font: 600 .7rem var(--mono); order: -1; }
.g-dia small { font-size: .62rem; white-space: nowrap; }
.g-taules { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.g-taula table, .g-darreres { width: 100%; border-collapse: collapse; font-size: .88rem; }
.g-taula td, .g-darreres td { padding: 7px 4px; border-bottom: 1px solid var(--linia); vertical-align: top; }
.g-taula td:last-child { text-align: right; font-family: var(--mono); font-weight: 700; white-space: nowrap; }
.g-desplaca { overflow-x: auto; }
.g-darreres td { white-space: nowrap; font-size: .8rem; }
.g-valoracio { border-bottom: 1px solid var(--linia); padding: 10px 0; }
.g-valoracio.amagada { opacity: .5; }
.g-valoracio p { margin: 0 0 6px; }
.g-enllacos { display: grid; gap: 10px; max-width: 640px; }
