.dvf { position: relative; width: 100%; container-type: inline-size; }

.dvf-shell {
  display: block;
  width: 100%;
  height: auto;
  position: relative;
  z-index: 2;
  pointer-events: none;
}

.dvf-scr {
  position: absolute;
  z-index: 1;
  display: block;
  border: 0;
  object-fit: cover;
  object-position: top center;
  background: #0a0a0f;
}

.dvf-mac .dvf-scr {
  left: 11.6886%;
  top: 14.6475%;
  width: 76.6227%;
  height: 73.6131%;
  border-radius: 0 0 0.35% 0.55%;
}

.dvf-mac::before {
  content: "";
  position: absolute;
  z-index: 0;
  left: 11.5%;
  top: 11.4%;
  width: 77%;
  height: 77.1%;
  background: #0a0a0f;
  border-radius: 0.35% / 0.55%;
}

.dvf-bar {
  position: absolute;
  z-index: 3;
  left: 11.6886%;
  top: 11.7395%;
  width: 76.6227%;
  height: 2.908%;
  display: flex;
  align-items: center;
  gap: 0.72cqw;
  padding-left: 1.5cqw;
  background: #26262a;
  pointer-events: none;
}
.dvf-bar i {
  width: 0.82cqw;
  height: 0.82cqw;
  border-radius: 50%;
  flex: 0 0 auto;
}
.dvf-bar i:nth-child(1) { background: #ff5f57; }
.dvf-bar i:nth-child(2) { background: #febc2e; }
.dvf-bar i:nth-child(3) { background: #28c840; }

.dvf-mac::after {
  content: "";
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 11.7395%;
  width: 9.731%;
  height: 2.908%;
  transform: translateX(-50%);
  background:
    radial-gradient(circle at 63% 54%, #2c4258 0 6%, #0b131c 7.5%, transparent 9.5%),
    #000;
  border-radius: 0 0 26% 26% / 0 0 46% 46%;
  pointer-events: none;
}

.dvf-phone .dvf-scr {
  left: 5.9746%;
  top: 2.9455%;
  width: 88.0508%;
  height: 94.1090%;
  border-radius: 12.4% / 5.7%;
}

.dvf-cluster {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  perspective: 2100px;
  align-items: center;
  padding: 3% 2% 0;
  gap: clamp(4px, 1.2vw, 18px);
}

.dvf-cluster > * { transform-style: preserve-3d; }
.dvf-cluster > :nth-child(1) { transform: rotateY(19deg) translateX(9%) scale(0.84); z-index: 1; }
.dvf-cluster > :nth-child(2) { transform: translateZ(70px) scale(0.97); z-index: 3; }
.dvf-cluster > :nth-child(3) { transform: rotateY(-19deg) translateX(-9%) scale(0.84); z-index: 1; }

@media (max-width: 780px) {
  .dvf-cluster { grid-template-columns: minmax(0, 1fr); padding: 0; }
  .dvf-cluster > :nth-child(1),
  .dvf-cluster > :nth-child(3) { display: none; }
  .dvf-cluster > :nth-child(2) { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .dvf-cluster > * { transform: none !important; }
  .dvf-cluster { perspective: none; }
}

.dvf-shell-d {
  display: none;
}
[data-theme="dark"] .dvf-shell-d {
  display: block;
}
[data-theme="dark"] .dvf-shell-l {
  display: none;
}
