/* ==========================================================
   Villa & Associati — Elementor Widgets
   Teal colorway. Matches approved design exactly.
   ========================================================== */

/* ── CSS Variables ───────────────────────────────────────── */
:root {
  --bg: #1e1e1e;
  --bg-2: #2c2c2c;
  --line: #444444;
  --red: #2A7F7F;
  --red-deep: #226868;
  --red-dark: #1d5757;
  --teal-lite: #3DB9B9;
  --light: #f5f5f5;
  --muted: rgba(255, 255, 255, .7);
  --display: "Lexend Exa", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --body: "Lexend", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --ease: cubic-bezier(.16, .84, .44, 1);
}

/* ── Base ────────────────────────────────────────────────── */
.va-widget {
  box-sizing: border-box;
  font-family: var(--body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.va-widget *,
.va-widget *::before,
.va-widget *::after {
  box-sizing: inherit;
}

/* ── Buttons (scoped to .va-widget to avoid theme conflicts) */
.va-widget .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--body);
  font-weight: 500;
  font-size: 15px;
  padding: 13px 22px;
  border-radius: 8px;
  border: 1px solid transparent;
  transition: transform .35s var(--ease), background .3s ease,
    box-shadow .35s var(--ease), color .3s ease;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
}

.va-widget .btn:active {
  transform: translateY(1px) scale(.99);
}

.va-widget .btn-primary {
  background: var(--red);
  color: #fff;
  box-shadow: 0 10px 26px -14px rgba(42, 127, 127, .9);
}

.va-widget .btn-primary:hover {
  background: var(--red-deep);
  transform: translateY(-2px);
  box-shadow: 0 16px 34px -14px rgba(42, 127, 127, .95);
}

.va-widget .btn-subtle {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, .28);
}

.va-widget .btn-subtle:hover {
  background: rgba(255, 255, 255, .07);
  border-color: rgba(255, 255, 255, .5);
  transform: translateY(-2px);
}

.va-widget .btn-ghost {
  background: rgba(255, 255, 255, .06);
  color: #fff;
  border-color: rgba(255, 255, 255, .16);
}

.va-widget .btn-ghost:hover {
  background: rgba(255, 255, 255, .12);
}

.va-widget .btn-sm {
  padding: 9px 16px;
  font-size: 13.5px;
}

/* ── Team actions: cards fill available width ─────────────── */
.tcard__actions .btn {
  flex: 1 1 0;
  min-width: 0;
}

/* ==========================================================
   1. HERO WIDGET
   ========================================================== */
.va-hero-widget {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: flex-end;
  padding: 200px 40px 90px;
  overflow: hidden;
  background-color: var(--bg);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}

/* Background extends past the frame so parallax never reveals an edge */
.va-hero-widget__bg {
  position: absolute;
  left: 0;
  right: 0;
  top: -140px;
  bottom: -140px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  will-change: transform;
}

/* Permanent cinematic gradient (matches original .page-hero::after) */
.va-hero-widget::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(270deg, rgba(30, 30, 30, .55) 0%, rgba(30, 30, 30, 0) 43%, var(--bg) 100%),
    linear-gradient(0deg, rgba(30, 30, 30, .65), rgba(30, 30, 30, .1));
}

.hero-intro-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(120% 120% at 22% 38%, rgba(18, 18, 18, .28), rgba(18, 18, 18, .62) 70%);
  opacity: 0;
  transition: opacity 1.1s var(--ease);
}

/* Scrim fades IN while lockup is zoomed, fades back OUT when it collapses */
.va-hero-widget.va-intro-running .hero-intro-scrim {
  opacity: 1;
}

.va-hero-widget.va-intro-running.va-intro-collapse .hero-intro-scrim {
  opacity: 0;
}

.va-hero-widget__inner {
  position: relative;
  z-index: 2;
  max-width: 1512px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 70px;
}

.va-hero-widget__top {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  padding-bottom: 210px;
  text-align: left;
}

:is(h1,h2,h3,h4,h5,h6) >span:nth-child(4) >:is(h1,h2,h3,h4,h5,h6,p,li,dt,dd,blockquote,figcaption,label,span,a,em,strong,small,td,th,caption), 
:is(h1,h2,h3,h4,h5,h6) >span:nth-child(5) >:is(h1,h2,h3,h4,h5,h6,p,li,dt,dd,blockquote,figcaption,label,span,a,em,strong,small,td,th,caption),
:is(h1,h2,h3,h4,h5,h6) >span:nth-child(6) >:is(h1,h2,h3,h4,h5,h6,p,li,dt,dd,blockquote,figcaption,label,span,a,em,strong,small,td,th,caption) {
    color: #3DB9B9 !important;
    #2a7f7ff2
}


/* Keep the lockup at its natural content width so the intro can measure,
   centre and scale it correctly (a stretched box breaks the zoom). */
.va-hero-widget .va-lockup {
  align-self: flex-start;
}

