/* ==========================================================================
   Illustrazioni delle tre card "Dove lavoro": telefoni con chat e agenda,
   laptop in videocall, icone social in 3D. È un disegno dimostrativo, non
   parte del sistema: i suoi grigi-verdi, i raggi in cqw e il rosso della
   registrazione servono solo a far sembrare vere le schermate.
   Le misure interne usano cqw, quindi tutto scala con la larghezza del dispositivo.
   ========================================================================== */

.channel__art {
  --device: #0b0c0b;
  --device-edge: #2b2f2c;
  --device-rim: #4a514d;
  --screen: #0f1d16;
  --screen-deep: #0a120d;
  --ui-surface: #1c2a22;
  --ui-surface-2: #16241c;
  --ui-muted: #8fb3a0;
  --ui-avatar: #23553a;
  --rec: #ff5a4f;
  --hang-up: #e5484d;
}

/* Telefoni */
.phone {
  position: absolute; container-type: inline-size;
  width: 52%; aspect-ratio: 9 / 19.2;
  padding: 3.2%;
  border-radius: 15% / 7.2%;
  background: var(--device);
  box-shadow: inset 0 0 0 1px var(--device-edge), 0 0 0 1.5px var(--device-rim), var(--shadow-drop);
}
.phone__screen {
  position: relative; width: 100%; height: 100%; overflow: hidden;
  border-radius: 12% / 5.6%;
  background: linear-gradient(180deg, var(--screen), var(--screen-deep) 62%);
}
.phone__island { position: absolute; top: 4.4%; left: 50%; translate: -50% 0; width: 30%; height: 3.4%; border-radius: var(--r-pill); background: var(--device); }
.phone--front { left: 9%; top: 8%; rotate: -11deg; z-index: 2; }
.phone--back { left: 54%; top: 5%; width: 44%; rotate: 10deg; opacity: 0.7; }

.phone__status {
  display: flex; justify-content: space-between; align-items: center;
  padding: 6.4cqw 9cqw 0;
  font-size: 5cqw; font-weight: 600; color: var(--mint-white);
}
.phone__sys { display: flex; align-items: flex-end; gap: 1.2cqw; }
.phone__sys i { width: 1.4cqw; border-radius: 0.3cqw; background: var(--mint-white); }
.phone__sys i:nth-child(1) { height: 2cqw; }
.phone__sys i:nth-child(2) { height: 3cqw; }
.phone__sys i:nth-child(3) { height: 4cqw; }
.phone__sys b { width: 7cqw; height: 3.6cqw; margin-left: 1.4cqw; border-radius: 1.2cqw; box-shadow: inset 0 0 0 1px var(--mint-white); background: linear-gradient(90deg, var(--mint-white) 64%, transparent 64%) padding-box; }
.chat__head {
  display: flex; align-items: center; gap: 3cqw;
  margin-top: 3cqw; padding: 5cqw 5cqw 4cqw;
  border-bottom: 1px solid color-mix(in srgb, var(--text) 7%, transparent);
}
.chat__back { width: 6cqw; height: 6cqw; color: var(--mint); }
.chat__avatar { width: 11cqw; height: 11cqw; border-radius: 50%; display: grid; place-items: center; background: var(--ui-avatar); color: var(--mint-mist); }
.chat__avatar svg { width: 7cqw; height: 7cqw; }
.chat__who b { display: block; font-size: 5.2cqw; font-weight: 600; line-height: 1.2; }
.chat__who small { font-size: 4cqw; color: var(--mint); }
.chat__body { display: flex; flex-direction: column; gap: 3cqw; padding: 5cqw; }
.msg { max-width: 84%; padding: 3cqw 4cqw; border-radius: 5cqw; font-size: 4.8cqw; line-height: 1.38; }
.msg--in { align-self: flex-start; background: var(--ui-surface); color: var(--mint-white); border-bottom-left-radius: 1.5cqw; }
.msg--out { align-self: flex-end; background: linear-gradient(135deg, var(--green-mid), var(--green-deep)); color: var(--text); border-bottom-right-radius: 1.5cqw; }
.msg--out svg { display: inline-block; width: 5cqw; height: 5cqw; margin-left: 1.5cqw; vertical-align: -1cqw; color: var(--mint-soft); }
.booked {
  display: flex; align-items: center; gap: 3cqw;
  margin-top: 1cqw; padding: 3.5cqw;
  border-radius: 5cqw;
  background: color-mix(in srgb, var(--mint) 12%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--mint) 38%, transparent);
}
.booked__ico { flex: none; width: 10cqw; height: 10cqw; border-radius: 3cqw; display: grid; place-items: center; background: var(--mint); color: var(--ink-deep); }
.booked__ico svg { width: 6cqw; height: 6cqw; }
.booked__txt b { display: block; font-size: 4.8cqw; line-height: 1.25; }
.booked__txt small { font-size: 4.2cqw; color: var(--mint-mist); }
.booked__ok { width: 7cqw; height: 7cqw; margin-left: auto; color: var(--mint); }

