/* Dgxcode design system — HUD/terminal aesthetic.
   CSP forbids <style> tags and style= attributes: every rule lives here.
   All motion is CSS-only and disabled under prefers-reduced-motion. */

:root {
  color-scheme: dark;
  --bg: #05070c;
  --bg-elev: #0a0f17;
  --bg-card: #080d15;
  --border: #1d2733;
  --border-strong: #2c3b4c;
  --fg: #e8eef5;
  --fg-muted: #9fb2c4;
  --fg-dim: #64798c;
  --accent: #ff9e00;
  --accent-dim: #7a3800;
  --accent-glow: rgba(255, 158, 0, .28);
  --warn: #fbbf24;
  --danger: #f87171;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --sans: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.site {
  margin: 0;
  background:
    radial-gradient(1100px 520px at 85% -10%, rgba(255, 158, 0, .10), transparent 60%),
    radial-gradient(900px 480px at 8% 108%, rgba(255, 158, 0, .06), transparent 60%),
    repeating-linear-gradient(0deg, rgba(255, 158, 0, .03) 0 1px, transparent 1px 4px),
    var(--bg);
  background-attachment: fixed;
  color: var(--fg);
  font-family: var(--sans);
  line-height: 1.65;
  letter-spacing: .01em;
}

/* Ambient HUD layers (decorative, aria-hidden in markup) */
.fx-grid, .fx-scan {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
}
.fx-grid {
  background:
    linear-gradient(rgba(255, 158, 0, .045) 1px, transparent 1px) 0 0 / 100% 44px,
    linear-gradient(90deg, rgba(255, 158, 0, .045) 1px, transparent 1px) 0 0 / 44px 100%;
  animation: grid-pan 26s linear infinite;
}
.fx-scan {
  background: linear-gradient(180deg, transparent 0%, rgba(255, 158, 0, .06) 46%, rgba(255, 244, 230, .05) 50%, rgba(255, 158, 0, .06) 54%, transparent 100%);
  background-size: 100% 220px;
  background-repeat: no-repeat;
  animation: scan-sweep 7.5s linear infinite;
}
@keyframes grid-pan {
  from { background-position: 0 0, 0 0; }
  to { background-position: 0 44px, 44px 0; }
}
@keyframes scan-sweep {
  from { background-position: 0 -240px; }
  to { background-position: 0 110vh; }
}

.shell {
  max-width: 68rem;
  margin-inline: auto;
  padding: 0 1.25rem;
}

h1, h2, h3 {
  line-height: 1.25;
  text-transform: uppercase;
  letter-spacing: .08em;
}
h1 { font-size: 2rem; margin: 0 0 1rem; }
h2 { font-size: 1.35rem; margin: 3rem 0 1rem; }
h2::before { content: "// "; color: var(--accent); }
h3 { font-size: .95rem; margin: 1.5rem 0 .5rem; }
p { margin: 0 0 1rem; }
ul, ol { margin: 0 0 1rem; padding-left: 1.4rem; }
li { margin-bottom: .4rem; }

a { color: var(--accent); }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

code, kbd, pre { font-family: var(--mono); }
code.value { color: var(--fg); word-break: break-all; font-size: .9rem; }

/* Masthead */
header.masthead {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--bg-elev);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(6px);
  box-shadow: 0 6px 24px rgba(0, 0, 0, .45);
}

.masthead .shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem 1rem;
  flex-wrap: wrap;
  padding-block: .65rem;
}

.brand {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--accent);
  text-decoration: none;
  text-shadow: 0 0 12px var(--accent-glow);
}
.brand:hover { text-decoration: none; }
.brand::after {
  content: "▮";
  margin-left: .15rem;
  color: var(--accent);
  animation: caret 1.1s steps(1) infinite;
}
@keyframes caret {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

.nav { display: flex; flex-wrap: wrap; gap: .25rem 1rem; }
.nav a {
  position: relative;
  font-family: var(--mono);
  font-size: .875rem;
  color: var(--fg-muted);
  text-decoration: none;
  padding: .2rem 0;
}
.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .18s ease;
}
.nav a:hover { color: var(--fg); }
.nav a:hover::after { transform: scaleX(1); }
.nav a.is-active { color: var(--fg); }
.nav a.is-active::after { transform: scaleX(1); }

