/* ================================================================
   Stile "Felice" — 13/11/2026
   linee semplici · arte di arrangiarsi · art nouveau semplificata · vissuto
   Palette: blu BF #0092ad · kraft #ece2d0 · inchiostro #2e2622 · colori birra (--bf-col)
   ================================================================ */

:root {
  --bf-blu: #0092ad;
  --bf-inchiostro: #2e2622;
  --bf-kraft: #ece2d0;
  --bf-cartellino: #dcc497;
  --bf-tappo: polygon(50.0% 0.0%, 56.6% 6.0%, 64.7% 2.2%, 69.3% 9.9%, 78.2% 8.7%, 80.3% 17.4%, 89.1% 18.8%, 88.5% 27.8%, 96.5% 31.7%, 93.4% 40.1%, 99.9% 46.3%, 94.4% 53.3%, 98.7% 61.1%, 91.4% 66.3%, 93.3% 75.0%, 84.8% 77.7%, 84.0% 86.7%, 75.1% 86.8%, 71.7% 95.0%, 63.1% 92.5%, 57.5% 99.4%, 50.0% 94.5%, 42.5% 99.4%, 36.9% 92.5%, 28.3% 95.0%, 24.9% 86.8%, 16.0% 86.7%, 15.2% 77.7%, 6.7% 75.0%, 8.6% 66.3%, 1.3% 61.1%, 5.6% 53.3%, 0.1% 46.3%, 6.6% 40.1%, 3.5% 31.7%, 11.5% 27.8%, 10.9% 18.8%, 19.7% 17.4%, 21.8% 8.7%, 30.7% 9.9%, 35.3% 2.2%, 43.4% 6.0%);
}