.agenda { padding: 17cqw 7cqw 0; }
.agenda__title { font-size: 7cqw; font-weight: 700; }
.agenda__days { display: flex; justify-content: space-between; align-items: center; margin: 5cqw 0 6cqw; font-size: 4.6cqw; color: var(--ui-muted); }
.agenda__days .is-on { width: 8cqw; height: 8cqw; border-radius: 50%; display: grid; place-items: center; background: var(--mint); color: var(--ink-deep); font-weight: 700; }
.agenda__slot { display: flex; align-items: center; gap: 3cqw; margin-bottom: 4cqw; }
.agenda__slot i { width: 9cqw; height: 2.2cqw; border-radius: 2cqw; background: var(--ui-surface); }
.agenda__slot span { flex: 1; height: 11cqw; border-radius: 3cqw; background: var(--ui-surface-2); }
.agenda__slot--hot span { background: linear-gradient(90deg, var(--green-mid), var(--green-deep)); }

/* Laptop in videocall */
.laptop {
  position: absolute; left: 11%; top: 14%; width: 98%;
  transform: perspective(1100px) rotateY(-22deg) rotateX(9deg) rotate(-3deg);
  transform-origin: left center;
}
.laptop__lid {
  container-type: inline-size;
  aspect-ratio: 16 / 10.4;
  padding: 2.2%;
  border-radius: 3.4% 3.4% 1% 1% / 5% 5% 1.4% 1.4%;
  background: var(--device);
  box-shadow: inset 0 0 0 1px var(--device-edge), 0 0 0 1.5px var(--device-rim);
}
.laptop__base {
  position: relative;
  width: 112%; margin-left: -6%;
  height: clamp(9px, 1.3vw, 15px);
  border-radius: 0 0 50% 50% / 0 0 80% 80%;
  background: linear-gradient(180deg, var(--device-rim), var(--device-edge) 58%, var(--device));
  box-shadow: var(--shadow-drop);
}
.laptop__base::before { content: ""; position: absolute; left: 50%; top: 0; translate: -50% 0; width: 16%; height: 38%; border-radius: 0 0 40% 40%; background: var(--device-edge); }
.vc {
  display: flex; flex-direction: column; gap: 2cqw;
  width: 100%; height: 100%; overflow: hidden;
  padding: 2.4cqw;
  border-radius: 1.4cqw;
  background: var(--screen-deep);
}
.vc__top { display: flex; justify-content: space-between; align-items: center; font-size: 2.7cqw; color: var(--mint-mist); }
.vc__live { display: flex; align-items: center; gap: 1.2cqw; }
.vc__live i { width: 1.6cqw; height: 1.6cqw; border-radius: 50%; background: var(--rec); box-shadow: 0 0 0 0.6cqw color-mix(in srgb, var(--rec) 25%, transparent); }
.vc__time { font-variant-numeric: tabular-nums; }
.vc__grid { flex: 1; min-height: 0; display: grid; grid-template-columns: 1.25fr 1fr; gap: 1.6cqw; }
.vc__tile { position: relative; overflow: hidden; display: grid; place-items: center; border-radius: 1.6cqw; background: var(--ui-surface-2); }
.vc__tile--me {
  background:
    url("../assets/img/giuseppe-hero.webp") 34% 14% / 150% auto no-repeat,
    radial-gradient(80% 80% at 40% 20%, var(--green-deep), var(--pine-deep));
  box-shadow: inset 0 0 0 0.4cqw var(--mint);
}
.vc__tile--guest svg { width: 12cqw; height: 12cqw; color: var(--ui-muted); opacity: 0.7; }
.vc__name { position: absolute; left: 1.4cqw; bottom: 1.4cqw; padding: 0.5cqw 1.4cqw; border-radius: var(--r-pill); background: color-mix(in srgb, var(--bg) 60%, transparent); font-size: 2.3cqw; color: var(--text); }
.vc__bar { display: flex; justify-content: center; gap: 1.6cqw; }
.vc__bar span { width: 5.8cqw; height: 5.8cqw; border-radius: 50%; display: grid; place-items: center; background: var(--ui-surface); color: var(--mint-mist); }
.vc__bar svg { width: 3cqw; height: 3cqw; }
.vc__bar .vc__end { width: 8.5cqw; border-radius: var(--r-pill); background: var(--hang-up); color: var(--text); }

