:root {
  --bg: #0b1220;
  --panel: #131c2e;
  --panel-2: #1a2740;
  --text: #e7edf6;
  --muted: #9fb0c8;
  --brand: #4f8cff;
  --brand-2: #2bd4a7;
  --border: #243450;
  --radius: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family:
    ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;
  color: var(--text);
  background: #07090f;
  line-height: 1.55;
}

/* full-page fixed photo background — dimmed + blurred so the viewfinder pops */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background: url("/hero.jpg") center / cover no-repeat;
  filter: blur(3px) brightness(0.66) saturate(0.96);
  transform: scale(1.03);
}

/* readability overlay over the photo */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    180deg,
    rgba(4, 6, 11, 0.3) 0%,
    rgba(4, 6, 11, 0.42) 50%,
    rgba(4, 6, 11, 0.72) 100%
  );
}

a {
  color: inherit;
  text-decoration: none;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px;
  max-width: 1080px;
  margin: 0 auto;
}

.brand {
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.3px;
}

.nav nav {
  display: flex;
  gap: 18px;
  align-items: center;
}

main {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 28px;
}

.hero {
  position: relative;
  margin: 0 0 52px;
  min-height: 640px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 44px 0;
}

/* ===== iPad-style device, screen shows the scene through ===== */
.tablet {
  position: relative;
  width: min(840px, 100%);
  border-radius: 36px;
  padding: 16px;
  background: linear-gradient(155deg, #262a32 0%, #0a0c10 58%, #16191f 100%);
  transform: perspective(1900px) rotateY(-9deg) rotateX(2deg);
  transform-origin: 60% 50%;
  box-shadow:
    34px 52px 100px rgba(0, 0, 0, 0.6),
    0 0 0 2px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.tablet-cam {
  position: absolute;
  top: 7px;
  left: 50%;
  transform: translateX(-50%);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #06080c;
  box-shadow:
    inset 0 0 0 1.5px #2b313b,
    0 0 4px rgba(120, 160, 255, 0.45);
}

.tablet-screen {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  aspect-ratio: 16 / 9;
  background: #05070d url("/hero.jpg") center / cover no-repeat;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    inset 0 0 90px rgba(0, 0, 0, 0.55);
}

/* glass glare */
.tablet-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(
    120deg,
    rgba(255, 255, 255, 0.1) 0%,
    rgba(255, 255, 255, 0) 32%,
    rgba(255, 255, 255, 0) 70%,
    rgba(255, 255, 255, 0.05) 100%
  );
}

/* ===== animated rain rolling down the glass ===== */
.rain {
  position: absolute;
  inset: 16px; /* align with the screen inside the bezel */
  z-index: 6;
  pointer-events: none;
  overflow: visible; /* let drips fall past the bottom edge */
}
.drop {
  position: absolute;
  top: 2%;
  left: var(--x);
  width: calc(5px * var(--s));
  height: calc(7px * var(--s));
  border-radius: 46% 46% 50% 50% / 38% 38% 62% 62%;
  background: radial-gradient(
    circle at 42% 32%,
    rgba(255, 255, 255, 0.55),
    rgba(206, 228, 245, 0.16) 48%,
    rgba(150, 180, 205, 0.05) 76%,
    transparent 82%
  );
  box-shadow:
    0 1px 1px rgba(0, 0, 0, 0.18),
    inset 0 -1px 1px rgba(255, 255, 255, 0.25);
  opacity: 0;
  /* longhand — var() in the `animation` shorthand is unreliable */
  animation-name: rain-roll;
  animation-duration: var(--d);
  animation-timing-function: linear;
  animation-delay: var(--delay);
  animation-iteration-count: infinite;
  will-change: top, opacity;
}
/* wet trail left behind as the drop rolls — fades before the drip */
.drop::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 55%;
  transform: translateX(-50%);
  width: 1.4px;
  height: var(--t);
  background: linear-gradient(
    to top,
    rgba(205, 228, 245, 0.22),
    rgba(205, 228, 245, 0)
  );
  border-radius: 2px;
  opacity: 0;
  animation-name: rain-trail;
  animation-duration: var(--d);
  animation-timing-function: linear;
  animation-delay: var(--delay);
  animation-iteration-count: infinite;
}
/* roll down, cling/hang at the bottom edge, then detach and drip off */
@keyframes rain-roll {
  0% {
    top: 2%;
    opacity: 0;
    transform: scale(0.5);
  }
  4% {
    opacity: 0.9;
    transform: scale(1);
  }
  70% {
    top: 95%;
    transform: scale(1);
  }
  74% {
    top: 96%;
    transform: scale(1.18);
  }
  88% {
    top: 97%;
    opacity: 0.9;
    transform: scale(1.18);
  }
  100% {
    top: 124%;
    opacity: 0;
    transform: scale(0.65);
  }
}
/* trail visible only while rolling */
@keyframes rain-trail {
  0% {
    opacity: 0;
  }
  6% {
    opacity: 1;
  }
  68% {
    opacity: 1;
  }
  76% {
    opacity: 0;
  }
  100% {
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .drop,
  .drop::before,
  .cam-scan,
  .cam-light,
  .cam-rec i,
  .cam-focus {
    animation: none;
  }
}

/* ===== camera viewfinder HUD ===== */
.cam {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: rgba(255, 255, 255, 0.82);
}

.cam-grid {
  position: absolute;
  inset: 4.5%;
  background:
    linear-gradient(
      90deg,
      transparent 33%,
      rgba(255, 255, 255, 0.07) 33% 33.25%,
      transparent 33.25% 66.6%,
      rgba(255, 255, 255, 0.07) 66.6% 66.85%,
      transparent 66.85%
    ),
    linear-gradient(
      0deg,
      transparent 33%,
      rgba(255, 255, 255, 0.07) 33% 33.3%,
      transparent 33.3% 66.6%,
      rgba(255, 255, 255, 0.07) 66.6% 66.9%,
      transparent 66.9%
    );
}

.cam-scan {
  position: absolute;
  left: 0;
  right: 0;
  top: -90px;
  height: 90px;
  background: linear-gradient(
    180deg,
    transparent,
    rgba(130, 190, 255, 0.06),
    transparent
  );
  animation: cam-scan 6s linear infinite;
}

@keyframes cam-scan {
  0% {
    top: -90px;
  }
  100% {
    top: 100%;
  }
}

.cam-corner {
  position: absolute;
  width: 26px;
  height: 26px;
  border: 2px solid rgba(255, 255, 255, 0.55);
}
.cam-corner.tl {
  top: 14px;
  left: 14px;
  border-right: 0;
  border-bottom: 0;
  border-radius: 4px 0 0 0;
}
.cam-corner.tr {
  top: 14px;
  right: 14px;
  border-left: 0;
  border-bottom: 0;
  border-radius: 0 4px 0 0;
}
.cam-corner.bl {
  bottom: 14px;
  left: 14px;
  border-right: 0;
  border-top: 0;
  border-radius: 0 0 0 4px;
}
.cam-corner.br {
  bottom: 14px;
  right: 14px;
  border-left: 0;
  border-top: 0;
  border-radius: 0 0 4px 0;
}

.cam-focus {
  position: absolute;
  right: 15%;
  top: 52%;
  width: 76px;
  height: 76px;
  transform: translateY(-50%);
  border: 1.5px solid rgba(130, 200, 255, 0.85);
  border-radius: 6px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35);
  animation: cam-focus 2.6s ease-in-out infinite;
}
.cam-focus::before,
.cam-focus::after {
  content: "";
  position: absolute;
  background: rgba(130, 200, 255, 0.85);
}
.cam-focus::before {
  top: 50%;
  left: 50%;
  width: 12px;
  height: 1.5px;
  transform: translate(-50%, -50%);
}
.cam-focus::after {
  top: 50%;
  left: 50%;
  width: 1.5px;
  height: 12px;
  transform: translate(-50%, -50%);
}
.cam-focus span {
  position: absolute;
  bottom: -16px;
  left: 0;
  font-size: 10px;
  letter-spacing: 1px;
  color: rgba(130, 200, 255, 0.95);
}

