/* ── Resume page: two toggleable resumes (Creative / Standard) ──
   Follows the same page-skin convention as about.css/projects.css/play.css/
   mini-folio.css: dark by default (grain-textured body + a --ink/--border
   token set scoped to this page), switching to a plain #fefefe light mode
   via body.page-resume.theme-light rather than core.css's light-first vars. */

body.page-resume {
  --bg: #0c0906;
  background-color: var(--bg);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='400'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0.3'/%3E%3C/filter%3E%3Crect width='400' height='400' filter='url(%23n)' opacity='0.055'/%3E%3C/svg%3E");
  color: var(--ink);
  min-height: 100vh;
}
body.page-resume:not(.theme-light) {
  --ink: rgba(255,255,255,0.92);
  --ink2: rgba(255,255,255,0.68);
  --muted: rgba(255,255,255,0.4);
  --border: rgba(255,255,255,0.1);
  --bord2: rgba(255,255,255,0.2);
  --bg2: rgba(255,255,255,0.08);
  --bg3: rgba(255,255,255,0.14);
}
body.page-resume.theme-light { --bg: #fefefe; }
body.page-resume.theme-light .nav-back { display: none; }
body.page-resume.theme-light .nav { background: var(--bg) !important; border-color: transparent !important; }
body.page-resume.theme-light .nav-logo { color: rgba(30,28,24,0.88) !important; }
body.page-resume.theme-light .nav-clock,
body.page-resume.theme-light .nav-clock-time { color: rgba(30,28,24,0.35) !important; }
body.page-resume.theme-light .nl { color: var(--muted) !important; }
body.page-resume.theme-light .nl:hover,
body.page-resume.theme-light .nl.on { color: var(--ink) !important; }
body.page-resume.theme-light .nl.nav-name { color: rgba(20,18,14,0.88) !important; }

/* ── Nav right slot (game button + theme toggle) — each page defines this
   itself; core.css only has the mobile override, not the base layout. ── */
.nav-r-cs { display: flex; align-items: center; gap: 16px; justify-self: end; }
body.page-resume .cs-theme-toggle {
  background: none; border: 0.5px solid rgba(255,255,255,0.22); color: rgba(255,255,255,0.5);
  height: 32px; border-radius: 100px; cursor: pointer; display: flex; align-items: center;
  justify-content: center; gap: 6px; line-height: 1;
  transition: color 0.2s, border-color 0.2s, background 0.2s; padding: 0 12px;
}
body.page-resume .cs-theme-toggle svg { transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.2s; display: block; }
body.page-resume .cs-theme-toggle:hover { color: rgba(255,255,255,0.9); border-color: rgba(255,255,255,0.5); }
body.page-resume .cs-theme-toggle:hover svg { transform: rotate(20deg) scale(1.15); }
@keyframes rs-spin-in {
  from { transform: rotate(-90deg) scale(0.6); opacity: 0; }
  to   { transform: rotate(0deg)  scale(1);   opacity: 1; }
}
body.page-resume .cs-theme-toggle.spin svg { animation: rs-spin-in 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; }
body.page-resume.theme-light .nc { color: var(--ink) !important; border-color: var(--bord2) !important; }
body.page-resume.theme-light .nc:hover { background: var(--bg2) !important; color: var(--ink) !important; }
body.page-resume.theme-light .cs-theme-toggle { border-color: rgba(30,28,24,0.22); color: rgba(30,28,24,0.5); }
body.page-resume.theme-light .cs-theme-toggle:hover { color: rgba(30,28,24,0.9); border-color: rgba(30,28,24,0.5); }

/* ── Page head + controls ── */
.rs-wrap { max-width: 1000px; margin: 0 auto; padding: 56px 24px 100px; }
.rs-head { max-width: 640px; margin-bottom: 32px; }
.rs-eyebrow {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 12px;
}
.rs-title {
  font-family: var(--serif); font-weight: 300; font-size: clamp(30px, 4.4vw, 46px);
  letter-spacing: -0.02em; line-height: 1.05; color: var(--ink); margin: 0 0 12px;
}
.rs-title em { font-style: normal; font-weight: inherit; color: inherit; }
.rs-sub { font-family: var(--mono); font-size: 13px; line-height: 1.7; color: var(--ink2); max-width: 560px; }

.rs-controls {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px;
  margin-bottom: 32px; padding-bottom: 24px; border-bottom: 1px solid var(--border);
}
.rs-toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 100px; padding: 4px; gap: 4px; }
.rs-toggle-btn {
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--muted); background: none; border: none; border-radius: 100px; padding: 9px 20px;
  cursor: pointer; transition: background 0.2s, color 0.2s;
}
.rs-toggle-btn.active { background: var(--ink); color: var(--bg); }
.rs-toggle-btn:not(.active):hover { color: var(--ink); }
.rs-download-btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--ink); background: none; border: 1px solid var(--bord2); border-radius: 100px;
  padding: 10px 20px; cursor: pointer; transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.rs-download-btn:hover { border-color: var(--ink); color: var(--ink); }

.rs-tailored-note {
  display: flex; align-items: center; gap: 12px; margin: -20px 0 24px;
  font-family: var(--mono); font-size: 11px; color: var(--muted);
}
.rs-tailored-reset {
  font-family: var(--mono); font-size: 11px; text-decoration: underline; text-underline-offset: 2px;
  color: var(--ink2); background: none; border: none; cursor: pointer; padding: 0;
}
.rs-tailored-reset:hover { color: var(--ink); }

