/* ============================================================
   Risi's Service — mobile mechanic
   charcoal + phosphor green terminal, cafe-menu layout
   ============================================================ */

:root {
  --bg: #1c1c1c;
  --bg-2: #232323;
  --surface: #202020;
  --surface-2: #262626;
  --ink: #39ff14;
  --ink-soft: #9ee88a;
  --secondary: #ffb000;
  --muted: #8f8f8f;
  --line: #3a3a3a;
  --line-strong: #4d4d4d;
  --glow-a: rgba(57, 255, 20, 0.07);
  --glow-b: rgba(255, 176, 0, 0.06);
  --btn-ink: #0d0d0d;
  --focus: #ffb000;
  --maxw: 74rem;
  --pad: clamp(1.15rem, 4vw, 2.75rem);
}

html[data-theme="light"] {
  --bg: #f4f2ec;
  --bg-2: #eae7de;
  --surface: #ffffff;
  --surface-2: #f7f5ef;
  --ink: #14532d;
  --ink-soft: #2f6b45;
  --secondary: #8a4b00;
  --muted: #5f5c55;
  --line: #d5d1c6;
  --line-strong: #b8b3a5;
  --glow-a: rgba(20, 83, 45, 0.06);
  --glow-b: rgba(138, 75, 0, 0.05);
  --btn-ink: #f4f2ec;
  --focus: #8a4b00;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: clamp(0.9rem, 0.55vw + 0.78rem, 1rem);
  line-height: 1.68;
  color: var(--ink-soft);
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 70% 55% at 12% 0%, var(--glow-a) 0%, transparent 62%),
    radial-gradient(ellipse 65% 50% at 92% 78%, var(--glow-b) 0%, transparent 58%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video { max-width: 100%; height: auto; display: block; }

a { color: var(--ink); text-decoration-thickness: 1px; text-underline-offset: 3px; }

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* ---------- scanline overlay ---------- */
.scanlines {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
  background: repeating-linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.16) 0px,
    rgba(0, 0, 0, 0.16) 1px,
    transparent 1px,
    transparent 3px
  );
  opacity: 0.5;
  mix-blend-mode: multiply;
}
html[data-theme="light"] .scanlines { opacity: 0.16; mix-blend-mode: multiply; }

/* ---------- header ---------- */
.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.head-row {
  display: flex;
  align-items: center;
  gap: 1rem 1.5rem;
  flex-wrap: wrap;
  padding-block: 0.85rem;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 0.55rem;
  text-decoration: none;
  color: var(--ink);
  margin-right: auto;
}
.brand-mark { color: var(--secondary); font-size: 0.85em; }
.brand-name {
  font-weight: 700;
  letter-spacing: 0.06em;
  font-size: 0.95rem;
}
.brand-sub {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  gap: 1.15rem;
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.82rem;
  padding: 0.5rem 0.1rem;
  border-bottom: 1px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.site-nav a:hover { color: var(--ink); border-bottom-color: var(--ink); }

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 44px;
  padding: 0.5rem 0.85rem;
  font: inherit;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--secondary);
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}
.theme-toggle:hover { border-color: var(--secondary); }
.tt-icon { font-size: 0.95rem; line-height: 1; }

/* ---------- marquee ---------- */
.marquee {
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 70%, transparent);
  padding-block: 0.55rem;
}
.marquee-track {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  width: max-content;
  animation: scroll 42s linear infinite;
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--secondary);
  white-space: nowrap;
}
.marquee-track .dot { color: var(--line-strong); }
@keyframes scroll { to { transform: translateX(-50%); } }

/* ---------- breathing width axis ---------- */
@keyframes breathe {
  0%, 100% { font-variation-settings: 'wdth' 78; }
  50%      { font-variation-settings: 'wdth' 118; }
}
.breathe {
  animation: breathe 9s ease-in-out infinite;
  font-variation-settings: 'wdth' 88;
}

/* ---------- hero ---------- */
.hero {
  padding-block: clamp(3rem, 9vw, 6.5rem) clamp(2.5rem, 6vw, 4.5rem);
}

.eyebrow {
  margin: 0 0 1.1rem;
  font-size: 0.76rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--secondary);
}

h1 {
  margin: 0 0 1.4rem;
  font-size: clamp(2rem, 6.2vw, 4.1rem);
  line-height: 1.06;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--ink);
  max-width: 22ch;
  text-wrap: balance;
}

.lede {
  margin: 0 0 2rem;
  max-width: 58ch;
  font-size: clamp(0.95rem, 0.5vw + 0.85rem, 1.08rem);
  color: var(--ink-soft);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-bottom: 3rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0.7rem 1.5rem;
  font: inherit;
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.btn-primary {
  background: var(--ink);
  color: var(--btn-ink);
  border-color: var(--ink);
  font-weight: 700;
}
.btn-primary:hover { background: var(--secondary); border-color: var(--secondary); }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-ghost:hover { border-color: var(--ink); }

.hero-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: 1.25rem 2rem;
  margin: 0;
  padding-top: 1.75rem;
  border-top: 1px solid var(--line);
}
.hero-facts dt {
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.3rem;
}
.hero-facts dd { margin: 0; color: var(--ink); }

/* ---------- generic band ---------- */
.band {
  padding-block: clamp(2.75rem, 6vw, 4.5rem);
  border-top: 1px solid var(--line);
}