@keyframes cam-focus {
  0%,
  100% {
    transform: translateY(-50%) scale(1);
    opacity: 0.65;
  }
  50% {
    transform: translateY(-50%) scale(1.06);
    opacity: 1;
  }
}

.cam-top {
  position: absolute;
  top: 13px;
  left: 18px;
  right: 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  letter-spacing: 0.5px;
}
.cam-rec {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #ff5a4a;
  font-weight: 600;
}
.cam-rec i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff3b30;
  box-shadow: 0 0 6px rgba(255, 59, 48, 0.8);
  animation: cam-blink 1.1s steps(1) infinite;
}
.cam-rec b {
  margin-left: 6px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
}
@keyframes cam-blink {
  0%,
  49% {
    opacity: 1;
  }
  50%,
  100% {
    opacity: 0.15;
  }
}
.cam-tag {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.8);
}
.cam-batt {
  width: 20px;
  height: 10px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 2px;
  background: linear-gradient(90deg, #58d39a 72%, transparent 72%);
  position: relative;
}
.cam-batt::after {
  content: "";
  position: absolute;
  right: -3px;
  top: 2px;
  width: 2px;
  height: 4px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 0 1px 1px 0;
}

.cam-foot {
  position: absolute;
  bottom: 13px;
  left: 18px;
  font-size: 10.5px;
  letter-spacing: 1.5px;
  color: rgba(255, 255, 255, 0.72);
}
.cam-exif {
  position: absolute;
  bottom: 13px;
  right: 18px;
  font-size: 10.5px;
  letter-spacing: 0.5px;
  color: rgba(255, 255, 255, 0.72);
}
.cam-label {
  font-size: 11px;
  letter-spacing: 1.5px;
  color: rgba(255, 255, 255, 0.72);
}

/* ===== blinking emergency lights over the scene ===== */
.cam-light {
  position: absolute;
  z-index: 5;
  border-radius: 50%;
  filter: blur(9px);
  pointer-events: none;
  transform: translate(-50%, -50%);
}
.police-red {
  left: 5%;
  top: 60%;
  width: 158px;
  height: 116px;
  background: radial-gradient(
    circle,
    rgba(255, 66, 52, 1) 0%,
    rgba(255, 66, 52, 0) 64%
  );
  animation: cam-blinkA 0.7s steps(1, end) infinite;
}
.police-blue {
  left: 11%;
  top: 60%;
  width: 158px;
  height: 116px;
  background: radial-gradient(
    circle,
    rgba(80, 130, 255, 1) 0%,
    rgba(80, 130, 255, 0) 64%
  );
  animation: cam-blinkB 0.7s steps(1, end) infinite;
}
.fire-red1 {
  left: 91%;
  top: 44%;
  width: 96px;
  height: 84px;
  background: radial-gradient(
    circle,
    rgba(255, 55, 44, 0.97) 0%,
    rgba(255, 55, 44, 0) 68%
  );
  animation: cam-blinkA 0.5s steps(1, end) infinite;
}
.fire-red2 {
  left: 95%;
  top: 47%;
  width: 84px;
  height: 74px;
  background: radial-gradient(
    circle,
    rgba(255, 80, 40, 0.97) 0%,
    rgba(255, 80, 40, 0) 68%
  );
  animation: cam-blinkB 0.5s steps(1, end) infinite;
}
@keyframes cam-blinkA {
  0%,
  49% {
    opacity: 0.95;
  }
  50%,
  100% {
    opacity: 0.06;
  }
}
@keyframes cam-blinkB {
  0%,
  49% {
    opacity: 0.06;
  }
  50%,
  100% {
    opacity: 0.95;
  }
}

/* lower-third caption over the live scene */
.hero-inner {
  position: absolute;
  z-index: 2;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 58px 40px 24px;
  background: linear-gradient(
    0deg,
    rgba(3, 5, 10, 0.92) 0%,
    rgba(3, 5, 10, 0.6) 52%,
    rgba(3, 5, 10, 0) 100%
  );
}

.hero h1 {
  font-size: clamp(1.3rem, 2.8vw, 1.95rem);
  line-height: 1.14;
  margin: 0 0 6px;
  max-width: 620px;
  text-shadow:
    0 2px 22px rgba(0, 0, 0, 0.8),
    0 1px 3px rgba(0, 0, 0, 0.75);
}

.lede {
  font-size: 1.02rem;
  font-weight: 600;
  color: #eaf1fb;
  margin: 0 0 6px;
  text-shadow:
    0 2px 18px rgba(0, 0, 0, 0.75),
    0 1px 2px rgba(0, 0, 0, 0.7);
}

.sub {
  font-size: 0.86rem;
  color: #cfdaea;
  margin: 0 0 14px;
  max-width: 520px;
  text-shadow:
    0 1px 12px rgba(0, 0, 0, 0.75),
    0 1px 2px rgba(0, 0, 0, 0.65);
}

.btn {
  display: inline-block;
  padding: 11px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: 1px solid transparent;
  transition:
    transform 0.06s ease,
    background 0.15s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand), #3a6fe0);
  color: white;
}

