:root {
  --bg: #07131a;
  --panel: rgba(7, 24, 32, 0.78);
  --panel-strong: #0d2633;
  --line: rgba(127, 217, 183, 0.22);
  --text: #ecf6f2;
  --muted: #99b7b0;
  --accent: #7fd9b7;
  --accent-strong: #c9ff7a;
  --danger: #ef6b5e;
  --danger-strong: #ff5d4f;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Space Grotesk", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top, rgba(127, 217, 183, 0.14), transparent 28%),
    linear-gradient(180deg, #0a161d 0%, #07131a 48%, #061017 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(127, 217, 183, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(127, 217, 183, 0.04) 1px, transparent 1px);
  background-size: 36px 36px;
  pointer-events: none;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent);
}

.page-shell {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 72px;
}

.topbar,
.hero-grid,
.contact-panel {
  animation: rise 0.8s ease both;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(8, 20, 28, 0.68);
  backdrop-filter: blur(16px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-icon {
  width: 34px;
  height: 34px;
  display: block;
  border-radius: 10px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25);
}

.brand-name,
.nav-links a,
.button,
.label,
.signal-time {
  letter-spacing: 0.04em;
}

.brand-name {
  font-weight: 700;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
}

.hero {
  padding-top: 16px;
}

.hero--policy {
  max-width: 840px;
  margin: 0 auto;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.9fr;
  gap: 28px;
  align-items: stretch;
  margin-top: 28px;
}

.hero-copy,
.signal-card,
.contact-panel {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--panel);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: 42px;
}

.eyebrow,
.label,
.signal-time {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.82rem;
  text-transform: uppercase;
  color: var(--accent);
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  max-width: 10ch;
  margin-top: 14px;
  font-size: clamp(3rem, 8vw, 5.8rem);
  line-height: 0.96;
}

.policy-card h1 {
  max-width: none;
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  line-height: 1.05;
}

.lede {
  max-width: 56ch;
  margin-top: 20px;
  color: var(--muted);
  font-size: 1.06rem;
  line-height: 1.7;
}

.release-note {
  max-width: 48ch;
  margin-top: 18px;
  color: var(--accent);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.92rem;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
}

.button-primary {
  color: #07131a;
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
}

.button-secondary {
  color: var(--text);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
}

.button-disabled {
  cursor: default;
  opacity: 0.78;
}

.signal-card {
  padding: 24px;
}

.signal-card__header,
.signal-grid {
  display: grid;
  gap: 16px;
}

.signal-card__header {
  grid-template-columns: 1fr auto;
  align-items: center;
}

.signal-status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 500;
}

.signal-status__dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--accent-strong);
  box-shadow: 0 0 18px rgba(201, 255, 122, 0.7);
  opacity: 1;
}

.signal-scene {
  position: relative;
  height: 268px;
  margin: 24px 0;
  padding: 20px;
  border-radius: 20px;
  background:
    radial-gradient(circle at 30% 12%, rgba(127, 217, 183, 0.08), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.01)),
    var(--panel-strong);
  overflow: hidden;
}

.signal-scene__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(127, 217, 183, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(127, 217, 183, 0.05) 1px, transparent 1px);
  background-size: 28px 28px;
  opacity: 0.35;
}

.timing-panel {
  position: absolute;
  top: 20px;
  left: 20px;
  z-index: 2;
  display: grid;
  gap: 4px;
  width: 170px;
  max-width: 170px;
}

.timing-row {
  display: grid;
  grid-template-columns: 88px 56px 14px;
  align-items: center;
  gap: 4px;
  color: var(--danger-strong);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.72rem;
  justify-items: start;
}

.timing-row input {
  width: 100%;
  padding: 4px 8px;
  border: 1px solid rgba(255, 117, 102, 0.5);
  border-radius: 10px;
  background: rgba(4, 15, 22, 0.58);
  color: #ffe2dd;
  font: inherit;
  text-align: left;
  color-scheme: dark;
}
.timing-row input:focus {
  outline: 1px solid rgba(255, 93, 79, 0.7);
}