.va-hero-widget__inner h1 {
  font-family: var(--display);
  font-size: clamp(32px, 6.6vw, 84px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -.03em;
  color: #fff;
  margin: 0;
  max-width: 1080px;
}

.va-hero-widget__action {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 40px;
  flex-wrap: wrap;
}

.va-hero-widget__subtitle {
  font-family: var(--body);
  font-size: 24px;
  color: var(--muted);
  line-height: 1.6;
  max-width: 720px;
  margin: 0;
  text-align: left;
}

.va-hero-widget__buttons {
  display: flex;
  gap: 16px;
  flex-shrink: 0;
}

/* ── Brand lockup ───────────────────────────────────────── */
.va-lockup {
  position: relative;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: .5em;
  font-family: var(--display);
  font-weight: 500;
  color: var(--teal-lite);
  font-size: clamp(22px, 2.2vw, 32px);
  line-height: 1;
  letter-spacing: .005em;
  transform-origin: center center;
  backface-visibility: hidden;
}

.va-lockup__mark {
  flex: 0 0 auto;
  width: 1.14em;
  height: 1.14em;
  display: block;
}

.va-lockup__mark svg {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}

.va-lockup .sq {
  fill: none;
  stroke: var(--teal-lite);
  stroke-width: 2.6;
  vector-effect: non-scaling-stroke;
  transform-box: fill-box;
  transform-origin: center;
  transition: transform .72s var(--ease), opacity .55s ease;
  will-change: transform, opacity;
}

.va-lockup__word {
  white-space: nowrap;
  transition: opacity .7s var(--ease) .22s, transform .7s var(--ease) .22s;
}

/* JS-controlled pre-intro states (without .js class everything shows assembled) */
.js .va-lockup {
  visibility: hidden;
}

.js .va-lockup.ready {
  visibility: visible;
}

.js .va-lockup .sq {
  opacity: 0;
}

.js .va-lockup .sq1 {
  transform: translate(-86px, -70px) rotate(-8deg) scale(.8);
}

.js .va-lockup .sq2 {
  transform: translate(70px, -40px) rotate(7deg) scale(.8);
}

.js .va-lockup .sq3 {
  transform: translate(34px, 96px) rotate(11deg) scale(.8);
}

.js .va-lockup__word {
  opacity: 0;
  transform: translateX(-14px);
}

.va-lockup.lit .sq {
  opacity: 1;
}

.va-lockup.lit .va-lockup__word {
  opacity: 1;
  transform: none;
}

.va-lockup.assembled .sq {
  transform: none;
}

.va-lockup .sq1 {
  transition-delay: 0s;
}

.va-lockup .sq2 {
  transition-delay: .16s;
}

.va-lockup .sq3 {
  transition-delay: .32s;
}

/* ── Hero text & content reveal (scoped to hero widget) ─────── */

/* Word-masked headline reveal */
.va-hero-widget .tr-word {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
}

.js .va-hero-widget .tr-word>span {
  display: inline-block;
  transform: translateY(110%);
  transition: transform .8s var(--ease);
}

.js .va-hero-widget [data-text-reveal].is-in .tr-word>span {
  transform: translateY(0);
}

/* Generic data-reveal (subtitle, buttons) */
.js .va-hero-widget [data-reveal] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
}

.js .va-hero-widget [data-reveal="right"] {
  transform: translateX(40px);
}

.js .va-hero-widget [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* Hold-back while intro is running — overrides is-in if somehow set early */
.js .va-hero-widget.va-intro-running [data-text-reveal] .tr-word>span {
  transform: translateY(110%) !important;
}

.js .va-hero-widget.va-intro-running [data-reveal] {
  opacity: 0 !important;
}

.js .va-hero-widget.va-intro-running [data-reveal="right"] {
  transform: translateX(40px) !important;
}

@media (max-width: 680px) {
  .va-hero-widget {
    padding: 140px 22px 56px;
  }

  .va-hero-widget__top {
    padding-bottom: 80px;
  }

  .va-hero-widget__action {
    flex-direction: column;
    align-items: flex-start;
  }

  .va-hero-widget__buttons {
    flex-direction: column;
    width: 100%;
  }

  .va-hero-widget__buttons .btn {
    width: 100%;
    justify-content: center;
  }
}

/* ==========================================================
   2. QUALITY WIDGET
   ========================================================== */
.va-quality-widget.qualita {
  position: relative;
  background: var(--bg);
  height: 215vh;
}

.qualita__pin {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.qualita__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: .5;
  z-index: 0;
}

.qualita__text {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 clamp(24px, 5vw, 80px);
  opacity: 0;
  will-change: opacity, transform;
  pointer-events: none;
}

.qualita__text h2 {
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: .92;
  font-size: clamp(64px, 13vw, 184px);
  margin: 0;
  display: flex;
  flex-direction: column;
}

.qualita__text .ql {
  display: block;
}

.qualita__text .ql--l {
  align-self: flex-start;
  text-align: left;
}

.qualita__text .ql--r {
  align-self: flex-end;
  text-align: right;
}

.qualita__text .l1 {
  color: #fff;
}

.qualita__text .l2 {
  color: var(--teal-lite);
}

.qualita__stack {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  z-index: 5;
}

.qualita__stack.is-behind {
  z-index: 1;
}

.qcard {
  position: absolute;
  left: 0;
  top: 0;
  width: clamp(208px, 23vw, 330px);
  aspect-ratio: 23/32;
  border-radius: 18px;
  overflow: hidden;
  background: #1c1c1c center/cover no-repeat;
  border: 1px solid rgba(255, 255, 255, .08);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .5);
  will-change: transform, opacity;
  transform: translate(-50%, -50%);
}

