/* Proporzioni della home e dettagli dei contatti. */
.hero{height:clamp(350px,37vw,555px)}
.hero-brand{top:50%;width:min(57%,780px)}
.leaf-left{width:25%;left:-4%;top:10%}
.leaf-right{width:24%;right:-7%;bottom:6%}
.motion-btn{font-size:12px;padding-inline:12px;background:#fff5e9d9;border-color:#ffffff66}
.category-card{display:flex;flex-direction:column;align-items:flex-start;min-height:210px}
.category-card .arrow{margin-top:auto;flex-shrink:0}
.category-card .category-art{top:12px;bottom:12px;height:calc(100% - 24px);right:2%;width:41%}
.ui-icon{display:block;width:30px;height:30px;flex-shrink:0}
.round-icon .ui-icon{width:31px;height:31px}
.footer-grid b{display:block}
.footer-grid .ui-icon{width:27px;height:27px}
.mobile-actions .ui-icon{width:20px;height:20px}
.opening-hours{display:inline-block;margin-block:5px;font-variant-numeric:tabular-nums;line-height:1.5}
@media(max-width:760px){
 .hero{height:clamp(290px,49vw,350px)}
 .hero-brand{top:59%;width:82%}
 .leaf-left{width:29%;left:-6%;top:12%}
 .leaf-right{width:27%;right:-9%;bottom:0}
 .category-card{min-height:185px}
 .category-card .category-art{width:40%}
 .round-icon .ui-icon{width:26px;height:26px}
}
@media(max-width:430px){.hero-brand{width:90%}}

/* Feedback discreto per mouse e tastiera, senza spostare il layout. */
.category-card,.ms-card{transition:box-shadow .2s ease,transform .2s ease}
.category-card .arrow{transition:background-color .2s ease,color .2s ease}
@media(hover:hover) and (pointer:fine){
 .category-card:hover,.ms-card:hover{transform:translateY(-3px);box-shadow:0 8px 22px #07173712}
 .category-card:hover .arrow{background:var(--red);color:var(--cream)}
 .ms-card:hover .ms-read{text-decoration:underline;text-underline-offset:4px}
}
.category-card:focus-within .arrow{background:var(--red);color:var(--cream)}
.ms-card:focus-within{outline:2px solid var(--red);outline-offset:3px}
@media(prefers-reduced-motion:reduce){
 .category-card,.ms-card,.category-card .arrow{transition:none}
 .category-card:hover,.ms-card:hover{transform:none}
}

/* Categorie della home: riquadri quadrati e collegamento a tutta superficie. */
#categorie #categoryGrid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(8px, 1.4vw, 16px);
}

@media (min-width: 1000px) {
  #categorie #categoryGrid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

#categorie #categoryGrid > .category-card {
  --card-accent: #628199;
  --card-shadow: inset 0 0 0 1px #d4d8df, 0 3px 9px #202d4010;
  display: grid;
  grid-template: minmax(0, 1fr) auto / minmax(0, 1fr);
  grid-column: auto;
  align-self: start;
  align-items: stretch;
  min-width: 0;
  min-height: 0;
  box-sizing: border-box;
  aspect-ratio: 1;
  padding: clamp(8px, 1.4vw, 18px);
  gap: clamp(4px, .7vw, 9px);
  background: #edf0f3;
  border-radius: 17px;
  box-shadow: var(--card-shadow) !important;
  text-align: center;
}

#categorie #categoryGrid > .category-card:is([hidden], .hidden) {
  display: none;
}

#categorie #categoryGrid > .category-card:nth-child(3n + 2) {
  --card-accent: #5a887d;
}

#categorie #categoryGrid > .category-card:nth-child(3n) {
  --card-accent: #8276a1;
}

#categorie #categoryGrid > .category-card > :is(.category-art, .heated-art) {
  position: static;
  grid-area: 1 / 1;
  justify-self: center;
  display: block;
  width: 84%;
  max-width: 100%;
  height: 100%;
  min-height: 0;
  border-radius: 10px;
  object-fit: contain !important;
  object-position: center;
  pointer-events: none;
}

