/* Tor Guide — field-station stationery. Cream desk, ochre sleeves, pine ink. */
:root {
  --paper: #f4efe6;
  --peach: #f3ddc8;
  --sage: #c5d1b8;
  --ochre: #c9a44a;
  --ochre-deep: #a88838;
  --pine: #1e3a2a;
  --pine-mid: #2e473b;
  --stamp: #b54a32;
  --graphite: #2c2a26;
  --navy: #243a6b;
  --measure: 38.5rem;
  --font-label: "Archivo Narrow", "Arial Narrow", "Helvetica Condensed", sans-serif;
  --font-title: "EB Garamond", "Palatino Linotype", "Book Antiqua", serif;
  --font-mono: "Special Elite", "Courier New", Courier, monospace;
  --font-script: "Caveat", "Segoe Script", cursive;
}

*, *::before, *::after { box-sizing: border-box; }
html { font-size: 18px; }
body {
  margin: 0;
  background-color: var(--paper);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.07'/%3E%3C/svg%3E");
  color: var(--graphite);
  font-family: var(--font-title);
  line-height: 1.58;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--pine); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--stamp); }
h1, h2 {
  font-family: var(--font-title);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.18;
  color: var(--pine);
}
h1 { font-size: clamp(1.85rem, 3.4vw, 2.45rem); margin: 0.15em 0 0.55em; }
h2 { font-size: 1.28rem; margin: 1.6em 0 0.55em; border-bottom: 1px solid var(--pine); padding-bottom: 0.2em; }
h2 .roman {
  font-family: var(--font-label);
  letter-spacing: 0.14em;
  font-size: 0.78em;
  color: var(--stamp);
}
h3 {
  font-family: var(--font-label);
  font-size: 0.92rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pine-mid);
  margin: 1.2em 0 0.4em;
}
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1.1em; padding-left: 1.15em; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); border: 0;
}
.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--pine); color: var(--paper); padding: 0.4em 0.8em;
}
.skip-link:focus { left: 0; z-index: 30; }