.qcard::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18, 18, 18, 0) 45%, rgba(18, 18, 18, .5));
}

/* ==========================================================
   3. TEAM WIDGET
   ========================================================== */
.va-team-widget {
  background-color: var(--bg);
  padding: clamp(3rem, 6vw, 5rem) clamp(1.5rem, 4vw, 3rem);
}

/* Team layout — block display like site.css .team-grid.team-layout */
.team-layout {
  display: block;
}

/* Founder area */
.team-founder {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 720px;
  margin: 0 auto clamp(40px, 5vw, 60px);
}

/* Bizcard — founder "business card" (white, horizontal) */
.bizcard {
  position: relative;
  display: flex;
  min-height: 236px;
  border-radius: 24px;
  overflow: hidden;
  background: #fff;
  color: var(--bg);
  box-shadow: 0 28px 64px -30px rgba(0, 0, 0, .72);
}

.bizcard__photo {
  position: relative;
  width: 240px;
  flex: 0 0 240px;
  overflow: hidden;
}

.bizcard__circle {
  position: absolute;
  left: 50%;
  top: 52%;
  transform: translate(-50%, -50%);
  width: 184px;
  height: 184px;
  border-radius: 50%;
  background: var(--red-deep);
}

.bizcard__img {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 96%;
  height: 104%;
  background-size: contain;
  background-position: bottom center;
  background-repeat: no-repeat;
}

.bizcard__body {
  flex: 1;
  padding: 36px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.bizcard__role {
  font-family: var(--display);
  font-weight: 700;
  font-size: 17px;
  color: var(--bg);
}

.bizcard__name {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(30px, 3vw, 40px);
  color: var(--red-deep);
  line-height: 1.05;
  margin: 6px 0 18px;
}

.bizcard__bio {
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.6;
  color: #555;
  max-width: 44ch;
  margin: 0;
}

/* Team roster — 2-col grid */
.team-roster {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(22px, 2.4vw, 32px);
  max-width: 880px;
  margin: 0 auto;
}

/* Flip card container */
.tcard {
  width: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  perspective: 1600px;
}

.tcard__flip {
  position: relative;
  min-height: 248px;
  transform-style: preserve-3d;
  transition: transform .8s var(--ease);
}

/* CSS hover on capable devices */
@media (hover:hover) {
  .tcard:hover .tcard__flip {
    transform: rotateY(180deg);
  }
}

/* JS adds .is-flipped on touch/no-hover devices */
.tcard.is-flipped .tcard__flip {
  transform: rotateY(180deg);
}

/* Shared face */
.tcard__face {
  border-radius: 18px;
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  box-shadow: 0 18px 40px -24px rgba(0, 0, 0, .65);
}

/* Front face — light bg, dark text */
.tcard__front {
  position: relative;
  display: flex;
  min-height: 248px;
  background: var(--light);
  color: var(--bg);
}

/* Back face — teal gradient */
.tcard__back {
  position: absolute;
  inset: 0;
  transform: rotateY(180deg);
  background: linear-gradient(160deg, var(--red-deep), #163f3f);
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
  padding: 32px 30px;
}

.tcard__back .b-role {
  font-family: var(--body);
  font-size: 14px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .72);
}

.tcard__back .b-name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 24px;
  line-height: 1.1;
}

.tcard__back .b-bio {
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.55;
  color: rgba(255, 255, 255, .92);
}

.tcard__back .b-mark {
  position: absolute;
  right: 22px;
  bottom: 18px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 60px;
  line-height: 1;
  color: rgba(255, 255, 255, .12);
}

/* Photo column */
.tcard__photo {
  position: relative;
  width: 172px;
  flex: 0 0 172px;
  overflow: hidden;
  background: #ececec;
}

.tcard__circle {
  position: absolute;
  left: 50%;
  top: 54%;
  transform: translate(-50%, -50%);
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: var(--red-deep);
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-weight: 700;
  font-size: 46px;
  color: rgba(255, 255, 255, .92);
}

.tcard__img {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 100%;
  height: 118%;
  background-size: contain;
  background-position: bottom center;
  background-repeat: no-repeat;
}