.rs-sheet-stage { display: flex; justify-content: center; }
.rs-sheet {
  display: none; width: 100%; max-width: 800px; aspect-ratio: 8.5 / 11;
  background: #fff; color: #1e1c18; box-shadow: 0 30px 80px rgba(0,0,0,0.4);
  overflow: hidden; position: relative;
}
.rs-sheet.rs-active { display: block; }

/* ── Standard resume: plain, ATS-safe, single column, no color ── */
.rs-standard {
  font-family: Georgia, 'Times New Roman', Times, serif; padding: 42px 50px; color: #1a1a1a;
  overflow-y: auto;
}
.rsx-head { text-align: center; margin-bottom: 14px; }
.rsx-name { font-size: 22px; font-weight: 700; letter-spacing: 0.02em; margin-bottom: 5px; }
.rsx-contact { font-size: 10.5px; color: #333; }
.rsx-contact span { margin: 0 8px; }
.rsx-section-title {
  font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  border-bottom: 1.2px solid #1a1a1a; padding-bottom: 2px; margin: 11px 0 6px;
}
.rsx-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 1px; }
.rsx-org { font-size: 11.5px; font-weight: 700; }
.rsx-role { font-size: 11px; font-style: italic; }
.rsx-dates { font-size: 10px; white-space: nowrap; color: #333; }
.rsx-block { margin-bottom: 6px; }
.rsx-bullets { margin: 2px 0 0; padding-left: 18px; }
.rsx-bullets li { font-size: 10.5px; line-height: 1.3; margin-bottom: 1.5px; }
.rsx-skills-row { font-size: 10.5px; line-height: 1.45; margin-bottom: 2px; }
.rsx-skills-label { font-weight: 700; }
.rsx-awards { margin: 2px 0 0; padding-left: 18px; }
.rsx-awards li { font-size: 10.5px; line-height: 1.35; margin-bottom: 1.5px; }

/* ── Creative resume: site's own case-study visual language ── */
.rs-creative {
  font-family: var(--serif); padding: 48px 52px; color: #1e1c18; background: #fdfcfa;
  overflow-y: auto; position: relative;
}
.rs-creative::before {
  content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0.3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.3'/%3E%3C/svg%3E");
  background-size: 180px 180px; opacity: 0.14;
}
.rs-creative > * { position: relative; z-index: 1; }
.rsc-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 30px; padding-bottom: 20px; }
.rsc-head-l { display: flex; align-items: center; gap: 12px; }
.rsc-logo { height: 34px; width: auto; object-fit: contain; display: block; }
.rsc-name { font-family: var(--serif); font-weight: 500; font-size: 22px; letter-spacing: -0.01em; line-height: 1.05; color: #211a13; margin-bottom: 3px; }
.rsc-headline { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(30,28,24,0.5); }
.rsc-contact { text-align: right; font-family: var(--mono); font-size: 9px; line-height: 1.6; color: rgba(30,28,24,0.55); white-space: nowrap; }
.rsc-section-title {
  font-family: var(--mono); font-size: 9.5px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: #211a13; border-bottom: 1px solid rgba(33,26,19,0.25); padding-bottom: 5px; margin-bottom: 16px;
}
.rsc-section { margin-bottom: 28px; }
.rsc-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.rsc-org { font-family: var(--serif); font-size: 10.5px; font-weight: 700; color: #211a13; }
.rsc-role { font-family: var(--serif); font-size: 9.5px; color: rgba(30,28,24,0.6); }
.rsc-dates { font-family: var(--mono); font-size: 9px; letter-spacing: 0.01em; color: rgba(30,28,24,0.45); white-space: nowrap; }
.rsc-block { margin-bottom: 20px; }
.rsc-bullets { margin: 6px 0 0; padding-left: 13px; }
.rsc-bullets li { font-family: var(--serif); font-size: 9.5px; line-height: 1.6; color: rgba(30,28,24,0.7); margin-bottom: 6px; }
.rsc-skills-text { font-family: var(--serif); font-size: 9.5px; line-height: 1.9; color: rgba(30,28,24,0.7); }
.rsc-awards { margin: 0; padding-left: 13px; }
.rsc-awards li { font-family: var(--serif); font-size: 9.5px; line-height: 1.7; color: rgba(30,28,24,0.7); margin-bottom: 7px; }
.rsc-awards li strong { color: #211a13; }
.rsc-cols { display: flex; gap: 26px; align-items: flex-start; }
.rsc-col-main { flex: 1.55; min-width: 0; }
.rsc-col-side { flex: 1; min-width: 0; }

@media (max-width: 700px) {
  .rs-controls { flex-direction: column; align-items: flex-start; }
  .rsc-cols { flex-direction: column; align-items: stretch; }
  .rsc-head { flex-direction: column; align-items: flex-start; }
  .rsc-contact { text-align: left; }
}

/* ── Print: exactly one US Letter page, only the active sheet ── */
@page { size: 8.5in 11in; margin: 0; }
@media print {
  .nav, .site-footer, .rs-head, .rs-controls, .rs-tailored-note { display: none !important; }
  html, body, .rs-wrap { min-height: 0 !important; height: auto !important; background: #fff !important; }
  .rs-wrap { padding: 0; max-width: none; }
  .rs-sheet-stage { display: block; }
  .rs-sheet {
    display: none !important; box-shadow: none; width: 8.5in; height: 11in; aspect-ratio: auto;
    max-width: none; min-height: 0; margin: 0; overflow: hidden;
  }
  /* Hard-capped to exactly one 8.5x11 page - anything taller clips at the
     page edge instead of spilling onto a second printed page. */
  .rs-sheet.rs-active { display: block !important; }
  .rs-standard, .rs-creative { overflow: hidden !important; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