.stamp-bar {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
  margin: 0;
  padding: 0.38rem 1.2rem;
  background: var(--pine);
  color: var(--paper);
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.mast {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1.2rem 0.6rem;
  border-bottom: 1px solid var(--ochre);
}
.brand { display: flex; gap: 0.7rem; align-items: center; text-decoration: none; color: var(--pine); }
.brand-stack { display: flex; flex-direction: column; }
.brand-kicker {
  font-family: var(--font-label);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.68rem;
  color: var(--stamp);
}
.brand-name {
  font-family: var(--font-title);
  font-size: 1.55rem;
  font-weight: 600;
}
.file-corner {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--graphite);
  margin: 0;
  transform: rotate(-2deg);
}
.nav-toggle {
  display: none;
  font-family: var(--font-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: var(--paper);
  border: 1px solid var(--pine);
  color: var(--pine);
  padding: 0.35rem 0.7rem;
}
.primary-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0;
  padding: 0 1.2rem;
  border-bottom: 2px solid var(--pine);
}
.primary-nav a {
  font-family: var(--font-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.78rem;
  text-decoration: none;
  padding: 0.55rem 0.7rem 0.45rem;
  color: var(--pine);
  border-right: 1px solid var(--sage);
}
.primary-nav a[aria-current="page"] {
  background: var(--sage);
  box-shadow: 0 3px 0 var(--ochre);
}
.primary-nav a.nav-plots {
  background: var(--peach);
  box-shadow: inset 0 -3px 0 var(--stamp);
  font-weight: 600;
}
.primary-nav a.nav-plots[aria-current="page"] {
  background: var(--sage);
  box-shadow: 0 3px 0 var(--stamp);
}

.desk {
  display: grid;
  grid-template-columns: 8.2rem minmax(0, 1fr) 13.5rem;
  gap: 1.1rem;
  align-items: start;
  padding: 1.4rem 1.2rem 2.4rem;
  max-width: 78rem;
  margin: 0 auto;
}
.sage-card {
  background: var(--sage);
  min-height: 14rem;
  padding: 2.4rem 0.55rem 0.8rem;
  box-shadow: 3px 5px 0 rgba(30, 58, 42, 0.12);
  transform: rotate(-3.2deg);
  position: relative;
}
.sage-card .card-spine {
  position: absolute;
  left: -0.15rem;
  top: 1.6rem;
  transform: rotate(-90deg);
  transform-origin: left top;
  font-family: var(--font-label);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.68rem;
  color: var(--pine);
  white-space: nowrap;
}
.sage-card .card-line {
  font-family: var(--font-label);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.68rem;
  border-bottom: 1px dotted var(--pine-mid);
  margin: 0 0 0.7rem;
  padding-bottom: 0.2rem;
}
.folder {
  background: var(--ochre);
  padding: 1.55rem 1.15rem 1.3rem;
  box-shadow: 6px 10px 0 rgba(30, 58, 42, 0.1);
  position: relative;
}
.folder-tab {
  position: absolute;
  top: -0.85rem;
  left: 1.4rem;
  width: 7.2rem;
  height: 0.9rem;
  background: var(--ochre-deep);
  clip-path: polygon(8% 0, 92% 0, 100% 100%, 0 100%);
}
.folder article {
  background: var(--paper);
  padding: 1.25rem 1.35rem 1.6rem;
  max-width: calc(var(--measure) + 2.4rem);
  box-shadow: 0 1px 0 rgba(44, 42, 38, 0.12);
}
.crumbs {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  margin: 0 0 0.7rem;
}
.form-row, .form-label {
  font-family: var(--font-label);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.7rem;
  color: var(--stamp);
}
.mono { font-family: var(--font-mono); letter-spacing: 0; text-transform: none; color: var(--graphite); }
.hat {
  font-style: italic;
  color: var(--pine-mid);
  max-width: var(--measure);
}

.slide-mount {
  margin: 0.6rem 0 1.3rem;
  background: #f7f7f5;
  border: 14px solid #f7f7f5;
  outline: 1px solid #cfcbc3;
  box-shadow: 4px 7px 0 rgba(44, 42, 38, 0.12);
  transform: rotate(-1.6deg);
  max-width: 36rem;
}
.slide-mount img { width: 100%; height: auto; filter: grayscale(0.35) contrast(1.12); }
.slide-caption {
  font-family: var(--font-script);
  color: var(--navy);
  font-size: 1.05rem;
  margin: 0.35rem 0.2rem 0.15rem;
  text-transform: lowercase;
}
.slide-mount::after {
  content: "This side toward screen";
  display: block;
  background: var(--stamp);
  color: var(--paper);
  font-family: var(--font-label);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.62rem;
  text-align: center;
  padding: 0.22rem 0.4rem;
  margin-top: 0.35rem;
}

.sheet-sec { max-width: var(--measure); }
.notice {
  border: 2px solid var(--stamp);
  padding: 0.7rem 0.85rem;
  margin: 0 0 1.1rem;
  background: var(--peach);
}
.notice .form-label { display: block; margin-bottom: 0.3rem; }
.voucher-block {
  border: 1px solid var(--pine);
  padding: 0.8rem 0.9rem;
  margin: 0 0 1.1rem;
  background: #f7f3ea;
}
.onion-list { list-style: none; padding: 0; margin: 0.4rem 0 0; }
.onion-list li { margin: 0 0 0.65rem; }
.kicker {
  display: block;
  font-family: var(--font-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.68rem;
  color: var(--ochre-deep);
}
code.onion {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  word-break: break-all;
  background: var(--sage);
  padding: 0.35rem 0.45rem;
  cursor: pointer;
}
code.onion.is-copied { outline: 2px solid var(--stamp); }
code.onion:hover { outline: 1px solid var(--pine); }

.plot-index {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin: 0 0 1.2rem;
  padding: 0;
  list-style: none;
}
.plot-index li {
  background: var(--peach);
  border: 1px solid var(--stamp);
  padding: 0.45rem 0.7rem;
  font-family: var(--font-label);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.85rem;
}
.plot-index li:nth-child(odd) { transform: rotate(-0.8deg); margin-right: 1.4rem; }
.plot-index li:nth-child(even) { transform: rotate(1.4deg); margin-left: 1.6rem; background: var(--sage); border-color: var(--pine); }
.plot-index a { display: block; color: inherit; text-decoration: none; }

.plot-stack { margin: 0.15rem 0 1.5rem; }
.plot-index--cards {
  gap: 0.75rem;
}
.plot-index--cards .plot-slip {
  padding: 0;
  text-transform: none;
  letter-spacing: 0;
  font-size: inherit;
  font-family: var(--font-title);
  overflow: hidden;
}
.plot-index--cards .plot-slip:nth-child(1) { transform: rotate(-1.2deg); margin-right: 2.4rem; }
.plot-index--cards .plot-slip:nth-child(2) { transform: rotate(1.5deg); margin-left: 1.9rem; }
.plot-index--cards .plot-slip:nth-child(3) { transform: rotate(-0.6deg); margin-right: 1.1rem; }
.plot-index--cards .plot-slip:nth-child(4) { transform: rotate(2.1deg); margin-left: 2.6rem; }
.plot-index--cards .plot-slip:nth-child(5) { transform: rotate(-1.8deg); margin-right: 1.7rem; }
.plot-index--cards .plot-slip:nth-child(6) { transform: rotate(0.9deg); margin-left: 0.8rem; }
.plot-index--cards .plot-slip:nth-child(7) { transform: rotate(-0.4deg); margin-right: 2.1rem; }
.plot-index--cards a {
  display: flex;
  align-items: stretch;
  gap: 0;
  color: inherit;
  text-decoration: none;
}
.plot-index--cards img {
  width: 9.2rem;
  height: 4.85rem;
  object-fit: cover;
  flex-shrink: 0;
  border-right: 1px solid var(--pine);
}
.plot-index--cards .plot-meta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0.45rem 0.8rem 0.5rem 0.75rem;
  min-width: 0;
}
.plot-index--cards .kicker {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--stamp);
  margin: 0 0 0.1rem;
}
.plot-index--cards .plot-name {
  font-family: var(--font-title);
  font-size: 1.22rem;
  line-height: 1.15;
  color: var(--pine);
  font-weight: 600;
}
.plot-index--cards .plot-line {
  font-size: 0.88rem;
  color: var(--graphite);
  margin-top: 0.12rem;
}
.plot-index--cards a:hover .plot-name { color: var(--stamp); }
.plot-index--cards a:focus-visible {
  outline: 2px solid var(--stamp);
  outline-offset: 2px;
}

