.bt { position: relative; height: max(600px, 100svh); background: radial-gradient(80% 70% at 50% 45%, #3a2216, #1a100b 70%); color: var(--avorio); overflow: hidden; isolation: isolate; }
.bt-cv { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: pan-y; opacity: 0; transition: opacity .6s var(--ease); }
.bt.pronta .bt-cv { opacity: 1; }
.bt::before, .bt::after { content: ''; position: absolute; left: 0; right: 0; pointer-events: none; z-index: 1; }
.bt::before { top: 0; height: calc(var(--alt-header) + 40px); background: linear-gradient(rgba(20, 12, 8, .6), transparent); transition: opacity .5s var(--ease); }
.bt::after { bottom: 0; height: 14%; background: linear-gradient(transparent, rgba(20, 12, 8, .5)); }
.bt.aperta::before { opacity: 0; }

.bt-titolo { position: absolute; z-index: 2; top: calc(var(--alt-header) + 14px); left: var(--gutter); max-width: min(360px, 70%); pointer-events: none;
  text-shadow: 0 2px 14px rgba(20, 12, 8, .7); opacity: 0; transition: opacity .6s var(--ease) .4s; }
.bt.pronta .bt-titolo { opacity: 1; }
.bt.aperta .bt-titolo { opacity: 0; transition-delay: 0s; }
.bt-titolo .mano { display: block; color: var(--arancio); font-size: clamp(1.05rem, 1.6vw, 1.35rem); line-height: 1; }
.bt-titolo h1 { margin: 4px 0 0; font: 800 clamp(1.15rem, 1.9vw, 1.6rem)/1.15 var(--display); letter-spacing: -.01em; color: var(--avorio); }

.bt-banchi { list-style: none; margin: 0; padding: 0; position: absolute; inset: 0; z-index: 2; pointer-events: none; transition: opacity .3s var(--ease); }
.bt-banchi.nascosti { opacity: 0; }
.bt-banchi.nascosti .bt-b { pointer-events: none; }
.bt-p { position: absolute; left: 0; top: 0; width: 0; height: 0; }
.bt-p.fuori { visibility: hidden; }
.bt-b { position: absolute; left: 0; top: 0; width: max-content; translate: -22px -50%; display: flex; align-items: center; gap: 8px; padding: 0; border: 0; background: none; color: var(--avorio); font: 600 .9rem/1.2 var(--corpo); cursor: pointer; pointer-events: auto; text-align: left; }
.bt-b b { flex: none; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: var(--arancio); color: #fff; font: 800 1.45rem/1 var(--corpo);
  box-shadow: 0 0 0 4px rgba(238, 122, 43, .3), 0 8px 18px -6px rgba(0, 0, 0, .6); animation: bt-pulsa 2.4s var(--ease) infinite; transition: scale .2s var(--molla); }
.bt-p.vuoto .bt-b b { background: rgba(30, 19, 13, .7); border: 2px dashed var(--arancio); color: var(--arancio); font-family: var(--display); animation: none; box-shadow: 0 8px 18px -6px rgba(0, 0, 0, .6); }
@keyframes bt-pulsa { 50% { box-shadow: 0 0 0 10px rgba(238, 122, 43, 0), 0 8px 18px -6px rgba(0, 0, 0, .6); } }
.bt-et { display: grid; padding: 7px 12px; border-radius: 14px; background: rgba(30, 19, 13, .82); border: 1px solid rgba(251, 244, 232, .2); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  max-width: 200px; opacity: 0; scale: .92; transition: opacity .2s var(--ease), scale .2s var(--ease); pointer-events: none; }
.bt-et strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-et small { color: var(--albicocca); font-weight: 700; }
.bt-p.su .bt-et, .bt-b:focus-visible .bt-et { opacity: 1; scale: 1; border-color: var(--arancio); }
.bt-p.su { z-index: 1; }
.bt-p.dx .bt-b { flex-direction: row-reverse; translate: calc(-100% + 22px) -50%; text-align: right; }
.bt-p.su .bt-b b, .bt-b:focus-visible b { scale: 1.12; }
.bt-b:focus-visible { outline: none; }
.bt-b:focus-visible b { outline: 3px solid var(--albicocca); outline-offset: 3px; }

.bt-facciata { position: absolute; z-index: 3; top: 0; bottom: 0; left: 0; width: min(470px, 42%); overflow-y: auto; overscroll-behavior: contain;
  padding: calc(var(--alt-header) + 18px) clamp(18px, 2.4vw, 32px) 28px; background: rgba(251, 244, 232, .96); color: var(--ink);
  box-shadow: 24px 0 60px -30px rgba(0, 0, 0, .6); animation: bt-entra .55s var(--ease); }
.bt-facciata[hidden] { display: none; }
@keyframes bt-entra { from { translate: -40px 0; opacity: 0; } }
.bt-f-testa { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.bt-f-n { font: 700 1.3rem/1 var(--mano); color: var(--brace); }
.bt-f-frecce { display: flex; gap: 6px; }
.bt-tondo { width: 42px; height: 42px; border-radius: 50%; border: 1px solid rgba(58, 35, 24, .25); background: #fff; color: var(--ink); font: 600 1.1rem/1 var(--corpo); cursor: pointer; display: grid; place-items: center; transition: background .2s, border-color .2s; }
.bt-tondo:hover, .bt-tondo:focus-visible { border-color: var(--arancio); background: var(--albicocca); }
.bt-x { font-size: 1.5rem; }
.bt-vista { position: relative; margin: 14px 0 0; aspect-ratio: 5 / 4; border-radius: 24px; background: radial-gradient(70% 70% at 50% 42%, #fff, #f3e4cc 70%, #ead3b1); overflow: hidden; }
.bt-mini-cv { position: absolute; inset: 0; width: 100%; height: 100%; display: block; cursor: grab; touch-action: pan-y; }
.bt-mini-cv:active { cursor: grabbing; }
.bt-vista img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bt-vista-sole { position: absolute; inset: 25%; background: var(--arancio); -webkit-mask: center / contain no-repeat; opacity: .3; border-radius: 50%; }
.bt-gira { margin: 8px 0 0; text-align: center; font-size: .82rem; color: rgba(58, 35, 24, .6); }
.bt-f-corpo h2 { margin: 16px 0 4px; font: 800 clamp(1.6rem, 2.4vw, 2.1rem)/1.1 var(--display); letter-spacing: -.01em; }
.bt-f-corpo h3 { margin: 18px 0 6px; font: 700 .8rem/1 var(--corpo); letter-spacing: .08em; text-transform: uppercase; color: var(--brace); }
.bt-f-corpo p { margin: 6px 0; line-height: 1.55; }
.bt-prezzo { font: 800 1.5rem/1 var(--display); color: var(--brace); }
.bt-dentro { margin: 0; padding-left: 1.1em; line-height: 1.6; }
.bt-foto { width: 100%; height: auto; margin-top: 16px; border-radius: 18px; display: block; }
.bt-azioni { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.bt-stato { display: inline-block; padding: 10px 16px; border-radius: 999px; background: var(--albicocca); font-weight: 700; }
.bt-tutti { display: inline-block; margin-top: 16px; color: var(--brace); font-weight: 700; }

.bt-piatta .bt-cv { display: none; }
.bt-piatta .bt-banchi { inset: auto 0 40px; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; padding: 0 16px; }
.bt-piatta .bt-p { position: static; width: auto; height: auto; }
.bt-piatta .bt-et { opacity: 1; scale: 1; }
.bt-piatta .bt-b, .bt-piatta .bt-p.dx .bt-b { position: static; translate: none; flex-direction: row; text-align: left; }

@media (max-width: 759px) {
  .bt { height: max(540px, calc(100svh - 84px)); }
  .bt-b b { width: 40px; height: 40px; font-size: 1.3rem; }
  .bt-et { display: none; }
  .bt-p.dx .bt-b { translate: -50% -50%; }
  .bt-b { translate: -50% -50%; }
  .bt-facciata { position: fixed; inset: 22svh 0 0; z-index: 60; width: 100%; padding-top: 18px; padding-bottom: 110px; border-radius: 26px 26px 0 0; box-shadow: 0 -20px 60px -20px rgba(0, 0, 0, .6); animation-name: bt-sale; }
  .bt.aperta .bt-velo { display: block; }
  @keyframes bt-sale { from { translate: 0 30px; opacity: 0; } }
  .bt-vista { aspect-ratio: 16 / 11; }
}
@media (prefers-reduced-motion: reduce) { .bt-facciata, .bt-b b { animation: none; } }
.bt-velo { display: none; position: fixed; inset: 0; z-index: 59; background: rgba(20, 12, 8, .35); border: 0; padding: 0; cursor: pointer; }
.bt:not(.pronta) .bt-banchi { opacity: 0; visibility: hidden; }

.bt-carica { position: absolute; inset: 0; z-index: 4; display: grid; place-content: center; justify-items: center; gap: 10px; padding: 0 16px; text-align: center; pointer-events: none;
  background: radial-gradient(70% 60% at 50% 45%, #3a2216, #1a100b 75%); transition: opacity .9s var(--ease), visibility 0s .9s; }
.bt-carica .mano { color: var(--arancio); font-size: clamp(1.4rem, 3vw, 2rem); }
.bt-carica strong { font: 900 clamp(2.1rem, 6vw, 4.4rem)/1.02 var(--display); letter-spacing: -.02em; color: var(--avorio); max-width: 14ch; animation: bt-titolo .9s var(--ease) both; }
.bt-carica small { display: inline-flex; align-items: center; gap: 10px; margin-top: 8px; font: 500 1rem/1.3 var(--corpo); color: rgba(251, 244, 232, .78); transition: opacity .3s var(--ease); }
.bt-fiamma { width: 12px; height: 12px; border-radius: 50%; background: var(--arancio); box-shadow: 0 0 14px 4px rgba(238, 122, 43, .55); animation: bt-fiamma 1.1s ease-in-out infinite alternate; }
@keyframes bt-titolo { from { opacity: 0; transform: translateY(14px); } }
@keyframes bt-fiamma { from { transform: scale(.7); opacity: .55; } to { transform: scale(1.15); opacity: 1; } }
.bt.entra .bt-carica small { opacity: 0; }
.bt.pronta .bt-carica, .bt-piatta .bt-carica { opacity: 0; visibility: hidden; }
@media (prefers-reduced-motion: reduce) { .bt-carica strong, .bt-fiamma { animation: none; } }