/* Text body */
.tcard__body {
  flex: 1;
  padding: 24px 22px;
  display: flex;
  flex-direction: column;
}

.tcard__role {
  font-family: var(--body);
  font-size: 15px;
  color: #9a9a9a;
  letter-spacing: .04em;
}

.tcard__name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 22px;
  color: var(--red-deep);
  line-height: 1.1;
  margin: 4px 0 12px;
}

.tcard__zone {
  font-family: var(--body);
  font-size: 15px;
  color: #555;
  line-height: 1.45;
  flex: 1;
}

.tcard__phone {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 16px;
  color: var(--bg);
  margin-top: 14px;
  font-weight: 500;
}

.tcard__phone svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

/* Flip hint icon (top-right of front face) */
.tcard__hint {
  position: absolute;
  right: 14px;
  top: 14px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(42, 127, 127, .14);
  color: var(--red-deep);
  display: grid;
  place-items: center;
}

.tcard__hint svg {
  width: 16px;
  height: 16px;
}

/* Actions row (below the flip card) */
.tcard__actions {
  display: flex;
  gap: 10px;
}

@media (max-width: 680px) {
  .team-roster {
    grid-template-columns: 1fr;
  }

  .bizcard {
    flex-direction: column;
    min-height: 0;
  }

  .bizcard__photo {
    width: 100%;
    flex: 0 0 auto;
    height: 260px;
  }

  .bizcard__body {
    padding: 26px 28px 32px;
  }
}

/* ==========================================================
   4. PROJECTS ACCORDION
   ========================================================== */
.va-projects-widget {
  padding: clamp(2rem, 4vw, 4rem) clamp(1rem, 3vw, 2.5rem);
  background-color: var(--bg);
}

.hacc {
  display: flex;
  gap: 14px;
  height: min(74vh, 660px);
  width: 100%;
}

.hpanel {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  flex-grow: 1;
  transition: flex-grow .85s var(--ease);
  background: #222;
  outline: none;
}

.hpanel:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 2px;
}

.hpanel.is-active {
  flex-grow: 6.5;
  cursor: default;
}

.hpanel__img {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.08);
  transition: transform 1.4s var(--ease);
}

.hpanel.is-active .hpanel__img {
  transform: scale(1);
}

/* Dark overlay */
.hpanel::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(18, 18, 18, .15), rgba(18, 18, 18, .78) 78%);
}

.hpanel.is-active::after {
  background: linear-gradient(90deg, rgba(18, 18, 18, .8) 0%, rgba(18, 18, 18, .25) 42%, transparent 70%),
    linear-gradient(0deg, rgba(18, 18, 18, .55), transparent 55%);
}

/* Number badge */
.hpanel__num {
  position: absolute;
  top: 22px;
  left: 22px;
  z-index: 3;
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  color: rgba(255, 255, 255, .85);
  letter-spacing: .08em;
}

/* Vertical label (collapsed state) */
.hpanel__v {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 26px;
  z-index: 3;
  display: flex;
  justify-content: center;
  transition: opacity .4s ease;
}

.hpanel.is-active .hpanel__v {
  opacity: 0;
}

.hpanel__v span {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--display);
  font-weight: 600;
  font-size: 19px;
  color: #fff;
  white-space: nowrap;
  letter-spacing: .01em;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .5);
}

/* Expanded content */
.hpanel__content {
  position: absolute;
  left: 40px;
  bottom: 40px;
  z-index: 3;
  max-width: 440px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .5s var(--ease) .2s, transform .6s var(--ease) .2s;
  pointer-events: none;
}

.hpanel.is-active .hpanel__content {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.hpanel__cat {
  font-family: var(--body);
  font-size: 16px;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--teal-lite);
}

.hpanel__title {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(26px, 2.6vw, 38px);
  line-height: 1.12;
  color: #fff;
  margin: 0;
  white-space: normal;
}

.hpanel__desc {
  font-family: var(--body);
  font-size: 17px;
  color: var(--muted);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .9rem;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--teal-lite);
  text-decoration: none;
  transition: gap .35s var(--ease);
}

.arrow-link .ico {
  width: 18px;
  height: 18px;
  transition: transform .35s var(--ease);
}

.arrow-link:hover {
  gap: .7rem;
}

.arrow-link:hover .ico {
  transform: translate(2px, -2px);
}

@media (max-width: 820px) {
  .hacc {
    flex-direction: column;
    height: auto;
  }

  .hpanel {
    flex: none;
    height: 84px;
    transition: height .7s var(--ease);
  }

  .hpanel.is-active {
    height: 440px;
  }

  /* Collapsed bar: vertically centre the number so it lines up with the
     horizontal title, and push the title clear of the number. */
  .hpanel:not(.is-active) .hpanel__num {
    top: 50%;
    transform: translateY(-50%);
  }

  .hpanel__v {
    bottom: 0;
    top: 0;
    right: 24px;
    left: 58px;
    justify-content: flex-start;
    align-items: center;
  }

  .hpanel__v span {
    writing-mode: horizontal-tb;
    transform: none;
    font-size: 18px;
  }

  .hpanel__content {
    left: 24px;
    bottom: 28px;
    right: 24px;
  }
}

