/* Shared pixel-console styling for the Galaxy A12 home server. No external fonts. */

:root {
  --bg: #0b0d12;
  --panel: #151a24;
  --panel-2: #1b2230;
  --ink: #eef2ff;
  --dim: #8b96ad;
  --line: #2b3446;
  --green: #4ade80;
  --amber: #ffd166;
  --hot: #ff5d73;
  --shadow: #05070a;
}

* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  padding: 24px;
  display: grid;
  place-items: center;
  color: var(--ink);
  background:
    radial-gradient(circle at 50% -10%, #17203a 0%, #0b0d12 55%) fixed,
    var(--bg);
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 16px;
  line-height: 1.65;
  letter-spacing: .06em;
  text-transform: uppercase;
  -webkit-font-smoothing: none;
  -moz-osx-font-smoothing: grayscale;
}

/* Pixel starfield: hard-edged dots, no anti-aliasing */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 12% 18%, #ffffffaa 50%, transparent 50%),
    radial-gradient(1px 1px at 78% 12%, #ffffff77 50%, transparent 50%),
    radial-gradient(1px 1px at 34% 72%, #ffffff55 50%, transparent 50%),
    radial-gradient(1px 1px at 88% 58%, #ffffff88 50%, transparent 50%),
    radial-gradient(1px 1px at 58% 34%, #ffffff66 50%, transparent 50%),
    radial-gradient(1px 1px at 22% 46%, #ffffff44 50%, transparent 50%),
    radial-gradient(1px 1px at 68% 82%, #ffffff77 50%, transparent 50%),
    radial-gradient(1px 1px at 46% 8%, #ffffff99 50%, transparent 50%);
  background-repeat: no-repeat;
}

/* CRT scanlines, very subtle */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(0, 0, 0, .22) 0 1px,
    rgba(0, 0, 0, 0) 1px 3px
  );
  opacity: .5;
}

.card {
  position: relative;
  width: min(46rem, 100%);
  padding: clamp(22px, 4vw, 44px);
  text-align: center;
  background: var(--panel);
  border: 4px solid var(--ink);
  box-shadow:
    8px 8px 0 var(--shadow),
    14px 14px 0 var(--line);
}

/* Corner blocks, the cheap way to read as "pixel window" */
.card::before,
.card::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  background: var(--ink);
}
.card::before { top: -7px; left: -7px; }
.card::after { bottom: -7px; right: -7px; }

.eyebrow {
  margin: 0 0 1.4rem;
  font-size: .7rem;
  letter-spacing: .22em;
  color: var(--dim);
}

h1 {
  margin: 0 0 .9rem;
  font-size: clamp(1.15rem, 4.2vw, 1.9rem);
  line-height: 1.35;
  letter-spacing: .1em;
  text-shadow:
    3px 3px 0 var(--shadow),
    6px 6px 0 var(--line);
}

h1 .name {
  display: block;
  margin-top: .5rem;
  font-size: 1.5em;
  color: var(--amber);
  text-shadow:
    3px 3px 0 #4a3a10,
    6px 6px 0 var(--shadow);
}

.tagline {
  margin: 0 auto 1.9rem;
  max-width: 30ch;
  font-size: .82rem;
  color: var(--dim);
  letter-spacing: .1em;
}

.caret {
  display: inline-block;
  margin-left: .15em;
  color: var(--amber);
  animation: blink 1.05s steps(1) infinite;
}

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

.art {
  display: block;
  margin: 0 auto 1.8rem;
  image-rendering: pixelated;
  filter: drop-shadow(4px 4px 0 rgba(0, 0, 0, .55));
}

.led { animation: pulse 2.1s steps(1) infinite; }
.led.d2 { animation-delay: .5s; }
.led.d3 { animation-delay: 1.1s; }

@keyframes pulse {
  0%, 55% { opacity: 1; }
  56%, 100% { opacity: .25; }
}

/* Chunky segmented progress bar */
.building { margin-bottom: 1.7rem; }

.building span {
  display: block;
  margin-bottom: .5rem;
  font-size: .68rem;
  letter-spacing: .2em;
  color: var(--dim);
}

.bar {
  display: flex;
  gap: 4px;
  justify-content: center;
}

.bar i {
  width: 12px;
  height: 12px;
  background: var(--line);
  animation: fill 3.2s steps(1) infinite;
}
.bar i:nth-child(2) { animation-delay: .2s; }
.bar i:nth-child(3) { animation-delay: .4s; }
.bar i:nth-child(4) { animation-delay: .6s; }
.bar i:nth-child(5) { animation-delay: .8s; }
.bar i:nth-child(6) { animation-delay: 1s; }
.bar i:nth-child(7) { animation-delay: 1.2s; }
.bar i:nth-child(8) { animation-delay: 1.4s; }

@keyframes fill {
  0%, 45% { background: var(--line); }
  46%, 100% { background: var(--green); }
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  justify-content: center;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .3rem .6rem;
  font-size: .66rem;
  letter-spacing: .14em;
  color: var(--dim);
  background: var(--panel-2);
  border: 2px solid var(--line);
  text-decoration: none;
}

a.chip:hover,
a.chip:focus-visible {
  color: var(--ink);
  border-color: var(--ink);
  outline: none;
}

.chip.primary {
  color: #241c07;
  background: var(--amber);
  border-color: var(--amber);
  font-weight: 700;
  letter-spacing: .16em;
}

a.chip.primary:hover,
a.chip.primary:focus-visible {
  color: #241c07;
  background: var(--ink);
  border-color: var(--ink);
}

.dot {
  width: .5rem;
  height: .5rem;
  background: var(--dim);
  flex: none;
}

.dot.up { background: var(--green); animation: pulse 2.1s steps(1) infinite; }
.dot.down { background: var(--hot); }

/* Status page table */
dl.facts {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: .5rem 1.4rem;
  margin: 0 0 1.8rem;
  font-size: .78rem;
  text-align: left;
  letter-spacing: .08em;
}

dl.facts dt { color: var(--dim); }
dl.facts dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }

.foot {
  margin: 1.6rem 0 0;
  font-size: .62rem;
  letter-spacing: .16em;
  color: #5d677c;
}

.foot a { color: var(--dim); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; }
  .caret { opacity: 1; }
  .bar i { background: var(--green); }
}