#categorie #categoryGrid > .category-card[data-basi-nicotina]:not(:has(> :is(.category-art, .heated-art)))::before {
  content: "";
  grid-area: 1 / 1;
  justify-self: center;
  width: 78%;
  background: url("tnt-vg-pg.svg") center / contain no-repeat;
  pointer-events: none;
}

#categorie #categoryGrid > .category-card > h3 {
  grid-area: 2 / 1;
  width: 100%;
  margin: 0;
  color: #141518;
  font-size: clamp(15px, 2.45vw, 27px);
  font-weight: 800;
  line-height: 1.13;
  overflow-wrap: anywhere;
}

#categorie #categoryGrid > .category-card > h3::before {
  content: none;
  display: none;
}

#categorie #categoryGrid > .category-card > p {
  display: none;
}

#categorie #categoryGrid > .category-card > .category-link {
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
}

#categorie #categoryGrid > .category-card:focus-within {
  --card-shadow: inset 0 0 0 2px var(--card-accent), 0 3px 9px #202d4010;
}

@media (hover: hover) and (pointer: fine) {
  #categorie #categoryGrid > .category-card:hover,
  #categorie #categoryGrid > .category-card.is-mouse-hover {
    --card-shadow: inset 0 0 0 1px #bfc6d1, 0 7px 17px #202d4018;
  }
}

/* Sfondo e sezioni editoriali della home. */
body:has(#categorie #categoryGrid) {
  --home-pearl: #edf0f3;
  --home-line: #d4d8df;
  --home-ink: #141518;
  --home-copy: #414852;
  --home-slate: #4f6578;
  --home-panel-shadow: 0 3px 9px #202d4010;
  background: #fff;
}

body:has(#categorie #categoryGrid) #mondo-svapo .ms-card,
body:has(#categorie #categoryGrid) #contatti.c78-contacts-unified {
  background: var(--home-pearl);
  border: 1px solid var(--home-line);
  border-radius: 17px;
  box-shadow: var(--home-panel-shadow);
}

#mondo-svapo #mondo-svapo-title a,
#mondo-svapo .ms-card .ms-card-title-link,
#contatti.c78-contacts-unified .contact-item h3 {
  color: var(--home-ink);
}

#mondo-svapo .ms-card .ms-card-title-link {
  font-weight: 700;
}

#mondo-svapo .c78-blog-kicker,
#mondo-svapo .c78-blog-subtitle,
#mondo-svapo .ms-card-copy p,
#mondo-svapo .ms-card-copy time,
#contatti.c78-contacts-unified .contact-item p {
  color: var(--home-copy);
}

#contatti.c78-contacts-unified .contact-item {
  border-color: var(--home-line);
}

#contatti.c78-contacts-unified .contact-item h3 svg,
#contatti.c78-contacts-unified .c78-contact-action {
  color: var(--home-slate);
}

#contatti.c78-contacts-unified .c78-contact-action {
  border-color: var(--home-slate);
}

#contatti.c78-contacts-unified .c78-contact-action:is(:hover, :focus-visible) {
  background: var(--home-slate);
  color: #fff;
}

body:has(#categorie #categoryGrid) > footer.footer-refined {
  background: #fff;
  border-top: 1px solid var(--home-line);
}

@media (max-width: 760px) {
  #contatti.c78-contacts-unified {
    grid-template-columns: minmax(0, 1fr);
  }

  #contatti.c78-contacts-unified .contact-item {
    border-inline: 0;
  }

  #contatti.c78-contacts-unified .contact-item + .contact-item {
    border-top: 1px solid var(--home-line);
    padding-top: 12px;
  }
}

/* Mantiene la maiuscola del nome impostato nel catalogo. */
#categorie #categoryGrid > .category-card:has(a[href="pod.html"]) > h3 {
  text-transform: none;
}