.signal-scene__status {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 2;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(180, 44, 32, 0.88);
  color: #ffd27d;
  text-align: center;
  font-family: "IBM Plex Mono", monospace;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
}

.signal-target {
  position: absolute;
  top: 28px;
  right: 18px;
  width: 170px;
  height: 170px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.signal-target:focus-visible {
  outline: 2px solid rgba(201, 255, 122, 0.85);
  outline-offset: 8px;
}

.signal-target__frame {
  position: absolute;
  border: 10px solid var(--danger);
  pointer-events: none;
}

.signal-target__frame--outer {
  inset: 0;
}

.signal-target__frame--inner {
  inset: 38px;
}

.signal-target__light {
  position: absolute;
  top: 53px;
  left: 53px;
  width: 64px;
  height: 64px;
  border-radius: 999px;
  background: rgba(127, 217, 183, 0.5);
  box-shadow:
    0 0 18px rgba(201, 255, 122, 0.95),
    0 0 42px rgba(127, 217, 183, 0.55);
  opacity: 0.28;
  transform: scale(0.88);
  transition:
    opacity 80ms linear,
    transform 80ms linear,
    box-shadow 80ms linear;
}

.fullscreen-light {
  width: 100vw;
  max-width: none;
  height: 100vh;
  max-height: none;
  padding: 0;
  border: 0;
  background: rgba(3, 9, 14, 0.98);
}

.fullscreen-light::backdrop {
  background: rgba(3, 9, 14, 0.98);
}

.fullscreen-light__panel {
  position: relative;
  width: 100%;
  height: 100%;
}

.fullscreen-light__close {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 1;
  min-width: 52px;
  min-height: 52px;
  border: 1px solid rgba(127, 217, 183, 0.3);
  border-radius: 999px;
  background: rgba(7, 24, 32, 0.52);
  color: var(--text);
  font: inherit;
  cursor: pointer;
}

.fullscreen-light__flash {
  width: 100%;
  height: 100%;
  background: rgba(127, 217, 183, 0.1);
  box-shadow: inset 0 0 80px rgba(127, 217, 183, 0.08);
  opacity: 0.16;
  transition:
    opacity 80ms linear,
    background 80ms linear,
    box-shadow 80ms linear;
}

.signal-toolbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
  margin-bottom: 16px;
}

.signal-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  min-width: 64px;
  padding: 10px 0;
  border-radius: 999px;
  border: 1px solid rgba(239, 107, 94, 0.3);
  background: rgba(255, 255, 255, 0.03);
}

.signal-toggle__dot {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  background: var(--danger);
  box-shadow: 0 0 16px rgba(239, 107, 94, 0.78);
  opacity: 0.22;
  transition: opacity 80ms linear, box-shadow 80ms linear;
}

.signal-toolbar__morse,
.reset-button {
  font-family: "IBM Plex Mono", monospace;
}

