@font-face { font-family: 'Inter'; font-weight: 400; font-display: swap; src: url('/fonts/inter-400.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 600; font-display: swap; src: url('/fonts/inter-600.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 700; font-display: swap; src: url('/fonts/inter-700.woff2') format('woff2'); }
@font-face { font-family: 'Space Grotesk'; font-weight: 500; font-display: swap; src: url('/fonts/spacegrotesk-500.woff2') format('woff2'); }
@font-face { font-family: 'Space Grotesk'; font-weight: 700; font-display: swap; src: url('/fonts/spacegrotesk-700.woff2') format('woff2'); }

/* joshuaaah.com color bible -- canonical tokens, copied verbatim (memory/feedback_joshuaaah_color_bible.md) */
:root {
  --jx-bg: #FFFFFF;
  --jx-surface: #F7F6FA;
  --jx-surface-alt: #ECEAF1;
  --jx-black: #000000;
  --jx-black-soft: #0D0D10;
  --jx-primary: #1A0633;
  --jx-primary-hover: #2E1152;
  --jx-primary-deep: #0F0320;
  --jx-silver: #C4CED4;
  --jx-accent: #0D9488;
  --jx-accent-hover: #14B8A6;
  --jx-accent-text: #0F766E;
  --jx-text: #121117;
  --jx-text-secondary: #6B6974;
  --jx-text-on-dark: #F2F1F5;
  --jx-border: #D8D5E0;
  --jx-success: #16A34A;
  --jx-warning: #D97706;
  --jx-spotlight: #F97316;
  --jx-spotlight-hover: #FB923C;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 8px;
  --font-sans: 'Inter', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, system-ui, -apple-system, sans-serif;
  --font-display: 'Space Grotesk', 'Inter', 'Segoe UI', Roboto, Arial, sans-serif;
  --nav-height: 60px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--jx-text);
  background:
    radial-gradient(1100px 600px at 12% -10%, rgba(13,148,136,0.05), transparent 60%),
    radial-gradient(900px 560px at 110% 10%, rgba(26,6,51,0.07), transparent 55%),
    var(--jx-bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3 { font-family: var(--font-display); letter-spacing: -0.01em; margin: 0; }
button, input, select { font: inherit; }
a { color: var(--jx-primary); }
a:hover, a:focus-visible { color: var(--jx-accent-text); }
:focus-visible { outline: 2px solid var(--jx-accent); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

/* header: purple fading into black, sticky */
.bar {
  position: sticky; top: 0; z-index: 20; height: var(--nav-height);
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 0 max(16px, env(safe-area-inset-left));
  background: linear-gradient(90deg, var(--jx-primary) 0%, var(--jx-primary-deep) 55%, var(--jx-black) 100%);
  color: #fff; box-shadow: 0 1px 0 rgba(196,206,212,0.18), 0 6px 20px rgba(15,3,32,0.18);
}
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.brand span { display: flex; flex-direction: column; line-height: 1.1; }
.brand b { font-family: var(--font-display); font-size: 1.12rem; letter-spacing: 0.01em; }
.brand small { color: var(--jx-silver); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; }
.bar nav a { color: #fff; text-decoration: none; font-size: 0.9rem; padding: 6px 10px; border-radius: var(--radius-sm); }
.bar nav a:hover { background: var(--jx-primary-hover); color: #fff; }

.card { background: linear-gradient(165deg, var(--jx-surface-alt), #ffffff); border: 1px solid var(--jx-border); border-radius: var(--radius-lg); padding: 16px; min-width: 0; }
.card h2 { font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.16em; color: var(--jx-text-secondary); margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.card h2::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--jx-spotlight); box-shadow: 0 0 8px rgba(249,115,22,0.6); }

/* ScrapyardOracle */
main { max-width: 1180px; margin: 0 auto; padding: 18px 16px 40px; display: grid; gap: 18px; }
main > * { min-width: 0; }
.intro h1 { font-size: clamp(1.6rem, 6vw, 2.4rem); line-height: 1.1; color: var(--jx-primary); }
.lede { color: var(--jx-text-secondary); margin: 8px 0 0; max-width: 760px; line-height: 1.5; font-size: 0.97rem; }
.layout { display: grid; grid-template-columns: 1fr; gap: 18px; align-items: start; min-width: 0; }
@media (min-width: 960px) { .layout { grid-template-columns: minmax(0, 1fr) minmax(0, 380px); gap: 22px; } }
.side { display: grid; gap: 18px; min-width: 0; }
.muted, .fine { color: var(--jx-text-secondary); }
.fine { font-size: 0.8rem; line-height: 1.5; margin: 10px 2px 0; }
.fine:empty { display: none; }
h3 { font-size: 1rem; color: var(--jx-primary); display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
h3 i { font-weight: 500; font-style: normal; color: var(--jx-text-secondary); font-size: 0.85rem; }
.num { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--jx-primary); color: #fff; font-size: 0.8rem; }

.chip { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--jx-primary); background: var(--jx-primary); color: #fff; border-radius: 999px; padding: 9px 16px; font-weight: 600; font-size: 0.92rem; cursor: pointer; min-height: 42px; }
.chip:hover { background: var(--jx-primary-hover); }
.chip.ghost { background: #fff; color: var(--jx-primary); border-color: var(--jx-border); }
.chip.ghost:hover { border-color: var(--jx-accent); }
.chip[disabled] { opacity: 0.55; cursor: progress; }
.pill { display: inline-flex; align-items: center; gap: 5px; border-radius: 999px; padding: 2px 9px; font-size: 0.74rem; font-weight: 600; background: var(--jx-surface-alt); color: var(--jx-primary); white-space: nowrap; }
.pill.daily { background: #E6F4F2; color: var(--jx-accent-text); }
.pill.monthly { background: #EFEAF7; color: var(--jx-primary-hover); }
.pill.warn, .pill.ai { background: #FFF4EC; color: #9A3412; }

.seg { display: inline-flex; border: 1px solid var(--jx-border); border-radius: 999px; background: #fff; padding: 3px; gap: 2px; }
.seg button { border: 0; background: none; border-radius: 999px; padding: 6px 12px; font-size: 0.82rem; font-weight: 600; color: var(--jx-text-secondary); cursor: pointer; min-height: 32px; }
.seg button[aria-checked="true"] { background: var(--jx-primary); color: #fff; }
.tape-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.tape-head h2 { margin-bottom: 0; }

.tape-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.tick-card { background: #fff; border: 1px solid var(--jx-border); border-radius: var(--radius-md); min-width: 0; }
.tick-card button { all: unset; box-sizing: border-box; width: 100%; cursor: pointer; display: grid; gap: 3px; padding: 10px 12px; }
.tick-card button:focus-visible { outline: 2px solid var(--jx-accent); outline-offset: -2px; border-radius: var(--radius-md); }
.tick-card .m { font-family: var(--font-display); font-weight: 700; color: var(--jx-primary); }
.tick-card .v { font-size: 1.15rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.tick-card .u { font-size: 0.78rem; color: var(--jx-text-secondary); font-variant-numeric: tabular-nums; }
.tick-card .d { font-size: 0.74rem; color: var(--jx-text-secondary); display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }

.step + .step { border-top: 1px solid var(--jx-border); margin-top: 16px; padding-top: 16px; }
.photo-row { display: flex; gap: 8px; flex-wrap: wrap; }
.file-btn { position: relative; overflow: hidden; }
.file-btn input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.photo-box { margin-top: 10px; display: grid; gap: 10px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .photo-box { grid-template-columns: 220px 1fr; align-items: start; } }
.photo-box img { width: 100%; max-height: 260px; object-fit: cover; border-radius: var(--radius-md); border: 1px solid var(--jx-border); background: var(--jx-surface); }
.ai { background: #fff; border: 1px dashed var(--jx-spotlight); border-radius: var(--radius-md); padding: 10px 12px; font-size: 0.88rem; line-height: 1.45; min-width: 0; }
.ai ul { margin: 6px 0 0; padding-left: 18px; }
.ai li + li { margin-top: 6px; }
.linkish { border: 0; background: none; color: var(--jx-accent-text); font-weight: 600; cursor: pointer; padding: 2px; text-decoration: underline; text-underline-offset: 3px; font-size: inherit; }

.groups { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.groups button { border: 1px solid var(--jx-border); background: #fff; color: var(--jx-primary); border-radius: 999px; padding: 6px 12px; font-weight: 600; font-size: 0.85rem; cursor: pointer; min-height: 36px; }
.groups button[aria-selected="true"] { background: var(--jx-primary); border-color: var(--jx-primary); color: #fff; }
.mats { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.mat { border: 1px solid var(--jx-border); border-radius: var(--radius-md); background: #fff; min-width: 0; }
.mat > button { all: unset; box-sizing: border-box; width: 100%; cursor: pointer; padding: 10px 12px; display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 10px; align-items: center; }
.mat > button:focus-visible { outline: 2px solid var(--jx-accent); outline-offset: -2px; border-radius: var(--radius-md); }
.mat.on { border-color: var(--jx-accent); box-shadow: 0 0 0 3px rgba(13,148,136,0.14); }
.swatch { width: 34px; height: 34px; border-radius: 10px; border: 1px solid rgba(0,0,0,0.12); box-shadow: inset 0 6px 10px rgba(255,255,255,0.35), inset 0 -6px 10px rgba(0,0,0,0.18); }
.mat b { display: block; font-weight: 600; }
.mat small { color: var(--jx-text-secondary); font-size: 0.8rem; line-height: 1.35; display: block; }
.mat .more { padding: 0 12px 12px 56px; font-size: 0.82rem; line-height: 1.5; color: var(--jx-text); overflow-wrap: anywhere; }
@media (max-width: 480px) { .mat .more { padding-left: 12px; } }
.mat .more p { margin: 6px 0 0; }
.cite { color: var(--jx-text-secondary); font-size: 0.76rem; }

.weigh { display: flex; gap: 8px; }
.weigh input, .weigh select, .hist-ctl select { font-size: 1rem; padding: 10px 14px; border: 1px solid var(--jx-border); border-radius: 999px; background: #fff; color: var(--jx-text); min-width: 0; }
.weigh input { flex: 1; font-variant-numeric: tabular-nums; }
.weigh input:focus, .weigh select:focus { border-color: var(--jx-accent); box-shadow: 0 0 0 3px rgba(13,148,136,0.14); outline: none; }

.result { margin-top: 16px; }
.result:empty { display: none; }
.big { border-radius: var(--radius-md); padding: 14px; background: linear-gradient(135deg, var(--jx-primary) 0%, var(--jx-primary-deep) 70%, var(--jx-black) 100%); color: var(--jx-text-on-dark); }
.big .lbl { font-size: 0.74rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--jx-silver); }
.big .amt { font-family: var(--font-display); font-size: clamp(1.6rem, 7vw, 2.2rem); font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.big p { margin: 6px 0 0; font-size: 0.85rem; line-height: 1.45; color: #d9d6e2; }
.payout { margin-top: 10px; border-radius: var(--radius-md); padding: 12px 14px; background: #FFF8EB; border: 1px solid #F5D9A8; font-size: 0.88rem; line-height: 1.5; overflow-wrap: anywhere; }
.payout .amt2 { font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.payout.none { background: var(--jx-surface); border-color: var(--jx-border); }
.tablewrap { overflow-x: auto; }
.lines { width: 100%; border-collapse: collapse; margin-top: 12px; font-size: 0.84rem; font-variant-numeric: tabular-nums; }
.lines th, .lines td { text-align: left; padding: 6px 4px; border-bottom: 1px solid var(--jx-surface-alt); vertical-align: top; }
.lines th { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--jx-text-secondary); font-weight: 600; }
.lines .r { text-align: right; }

.tests { margin: 0; padding-left: 20px; display: grid; gap: 10px; font-size: 0.88rem; line-height: 1.5; }
.ppi { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; font-size: 0.86rem; }
.ppi li { display: flex; justify-content: space-between; gap: 10px; background: #fff; border: 1px solid var(--jx-border); border-radius: var(--radius-sm); padding: 7px 10px; }
.ppi .chg { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.up { color: var(--jx-success); }
.down { color: #9F1239; }

.hist-ctl { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; min-width: 0; max-width: 100%; }
.hist-ctl select { font-size: 0.88rem; padding: 7px 12px; max-width: 100%; }
.chart { width: 100%; height: auto; display: block; touch-action: pan-y; }
.chart .grid { stroke: var(--jx-surface-alt); stroke-width: 1; vector-effect: non-scaling-stroke; }
.chart .tick { fill: var(--jx-text-secondary); font-size: 12px; font-family: var(--font-sans); }
.chart .line { fill: none; stroke: var(--jx-accent); stroke-width: 2; vector-effect: non-scaling-stroke; }
.chart .area { fill: rgba(13,148,136,0.08); }
.chart .cursor { stroke: var(--jx-spotlight); stroke-width: 1; vector-effect: non-scaling-stroke; }
.chart .dot { fill: var(--jx-spotlight); }
.readout { font-size: 0.85rem; font-weight: 600; color: var(--jx-primary); margin-top: 4px; font-variant-numeric: tabular-nums; }

.foot { background: linear-gradient(90deg, var(--jx-black) 0%, var(--jx-primary-deep) 50%, var(--jx-primary) 100%); color: var(--jx-text-on-dark); padding: 22px 16px 28px; font-size: 0.84rem; line-height: 1.55; }
.foot p { max-width: 1148px; margin: 0 auto 10px; color: #d9d6e2; }
.foot b { color: #fff; }
.foot a { color: var(--jx-silver); }
.foot a:hover { color: var(--jx-accent-hover); }
@media (max-width: 420px) { .bar nav a { padding: 6px 4px; font-size: 0.82rem; } .brand small { display: none; } }
