:root {
  --bg: #060606;
  --fg: #f0f0f0;
  --dim: #8a8a8a;
  --border: #2c2c2c;
  --accent: #f0f0f0;
  --term-red: #ff5f56;
  --term-yellow: #ffbd2e;
  --term-green: #27c93f;
  --glow-purple: #a855f7;
  --mono: "SFMono-Regular", "Menlo", "Consolas", "Liberation Mono", monospace;
  --sans: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  line-height: 1.6;
}

a { color: var(--dim); text-decoration: none; }
a:hover { color: var(--fg); text-decoration: underline; }

code {
  font-family: var(--mono);
  font-size: 0.92em;
  color: var(--fg);
  background: #121212;
  padding: 0.1em 0.4em;
  border: 1px solid var(--border);
}

/* Top nav: bordered grid of cells, no rounded corners anywhere */
.navbar {
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid var(--border);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 24px;
  border-right: 1px solid var(--border);
  flex: 1;
}

.dots { color: var(--dim); font-size: 1.1rem; }

.wordmark {
  font-weight: 700;
  letter-spacing: 0.12em;
  font-size: 1.05rem;
}

.navcell {
  display: flex;
  align-items: center;
  padding: 18px 24px;
  border-right: 1px solid var(--border);
  font-size: 0.95rem;
  white-space: nowrap;
  color: var(--fg);
}
.navcell:last-child { border-right: none; }

@media (max-width: 700px) {
  .navbar { flex-wrap: wrap; }
  .brand { flex: 1 1 100%; border-right: none; border-bottom: 1px solid var(--border); }
  .navcell { flex: 1 1 50%; border-bottom: 1px solid var(--border); }
}

/* Hero: a real terminal window (left third) beside a media column
   (right two-thirds) */
.hero {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 24px;
  padding: 48px 24px;
  border-bottom: 1px solid var(--border);
  align-items: stretch;
}

.terminal {
  border: 1px solid var(--border);
  background: #0a0a0a;
  display: flex;
  flex-direction: column;
}

.term-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #161616;
  border-bottom: 1px solid var(--border);
}

.term-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}
.term-dot.red { background: var(--term-red); }
.term-dot.yellow { background: var(--term-yellow); }
.term-dot.green { background: var(--term-green); }

.term-title {
  margin-left: 8px;
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--dim);
}

.term-body {
  font-family: var(--mono);
  padding: 20px 18px;
  flex: 1;
}

.term-line { margin: 0 0 4px; color: var(--fg); }
.term-line .dim { color: var(--dim); }

.term-out {
  margin: 0 0 16px;
  padding-left: 16px;
  color: var(--dim);
}

.term-headline {
  font-weight: 700;
  font-size: 2.1rem;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--fg);
}

.term-lede {
  font-size: 0.95rem;
  max-width: 420px;
}

.term-cmd {
  color: var(--fg);
  font-family: var(--mono);
}
.term-cmd:hover { text-decoration: underline; }