.signal-toolbar__morse {
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  font-size: 0.94rem;
  color: var(--text);
  text-align: right;
  direction: ltr;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.signal-toolbar__morse::-webkit-scrollbar {
  display: none;
}

.reset-button {
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

.signal-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.signal-grid--app {
  align-items: stretch;
}

.signal-grid > div {
  padding: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
  border-radius: 20px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.signal-grid__wide {
  grid-column: 1 / -1;
}

.decoded-trigger {
  width: 100%;
  margin-top: 6px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.decoded-trigger:focus-visible {
  outline: 2px solid rgba(201, 255, 122, 0.85);
  outline-offset: 8px;
  border-radius: 16px;
}

.value {
  margin-top: 6px;
  font-size: 1.2rem;
  font-weight: 700;
}

.value--message {
  display: block;
  font-size: 1rem;
  min-height: 6.4em;
  line-height: 1.6;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.decoded-trigger__hint {
  display: inline-block;
  margin-top: 10px;
  color: var(--accent);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.message-dialog {
  width: min(720px, calc(100% - 24px));
  padding: 0;
  border: 1px solid rgba(127, 217, 183, 0.28);
  border-radius: 28px;
  background: rgba(6, 20, 30, 0.95);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.5);
  color: var(--text);
}

.message-dialog::backdrop {
  background: rgba(3, 9, 14, 0.76);
  backdrop-filter: blur(6px);
}

.message-dialog__panel {
  padding: 28px;
}

.message-dialog__header,
.message-dialog__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.message-dialog__header h2 {
  max-width: none;
  margin-top: 10px;
  font-size: clamp(1.7rem, 4vw, 2.4rem);
}

.message-dialog__close {
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
}

.message-dialog__fields {
  display: grid;
  gap: 16px;
  margin-top: 22px;
}

.message-dialog__field {
  display: grid;
  gap: 8px;
}

.message-dialog__field span,
.message-dialog__note {
  color: var(--muted);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

.message-dialog__field textarea {
  width: 100%;
  padding: 16px 18px;
  border: 1px solid rgba(127, 217, 183, 0.22);
  border-radius: 18px;
  background: rgba(4, 15, 22, 0.82);
  color: var(--text);
  font: inherit;
  line-height: 1.6;
  resize: vertical;
}

.message-dialog__field textarea:focus {
  outline: 1px solid rgba(201, 255, 122, 0.8);
}

.message-dialog__field textarea[readonly] {
  color: var(--muted);
  cursor: default;
}

.message-dialog__note {
  margin-top: 14px;
}

.message-dialog__actions {
  margin-top: 22px;
}

.section {
  margin-top: 28px;
}

.section-introduction,
.section-demo,
.section-offline,
.section-contact {
  scroll-margin-top: 24px;
}

.section-heading {
  padding: 12px 4px 0;
}

h2 {
  max-width: 14ch;
  margin-top: 10px;
  font-size: clamp(2.1rem, 4vw, 3.6rem);
  line-height: 1;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 22px;
}

@media (max-width: 1180px) {
  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.shot-card {
  padding: 16px;
  border: 1px solid rgba(84, 179, 191, 0.44);
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(5, 22, 32, 0.96), rgba(4, 16, 24, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(84, 179, 191, 0.12),
    0 12px 28px rgba(0, 0, 0, 0.34);
}

.shot-frame {
  padding: 5px;
  border-radius: 42px;
  background: linear-gradient(180deg, #09111a, #050b12);
  border: 1px solid rgba(108, 158, 177, 0.34);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.025),
    0 10px 20px rgba(0, 0, 0, 0.32);
}

.shot-screen {
  overflow: hidden;
  border-radius: 36px;
  border: 1px solid rgba(98, 183, 196, 0.14);
  background: #03070c;
}

.shot-frame img {
  width: 100%;
  display: block;
}

.shot-card h3 {
  margin-top: 14px;
  font-size: 1.08rem;
  color: #f0faf8;
}

.shot-card p {
  margin-top: 8px;
  color: #a6bdbe;
  line-height: 1.55;
  font-size: 0.98rem;
}

.demo-panel {
  margin-top: 22px;
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 16px;
  padding: 16px;
  border-radius: 24px;
  border: 1px solid rgba(98, 183, 196, 0.28);
  background: linear-gradient(180deg, rgba(6, 24, 35, 0.9), rgba(4, 16, 25, 0.92));
}

.demo-copy {
  border-radius: 18px;
  border: 1px solid rgba(98, 183, 196, 0.18);
  background: rgba(6, 20, 30, 0.6);
  padding: 20px;
}

.demo-copy p {
  color: #b3c6c4;
  line-height: 1.65;
}

.demo-actions {
  margin-top: 18px;
}

.demo-video {
  border-radius: 18px;
  border: 1px solid rgba(98, 183, 196, 0.22);
  background: rgba(3, 10, 16, 0.76);
  overflow: hidden;
}

.demo-video video {
  width: 100%;
  display: block;
  background: #02060a;
}

.offline-panel {
  margin-top: 22px;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 16px;
  padding: 16px;
  border-radius: 24px;
  border: 1px solid rgba(98, 183, 196, 0.28);
  background: linear-gradient(180deg, rgba(6, 24, 35, 0.9), rgba(4, 16, 25, 0.92));
}

.offline-copy {
  border-radius: 18px;
  border: 1px solid rgba(98, 183, 196, 0.18);
  background: rgba(6, 20, 30, 0.6);
  padding: 20px;
}

.offline-copy p {
  color: #b3c6c4;
  line-height: 1.65;
}

.offline-copy p + p {
  margin-top: 12px;
}

.offline-visual {
  border-radius: 18px;
  border: 1px solid rgba(98, 183, 196, 0.22);
  background: rgba(3, 10, 16, 0.76);
  overflow: hidden;
}

.offline-visual img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.contact-panel {
  padding: 28px;
  margin-top: 22px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.policy-card {
  margin-top: 24px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--panel);
  box-shadow: var(--shadow);
  animation: rise 0.8s ease both;
}

.policy-date {
  margin-top: 14px;
  color: var(--muted);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.86rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.policy-card h2 {
  max-width: none;
  margin-top: 28px;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
}

.policy-card p {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.7;
}

.policy-card a {
  color: var(--accent-strong);
  text-decoration: none;
}

.contact-panel p,
.site-footer p {
  color: var(--muted);
  line-height: 1.7;
}

.contact-panel a,
.site-footer a {
  color: var(--accent-strong);
  text-decoration: none;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 28px 6px 0;
  color: var(--muted);
  font-size: 0.95rem;
  border-top: 1px solid var(--line);
  margin-top: 42px;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 900px) {
  .hero-grid,
  .gallery-grid,
  .demo-panel,
  .offline-panel {
    grid-template-columns: 1fr;
  }

  h1 {
    max-width: none;
  }
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 20px, 1160px);
    padding-top: 12px;
  }

  .topbar,
  .hero-copy,
  .signal-card,
  .shot-card,
  .contact-panel,
  .policy-card {
    border-radius: 22px;
  }

  .topbar,
  .nav-links,
  .hero-actions {
    align-items: flex-start;
  }

  .topbar,
  .signal-card__header {
    grid-template-columns: 1fr;
  }

  .topbar {
    flex-direction: column;
  }

  .hero-copy {
    padding: 28px;
  }

  .policy-card {
    padding: 24px;
  }

  .signal-grid {
    grid-template-columns: 1fr;
  }

  .signal-scene {
    height: auto;
    display: grid;
    gap: 14px;
    padding: 16px;
  }

  .signal-toolbar {
    grid-template-columns: 1fr;
  }

  .message-dialog {
    width: min(100% - 16px, 720px);
    border-radius: 22px;
  }

  .message-dialog__panel {
    padding: 22px;
  }

  .message-dialog__header,
  .message-dialog__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .timing-panel {
    position: relative;
    top: auto;
    left: auto;
    width: 100%;
    max-width: none;
    margin-bottom: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .timing-row {
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    gap: 4px 6px;
    align-items: end;
    padding: 10px 10px 8px;
    border: 1px solid rgba(255, 117, 102, 0.22);
    border-radius: 14px;
    background: rgba(4, 15, 22, 0.42);
    font-size: 0.78rem;
  }

  .timing-row > span:first-child {
    grid-column: 1 / -1;
    font-size: 0.68rem;
    letter-spacing: 0.04em;
  }

  .timing-row > span:last-child {
    align-self: center;
  }

  .signal-target {
    position: relative;
    top: auto;
    right: auto;
    width: 140px;
    height: 140px;
    margin: 0 auto;
  }

  .signal-target__frame--inner {
    inset: 30px;
  }

  .signal-target__light {
    top: 45px;
    left: 45px;
    width: 50px;
    height: 50px;
  }

  .site-footer {
    flex-direction: column;
  }
}