h2 {
  margin: 0 0 1.1rem;
  font-size: clamp(1.4rem, 3.2vw, 2.3rem);
  line-height: 1.14;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.section-intro {
  margin: 0 0 2.5rem;
  max-width: 62ch;
  color: var(--ink-soft);
}

.note {
  margin: 2.25rem 0 0;
  padding-top: 1.25rem;
  border-top: 1px dashed var(--line-strong);
  font-size: 0.85rem;
  color: var(--muted);
  max-width: 62ch;
}

/* ---------- menu ---------- */
.menu {
  display: grid;
  gap: clamp(2rem, 4vw, 3rem);
}

.menu-group h3 {
  margin: 0 0 1.1rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--line-strong);
  font-size: 0.82rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--secondary);
  font-weight: 700;
}

.item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.4rem 1.5rem;
  padding-block: 0.95rem;
  border-bottom: 1px solid var(--line);
}
.item:last-child { border-bottom: 0; }

.item-name {
  margin: 0 0 0.3rem;
  color: var(--ink);
  font-weight: 700;
  font-size: 0.95rem;
}
.item-desc {
  margin: 0;
  font-size: 0.86rem;
  color: var(--muted);
  max-width: 66ch;
}
.item-price {
  margin: 0;
  color: var(--secondary);
  font-size: 0.85rem;
  white-space: nowrap;
  text-align: right;
  padding-top: 0.1rem;
}

/* ---------- steps ---------- */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
  counter-reset: step;
}
.steps li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.25rem;
  padding-block: 1.5rem;
  border-bottom: 1px solid var(--line);
}
.steps li:last-child { border-bottom: 0; }
.step-n {
  color: var(--secondary);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  padding-top: 0.25rem;
}
.steps h3 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
  color: var(--ink);
  font-weight: 700;
}
.steps p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--muted);
  max-width: 68ch;
}

/* ---------- cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1.5rem;
}
.card {
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 1.5rem 1.4rem;
}
.card h3 {
  margin: 0 0 0.7rem;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--secondary);
}
.card p { margin: 0; font-size: 0.88rem; color: var(--ink-soft); }

/* ---------- booking ---------- */
.book-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: clamp(1.75rem, 4vw, 3.5rem);
  align-items: start;
}

.book-form { display: grid; gap: 1.1rem; }

.field { display: grid; gap: 0.4rem; }
.field label {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.field input,
.field textarea {
  font: inherit;
  font-size: 0.92rem;
  color: var(--ink);
  background: color-mix(in srgb, var(--surface) 80%, transparent);
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  padding: 0.7rem 0.8rem;
  width: 100%;
  min-height: 46px;
  transition: border-color 0.2s ease;
}
.field textarea { min-height: 8rem; resize: vertical; }
.field input::placeholder,
.field textarea::placeholder { color: var(--muted); opacity: 0.75; }
.field input:focus,
.field textarea:focus { border-color: var(--ink); }

.book-form .btn { justify-self: start; margin-top: 0.4rem; }

.form-status {
  margin: 0;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.form-status.is-ok { color: var(--ink); }
.form-status.is-error { color: var(--secondary); }

.book-side {
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 1.5rem 1.4rem;
  background: color-mix(in srgb, var(--surface) 70%, transparent);
}
.book-side h3 {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--secondary);
}
.side-line {
  margin: 0 0 0.75rem;
  font-size: 0.88rem;
  display: grid;
  gap: 0.15rem;
}
.side-line .k {
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.side-note {
  margin: 1.25rem 0 0;
  padding-top: 1rem;
  border-top: 1px dashed var(--line-strong);
  font-size: 0.82rem;
  color: var(--muted);
}

/* ---------- closing ---------- */
.closing { text-align: left; }
.closing blockquote {
  margin: 0 0 1.25rem;
  padding-left: 1.25rem;
  border-left: 2px solid var(--secondary);
}
.closing blockquote p {
  margin: 0;
  font-size: clamp(1.05rem, 2vw, 1.5rem);
  line-height: 1.4;
  color: var(--ink);
  max-width: 46ch;
}
.closing-note {
  margin: 0;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- placeholders ---------- */
.ph {
  color: var(--secondary);
  border-bottom: 1px dotted var(--secondary);
  padding-bottom: 1px;
}

/* ---------- footer ---------- */
.site-foot {
  border-top: 1px solid var(--line);
  padding-block: 2rem 3.5rem;
  background: color-mix(in srgb, var(--surface) 55%, transparent);
}
.foot-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.75rem;
}
.foot-brand {
  margin: 0;
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
}
.foot-links {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-right: auto;
}
.foot-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.78rem;
}
.foot-links a:hover { color: var(--ink); text-decoration: underline; }

.attribution {
  position: static;
  margin: 0;
  font-size: 0.72rem;
  font-family: inherit;
  opacity: 1;
}
.attribution a { color: var(--muted); text-decoration: none; }
.attribution a:hover { color: var(--ink); text-decoration: underline; }

/* ---------- responsive ---------- */
@media (max-width: 60rem) {
  .book-grid { grid-template-columns: 1fr; }
}

@media (max-width: 44rem) {
  .head-row { gap: 0.6rem 1rem; }
  .brand-sub { display: none; }
  .site-nav { order: 3; width: 100%; gap: 0.9rem; }
  .site-nav a { font-size: 0.78rem; }
  .item { grid-template-columns: 1fr; }
  .item-price { text-align: left; padding-top: 0.35rem; }
  .steps li { grid-template-columns: 1fr; gap: 0.5rem; }
  .step-n { padding-top: 0; }
  .hero-actions .btn { flex: 1 1 auto; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .marquee-track { animation: none; }
  .breathe { animation: none; font-variation-settings: 'wdth' 92; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