.float-chip {
  position: absolute; right: 6%; bottom: 30%;
  display: flex; align-items: center; gap: 8px;
  padding: 9px 16px 9px 9px;
  border-radius: var(--r-pill);
  background: var(--card-deep);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--mint) 38%, transparent), var(--shadow-float);
  font-size: var(--fs-micro); font-weight: 600; color: var(--mint-white); white-space: nowrap;
  animation: bob 6s ease-in-out infinite;
}
.float-chip svg { width: 24px; height: 24px; padding: 4px; border-radius: 50%; background: var(--mint); color: var(--ink-deep); }

/* Icone 3D: faccia lucida davanti, piastra scura dietro (translateZ) per lo spessore */
.channel--social .channel__art { perspective: 900px; }
.tile {
  position: absolute; aspect-ratio: 1;
  display: grid; place-items: center;
  border-radius: 27%;
  color: var(--mint-white);
  background: linear-gradient(150deg, var(--logo-mint) 0%, var(--mint) 36%, var(--dot) 70%, var(--green-deep) 100%);
  box-shadow:
    inset 0 2px 1px color-mix(in srgb, var(--text) 55%, transparent),
    inset 0 -10px 18px color-mix(in srgb, var(--pine-deep) 45%, transparent),
    0 0 80px color-mix(in srgb, var(--mint) 26%, transparent);
  transform-style: preserve-3d;
  transform: rotateX(var(--rx)) rotateY(var(--ry)) rotateZ(var(--rz));
  animation: float 7s ease-in-out infinite;
}
.tile::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: linear-gradient(150deg, var(--green-deep), var(--ink-deep));
  transform: translateZ(-16px);
  box-shadow: var(--shadow-drop);
}
.tile::after {
  content: ""; position: absolute; inset: 5% 9% 55%;
  border-radius: 45% 45% 50% 50% / 70% 70% 30% 30%;
  background: linear-gradient(180deg, color-mix(in srgb, var(--text) 42%, transparent), transparent);
  transform: translateZ(1px);
}
.tile svg { width: 50%; height: 50%; transform: translateZ(10px); filter: drop-shadow(0 3px 4px color-mix(in srgb, var(--ink-deep) 35%, transparent)); }
.tile--ig { left: 14%; top: 13%; width: 40%; --rx: 16deg; --ry: -24deg; --rz: -11deg; }
.tile--wa { left: 60%; top: 9%; width: 27%; --rx: 10deg; --ry: 26deg; --rz: 12deg; animation-delay: -2.4s; animation-duration: 8s; }
.tile--meta { left: 55%; top: 43%; width: 24%; --rx: -10deg; --ry: -20deg; --rz: -7deg; animation-delay: -4.6s; animation-duration: 9s; }

@keyframes float { 50% { translate: 0 -12px; } }
@keyframes bob { 50% { translate: 0 -6px; } }

@media (max-width: 860px) {
  .phone--front { width: 50%; left: 10%; }
  .phone--back { width: 42%; }
  .laptop { width: 92%; left: 8%; }
}
@media (max-width: 520px) {
  .float-chip { right: 5%; bottom: 40%; }
}