.cursor {
  display: inline-block;
  width: 0.55em;
  height: 1em;
  background: var(--fg);
  margin-left: 4px;
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.hero-media {
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

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

.hero-media-placeholder {
  color: var(--dim);
  font-family: var(--mono);
  font-size: 0.85rem;
}

@media (max-width: 800px) {
  .hero { grid-template-columns: 1fr; }
}

/* Recurring full-width wordmark band, echoing the small nav wordmark
   at large scale */
.wordmark-band {
  display: block;
  text-align: center;
  font-weight: 700;
  letter-spacing: 0.3em;
  font-size: clamp(1.5rem, 6vw, 3.2rem);
  padding: 40px 16px;
  border-bottom: 1px solid var(--border);
  overflow-wrap: break-word;
}

main {
  max-width: 720px;
  margin: 0 auto;
}

.block {
  padding: 48px 24px;
  border-bottom: 1px solid var(--border);
}
main .block:last-child { border-bottom: none; }

h2.tag {
  margin: 0 0 16px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.project-card {
  display: block;
  border: 1px solid rgba(168, 85, 247, 0.4);
  border-radius: 12px;
  padding: 28px 32px;
  background:
    linear-gradient(160deg, rgba(168, 85, 247, 0.10), rgba(168, 85, 247, 0) 60%),
    var(--bg);
  box-shadow:
    inset 0 0 0 1px rgba(168, 85, 247, 0.12),
    0 14px 34px rgba(0, 0, 0, 0.6),
    0 0 32px rgba(168, 85, 247, 0.20);
  transform: translateY(0);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.project-card:hover {
  transform: translateY(-5px);
  border-color: rgba(168, 85, 247, 0.75);
  box-shadow:
    inset 0 0 0 1px rgba(168, 85, 247, 0.25),
    0 20px 44px rgba(0, 0, 0, 0.65),
    0 0 48px rgba(168, 85, 247, 0.4);
}

.project-card-name {
  display: inline-block;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  padding: 10px 22px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--glow-purple), #7c3aed);
  box-shadow: 0 4px 18px rgba(168, 85, 247, 0.45);
  margin-bottom: 16px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.project-card-name:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 26px rgba(168, 85, 247, 0.65);
  color: #fff;
}

.project-card-cta {
  display: inline-block;
  margin-top: 18px;
  padding: 8px 16px;
  border: 1px solid rgba(168, 85, 247, 0.5);
  border-radius: 999px;
  color: var(--glow-purple);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.project-card-cta:hover {
  background: rgba(168, 85, 247, 0.15);
  border-color: rgba(168, 85, 247, 0.9);
  color: #fff;
}

.project-card-tag {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--glow-purple);
  margin-bottom: 14px;
}

.project-card-desc {
  margin: 0;
  color: var(--dim);
  line-height: 1.55;
}

.feature-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.feature-list li {
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.feature-list li:last-child { border-bottom: none; }

.footgrid {
  display: flex;
  flex-wrap: wrap;
}

.footgrid .navcell {
  flex: 1 1 25%;
  border-top: 1px solid var(--border);
  justify-content: center;
  color: var(--dim);
}

.footnote {
  text-align: center;
  font-size: 0.8rem;
  color: var(--dim);
  padding: 16px 24px 0;
  margin: 0;
}
.footnote:last-child { padding-bottom: 16px; }

@media (max-width: 600px) {
  .hero h1 { font-size: 2.6rem; }
  .footgrid .navcell { flex: 1 1 50%; }
}

/* Known Issues: rendered from this repo's KNOWN_ISSUES.md at runtime
   (see the fetch script near the end of the page). Each "## " issue
   becomes its own collapsible card, rather than one undifferentiated
   wall of text. */
.markdown-embed p.dim { color: var(--dim); margin: 0; }

.markdown-embed details {
  border: 1px solid var(--border);
  background: #0a0a0a;
  margin-bottom: 14px;
}
.markdown-embed details:last-child { margin-bottom: 0; }
.markdown-embed details[open] { border-color: #3a3a3a; }

.markdown-embed summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 20px;
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--fg);
  -webkit-tap-highlight-color: transparent;
}
.markdown-embed summary::-webkit-details-marker { display: none; }
.markdown-embed summary::marker { content: ""; }

.markdown-embed .issue-title {
  flex: 1;
  min-width: 0;
  overflow-wrap: anywhere;
}

.markdown-embed summary::before {
  content: "▸";
  color: var(--dim);
  font-size: 0.8em;
  display: inline-block;
  transition: transform 0.15s ease;
  flex-shrink: 0;
}
.markdown-embed details[open] summary::before { transform: rotate(90deg); }
.markdown-embed summary:hover::before { color: var(--fg); }

.markdown-embed .issue-body {
  padding: 0 20px 18px;
  border-top: 1px solid var(--border);
  padding-top: 16px;
}

.markdown-embed .issue-body p { margin: 0 0 14px; color: var(--fg); }
.markdown-embed .issue-body p:last-child { margin-bottom: 0; }

.markdown-embed .issue-body pre {
  margin: 0 0 14px;
  overflow-x: auto;
}

.markdown-embed .issue-body ul,
.markdown-embed .issue-body ol {
  margin: 0 0 14px;
  padding-left: 1.3em;
}
.markdown-embed .issue-body li { margin-bottom: 6px; }
.markdown-embed .issue-body li:last-child { margin-bottom: 0; }

.markdown-embed .issue-body a { text-decoration: underline; }

/* Symptom/Cause/Workaround/Fixed labels, pulled out of the leading
   "**Label:**" bold text and turned into small colored tags -- a
   problem/diagnosis/fix traffic light, echoing the terminal-window
   dots in the hero. */
.markdown-embed .issue-label {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 7px;
  margin-right: 2px;
  border: 1px solid var(--border);
  white-space: nowrap;
}
.markdown-embed .label-symptom { color: var(--term-red); border-color: var(--term-red); }
.markdown-embed .label-cause { color: var(--term-yellow); border-color: var(--term-yellow); }
.markdown-embed .label-fixed { color: var(--term-green); border-color: var(--term-green); }
.markdown-embed .label-default { color: var(--dim); }

/* configure.html -- the client-side installer-script builder */

.configure-title {
  margin: 0 0 16px;
  font-size: 1.6rem;
  line-height: 1.25;
}

.privacy-note {
  border: 1px solid var(--term-green);
  background: rgba(39, 201, 63, 0.08);
  padding: 14px 16px;
  font-size: 0.9rem;
}
.privacy-note strong { color: var(--term-green); }

.field-row {
  margin-bottom: 20px;
}

.field-row label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.9rem;
  font-weight: 600;
}

.field-row input[type="text"],
.field-row input[type="password"],
.field-row select,
.field-row textarea {
  width: 100%;
  background: #121212;
  color: var(--fg);
  border: 1px solid var(--border);
  padding: 10px 12px;
  font-family: var(--mono);
  font-size: 0.9rem;
}

.field-row input[type="text"]:focus,
.field-row input[type="password"]:focus,
.field-row select:focus,
.field-row textarea:focus {
  outline: none;
  border-color: var(--dim);
}

.field-row textarea { resize: vertical; }

.field-hint {
  margin: 8px 0 0;
  font-size: 0.82rem;
  color: var(--dim);
  line-height: 1.5;
}
.field-hint a { text-decoration: underline; }

.field-warning {
  margin: 8px 0 0;
  padding: 8px 12px;
  border: 1px solid var(--term-red);
  background: rgba(255, 95, 86, 0.08);
  color: var(--fg);
  font-size: 0.82rem;
  line-height: 1.5;
}

.radio-group { display: flex; flex-direction: column; gap: 10px; }

.radio-option,
.checkbox-option {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-weight: 400;
  font-size: 0.95rem;
  cursor: pointer;
}

.radio-option input,
.checkbox-option input {
  flex-shrink: 0;
}

.field-group {
  margin: 4px 0 20px;
  padding: 16px 18px 2px;
  border-left: 2px solid var(--border);
}

.script-output-wrap {
  position: relative;
}

.script-output {
  margin: 0;
  padding: 20px;
  background: #0a0a0a;
  border: 1px solid var(--border);
  overflow-x: auto;
  max-height: 480px;
  overflow-y: auto;
  font-size: 0.82rem;
  line-height: 1.5;
}

.copy-btn {
  position: sticky;
  float: right;
  top: 12px;
  margin: 12px 12px 0 0;
  z-index: 1;
  background: #161616;
  color: var(--fg);
  border: 1px solid var(--border);
  padding: 8px 16px;
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.copy-btn:hover { border-color: var(--dim); }
