/* ============================================================
   JAWASYSTEMS.NET — sci-fi landing page
   No image assets: everything is canvas, CSS, and text.
   ============================================================ */

:root {
  --bg: #04060f;
  --fg: #d8e6ff;
  --accent: #4fd8ff;
  --accent-dim: rgba(79, 216, 255, 0.35);
  --accent-glow: rgba(79, 216, 255, 0.55);
  --magenta: #c46bff;
  --ok: #6bffb0;
  --warn: #ffc46b;
  --grid-line: rgba(79, 216, 255, 0.12);
  --mono: "Courier New", "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--mono);
  overflow-x: hidden;
  min-height: 100vh;
}

/* ---------- Starfield canvas ---------- */

#starfield {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
}

/* ---------- Scanlines (pure CSS) ---------- */

.scanlines {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0px,
    transparent 2px,
    rgba(0, 0, 0, 0.18) 3px,
    transparent 4px
  );
  mix-blend-mode: multiply;
}

/* ---------- Layout ---------- */

.content {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.25rem 4rem;
  gap: 2.5rem;
}

/* ---------- Boot line ---------- */

.boot-line {
  color: var(--accent-dim);
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  min-height: 1.2em;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  text-align: center;
  max-width: 46rem;
  padding: 3rem 2.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

/* Corner brackets frame */
.frame {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.corner {
  position: absolute;
  width: 28px;
  height: 28px;
  border: 2px solid var(--accent-dim);
}

.corner.tl { top: 0; left: 0; border-right: none; border-bottom: none; }
.corner.tr { top: 0; right: 0; border-left: none; border-bottom: none; }
.corner.bl { bottom: 0; left: 0; border-right: none; border-top: none; }
.corner.br { bottom: 0; right: 0; border-left: none; border-top: none; }

/* ---------- Title ---------- */

.title {
  font-size: clamp(2.2rem, 8vw, 4.5rem);
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--fg);
  text-shadow:
    0 0 6px var(--accent-glow),
    0 0 24px var(--accent-glow),
    0 0 60px var(--accent-dim);
  animation: flicker 6s infinite;
  position: relative;
}

/* Chromatic ghost layer (text only, no images) */
.title::before {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  color: var(--magenta);
  opacity: 0.35;
  transform: translate(2px, -1px);
  z-index: -1;
}

@keyframes flicker {
  0%, 100% { opacity: 1; }
  92% { opacity: 1; }
  93% { opacity: 0.6; }
  94% { opacity: 1; }
  96% { opacity: 0.8; }
  97% { opacity: 1; }
}

.domain {
  font-size: clamp(1rem, 3vw, 1.4rem);
  letter-spacing: 0.6em;
  color: var(--accent);
  text-shadow: 0 0 12px var(--accent-glow);
  margin-top: -1rem;
}

/* ---------- Tagline & paragraph ---------- */

.tagline {
  font-size: clamp(0.7rem, 2vw, 0.9rem);
  letter-spacing: 0.45em;
  color: var(--accent);
  border-top: 1px solid var(--accent-dim);
  border-bottom: 1px solid var(--accent-dim);
  padding: 0.6rem 1rem;
}

.paragraph {
  font-size: 0.95rem;
  line-height: 1.9;
  color: rgba(216, 230, 255, 0.75);
  max-width: 38rem;
}

/* ---------- Buttons ---------- */

.cta-row {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 0.5rem;
}

.btn {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.25em;
  color: var(--accent);
  text-decoration: none;
  padding: 0.8rem 1.6rem;
  border: 1px solid var(--accent-dim);
  background: rgba(79, 216, 255, 0.06);
  transition: background 0.2s, box-shadow 0.2s, color 0.2s;
}

.btn:hover,
.btn:focus-visible {
  background: rgba(79, 216, 255, 0.15);
  box-shadow: 0 0 18px var(--accent-dim), inset 0 0 12px rgba(79, 216, 255, 0.15);
  color: #ffffff;
  outline: none;
}

.btn.ghost {
  background: transparent;
  color: rgba(216, 230, 255, 0.6);
  border-color: rgba(216, 230, 255, 0.2);
}

.btn.ghost:hover,
.btn.ghost:focus-visible {
  color: var(--fg);
  box-shadow: 0 0 14px rgba(216, 230, 255, 0.15);
}

/* ---------- Status bar ---------- */

.status-bar {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  color: rgba(216, 230, 255, 0.45);
  border-top: 1px solid var(--accent-dim);
  padding-top: 1rem;
  width: 100%;
  max-width: 46rem;
}

.bars {
  color: var(--accent);
  letter-spacing: 0.05em;
}

/* ---------- Contact channels ---------- */

.contact-hero {
  max-width: 40rem;
}

.title.small {
  font-size: clamp(1.6rem, 6vw, 3rem);
}

.channels {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  text-align: left;
}

.channel {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border: 1px solid rgba(216, 230, 255, 0.2);
  background: rgba(79, 216, 255, 0.04);
  text-decoration: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.channel:hover,
.channel:focus-visible {
  border-color: var(--accent);
  background: rgba(79, 216, 255, 0.1);
  box-shadow: 0 0 18px var(--accent-dim), inset 0 0 12px rgba(79, 216, 255, 0.08);
  outline: none;
}

.channel-icon {
  flex-shrink: 0;
  width: 3rem;
  height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--accent);
  border: 1px solid var(--accent-dim);
  text-shadow: 0 0 10px var(--accent-glow);
}

.channel-body {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.channel-name {
  font-size: 0.8rem;
  letter-spacing: 0.3em;
  color: var(--fg);
}

.channel-detail {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: rgba(216, 230, 255, 0.55);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.channel-arrow {
  margin-left: auto;
  font-size: 1.2rem;
  color: var(--accent-dim);
  transition: transform 0.2s, color 0.2s;
}

.channel:hover .channel-arrow,
.channel:focus-visible .channel-arrow {
  transform: translateX(4px);
  color: var(--accent);
}

.status-link {
  color: rgba(216, 230, 255, 0.45);
  text-decoration: none;
  letter-spacing: 0.15em;
  transition: color 0.2s;
}

.status-link:hover,
.status-link:focus-visible {
  color: var(--accent);
}

/* ---------- Status page ---------- */

.status-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.9rem 1.25rem;
  border: 1px solid rgba(255, 196, 107, 0.4);
  background: rgba(255, 196, 107, 0.06);
  box-shadow: 0 0 18px rgba(255, 196, 107, 0.15), inset 0 0 14px rgba(255, 196, 107, 0.05);
}

.banner-icon {
  color: var(--warn);
  font-size: 1.1rem;
  animation: spin 6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.banner-text {
  font-size: 0.85rem;
  letter-spacing: 0.25em;
  color: var(--warn);
  text-shadow: 0 0 12px rgba(255, 196, 107, 0.5);
}

.cursor {
  animation: blink 1s steps(1) infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

.status-panel {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  border: 1px solid rgba(216, 230, 255, 0.15);
  background: rgba(79, 216, 255, 0.03);
  padding: 1.25rem;
}

.status-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.8rem;
  letter-spacing: 0.15em;
}

.status-name {
  flex: 0 0 9.5rem;
  color: var(--fg);
}

.status-meter {
  flex: 1;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  white-space: nowrap;
  overflow: hidden;
}

.meter-fill.full {
  color: var(--ok);
  text-shadow: 0 0 8px rgba(107, 255, 176, 0.5);
}

.meter-fill.partial {
  color: var(--warn);
  text-shadow: 0 0 8px rgba(255, 196, 107, 0.5);
  animation: pulse 1.6s ease-in-out infinite;
}

@keyframes pulse {
  50% { opacity: 0.45; }
}

.status-flag {
  flex: 0 0 7.5rem;
  text-align: right;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
}

.status-flag.ok {
  color: var(--ok);
}

.status-flag.warn {
  color: var(--warn);
  animation: blink 1.4s steps(1) infinite;
}

.status-note {
  font-size: 0.8rem;
  line-height: 1.9;
  letter-spacing: 0.08em;
  color: rgba(216, 230, 255, 0.6);
  max-width: 34rem;
  text-align: center;
}

/* ---------- Responsive ---------- */

@media (max-width: 560px) {
  .hero {
    padding: 2.5rem 1rem;
  }

  .status-bar {
    gap: 1rem;
    font-size: 0.6rem;
  }

  .status-row {
    gap: 0.6rem;
    font-size: 0.7rem;
  }

  .status-name {
    flex-basis: 6.5rem;
  }

  .status-flag {
    flex-basis: 5.5rem;
  }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  .title {
    animation: none;
  }

  .scanlines {
    display: none;
  }
}