.btn-ghost {
  border-color: var(--border);
  color: var(--text);
  background: transparent;
}

h2 {
  font-size: 1.6rem;
  margin: 0 0 8px;
}

.demos {
  padding: 32px 0;
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin: 22px 0 14px;
}

.card {
  background: rgba(17, 24, 40, 0.55);
  backdrop-filter: blur(16px) saturate(1.1);
  -webkit-backdrop-filter: blur(16px) saturate(1.1);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.4);
}

.card h3 {
  margin: 0 0 10px;
  font-size: 1.2rem;
}

.card p {
  color: var(--muted);
  margin: 0 0 20px;
  flex: 1;
}

.card-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.tag {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  background: var(--brand-2);
  color: #04261d;
  padding: 2px 8px;
  border-radius: 999px;
  vertical-align: middle;
}

.note {
  color: var(--muted);
  font-size: 0.92rem;
}

.request {
  padding: 32px 0 64px;
  max-width: 560px;
}

.request > p {
  color: var(--muted);
}

form {
  margin-top: 22px;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  font-size: 0.88rem;
  margin-bottom: 6px;
  color: var(--muted);
}

input,
select,
textarea {
  width: 100%;
  padding: 11px 13px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font: inherit;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--brand);
}

.form-status {
  margin-top: 14px;
  font-size: 0.92rem;
  min-height: 1.2em;
}

.form-status.ok {
  color: var(--brand-2);
}

.form-status.err {
  color: #ff6b6b;
}

.footer {
  max-width: 1080px;
  margin: 0 auto;
  padding: 28px;
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 0.88rem;
  border-top: 1px solid var(--border);
}

@media (max-width: 640px) {
  .hero {
    min-height: 0;
    padding: 24px 0;
  }
  .tablet {
    border-radius: 26px;
    padding: 11px;
  }
  .hero-inner {
    padding: 34px 26px;
  }
}

@media (max-width: 520px) {
  .footer {
    flex-direction: column;
    gap: 6px;
  }
}