/* ==========================================================
   5. LOGO WALL WIDGET
   ========================================================== */
.va-logo-wall-widget {
  background-color: var(--bg);
  padding: clamp(3rem, 6vw, 5rem) clamp(1.5rem, 4vw, 3rem);
}

.logo-wall {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: clamp(14px, 1.7vw, 26px);
  max-width: 1160px;
  margin: 0 auto;
}

.logo-card {
  background: #f3f1ea;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 1.5vw, 23px) clamp(24px, 2.4vw, 40px);
  min-height: 74px;
  box-shadow: 0 26px 50px -22px rgba(0, 0, 0, .72), 0 5px 14px -7px rgba(0, 0, 0, .55);
  transform: rotate(var(--rot, 0deg));
  transition: transform .55s var(--ease), box-shadow .55s var(--ease);
  will-change: transform;
  text-decoration: none;
  cursor: default;
}

a.logo-card {
  cursor: pointer;
}

.logo-card:hover {
  transform: translateY(-9px) scale(1.045) rotate(0deg) !important;
  box-shadow: 0 38px 70px -24px rgba(0, 0, 0, .82), 0 6px 16px -7px rgba(0, 0, 0, .5);
  z-index: 5;
}

.logo-card img {
  max-width: 120px;
  max-height: 48px;
  width: auto;
  height: auto;
  object-fit: contain;
}

/* Per-logo invert — keeps light/white marks visible on the light card */
.logo-card--invert img {
  filter: invert(1) grayscale(1) contrast(1.15);
}

.lw {
  font-family: var(--display);
  font-size: clamp(20px, 2vw, 29px);
  line-height: 1;
  white-space: nowrap;
  color: #1c1c1c;
}

.lw-sub {
  font-family: var(--body);
  font-weight: 400;
  font-size: clamp(9px, .78vw, 11px);
  letter-spacing: .24em;
  text-transform: uppercase;
  color: #867f73;
  margin-top: 7px;
}

.lw-serif {
  font-family: Georgia, "Times New Roman", serif;
}

.lw-sans {
  font-family: var(--body);
}

/* Float animation — only for users who haven't opted out of motion */
@media (prefers-reduced-motion: no-preference) {
  .logo-wall--floating .logo-card {
    animation: logoFloat var(--dur, 8s) ease-in-out var(--del, 0s) infinite;
  }

  @keyframes logoFloat {

    0%,
    100% {
      transform: translateY(0) rotate(var(--rot, 0deg));
    }

    50% {
      transform: translateY(-9px) rotate(var(--rot, 0deg));
    }
  }

  .logo-wall--floating .logo-card:hover {
    animation-play-state: paused;
  }
}

/* ==========================================================
   6. MARCHI / BRAND GRID WIDGET
   ========================================================== */
.va-marchi-widget {
  position: relative;
  background-color: var(--bg);
  color: #fff;
}

.va-marchi-widget .vam-wrap {
  max-width: none;
  margin: 0 auto;
  width: 100%;
  padding: 0 clamp(1rem, 3vw, 2.5rem);
}

.va-marchi-widget .vam-intro {
  padding: 96px 0 36px;
}

/* Section head */
.va-marchi-widget .sec-head {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.va-marchi-widget h5.eyebrow {
  font-family: var(--display);
  font-weight: 400;
  color: #FFFFFFB3;
  letter-spacing: .01em;
  line-height: 1.2;
  /*font-size: clamp(20px, 2vw, 24px);*/
  margin: 0;
  text-align: left;
}

.va-marchi-widget .sec-head h2 {
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.2;
  /*font-size: clamp(36px, 4.6vw, 60px);*/
  margin: 0;
  color: #f5f5f5;
  text-align: left;
}

@media (max-width: 767px) {
  .va-marchi-widget .sec-head h2 {
line-height: 1.5em;
}
}

/* Filter tags */
.va-marchi-widget .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.va-marchi-widget .marchi-filters {
  margin-top: 40px;
}

.va-marchi-widget .tag {
  font-family: var(--body);
  font-size: 14px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .16);
  color: var(--muted);
  background: transparent;
  transition: .3s;
  cursor: pointer;
}

.va-marchi-widget .tag:hover {
  border-color: rgba(255, 255, 255, .4);
  color: #fff;
}

.va-marchi-widget .tag.is-on {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

/* Grid */
.va-marchi-widget .brand-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 64px 47px;
  padding: 48px 0 130px;
}

/* Card */
.va-marchi-widget .brand-card {
  position: relative;
  padding-top: 65px;
}

.va-marchi-widget .brand-badge {
  position: absolute;
  left: 32px;
  top: 0;
  z-index: 3;
  width: 200px;
  height: 120px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 16px 32px -8px rgba(12, 12, 13, .45);
  display: grid;
  place-items: center;
  padding: 18px 22px;
  transition: transform .5s var(--ease), box-shadow .5s var(--ease);
}