/* Page + hero */
main.page { padding: 3rem 0 4rem; }

main.page .shell > * { animation: rise-in .5s ease-out both; }
main.page .shell > *:nth-child(2) { animation-delay: .06s; }
main.page .shell > *:nth-child(3) { animation-delay: .12s; }
main.page .shell > *:nth-child(4) { animation-delay: .18s; }
main.page .shell > *:nth-child(5) { animation-delay: .24s; }
main.page .shell > *:nth-child(6) { animation-delay: .3s; }
main.page .shell > *:nth-child(7) { animation-delay: .36s; }
main.page .shell > *:nth-child(8) { animation-delay: .42s; }
main.page .shell > *:nth-child(9) { animation-delay: .48s; }
main.page .shell > *:nth-child(10) { animation-delay: .54s; }
@keyframes rise-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1.15;
  letter-spacing: .04em;
  margin: .5rem 0 1rem;
  animation: flicker-in .9s steps(12) both, hero-glow 4s ease-in-out 1s infinite;
}
@keyframes flicker-in {
  0% { opacity: 0; transform: translateY(6px) skewX(4deg); }
  8% { opacity: .6; }
  12% { opacity: .1; }
  20% { opacity: .9; transform: none; }
  28% { opacity: .3; }
  36%, 100% { opacity: 1; }
}
@keyframes hero-glow {
  0%, 100% { text-shadow: 0 0 14px var(--accent-glow); }
  50% { text-shadow: 0 0 26px var(--accent-glow), 0 0 2px rgba(255, 158, 0, .5); }
}

.hero-sub {
  color: var(--fg-muted);
  font-size: 1.05rem;
  max-width: 46rem;
  margin-bottom: 1.5rem;
}

.eyebrow {
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .75rem;
  color: var(--accent);
  margin: 0;
}
.eyebrow::before {
  content: "▸ ";
  animation: pulse-dot 1.6s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: .25; }
}

/* Buttons */
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; margin: 0 0 2rem; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .6rem 1rem;
  border-radius: 6px;
  border: 1px solid var(--border-strong);
  font-family: var(--mono);
  font-size: .875rem;
  line-height: 1.2;
  text-decoration: none;
  background: transparent;
  color: var(--fg);
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease, background .15s ease;
}
.btn:hover {
  border-color: var(--accent);
  text-decoration: none;
  box-shadow: 0 0 14px var(--accent-glow);
  transform: translateY(-1px);
}
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn-primary {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: #fff6ea;
  box-shadow: 0 0 10px rgba(255, 158, 0, .18);
}
.btn-primary:hover { box-shadow: 0 0 20px var(--accent-glow); }
.btn-ghost { background: transparent; color: var(--fg); }

/* Cards */
.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
}

.card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.25rem;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.card::before, .card::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border: 1px solid var(--accent);
  opacity: .65;
  transition: width .18s ease, height .18s ease, opacity .18s ease;
}
.card::before { top: -1px; left: -1px; border-right: 0; border-bottom: 0; }
.card::after { bottom: -1px; right: -1px; border-left: 0; border-top: 0; }
.card:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  box-shadow: 0 0 24px rgba(255, 158, 0, .12), 0 8px 24px rgba(0, 0, 0, .5);
}
.card:hover::before, .card:hover::after { width: 22px; height: 22px; opacity: 1; }
.card h3 {
  font-family: var(--mono);
  letter-spacing: .06em;
  font-size: .8rem;
  margin: 0 0 .5rem;
  color: var(--accent);
}
.card p { color: var(--fg-muted); font-size: .9375rem; }
.card > a:last-child {
  display: inline-block;
  margin-top: .25rem;
  font-family: var(--mono);
  font-size: .8125rem;
}

/* Services */
.service { border-top: 2px solid var(--accent-dim); padding: 1.5rem 0; }
.service h2 { margin: 0 0 .75rem; font-size: 1.3rem; }
.service > p:not([class]) { color: var(--fg-muted); }
.service h3 {
  font-family: var(--mono);
  letter-spacing: .06em;
  font-size: .75rem;
  color: var(--fg-dim);
  margin: 1.25rem 0 .4rem;
}
.service ul { color: var(--fg-muted); font-size: .9375rem; }

