/* ═══════════════════════════════════════════════════════════════
   V8: BLUEPRINT BUILDING ANIMATION
   Isometric building with animated measurements - GPU-accelerated
   ═══════════════════════════════════════════════════════════════ */

.blueprint-hero {
  --mx: 50%;
  --my: 50%;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}

.blueprint-grid-bg {
  position: absolute;
  inset: -100px;
  background-image:
    linear-gradient(rgba(16, 185, 129, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 185, 129, 0.08) 1px, transparent 1px);
  background-size: 50px 50px;
  opacity: 0.8;
}

.blueprint-cursor-glow {
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  transform: translate(-50%, -50%);
  left: var(--mx);
  top: var(--my);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.blueprint-hero:hover .blueprint-cursor-glow {
  opacity: 1;
}

.blueprint-container {
  position: absolute;
  top: 50%;
  right: 5%;
  transform: translateY(-50%);
  width: 700px;
  height: 580px;
  opacity: 0.95;
  filter: drop-shadow(0 0 40px rgba(16, 185, 129, 0.15));
}

@media (max-width: 1280px) {
  .blueprint-container {
    width: 600px;
    height: 500px;
    right: 2%;
  }
}

@media (max-width: 1024px) {
  .blueprint-container {
    right: 50%;
    transform: translate(50%, -50%);
    opacity: 0.5;
    width: 500px;
    height: 420px;
  }
}

@media (max-width: 768px) {
  .blueprint-container {
    width: 380px;
    height: 340px;
    opacity: 0.35;
  }
}

.blueprint-building {
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* Building layers - stroke animation */
.bp-layer {
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 2000;
  stroke-dashoffset: 2000;
}

.bp-foundation {
  stroke: #10b981;
  stroke-width: 2.5;
  filter: drop-shadow(0 0 8px rgba(16, 185, 129, 0.6));
  animation: bp-draw 10s ease-out infinite;
  animation-delay: 0s;
}

.bp-floor1 {
  stroke: rgba(16, 185, 129, 0.95);
  stroke-width: 2;
  filter: drop-shadow(0 0 6px rgba(16, 185, 129, 0.4));
  animation: bp-draw 10s ease-out infinite;
  animation-delay: 0.8s;
}

.bp-floor2 {
  stroke: rgba(16, 185, 129, 0.85);
  stroke-width: 1.8;
  filter: drop-shadow(0 0 5px rgba(16, 185, 129, 0.35));
  animation: bp-draw 10s ease-out infinite;
  animation-delay: 1.6s;
}

.bp-floor3 {
  stroke: rgba(16, 185, 129, 0.75);
  stroke-width: 1.6;
  filter: drop-shadow(0 0 4px rgba(16, 185, 129, 0.3));
  animation: bp-draw 10s ease-out infinite;
  animation-delay: 2.4s;
}

.bp-roof {
  stroke: #14b8a6;
  stroke-width: 2.5;
  filter: drop-shadow(0 0 10px rgba(20, 184, 166, 0.5));
  animation: bp-draw 10s ease-out infinite;
  animation-delay: 3.2s;
}

@keyframes bp-draw {
  0%,
  5% {
    stroke-dashoffset: 2000;
  }
  30%,
  80% {
    stroke-dashoffset: 0;
  }
  95%,
  100% {
    stroke-dashoffset: 2000;
  }
}

/* Building fills */
.bp-fill {
  opacity: 0;
  animation: bp-fill 10s ease-out infinite;
}

.bp-fill-1 {
  fill: rgba(16, 185, 129, 0.15);
  animation-delay: 1s;
}
.bp-fill-2 {
  fill: rgba(16, 185, 129, 0.12);
  animation-delay: 1.8s;
}
.bp-fill-3 {
  fill: rgba(16, 185, 129, 0.1);
  animation-delay: 2.6s;
}
.bp-fill-4 {
  fill: rgba(16, 185, 129, 0.08);
  animation-delay: 3.4s;
}
.bp-fill-roof {
  fill: rgba(20, 184, 166, 0.18);
  animation-delay: 4s;
}

@keyframes bp-fill {
  0%,
  15% {
    opacity: 0;
  }
  30%,
  80% {
    opacity: 1;
  }
  95%,
  100% {
    opacity: 0;
  }
}

/* Floor labels */
.bp-floor-label {
  font-family: "JetBrains Mono", "SF Mono", monospace;
  font-size: 11px;
  font-weight: 500;
  fill: #10b981;
  opacity: 0;
  animation: bp-label 10s ease-out infinite;
}

.bp-floor-label:nth-of-type(1) {
  animation-delay: 1s;
}
.bp-floor-label:nth-of-type(2) {
  animation-delay: 1.8s;
}
.bp-floor-label:nth-of-type(3) {
  animation-delay: 2.6s;
}
.bp-floor-label:nth-of-type(4) {
  animation-delay: 3.4s;
}

@keyframes bp-label {
  0%,
  12% {
    opacity: 0;
  }
  22%,
  80% {
    opacity: 1;
  }
  95%,
  100% {
    opacity: 0;
  }
}

/* Measurement lines */
.bp-measure {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0;
  animation: bp-measure 10s ease-out infinite;
}

.bp-measure-h {
  flex-direction: row;
}

.bp-measure-v {
  flex-direction: column;
}

.bp-measure-line {
  background: linear-gradient(90deg, transparent, #10b981, transparent);
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.5);
}

.bp-measure-line-h {
  width: 0;
  height: 2px;
  animation: bp-line-h 10s ease-out infinite;
}

.bp-measure-line-v {
  width: 2px;
  height: 0;
  animation: bp-line-v 10s ease-out infinite;
}

.bp-measure-value {
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  font-weight: 600;
  color: #10b981;
  text-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
  white-space: nowrap;
  opacity: 0;
  animation: bp-value 10s ease-out infinite;
}

/* Measurement positions */
.bp-m-width {
  top: 88%;
  left: 20%;
  animation-delay: 4s;
}
.bp-m-width .bp-measure-line-h {
  animation-delay: 4s;
}
.bp-m-width .bp-measure-value {
  animation-delay: 4.3s;
}

.bp-m-height {
  top: 25%;
  left: 5%;
  animation-delay: 4.5s;
}
.bp-m-height .bp-measure-line-v {
  animation-delay: 4.5s;
}
.bp-m-height .bp-measure-value {
  animation-delay: 4.8s;
}

.bp-m-depth {
  top: 15%;
  right: 10%;
  animation-delay: 5s;
}
.bp-m-depth .bp-measure-line-h {
  animation-delay: 5s;
}
.bp-m-depth .bp-measure-value {
  animation-delay: 5.3s;
}

@keyframes bp-measure {
  0%,
  35% {
    opacity: 0;
  }
  45%,
  80% {
    opacity: 1;
  }
  95%,
  100% {
    opacity: 0;
  }
}

@keyframes bp-line-h {
  0%,
  35% {
    width: 0;
  }
  50%,
  80% {
    width: 120px;
  }
  95%,
  100% {
    width: 0;
  }
}

@keyframes bp-line-v {
  0%,
  35% {
    height: 0;
  }
  50%,
  80% {
    height: 100px;
  }
  95%,
  100% {
    height: 0;
  }
}

@keyframes bp-value {
  0%,
  40% {
    opacity: 0;
    transform: translateY(5px);
  }
  50%,
  80% {
    opacity: 1;
    transform: translateY(0);
  }
  95%,
  100% {
    opacity: 0;
    transform: translateY(-5px);
  }
}

/* Metric badges floating around building */
.bp-metric {
  position: absolute;
  opacity: 0;
  animation: bp-metric 10s ease-out infinite;
  z-index: 5;
}

.bp-metric-inner {
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(16, 185, 129, 0.5);
  border-radius: 10px;
  padding: 12px 16px;
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  box-shadow:
    0 0 20px rgba(16, 185, 129, 0.2),
    0 4px 20px rgba(0, 0, 0, 0.3);
}

.bp-metric-value {
  font-family: "Space Grotesk", sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: #10b981;
  text-shadow: 0 0 15px rgba(16, 185, 129, 0.5);
}

.bp-metric-label {
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

@keyframes bp-metric {
  0%,
  30% {
    opacity: 0;
    transform: translateY(10px);
  }
  45%,
  75% {
    opacity: 1;
    transform: translateY(0);
  }
  90%,
  100% {
    opacity: 0;
    transform: translateY(-10px);
  }
}

.bp-metric-1 {
  top: 15%;
  left: 12%;
  animation-delay: 5s;
}
.bp-metric-2 {
  top: 20%;
  right: 15%;
  animation-delay: 5.5s;
}
.bp-metric-3 {
  bottom: 22%;
  left: 10%;
  animation-delay: 6s;
}

@media (max-width: 768px) {
  .bp-measure,
  .bp-metric {
    display: none;
  }
}