.va-marchi-widget .brand-card:hover .brand-badge {
  transform: translateY(-6px);
  box-shadow: 0 24px 44px -10px rgba(12, 12, 13, .6);
}

.va-marchi-widget .brand-badge img {
  height: auto;
  width: auto;
  max-height: 42px;
  max-width: 100%;
  object-fit: contain;
}

.va-marchi-widget .brand-badge img.inv {
  filter: brightness(0);
}

.va-marchi-widget .brand-wm {
  font-family: var(--display);
  color: #1e1e1e;
  line-height: 1;
  text-align: center;
}

.va-marchi-widget .wm-bold {
  font-weight: 700;
  font-size: 25px;
  letter-spacing: -.02em;
}

.va-marchi-widget .wm-wide {
  font-weight: 600;
  font-size: 20px;
  letter-spacing: .22em;
  text-transform: uppercase;
}

.va-marchi-widget .wm-serif {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 600;
  font-size: 24px;
  font-style: italic;
}

.va-marchi-widget .wm-thin {
  font-weight: 300;
  font-size: 24px;
  letter-spacing: .04em;
}

.va-marchi-widget .brand-card__inner {
  background: transparent;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 6px;
}

.va-marchi-widget .brand-img {
  position: relative;
  height: 300px;
  overflow: hidden;
  border-radius: 6px;
}

.va-marchi-widget .brand-img .img-fill {
  position: absolute;
  inset: 0;
}

.va-marchi-widget .brand-img::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(20, 20, 20, .25), transparent 40%);
}

.va-marchi-widget .img-fill {
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
}

/* Hover zoom on the surface image */
.va-marchi-widget .zoom {
  overflow: hidden;
}

.va-marchi-widget .zoom > .img-fill {
  transition: transform 1s var(--ease);
  will-change: transform;
}

.va-marchi-widget .zoom:hover > .img-fill {
  transform: scale(1.06);
}

.va-marchi-widget .brand-body {
  padding: 26px 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.va-marchi-widget .brand-cat {
  font-family: var(--body);
  font-size: 14px;
  letter-spacing: .04em;
  color: var(--red);
  text-transform: uppercase;
}

.va-marchi-widget .brand-title {
  font-family: var(--display);
  font-weight: 500;
  font-size: 30px;
  color: #f5f5f5;
  line-height: 1.1;
  margin: 0;
}

.va-marchi-widget .brand-desc {
  font-family: var(--body);
  font-size: 20px;
  color: var(--muted);
  line-height: 1.55;
  margin: 0;
  min-height: 66px;
}

.va-marchi-widget .brand-sep {
  height: 1px;
  background: rgba(255, 255, 255, .16);
  margin-top: 6px;
}

.va-marchi-widget .brand-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--body);
  font-size: 15px;
  color: #e3e3e3;
  padding-top: 4px;
  text-decoration: none;
}

.va-marchi-widget .brand-link .ib {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .22);
  display: grid;
  place-items: center;
  transition: .35s var(--ease);
}

.va-marchi-widget .brand-link:hover .ib {
  background: var(--red);
  border-color: var(--red);
  transform: translate(2px, -2px);
}

.va-marchi-widget .brand-link svg {
  width: 18px;
  height: 18px;
}

/* Reveal primitives — only active once JS adds .va-reveal-ready */
.va-marchi-widget.va-reveal-ready [data-reveal] {
  opacity: 0;
  transform: translateY(30px);
  will-change: transform, opacity;
  transition: opacity .9s var(--ease), transform .9s var(--ease);
}

.va-marchi-widget.va-reveal-ready [data-reveal="left"]  { transform: translateX(-40px); }
.va-marchi-widget.va-reveal-ready [data-reveal="right"] { transform: translateX(40px); }
.va-marchi-widget.va-reveal-ready [data-reveal].is-in   { opacity: 1; transform: none; }

/* Responsive — column count is driven by the Elementor "Colonne" control
   (3 desktop / 2 tablet / 1 mobile); these only fine-tune spacing & scale. */
@media (max-width: 1024px) {
  .va-marchi-widget .brand-grid {
    gap: 56px 40px;
  }
}

@media (max-width: 767px) {
  .va-marchi-widget .vam-intro {
    padding: 64px 0 24px;
  }

  .va-marchi-widget .brand-grid {
    gap: 56px 0;
    padding: 36px 0 90px;
  }

  .va-marchi-widget .marchi-filters {
    margin-top: 28px;
  }

  .va-marchi-widget .brand-badge {
    left: 18px;
    width: 168px;
    height: 104px;
  }

  .va-marchi-widget .brand-title {
    font-size: 26px;
  }

  .va-marchi-widget .brand-desc {
    font-size: 17px;
    min-height: 0;
  }
}