.service-price {
  font-family: var(--mono);
  font-size: 1.5rem;
  color: var(--accent);
  margin: 1.25rem 0 .25rem;
  animation: price-glow 3.2s ease-in-out infinite;
}
@keyframes price-glow {
  0%, 100% { text-shadow: 0 0 8px rgba(255, 158, 0, .25); }
  50% { text-shadow: 0 0 20px rgba(255, 158, 0, .55); }
}
.price-note { color: var(--fg-dim); font-size: .8125rem; margin: 0 0 1rem; }

@media (min-width: 56rem) {
  .service {
    display: grid;
    grid-template-columns: 1.4fr .6fr;
    column-gap: 2.5rem;
  }
  .service > h2,
  .service > h3,
  .service > ul,
  .service > p:not([class]) { grid-column: 1; }
  .service > .service-price { grid-column: 2; grid-row: 1; align-self: start; margin-top: .35rem; }
  .service > .price-note { grid-column: 2; grid-row: 2; align-self: start; }
  .service > .btn { grid-column: 2; grid-row: 3; justify-self: start; align-self: start; }
}

/* Spec list */
.spec {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: .4rem 1.5rem;
  margin: 0 0 1rem;
}
.spec dt {
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .75rem;
  color: var(--accent);
  padding-top: .25rem;
}
.spec dd { margin: 0; color: var(--fg); overflow-wrap: anywhere; }

@media (max-width: 40rem) {
  .spec { grid-template-columns: 1fr; gap: .1rem; }
  .spec dd { margin-bottom: .7rem; }
}

/* Numbered steps */
.steps li { margin-bottom: .6rem; }
.steps li::marker {
  font-family: var(--mono);
  color: var(--accent);
  font-size: .9rem;
}

/* Contact rows */
.contact-row {
  display: flex;
  gap: .75rem;
  align-items: center;
  flex-wrap: wrap;
  padding: .75rem 0;
  border-bottom: 1px solid var(--border);
  transition: background .15s ease;
}
.contact-row:hover { background: rgba(255, 158, 0, .04); }

.copy {
  padding: .35rem .6rem;
  font-family: var(--mono);
  font-size: .75rem;
  line-height: 1.2;
  background: transparent;
  color: var(--fg);
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease, color .15s ease;
}
.copy:hover { border-color: var(--accent); box-shadow: 0 0 10px var(--accent-glow); }
.copy:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.copy.is-copied { border-color: var(--accent); color: var(--accent); }
.copy.is-failed { color: var(--warn); }

/* Disclosure policy */
.policy h2 { scroll-margin-top: 5rem; }
.policy h3 {
  font-family: var(--mono);
  letter-spacing: .06em;
  font-size: .8rem;
  color: var(--accent);
  margin: 1.75rem 0 .6rem;
}
.policy li { margin-bottom: .5rem; color: var(--fg-muted); }

/* Footer */
footer.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-elev);
  padding: 2rem 0;
  color: var(--fg-dim);
  font-size: .8125rem;
}
.site-footer p { margin: 0 0 .5rem; }
.site-footer a { color: var(--fg-muted); }
.site-footer a:hover { color: var(--accent); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}

::selection { background: var(--accent-dim); color: #fff6ea; }

/* Proof page */
.stamp {
  display: inline-block;
  padding: .25rem .6rem;
  border: 1px dashed var(--accent);
  border-radius: 999px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: .7rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin: 0 0 1rem;
}

.finding {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 2px solid var(--accent);
  border-radius: 8px;
  padding: 1.5rem;
  margin: 1.5rem 0;
}
.finding h2 { margin-top: 0; font-size: 1.15rem; }
.finding h3 {
  font-family: var(--mono);
  letter-spacing: .06em;
  font-size: .8rem;
  color: var(--accent);
  margin: 1.5rem 0 .5rem;
}

pre {
  background: #04060a;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: .9rem 1rem;
  overflow-x: auto;
  font-size: .8125rem;
  line-height: 1.55;
  color: var(--fg-muted);
  margin: 0 0 1rem;
}