.pad-plots {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  margin: 0 0 0.7rem;
}
.pad-plots .form-label { margin-bottom: 0.2rem; }
.pad-plots a {
  font-family: var(--font-label);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.78rem;
  text-decoration: none;
  color: var(--pine);
  border-bottom: 1px dotted var(--sage);
  padding: 0.12rem 0;
}
.pad-plots a:hover { color: var(--stamp); }

.cert {
  border: 2px double var(--stamp);
  background: var(--peach);
  padding: 0.8rem 1rem;
  margin: 0 1.2rem 1.2rem 0;
  transform: rotate(2.4deg);
  max-width: 22rem;
  font-family: var(--font-label);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 0.75rem;
}

.pad {
  background: var(--paper);
  border: 1px solid var(--pine-mid);
  border-top: 10px solid var(--stamp);
  padding: 0.85rem 0.8rem 2.4rem;
  box-shadow: 4px 6px 0 rgba(30, 58, 42, 0.08);
  transform: rotate(2.8deg);
  font-size: 0.92rem;
}
.pad-head {
  font-family: var(--font-title);
  font-variant: small-caps;
  letter-spacing: 0.12em;
  margin: 0 0 0.5rem;
  color: var(--pine);
}
.pad-rule {
  border-top: 1px solid var(--sage);
  height: 0;
  margin: 0.6rem 0;
}
.patch {
  width: 3.4rem;
  height: 3.4rem;
  margin-top: 1rem;
  border-radius: 50%;
  box-shadow: 0 0 0 3px var(--paper), 0 0 0 4px var(--pine);
}
.patch-pine {
  background: var(--pine-mid);
  position: relative;
}
.patch-pine::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 18%;
  width: 0;
  height: 0;
  border-left: 0.7rem solid transparent;
  border-right: 0.7rem solid transparent;
  border-bottom: 1.5rem solid var(--sage);
  transform: translateX(-50%);
}
.pencil {
  margin-top: 1.1rem;
  height: 0.42rem;
  background: #2a4a86;
  border-radius: 1px;
  position: relative;
}
.pencil::after {
  content: "";
  position: absolute;
  right: -0.55rem;
  top: -0.12rem;
  border-top: 0.32rem solid transparent;
  border-bottom: 0.32rem solid transparent;
  border-left: 0.55rem solid #d4a84a;
}

footer {
  border-top: 2px solid var(--pine);
  padding: 1.3rem 1.2rem 2rem;
  background: #efe8d8;
}
.foot-inner { max-width: 78rem; margin: 0 auto; }
.foot-brand {
  font-family: var(--font-label);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pine);
}
.foot-links { display: flex; flex-wrap: wrap; gap: 0.75rem 1.1rem; margin: 0.4rem 0 0.45rem; }
.foot-links a { font-family: var(--font-label); letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.8rem; }
.foot-plots {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.05rem;
  margin: 0 0 0.9rem;
}
.foot-plots a {
  font-family: var(--font-title);
  font-size: 1.05rem;
  color: var(--pine);
}
.disc { font-size: 0.92rem; max-width: 46rem; color: var(--pine-mid); }

@media (max-width: 900px) {
  .desk { grid-template-columns: 1fr; }
  .sage-card { display: none; }
  .pad { transform: none; max-width: 22rem; }
  .nav-toggle { display: inline-block; }
  .primary-nav { display: none; flex-direction: column; }
  .primary-nav.is-open { display: flex; }
  .primary-nav a { border-right: 0; border-bottom: 1px solid var(--sage); }
  .plot-index--cards .plot-slip { margin-left: 0 !important; margin-right: 0.4rem !important; }
  .plot-index--cards img { width: 6.4rem; height: 3.4rem; }
  .plot-index--cards .plot-name { font-size: 1.08rem; }
}
