@import url('./fonts/fonts.css');

/* ============================================================
   the workshop — unamcd.com
   Dark, warm, lamp-lit. One source of truth in :root.
   ============================================================ */

:root {
  --bg: #1a1614;
  --surface: #241e1b;
  --surface-2: #2c2521;
  --text: #f2e9df;
  --muted: #b3a596;          /* lightened from concept #a8978a for AA body contrast */
  --muted-dim: #8c7f73;      /* large/label use only */
  --accent: #e0793b;         /* citadel-orange — used sparingly */
  --accent-soft: #e0793b26;  /* ~15% */
  --accent-2: #6fa292;       /* sage */
  --line: #3a322d;
  --line-soft: #2c2622;

  --maxw: 46rem;
  --pad: clamp(1.25rem, 5vw, 2.5rem);

  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body: 'Hanken Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: ui-monospace, 'SF Mono', SFMono-Regular, Menlo, Consolas, monospace;

  color-scheme: dark;
}

/* ---------- reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.95rem + 0.25vw, 1.0625rem);
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-optical-sizing: auto;
  /* subtle warm vignette so it reads "lamp-lit" not "flat dark" */
  background-image:
    radial-gradient(120% 70% at 50% -10%, #2a221d 0%, var(--bg) 55%);
  background-attachment: fixed;
  min-height: 100vh;
}

a { color: inherit; }

::selection { background: var(--accent-soft); color: var(--text); }

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

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

.mono { font-family: var(--font-mono); }

/* a faux shell prompt used as a recurring accent */
.prompt {
  font-family: var(--font-mono);
  font-size: 0.82em;
  color: var(--accent-2);
  letter-spacing: 0.01em;
}
.prompt::before { content: '~ '; color: var(--muted-dim); }

/* blinking cursor */
.cursor {
  display: inline-block;
  width: 0.58ch;
  height: 1.05em;
  margin-left: 0.08em;
  translate: 0 0.12em;
  background: var(--accent);
  animation: blink 1.15s steps(2, jump-none) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ---------- skip link ---------- */
.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: #160f0a;
  padding: 0.5rem 0.9rem;
  font-weight: 600;
  z-index: 10;
}
.skip:focus { left: 0.5rem; top: 0.5rem; border-radius: 5px; }

/* ---------- masthead ---------- */
.masthead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.6rem;
  border-bottom: 1px solid var(--line-soft);
}
.brand {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.005em;
}
.brand .dot { color: var(--accent); }
.masthead .where {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--muted-dim);
}

/* ---------- section rhythm ---------- */
main { display: block; }
.section { padding-block: clamp(2.75rem, 7vw, 4.5rem); }
.section + .section { border-top: 1px solid var(--line-soft); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted-dim);
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.eyebrow::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--line-soft);
}

/* ---------- hero ---------- */
.hero { padding-top: clamp(2.5rem, 6vw, 4rem); }
.hero .art {
  width: min(100%, 22rem);
  height: auto;
  color: var(--muted);
  margin-bottom: 2rem;
}
.hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.4rem, 6.5vw, 4rem);
  line-height: 1.04;
  letter-spacing: -0.018em;
  max-width: 16ch;
}
.hero h1 em {
  font-style: italic;
  color: var(--accent);
  font-weight: 500;
}
.hero .sub {
  margin-top: 1.4rem;
  font-size: 1.12rem;
  color: var(--muted);
  max-width: 44ch;
  line-height: 1.6;
}

/* ---------- currently (living status line) ---------- */
.currently .rows {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  display: grid;
  gap: 0.7rem;
}
.currently .row {
  display: grid;
  grid-template-columns: 6.5rem 1fr;
  gap: 0.5rem 1rem;
  align-items: baseline;
}
.currently .k { color: var(--accent-2); }
.currently .k::before { content: '> '; color: var(--muted-dim); }
.currently .v { color: var(--text); }
.currently .v small { color: var(--muted-dim); font-family: var(--font-body); }

/* ---------- selected work (numbered index of cards) ---------- */
.work .grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.9rem;
}
.card {
  position: relative;
  display: block;
  text-decoration: none;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 1.4rem 1.4rem 1.5rem;
  transition: border-color 0.25s ease, transform 0.25s ease, background 0.25s ease;
}
.card .num {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--muted-dim);
  letter-spacing: 0.05em;
}
.card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.3rem;
  margin-top: 0.5rem;
  letter-spacing: -0.01em;
}
.card p {
  color: var(--muted);
  font-size: 0.96rem;
  margin-top: 0.55rem;
  line-height: 1.55;
}
.card .tags {
  margin-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--muted-dim);
  letter-spacing: 0.02em;
}
a.card:hover, a.card:focus-visible {
  border-color: var(--accent);
  background: var(--surface-2);
  transform: translateY(-2px);
}
a.card:hover h3, a.card:focus-visible h3 { color: var(--accent); }

/* ---------- the workbench ---------- */
.bench .items { display: grid; gap: 1.4rem; }
.bench .item {
  display: grid;
  grid-template-columns: 2.5rem 1fr;
  gap: 1rem;
  align-items: start;
}
.bench .item svg { width: 2rem; height: 2rem; color: var(--accent-2); }
.bench .item h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
}
.bench .item p { color: var(--muted); font-size: 0.96rem; margin-top: 0.25rem; }

/* ---------- interests / chips ---------- */
.care .chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}
.chip {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.4rem 0.85rem;
  transition: border-color 0.2s ease, color 0.2s ease;
}
.chip:hover { border-color: var(--accent-2); color: var(--text); }

/* ---------- field notes ---------- */
.notes .prompt-line {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--muted-dim);
  margin-bottom: 1.1rem;
}
.notes .prompt-line b { color: var(--accent-2); font-weight: 400; }
.notes p {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.15rem, 2.5vw, 1.4rem);
  line-height: 1.5;
  letter-spacing: -0.005em;
  max-width: 40ch;
}
.notes p em { font-style: italic; color: var(--accent); }

/* ---------- footer ---------- */
.foot {
  padding-block: 3rem 3.5rem;
  border-top: 1px solid var(--line-soft);
  color: var(--muted-dim);
  font-size: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem 2rem;
  justify-content: space-between;
  align-items: center;
}
.foot .colophon { max-width: 32ch; line-height: 1.5; }
.foot .signoff { font-family: var(--font-mono); color: var(--muted); }

/* ---------- reveal animation ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(14px); }
[data-reveal].is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
  }
}
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { opacity: 1; transform: none; }
  .cursor { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- responsive ---------- */
@media (max-width: 36rem) {
  .work .grid { grid-template-columns: 1fr; }
  .currently .row { grid-template-columns: 1fr; gap: 0.15rem; }
  .currently .row .v { padding-left: 1rem; }
  .foot { flex-direction: column; align-items: flex-start; }
}