/* ---------- intestazione home: foto vera su cartone ---------- */
.hero-homepage-section { background: #fff; }  /* fondo blu-lago con polaroid (13/11) */
.hero-homepage-section .content-container { left: 77%; top: 42%; }
.text-container .hero-h1 { color: #fff; text-shadow: 0 2px 3px rgba(0,40,50,.35); }
.text-container .divider { background-color: #fff; height: 4px; border-radius: 2px; }
.text-container .slogan { color: #fff; text-shadow: 0 2px 3px rgba(0,40,50,.35); font-family: 'LittleMiracles', 'Myriad', sans-serif; font-size: clamp(1.3rem, 2.8vw, 2.2rem) !important; letter-spacing: 0; }
.hero-homepage-section .logo { filter: drop-shadow(0 2px 2px rgba(0,0,0,.25)); }
@media (min-width: 992px) and (hover: hover) and (pointer: fine) {
  /* lo slogan si vede sempre: è parte del tono */
  .text-container:not(:hover) .divider,
  .text-container:not(:hover) .slogan { opacity: 1; transform: none; }
}

/* ---------- sezioni della home su carta kraft con bordi strappati ---------- */
.home .beer-coaster {
  position: relative;
  background: var(--bf-kraft) url("felice/carta-kraft.jpg") repeat;
  background-size: 700px;
  padding: 46px clamp(14px, 3vw, 44px) 30px;
  margin: 70px 0 110px;
}
.home .beer-coaster::before,
.home .beer-coaster::after {
  content: "";
  position: absolute; left: 0; right: 0;
  height: 70px;
  background-repeat: repeat-x;
  background-size: 1600px 70px;
  pointer-events: none;
}
.home .beer-coaster::before { top: -66px; background-image: url("felice/strappo-alto.png"); }
.home .beer-coaster::after { bottom: -66px; background-image: url("felice/strappo-basso.png"); background-position: 380px 0; }
.home .beer-coaster:nth-of-type(even)::before { background-position: 700px 0; }

/* titoli di sezione + linea a frusta (art nouveau semplificata) */
.home .coaster-title { margin-bottom: 4px; color: var(--bf-blu); }
.bf-frusta {
  display: block;
  width: min(380px, 80%);
  height: 34px;
  margin: 0 0 34px -4px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 380 34'%3E%3Cpath d='M3 24 C 70 25 120 8 205 13 S 312 29 334 17 C 347 10 343 2 333 4 C 324 6 326 17 336 17 C 343 17 346 12 344 9' fill='none' stroke='%230092ad' stroke-width='2.6' stroke-linecap='round'/%3E%3Cpath d='M150 12 C 156 4 166 3 171 7 C 164 9 158 11 150 12 Z' fill='%230092ad'/%3E%3C/svg%3E") no-repeat left center / contain;
}

/* ---------- card prodotto: scheda bianca con angoli concavi ---------- */
.home ul.products li.product {
  position: relative;
  background: #fff;
  padding: 18px 14px 16px !important;
  -webkit-mask: radial-gradient(circle 15px at 0 0, transparent 97%, #000) top left / 51% 51% no-repeat,
                radial-gradient(circle 15px at 100% 0, transparent 97%, #000) top right / 51% 51% no-repeat,
                radial-gradient(circle 15px at 0 100%, transparent 97%, #000) bottom left / 51% 51% no-repeat,
                radial-gradient(circle 15px at 100% 100%, transparent 97%, #000) bottom right / 51% 51% no-repeat;
          mask: radial-gradient(circle 15px at 0 0, transparent 97%, #000) top left / 51% 51% no-repeat,
                radial-gradient(circle 15px at 100% 0, transparent 97%, #000) top right / 51% 51% no-repeat,
                radial-gradient(circle 15px at 0 100%, transparent 97%, #000) bottom left / 51% 51% no-repeat,
                radial-gradient(circle 15px at 100% 100%, transparent 97%, #000) bottom right / 51% 51% no-repeat;
}
/* filetto interno con gli stessi angoli */
.home ul.products li.product::after {
  content: "";
  position: absolute; inset: 7px;
  pointer-events: none;
  background:
    radial-gradient(circle at 0 0, #0000 8.5px, rgba(46,38,34,.3) 9px 10px, #0000 10.5px) 0 0 / 11px 11px no-repeat,
    radial-gradient(circle at 100% 0, #0000 8.5px, rgba(46,38,34,.3) 9px 10px, #0000 10.5px) 100% 0 / 11px 11px no-repeat,
    radial-gradient(circle at 0 100%, #0000 8.5px, rgba(46,38,34,.3) 9px 10px, #0000 10.5px) 0 100% / 11px 11px no-repeat,
    radial-gradient(circle at 100% 100%, #0000 8.5px, rgba(46,38,34,.3) 9px 10px, #0000 10.5px) 100% 100% / 11px 11px no-repeat,
    linear-gradient(rgba(46,38,34,.3), rgba(46,38,34,.3)) 50% 0 / calc(100% - 20px) 1px no-repeat,
    linear-gradient(rgba(46,38,34,.3), rgba(46,38,34,.3)) 50% 100% / calc(100% - 20px) 1px no-repeat,
    linear-gradient(rgba(46,38,34,.3), rgba(46,38,34,.3)) 0 50% / 1px calc(100% - 20px) no-repeat,
    linear-gradient(rgba(46,38,34,.3), rgba(46,38,34,.3)) 100% 50% / 1px calc(100% - 20px) no-repeat;
}
.home ul.products li.product .attachment-woocommerce_thumbnail { background: transparent; }
.home ul.products li.product:hover img { transform: scale(1.04); }

/* nome della birra sottolineato col suo colore */
.home .botiga-wc-loop-product__title { color: var(--bf-inchiostro) !important; }
li.product[class*="bf-c-"] .botiga-wc-loop-product__title {
  /* tratto sotto le lettere (non sopra: sembrava barrato) e un po' trasparente */
  --bf-sott: color-mix(in srgb, var(--bf-col) 70%, transparent);
  background-image: linear-gradient(var(--bf-sott), var(--bf-sott));
  background-repeat: no-repeat;
  background-size: 100% 3px;
  background-position: 0 100%;
  padding: 0 2px 7px;
  display: block; /* tratto uguale per tutte: da lato a lato della casella */
}

/* stile + stagioni */
.product-stile { margin: 6px 0 2px !important; color: var(--bf-inchiostro); }
.bf-stagioni { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 3px; margin: 0 0 6px !important; font-size: 13px; color: #6d625a; }
.bf-stagioni img { width: 18px !important; height: 18px; opacity: .85; transform: none !important; }
.bf-stagioni span { margin-left: 5px; font-style: italic; white-space: nowrap; }

/* ---------- prezzo su cartellino legato con lo spago ---------- */
.home ul.products li.product .price {
  position: relative;
  isolation: isolate;
  display: inline-block;
  margin: 10px 0 4px 30px;
  padding: 6px 14px 6px 26px;
  color: var(--bf-inchiostro) !important;
  font-family: 'LittleMiracles', 'Myriad', sans-serif;
  font-size: 22px !important;
  line-height: 1.1;
  transform: rotate(-2.5deg);
}
.home ul.products li.product .price::before { /* cartellino con foro */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(circle at 13px 50%, #fff 0 3.5px, rgba(120,90,50,.65) 4px 5px, transparent 5.5px),
    url("felice/carta-kraft.jpg"), var(--bf-cartellino);
  background-blend-mode: normal, multiply, normal;
  clip-path: polygon(14px 0, 100% 0, 100% 100%, 14px 100%, 0 50%);
}
.home ul.products li.product .price::after { /* spago */
  content: ""; position: absolute; left: -32px; top: 50%; width: 46px; height: 16px; margin-top: -14px; z-index: 1;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 46 16'%3E%3Cpath d='M1 3 C 14 1 22 13 33 11 S 41 9 45 12' fill='none' stroke='%23a07c4b' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat;
}
.home ul.products li.product .price .woocommerce-price-suffix { font-size: 13px; font-family: 'Myriad', sans-serif; opacity: .75; }

/* ---------- pulsante: tappo a corona, sempre visibile ---------- */
.home .loop-image-wrap > .loop-button-wrap.button-layout3 {
  top: auto; left: auto; right: 2%; bottom: 3%;
  min-width: 0;
  opacity: 1; visibility: visible;
  transform: none;
  z-index: 3;
}
.home ul.products li.product .add_to_cart_button,
.home ul.products li.product .loop-button-wrap .button {
  width: 84px !important; height: 84px !important;
  padding: 8px !important;
  border: 0 !important;
  border-radius: 0 !important;
  clip-path: var(--bf-tappo);
  background: radial-gradient(circle at 38% 32%, #2bb8d1 0, var(--bf-blu) 46%, #006f84 100%) !important;
  box-shadow: none !important;
  color: #fff !important;
  font-family: 'NexaRustSans', sans-serif;
  font-size: 12px !important; letter-spacing: .5px; text-transform: uppercase;
  display: flex; align-items: center; justify-content: center; text-align: center; line-height: 1.1;
  white-space: normal;
}
.home ul.products li.product .add_to_cart_button:hover { transform: rotate(200deg) !important; border: 0 !important; }
.home ul.products li.product .add_to_cart_button.loading { opacity: .6; }
.home ul.products li.product .add_to_cart_button.added::after { content: "✓"; margin-left: 2px !important; }

/* ---------- timbri ---------- */
.bf-timbro {
  position: absolute;
  z-index: 4;
  top: 58%; left: 10px;
  padding: 5px 10px 3px;
  border: 3px double currentColor;
  border-radius: 6px;
  color: #b5392b;
  font-family: 'NexaRustSans', sans-serif;
  font-size: 13px; line-height: 1.15; letter-spacing: 1px; text-transform: uppercase;
  transform: rotate(-9deg);
  opacity: .88;
  mix-blend-mode: multiply;
  -webkit-mask: url("felice/grana-timbro.png") center / 160px;
          mask: url("felice/grana-timbro.png") center / 160px;
  pointer-events: none;
  max-width: 70%;
}
.bf-timbro-esaurito { color: #5c5c5c; }
.bf-timbro-scheda { position: relative; top: 0; left: 0; display: inline-block; margin: 4px 0 14px; font-size: 15px; }

/* ---------- riga spedizioni ---------- */
.bf-spedizioni {
  display: flex; align-items: center; gap: 12px;
  margin: 0 0 30px; padding: 12px 18px;
  border: 1.5px dashed rgba(46,38,34,.35);
  border-radius: 4px;
  color: var(--bf-inchiostro);
  font-size: 15px; line-height: 1.4;
  background: rgba(255,255,255,.55);
}
.bf-spedizioni a { color: var(--bf-blu); text-decoration: underline; }
.bf-spedizioni-icona {
  flex: 0 0 34px; height: 24px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 34 24' fill='none' stroke='%232e2622' stroke-width='1.8' stroke-linejoin='round'%3E%3Cpath d='M2 4h19v13H2zM21 9h6l4 4v4h-10z'/%3E%3Ccircle cx='8' cy='19' r='2.6' fill='%23fff'/%3E%3Ccircle cx='26' cy='19' r='2.6' fill='%23fff'/%3E%3C/svg%3E") no-repeat center / contain;
}
.single-product .bf-spedizioni { margin: 18px 0 0; font-size: 14px; }

/* ---------- colonna laterale: testo leggibile ---------- */
.widget-excerpt p {
  font-family: 'Lora', Georgia, serif !important;
  font-size: 16px !important;
  line-height: 1.55 !important;
  text-transform: none !important;
  color: #4a4440 !important;
}

/* ---------- galleria: foto fissate col nastro ---------- */
.wp-block-gallery .wp-block-image { position: relative; overflow: visible !important; }
.wp-block-gallery .wp-block-image img { box-shadow: 0 6px 14px rgba(40,30,20,.18); border: 7px solid #fff; }
.wp-block-gallery .wp-block-image::before {
  content: ""; position: absolute; z-index: 2; top: -12px; left: 50%;
  width: 110px; height: 32px; margin-left: -55px;
  background: url("felice/nastro.png") no-repeat center / contain;
  transform: rotate(-4deg);
  pointer-events: none;
}
.wp-block-gallery .wp-block-image:nth-child(3n+1) { transform: rotate(-1.2deg); }
.wp-block-gallery .wp-block-image:nth-child(3n+2) { transform: rotate(.9deg); }
.wp-block-gallery .wp-block-image:nth-child(3n+2)::before { transform: rotate(5deg); left: 30%; }
.wp-block-gallery .wp-block-image:nth-child(4n)::before { transform: rotate(-9deg); left: 70%; }

/* ---------- telefono ---------- */
@media (max-width: 768px) {
  .home .beer-coaster { margin: 50px -6px 90px; padding: 34px 10px 20px; }
  .home ul.products li.product { padding: 12px 8px 10px !important; }
  .home ul.products li.product .add_to_cart_button { width: 64px !important; height: 64px !important; font-size: 9px !important; }
  .home ul.products li.product .price { font-size: 18px !important; margin-left: 10px; }
  .bf-timbro { top: 56%; font-size: 10px; }
  .bf-spedizioni { font-size: 13px; padding: 10px 12px; }
  .hero-homepage-section .content-container { left: 78%; top: 38%; }
}

/* ---------- Dove trovarci ---------- */
.bf-dove { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 40px; align-items: start; margin: 20px 0 60px; }
.bf-dove h2 { font-family: 'CourageRoad', sans-serif; text-transform: lowercase; color: var(--bf-blu); font-size: 30px; margin: 26px 0 6px; }
.bf-dove h2:first-child { margin-top: 0; }
.bf-dove h2::after { content: ""; display: block; width: 190px; height: 18px; margin-top: 2px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 380 34'%3E%3Cpath d='M3 24 C 70 25 120 8 205 13 S 312 29 334 17 C 347 10 343 2 333 4 C 324 6 326 17 336 17 C 343 17 346 12 344 9' fill='none' stroke='%230092ad' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat left / contain; }
.bf-dove p { font-size: 17px; line-height: 1.55; }
.bf-dove a { color: var(--bf-blu); }
.bf-bottone { display: inline-block; padding: 10px 22px; background: var(--bf-blu); color: #fff !important; text-decoration: none; font-family: 'NexaRustSans', sans-serif; letter-spacing: .5px; text-transform: uppercase; font-size: 14px; border-radius: 2px; transform: rotate(-1.5deg); }
.bf-dove-mappa { position: relative; background: #fff; padding: 12px 12px 8px; box-shadow: 0 8px 20px rgba(40,30,20,.18); transform: rotate(.8deg); }
.bf-dove-mappa::before { content: ""; position: absolute; z-index: 2; top: -14px; left: 50%; width: 130px; height: 36px; margin-left: -65px; background: url("felice/nastro.png") no-repeat center / contain; transform: rotate(-3deg); }
.bf-dove-mappa iframe { display: block; width: 100%; height: 460px; border: 0; }
.bf-dove-mappa small { display: block; text-align: right; margin-top: 6px; font-size: 12px; color: #776d65; }
@media (max-width: 768px) { .bf-dove { grid-template-columns: 1fr; } .bf-dove-mappa iframe { height: 320px; } }

/* correzioni telefono (le regole del tema sulle img sono più forti) */
.woocommerce ul.products li.product .bf-stagioni img,
ul.products li.product .bf-stagioni img { width: 18px !important; max-width: 18px !important; height: 18px !important; margin: 0 !important; }
@media (max-width: 768px) {
  .woocommerce ul.products li.product .bf-stagioni img, ul.products li.product .bf-stagioni img { width: 14px !important; max-width: 14px !important; height: 14px !important; }
  .bf-stagioni { font-size: 11px; }
  .home ul.products li.product .loop-button-wrap .add_to_cart_button { width: 60px !important; height: 60px !important; font-size: 0 !important; }
  .home ul.products li.product .loop-button-wrap .add_to_cart_button::before { content: "+"; font-size: 34px; line-height: 1; font-family: 'Myriad', Arial, sans-serif; font-weight: bold; }
  .hero-homepage-section .content-container { left: 80%; top: 40%; }
  .text-container .hero-h1 { font-size: 1.25rem; margin: 4px; }
  .hero-homepage-section .logo { width: 62px; }
  .hero-homepage-section .logo-container { margin-top: 6px; }
}

/* nome della birra un po' più giù, staccato dal bordo della casella */
.home ul.products li.product h2.woocommerce-loop-product__title { margin-top: 18px !important; }