/* ==========================================================
   7. REDUCED MOTION
   ========================================================== */
@media (prefers-reduced-motion: reduce) {

  /* Hero lockup — show immediately */
  .js .va-lockup,
  .js .va-lockup.ready {
    visibility: visible !important;
  }

  .js .va-lockup .sq {
    opacity: 1 !important;
    transform: none !important;
  }

  .js .va-lockup__word {
    opacity: 1 !important;
    transform: none !important;
  }

  .va-lockup,
  .va-lockup .sq,
  .va-lockup__word {
    transition: none !important;
  }

  /* Hero content — show immediately */
  .js .va-hero-widget [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }

  .js .va-hero-widget [data-text-reveal] {
    opacity: 1 !important;
  }

  .js .va-hero-widget .tr-word>span {
    transform: none !important;
    transition: none !important;
  }

  .hero-intro-scrim {
    transition: none !important;
  }

  /* Quality — show everything static */
  .qualita__text {
    opacity: 1 !important;
    transform: none !important;
  }

  .qcard {
    opacity: 1 !important;
    transform: translate(-50%, -50%) !important;
  }

  /* Accordion — no transitions */
  .hpanel,
  .hpanel__img,
  .hpanel__content,
  .hpanel__v {
    transition: none !important;
  }

  /* Flip card — no 3D rotation */
  .tcard__flip {
    transition: none !important;
  }

  /* Logo wall — no float */
  .logo-card {
    animation: none !important;
  }

  /* Marchi — reveal instantly, no slide */
  .va-marchi-widget.va-reveal-ready [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }

  .va-marchi-widget .zoom > .img-fill {
    transition: none !important;
  }
}

/* ==========================================================
   8. ELEMENTOR EDITOR OVERRIDES
   ========================================================== */

/* Quality section — disable scroll-trick in editor */
.elementor-editor-active .va-quality-widget.qualita {
  height: auto;
}

.elementor-editor-active .qualita__pin {
  position: relative;
  height: auto;
  min-height: 60vh;
}

.elementor-editor-active .qualita__text {
  opacity: 1 !important;
  transform: none !important;
}

.elementor-editor-active .qcard {
  opacity: .9 !important;
}

/* Marchi — show all cards/heads in the editor regardless of reveal state */
.elementor-editor-active .va-marchi-widget [data-reveal] {
  opacity: 1 !important;
  transform: none !important;
}

/* Lockup — always show in editor */
.elementor-editor-active .va-lockup {
  visibility: visible !important;
}

.elementor-editor-active .va-lockup .sq {
  opacity: 1 !important;
  transform: none !important;
}

.elementor-editor-active .va-lockup__word {
  opacity: 1 !important;
  transform: none !important;
}

/* Hero content — never hide in editor */
.elementor-editor-active .va-hero-widget [data-reveal] {
  opacity: 1 !important;
  transform: none !important;
}

.elementor-editor-active .va-hero-widget [data-text-reveal] {
  opacity: 1 !important;
}

.elementor-editor-active .va-hero-widget .tr-word>span {
  transform: none !important;
}

.elementor-editor-active .hero-intro-scrim {
  opacity: 0 !important;
  transition: none !important;
}

/* Accordion — show first panel's content */
.elementor-editor-active .hpanel__content {
  opacity: 1 !important;
  transform: none !important;
}

.elementor-editor-active .hpanel__v {
  opacity: .55;
}

/* ==========================================================
   FAQ WIDGET — accordion + category filters (teal colorway)
   ========================================================== */
.va-faq-widget {
  background: var(--bg);
  color: var(--light);
  font-family: var(--body);
  padding: 110px 24px;
}

.va-faq-widget .faq-inner {
  max-width: 920px;
  margin: 0 auto;
}

/* ── Header ─────────────────────────────────────────────── */
.va-faq-widget .faq-head {
  text-align: center;
  margin-bottom: 44px;
}

/* Eyebrow + title — same treatment as the Marchi widget */
.va-faq-widget .faq-eyebrow {
  display: inline-block;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(18px, 2vw, 24px);
  color: #FFFFFFB3;
  letter-spacing: .01em;
  line-height: 1.2;
  margin: 0 0 16px;
}

.va-faq-widget .faq-title {
  font-family: var(--display);
  font-weight: 700;
  /*font-size: clamp(32px, 4.6vw, 56px);*/
  line-height: 1.2;
  letter-spacing: -.02em;
  color: #f5f5f5;
  margin: 0;
}

/* First word of the title ("Domande") */
.va-faq-widget .faq-title__hl {
  color: #3DB9B9;
}

.va-faq-widget .faq-intro {
  max-width: 620px;
  margin: 18px auto 0;
  font-size: 20px;
  line-height: 1.6;
  color: var(--muted);
}

/* ── Filters (reuse marchi .tags/.tag) ──────────────────── */
.va-faq-widget .faq-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 36px;
}

