/* ---------- Screenshot applicazione ---------- */
.app-showcase {
  overflow: hidden;
}

.app-spotlight {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.75fr);
  gap: clamp(28px, 5vw, 70px);
  align-items: center;
  padding: clamp(22px, 4vw, 46px);
  margin-bottom: 22px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 24px;
  background:
    linear-gradient(
      125deg,
      rgba(255, 255, 255, 0.08),
      rgba(255, 255, 255, 0.025)
    ),
    #121827;
}

.app-spotlight-glow {
  position: absolute;
  top: 50%;
  left: 18%;
  width: 450px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: rgba(182, 36, 45, 0.25);
  filter: blur(95px);
  pointer-events: none;
  transform: translate(-50%, -50%);
}

.app-screen {
  position: relative;
  z-index: 1;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;
  background: #080b13;
  box-shadow: 0 22px 45px -28px rgba(0, 0, 0, 0.95);
}

.app-screen-topbar {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 13px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.08);
}

.app-screen-topbar span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
}

.app-screen-topbar span:first-child {
  background: var(--light-red);
}

.app-screen-topbar small {
  margin-left: 5px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 10px;
  letter-spacing: 0.04em;
}

.app-screen img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center;
  transition: transform 0.55s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.app-spotlight:hover .app-screen img,
.app-gallery-card:hover .app-screen img {
  transform: scale(1.035);
}

.app-screen-large {
  transform: perspective(1300px) rotateY(2deg) rotateX(1deg);
  transition: transform 0.45s ease;
}

.app-spotlight:hover .app-screen-large {
  transform: perspective(1300px) rotateY(0) rotateX(0) translateY(-4px);
}

.app-spotlight-copy {
  position: relative;
  z-index: 1;
}

.app-shot-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--light-red);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.app-spotlight-copy h3 {
  margin: 0;
  color: #fff;
  font-size: clamp(25px, 2.5vw, 36px);
  line-height: 1.15;
}

.app-spotlight-copy > p {
  margin: 18px 0 0;
  color: var(--white-50);
  font-size: 15px;
  line-height: 1.7;
}

.app-spotlight-list {
  display: flex;
  flex-direction: column;
  gap: 11px;
  margin-top: 25px;
}

.app-spotlight-list li {
  display: flex;
  gap: 10px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
}

.app-spotlight-list i {
  color: #3ed690;
}

.app-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.app-gallery-card {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(190px, 0.72fr);
  gap: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.055);
  transition:
    transform 0.3s ease,
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}

.app-gallery-card:hover {
  z-index: 1;
  border-color: rgba(219, 84, 97, 0.48);
  box-shadow: 0 22px 50px -28px rgba(182, 36, 45, 0.42);
  transform: translateY(-5px);
}

.app-gallery-card .app-screen {
  border: 0;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0;
  box-shadow: none;
}

.app-gallery-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 26px 23px;
  background:
    linear-gradient(
      125deg,
      rgba(255, 255, 255, 0.08),
      rgba(255, 255, 255, 0.025)
    ),
    #121827;
}

.app-gallery-copy .app-shot-label {
  margin-bottom: 9px;
}

.app-gallery-copy h3 {
  margin: 0;
  color: #fff;
  font-size: 18px;
  line-height: 1.25;
}

.app-gallery-copy p {
  margin: 10px 0 0;
  color: var(--white-50);
  font-size: 13px;
  line-height: 1.6;
}

@media (max-width: 1199px) {
  .app-gallery {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 991px) {
  .app-spotlight {
    grid-template-columns: 1fr;
  }

  .app-screen-large {
    transform: none;
  }
}

@media (max-width: 575.98px) {
  .app-spotlight {
    padding: 16px;
    border-radius: 18px;
  }

  .app-gallery-card {
    grid-template-columns: 1fr;
  }

  .app-gallery-card .app-screen {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .app-gallery-copy {
    padding: 21px;
  }

  .app-spotlight-copy {
    padding: 4px 5px 8px;
  }
}

/* ---------- Lightbox screenshot ---------- */
.app-screen-trigger {
  display: block;
  width: 100%;
  padding: 0;
  color: inherit;
  text-align: left;
  cursor: zoom-in;
}

.app-screen-trigger::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(180deg, transparent 45%, rgba(5, 9, 22, 0.5));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.app-screen-expand {
  position: absolute;
  z-index: 3;
  right: 15px;
  bottom: 15px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 999px;
  color: #fff;
  background: rgba(10, 13, 23, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(12px);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
}

.app-screen-trigger:hover::after,
.app-screen-trigger:focus-visible::after {
  opacity: 1;
}

.app-screen-trigger:hover .app-screen-expand,
.app-screen-trigger:focus-visible .app-screen-expand {
  opacity: 1;
  transform: translateY(0);
}

.app-screen-trigger:focus-visible {
  outline: 2px solid var(--light-red);
  outline-offset: 3px;
}

/* Modale */
.app-lightbox {
  position: fixed;
  z-index: 9999;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  visibility: hidden;
  opacity: 0;
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}

.app-lightbox.is-open {
  visibility: visible;
  opacity: 1;
}

.app-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 5, 12, 0.86);
  backdrop-filter: blur(12px);
}

.app-lightbox-dialog {
  position: relative;
  z-index: 1;
  width: min(1180px, 100%);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 18px;
  background: #101522;
  box-shadow: 0 35px 100px rgba(0, 0, 0, 0.7);
  transform: translateY(18px) scale(0.98);
  transition: transform 0.3s ease;
}

.app-lightbox.is-open .app-lightbox-dialog {
  transform: translateY(0) scale(1);
}

.app-lightbox-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 46px;
  padding: 0 58px 0 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.06);
}

.app-lightbox-bar p {
  margin: 0;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.6);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.app-lightbox-dots {
  display: flex;
  gap: 6px;
}

.app-lightbox-dots i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.28);
}

.app-lightbox-dots i:first-child {
  background: var(--light-red);
}

.app-lightbox-close {
  position: absolute;
  z-index: 2;
  top: 7px;
  right: 10px;
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  cursor: pointer;
  transition:
    background 0.2s ease,
    transform 0.2s ease;
}

.app-lightbox-close:hover {
  background: var(--red);
  transform: rotate(90deg);
}

.app-lightbox-image-wrap {
  max-height: calc(100vh - 120px);
  overflow: auto;
  background: #080b13;
}

.app-lightbox-image-wrap img {
  display: block;
  width: 100%;
  height: auto;
}

body.lightbox-open {
  overflow: hidden;
}

@media (max-width: 575.98px) {
  .app-lightbox {
    padding: 12px;
  }

  .app-lightbox-dialog {
    border-radius: 13px;
  }

  .app-screen-expand {
    opacity: 1;
    transform: none;
  }
}