.va-faq-widget .tag {
  font-family: var(--body);
  font-size: 14px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .16);
  color: var(--muted);
  background: transparent;
  transition: .3s var(--ease);
  cursor: pointer;
}

.va-faq-widget .tag:hover {
  border-color: rgba(255, 255, 255, .4);
  color: #fff;
}

.va-faq-widget .tag.is-on {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

/* ── List ───────────────────────────────────────────────── */
.va-faq-widget .faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.va-faq-widget .faq-item {
  background: rgba(255, 255, 255, .03);
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 14px;
  overflow: hidden;
  transition: border-color .3s var(--ease), background .3s var(--ease);
}

.va-faq-widget .faq-item.is-open {
  border-color: rgba(42, 127, 127, .55);
  background: rgba(42, 127, 127, .06);
}

.va-faq-widget .faq-q {
  width: 100%;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px;
  background: transparent;
  border: 0;
  text-align: left;
  cursor: pointer;
  font-family: var(--body);
}

.va-faq-widget .faq-q__main {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.va-faq-widget .faq-cat {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--red);
}

.va-faq-widget .faq-q__text {
  font-size: 17px;
  font-weight: 500;
  line-height: 1.45;
  color: #fff;
}

/* Plus / minus icon */
.va-faq-widget .faq-icon {
  position: relative;
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  margin-top: 2px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .22);
  transition: .3s var(--ease);
}

.va-faq-widget .faq-icon::before,
.va-faq-widget .faq-icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 12px;
  height: 2px;
  background: currentColor;
  color: var(--light);
  transform: translate(-50%, -50%);
  transition: .3s var(--ease);
}

.va-faq-widget .faq-icon::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.va-faq-widget .faq-item.is-open .faq-icon {
  background: var(--red);
  border-color: var(--red);
}

.va-faq-widget .faq-item.is-open .faq-icon::before,
.va-faq-widget .faq-item.is-open .faq-icon::after {
  color: #fff;
}

.va-faq-widget .faq-item.is-open .faq-icon::after {
  transform: translate(-50%, -50%) rotate(0deg);
}

/* Answer — smooth height via grid-rows */
.va-faq-widget .faq-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .4s var(--ease);
}

.va-faq-widget .faq-item.is-open .faq-a {
  grid-template-rows: 1fr;
}

/* Pure clip layer — keeps the collapsed item at exactly 0 height
   (no padding here, or the closed accordion would grow) */
.va-faq-widget .faq-a__inner {
  overflow: hidden;
}

.va-faq-widget .faq-a__body {
  padding: 0 24px 24px;
  text-align: left;
}

.va-faq-widget .faq-a__text {
  margin: 0;
  font-size: 15px;
  line-height: 1.65;
  color: rgba(255, 255, 255, .72);
  text-align: left;
}

/* "Chiedi a Materia" CTA — one link for all answers */
.va-faq-widget .faq-cta {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-top: 18px;
  padding: 11px 22px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-family: var(--body);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .02em;
  line-height: 1;
  text-decoration: none;
  transition: background .3s var(--ease), transform .3s var(--ease);
}

.va-faq-widget .faq-cta:hover {
  background: var(--red-deep);
  transform: translateY(-1px);
}

.va-faq-widget .faq-cta svg {
  flex: 0 0 auto;
}

.va-faq-widget .faq-empty {
  text-align: center;
  color: var(--muted);
  padding: 40px 0;
}

/* ── Pagination ─────────────────────────────────────────── */
.va-faq-widget .faq-pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 40px;
}

.va-faq-widget .faq-page {
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .16);
  background: transparent;
  color: var(--muted);
  font-family: var(--body);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  transition: .3s var(--ease);
}

.va-faq-widget .faq-page:hover:not(.is-disabled):not(.is-on) {
  border-color: rgba(255, 255, 255, .4);
  color: #fff;
}

.va-faq-widget .faq-page.is-on {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
  cursor: default;
}

.va-faq-widget .faq-page.is-disabled {
  opacity: .35;
  cursor: default;
}

.va-faq-widget .faq-page--prev,
.va-faq-widget .faq-page--next {
  width: 40px;
  padding: 0;
}

.va-faq-widget .faq-page-ellipsis {
  color: var(--muted);
  padding: 0 2px;
}

/* Reveal primitive */
.va-faq-widget.va-reveal-ready [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}

.va-faq-widget.va-reveal-ready [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* Inside the editor never hide content */
.elementor-editor-active .va-faq-widget [data-reveal] {
  opacity: 1 !important;
  transform: none !important;
}

@media (max-width: 680px) {
  .va-faq-widget {
    padding: 72px 18px;
  }
  .va-faq-widget .faq-q {
    padding: 18px 18px;
    gap: 14px;
  }
  .va-faq-widget .faq-q__text {
    font-size: 16px;
  }
  .va-faq-widget .faq-a__body {
    padding: 0 18px 20px;
  }
  .va-faq-widget .faq-cta {
    margin-top: 16px;
  }
}