:root {
  color-scheme: dark;
  --ink: #050505;
  --ink-soft: #101111;
  --paper: #f1f1ef;
  --paper-bright: #fafaf8;
  --silver: #aeb3b5;
  --muted: #868a8b;
  --line: rgba(255, 255, 255, 0.19);
  --line-dark: rgba(5, 5, 5, 0.18);
  --white: #fff;
  --content-pad: clamp(1.25rem, 4vw, 4.5rem);
  --sans: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --serif: Georgia, "Times New Roman", serif;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--ink);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

body.is-locked {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
select {
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.75rem 1rem;
  background: var(--paper);
  color: var(--ink);
  transform: translateY(-160%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.eyebrow {
  margin: 0;
  color: var(--silver);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.19em;
  line-height: 1.2;
  text-transform: uppercase;
}

.button {
  min-height: 3.25rem;
  border: 1px solid transparent;
  border-radius: 0;
  padding: 0.85rem 1.25rem;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  line-height: 1.1;
  text-transform: uppercase;
  transition: background 180ms ease, color 180ms ease, border-color 180ms ease;
}

.button-primary {
  background: var(--ink);
  color: var(--white);
}

.button-primary:hover {
  background: #292a2a;
}

.button-quiet {
  border-color: currentColor;
  background: transparent;
  color: inherit;
}

.button-quiet:hover {
  background: rgba(128, 128, 128, 0.12);
}

/* Public landing */

.page-home {
  overflow-x: hidden;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  padding: 1.4rem var(--content-pad);
  pointer-events: none;
}

.site-header a {
  pointer-events: auto;
}

.header-home {
  display: inline-flex;
  gap: 0.7rem;
  align-items: center;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.15em;
}

.header-mark {
  width: 1.65rem;
  height: 1.65rem;
  background: url("../images/favicon.png") center / contain no-repeat;
  opacity: 0.75;
}

.header-actions {
  display: flex;
  gap: clamp(1rem, 2.5vw, 2.5rem);
  align-items: center;
}

.header-actions a,
.portal-header nav a {
  position: relative;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.header-actions a::after,
.portal-header nav a::after {
  position: absolute;
  right: 0;
  bottom: -0.45rem;
  left: 0;
  height: 1px;
  background: currentColor;
  content: "";
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 180ms ease;
}

.header-actions a:hover::after,
.portal-header nav a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.landing {
  display: grid;
  min-height: 100svh;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.landing-copy {
  position: relative;
  z-index: 2;
  display: flex;
  min-height: 100svh;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(6.5rem, 11vh, 8.5rem) var(--content-pad) 1.5rem;
  background: var(--ink);
}

.copy-inner {
  display: flex;
  width: min(100%, 36rem);
  flex: 1;
  flex-direction: column;
  justify-content: center;
  margin: 0 auto;
}

.brand-lockup {
  width: clamp(16rem, 30vw, 27rem);
  height: auto;
  margin-bottom: clamp(2.75rem, 7vh, 5.5rem);
}

.thesis h1 {
  max-width: 30rem;
  margin: 1rem 0 1.35rem;
  color: var(--paper-bright);
  font-family: var(--sans);
  font-size: clamp(2rem, 3vw, 3.15rem);
  font-style: normal;
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1.02;
}

.home-description {
  max-width: 35rem;
  margin: 0;
  color: rgba(255, 255, 255, 0.61);
  font-size: clamp(0.98rem, 1.15vw, 1.08rem);
  line-height: 1.75;
}

.home-paths {
  display: grid;
  margin-top: clamp(2.4rem, 6vh, 4.75rem);
  border-top: 1px solid var(--line);
}

.path-link {
  display: grid;
  min-height: 4.65rem;
  grid-template-columns: 2rem 1fr auto;
  gap: 0.85rem;
  align-items: center;
  border-bottom: 1px solid var(--line);
  transition: padding 180ms ease, background 180ms ease;
}

.path-link:hover {
  padding-right: 0.6rem;
  padding-left: 0.6rem;
  background: rgba(255, 255, 255, 0.04);
}

.path-number {
  align-self: start;
  padding-top: 1.18rem;
  color: var(--muted);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.path-copy {
  display: grid;
  gap: 0.15rem;
}

.path-copy strong {
  font-size: 0.78rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.path-copy small {
  color: var(--muted);
  font-size: 0.8rem;
}

.path-link .arrow {
  color: var(--silver);
  font-size: 1rem;
}

.landing-footer {
  display: flex;
  justify-content: space-between;
  padding-top: 1.2rem;
  color: rgba(255, 255, 255, 0.42);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.landing-image {
  position: sticky;
  top: 0;
  overflow: hidden;
  min-height: 100svh;
  background: #4f5150;
  --reveal-x: 50%;
  --reveal-y: 50%;
}

.landing-image > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 55% center;
}

.image-base {
  filter: contrast(1.02);
}

.image-reveal {
  opacity: 0;
  -webkit-mask-image: radial-gradient(circle 13rem at var(--reveal-x) var(--reveal-y), #000 0, rgba(0, 0, 0, 0.92) 48%, transparent 100%);
  mask-image: radial-gradient(circle 13rem at var(--reveal-x) var(--reveal-y), #000 0, rgba(0, 0, 0, 0.92) 48%, transparent 100%);
  transition: opacity 240ms ease;
}

.landing-image.is-engaged .image-reveal {
  opacity: 0.9;
}

.image-wash {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(5, 5, 5, 0.2), transparent 28%),
    linear-gradient(0deg, rgba(5, 5, 5, 0.38), transparent 35%);
  pointer-events: none;
}

/* Shared portal header */

.portal-header {
  position: relative;
  z-index: 10;
  display: flex;
  height: 6.5rem;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem var(--content-pad);
  border-bottom: 1px solid var(--line);
  background: var(--ink);
}

.portal-brand img {
  width: 11rem;
  height: auto;
}

.portal-header nav {
  display: flex;
  gap: 2rem;
}

/* Opportunity intake */

.page-portal {
  min-height: 100svh;
}

.portal-layout {
  display: grid;
  min-height: calc(100svh - 6.5rem);
  grid-template-columns: minmax(19rem, 37%) minmax(0, 1fr);
}

.portal-intro {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(3rem, 7vw, 7rem) var(--content-pad);
  border-right: 1px solid var(--line);
  background:
    linear-gradient(rgba(5, 5, 5, 0.84), rgba(5, 5, 5, 0.94)),
    url("../images/raquette-river-potsdam-ny-mono.webp") center / cover;
}

.portal-intro h1,
.access-panel h1,
.ledger-title-row h1,
.admin-heading h1 {
  margin: 1rem 0 1.4rem;
  color: var(--paper-bright);
  font-family: var(--serif);
  font-size: clamp(3rem, 6vw, 6.5rem);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.055em;
  line-height: 0.9;
}

.portal-intro > p:not(.eyebrow) {
  max-width: 29rem;
  margin: 0;
  color: rgba(255, 255, 255, 0.62);
  font-size: 1.05rem;
  line-height: 1.7;
}

.portal-note {
  display: grid;
  gap: 0.4rem;
  margin-top: clamp(4rem, 11vh, 8rem);
  padding-top: 1.2rem;
  border-top: 1px solid var(--line);
}

.portal-note span {
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.portal-note strong {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-style: italic;
  font-weight: 400;
}

.form-shell {
  min-width: 0;
  padding: clamp(2rem, 5vw, 5.5rem) clamp(1.5rem, 6vw, 7rem);
  background: var(--paper);
  color: var(--ink);
}

.form-progress {
  display: grid;
  grid-template-columns: auto minmax(4rem, 1fr) auto;
  gap: 1rem;
  align-items: center;
  margin-bottom: clamp(3rem, 7vh, 5.5rem);
  color: #5f6262;
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.13em;
}

.progress-track {
  position: relative;
  display: block;
  overflow: hidden;
  height: 1px;
  background: var(--line-dark);
}

.progress-track i {
  position: absolute;
  inset: 0 auto 0 0;
  display: block;
  width: var(--progress);
  background: var(--ink);
  transition: width 260ms ease;
}

#opportunity-form {
  width: min(100%, 55rem);
  margin: 0 auto;
}

.form-step {
  min-width: 0;
  margin: 0;
  border: 0;
  padding: 0;
}

.form-step[hidden] {
  display: none;
}

.form-step h2,
.submission-success h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.25rem, 4.8vw, 4.7rem);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 1;
}

.step-intro {
  margin: 0.75rem 0 clamp(2.2rem, 5vh, 3.5rem);
  color: #626565;
  font-size: 1rem;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.6rem 1.25rem;
}

.field {
  display: grid;
  gap: 0.55rem;
}

.field-wide {
  grid-column: 1 / -1;
}

.field > span,
.detail-actions label > span,
.admin-toolbar label > span {
  color: #565959;
  font-size: 0.69rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.field input,
.field select,
.field textarea,
.detail-actions select,
.admin-toolbar select {
  width: 100%;
  border: 0;
  border-bottom: 1px solid rgba(5, 5, 5, 0.36);
  border-radius: 0;
  padding: 0.6rem 0 0.8rem;
  background: transparent;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.4;
}

.field textarea {
  min-height: 6rem;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--ink);
  outline: 0;
}

.field input[aria-invalid="true"],
.field select[aria-invalid="true"],
.field textarea[aria-invalid="true"] {
  border-color: #8a2d25;
}

.field small {
  color: #777a7a;
  font-size: 0.75rem;
}

.file-drop {
  position: relative;
  display: grid;
  min-height: 10.5rem;
  place-items: center;
  align-content: center;
  gap: 0.35rem;
  border: 1px dashed rgba(5, 5, 5, 0.38);
  padding: 1.5rem;
  text-align: center;
  transition: background 180ms ease, border-color 180ms ease;
}

.file-drop:hover,
.file-drop.is-dragging {
  border-color: var(--ink);
  background: rgba(5, 5, 5, 0.04);
}

.file-drop input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

.file-icon {
  font-size: 1.8rem;
  font-weight: 300;
}

.file-drop strong {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.file-drop small {
  color: #747777;
  font-size: 0.76rem;
}

.file-list {
  display: grid;
  gap: 0.5rem;
  margin: -0.75rem 0 0;
  padding: 0;
  list-style: none;
}

.file-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--line-dark);
  color: #4f5252;
  font-size: 0.8rem;
}

.file-list button {
  border: 0;
  background: transparent;
  color: #5e6161;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.turnstile-wrap {
  min-height: 2rem;
}

.turnstile-wrap p {
  margin: 0;
  color: #777a7a;
  font-size: 0.75rem;
}

.consent {
  display: flex;
  gap: 0.8rem;
  align-items: flex-start;
  color: #444747;
  font-size: 0.82rem;
}

.consent input {
  width: 1rem;
  height: 1rem;
  flex: 0 0 auto;
  margin-top: 0.12rem;
  accent-color: var(--ink);
}

.legal {
  margin: 0;
  color: #747777;
  font-size: 0.7rem;
  line-height: 1.55;
}

.form-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  margin-top: clamp(2.5rem, 6vh, 4rem);
  padding-top: 1.3rem;
  border-top: 1px solid var(--line-dark);
}

.form-error {
  margin-top: 1.5rem;
  border-left: 2px solid #8a2d25;
  padding: 0.7rem 1rem;
  background: rgba(138, 45, 37, 0.08);
  color: #74261f;
  font-size: 0.84rem;
}

.submission-success {
  display: grid;
  min-height: 27rem;
  place-content: center;
  text-align: center;
}

.submission-success[hidden] {
  display: none;
}

.submission-success p:not(.eyebrow) {
  max-width: 30rem;
  color: #5f6262;
}

/* Access */

.access-layout {
  display: grid;
  min-height: calc(100svh - 6.5rem);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.access-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(3rem, 8vw, 8rem);
}

.access-panel > p:not(.eyebrow) {
  max-width: 31rem;
  margin: 0 0 2.25rem;
  color: rgba(255, 255, 255, 0.62);
  font-size: 1.02rem;
  line-height: 1.75;
}

.access-button {
  display: flex;
  width: min(100%, 31rem);
  align-items: center;
  justify-content: space-between;
  border-color: rgba(255, 255, 255, 0.45);
  background: var(--paper);
  color: var(--ink);
}

.access-button:hover {
  background: var(--white);
}

.access-help {
  display: block;
  max-width: 31rem;
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.72rem;
}

.access-image {
  position: relative;
  overflow: hidden;
  border-left: 1px solid var(--line);
}

.access-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1) contrast(1.05) brightness(0.72);
}

.access-image::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(5, 5, 5, 0.05), rgba(5, 5, 5, 0.55));
  content: "";
}

.access-image-label {
  position: absolute;
  z-index: 2;
  right: 2rem;
  bottom: 1.5rem;
  left: 2rem;
  display: flex;
  justify-content: space-between;
  color: rgba(255, 255, 255, 0.63);
  font-size: 0.61rem;
  font-weight: 700;
  letter-spacing: 0.14em;
}

/* Investor ledger */

.ledger-header {
  display: flex;
  height: 6.5rem;
  align-items: center;
  justify-content: space-between;
  padding: 1rem var(--content-pad);
  border-bottom: 1px solid var(--line);
}

.ledger-brand img {
  width: 10rem;
  height: auto;
}

.ledger-identity {
  display: grid;
  gap: 0.15rem;
  text-align: right;
}

.ledger-identity span:first-child {
  font-size: 0.69rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ledger-identity span:last-child {
  color: var(--muted);
  font-size: 0.74rem;
}

.ledger-main,
.admin-main {
  width: min(100%, 100rem);
  margin: 0 auto;
  padding: clamp(2.5rem, 6vw, 6rem) var(--content-pad) 5rem;
}

.ledger-title-row,
.admin-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 0.72fr);
  gap: 3rem;
  align-items: end;
  padding-bottom: clamp(2rem, 5vh, 4rem);
}

.ledger-title-row h1,
.admin-heading h1 {
  margin-bottom: 0;
  font-size: clamp(3rem, 6vw, 6rem);
}

.ledger-intro {
  max-width: 34rem;
  margin: 0;
  padding-bottom: 0.45rem;
  color: rgba(255, 255, 255, 0.58);
  line-height: 1.7;
}

.ledger-tabs {
  display: flex;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.ledger-tabs button {
  position: relative;
  min-height: 4.5rem;
  flex: 1;
  border: 0;
  border-right: 1px solid var(--line);
  padding: 1rem 1.2rem;
  background: transparent;
  color: var(--muted);
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-align: left;
  text-transform: uppercase;
}

.ledger-tabs button:last-child {
  border-right: 0;
}

.ledger-tabs button[aria-selected="true"] {
  background: rgba(255, 255, 255, 0.055);
  color: var(--paper);
}

.ledger-tabs button span {
  float: right;
  color: var(--muted);
}

.ledger-status,
.admin-status {
  padding: 2rem 0;
  color: var(--muted);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ledger-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.ledger-card {
  display: flex;
  min-height: 24rem;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 1.5rem;
  background: var(--ink-soft);
}

.ledger-card-top {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.ledger-card h2 {
  margin: 0 0 0.5rem;
  font-family: var(--serif);
  font-size: 2rem;
  font-style: italic;
  font-weight: 400;
  line-height: 1.05;
}

.ledger-card-location,
.ledger-card-summary,
.card-location,
.card-summary,
.card-period {
  color: var(--muted);
  font-size: 0.86rem;
}

.ledger-card-summary,
.card-summary {
  margin-top: 1rem;
  line-height: 1.6;
}

.card-period {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.document-none {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.ledger-documents {
  display: grid;
  gap: 0.45rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.ledger-documents a {
  display: flex;
  justify-content: space-between;
  color: rgba(255, 255, 255, 0.77);
  font-size: 0.72rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.empty-ledger {
  display: grid;
  min-height: 24rem;
  place-content: center;
  padding: 3rem 1rem;
  border-bottom: 1px solid var(--line);
  text-align: center;
}

.empty-ledger[hidden] {
  display: none;
}

.empty-ledger > span {
  color: #525454;
  font-family: var(--serif);
  font-size: 4rem;
  font-style: italic;
}

.empty-ledger h2 {
  max-width: 31rem;
  margin: 0 auto;
  font-family: var(--serif);
  font-size: 1.65rem;
  font-style: italic;
  font-weight: 400;
}

.empty-ledger p {
  color: var(--muted);
  font-size: 0.86rem;
}

/* Admin */

.admin-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.admin-stats span {
  display: grid;
  gap: 0.2rem;
  border-right: 1px solid var(--line);
  padding: 1rem;
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.admin-stats span:last-child {
  border-right: 0;
}

.admin-stats strong {
  color: var(--paper);
  font-family: var(--serif);
  font-size: 2rem;
  font-style: italic;
  font-weight: 400;
}

.admin-toolbar {
  display: flex;
  align-items: end;
  justify-content: space-between;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.admin-toolbar label {
  display: grid;
  gap: 0.25rem;
}

.admin-toolbar label > span {
  color: var(--muted);
}

.admin-toolbar select {
  min-width: 13rem;
  border-color: var(--line);
  color: var(--paper);
}

.submission-table-wrap {
  overflow-x: auto;
}

.submission-table-wrap[hidden] {
  display: none;
}

.submission-table {
  width: 100%;
  border-collapse: collapse;
}

.submission-table th,
.submission-table td {
  border-bottom: 1px solid var(--line);
  padding: 1rem 0.75rem;
  text-align: left;
}

.submission-table th {
  color: var(--muted);
  font-size: 0.63rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.submission-table td {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.82rem;
}

.submission-table tr {
  transition: background 160ms ease;
}

.submission-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.04);
}

.submission-table button {
  border: 0;
  background: transparent;
  color: var(--paper);
  font-weight: 700;
  text-align: left;
}

.status-pill {
  display: inline-flex;
  border: 1px solid var(--line);
  padding: 0.28rem 0.5rem;
  color: var(--silver);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.submission-detail {
  position: fixed;
  z-index: 30;
  top: 0;
  right: 0;
  overflow-y: auto;
  width: min(100%, 42rem);
  height: 100svh;
  border-left: 1px solid var(--line);
  padding: clamp(2rem, 5vw, 4rem);
  background: #111212;
  box-shadow: -2rem 0 5rem rgba(0, 0, 0, 0.45);
}

.submission-detail[hidden] {
  display: none;
}

.detail-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  border: 0;
  background: transparent;
  color: var(--paper);
  font-size: 2rem;
  font-weight: 200;
}

.submission-detail h2 {
  margin: 1rem 0 2rem;
  font-family: var(--serif);
  font-size: 2.7rem;
  font-style: italic;
  font-weight: 400;
  line-height: 1;
}

.detail-content {
  display: grid;
  gap: 1.4rem;
}

.detail-list {
  display: grid;
  gap: 0;
  margin: 0;
}

.detail-list > div {
  display: grid;
  gap: 0.3rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--line);
}

.detail-list dt {
  color: var(--muted);
  font-size: 0.63rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.detail-list dd {
  margin: 0;
  color: rgba(255, 255, 255, 0.76);
  white-space: pre-wrap;
}

.detail-files h3 {
  margin: 0.5rem 0;
  font-family: var(--serif);
  font-size: 1.35rem;
  font-style: italic;
  font-weight: 400;
}

.detail-block {
  display: grid;
  gap: 0.3rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
}

.detail-block span {
  color: var(--muted);
  font-size: 0.63rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.detail-block p {
  margin: 0;
  color: rgba(255, 255, 255, 0.76);
  white-space: pre-wrap;
}

.detail-files {
  display: grid;
  gap: 0.55rem;
}

.detail-files a {
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  padding: 0.6rem 0;
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.detail-actions {
  display: flex;
  gap: 1rem;
  align-items: end;
  justify-content: space-between;
  margin-top: 2.5rem;
}

.detail-actions label {
  display: grid;
  flex: 1;
  gap: 0.3rem;
}

.detail-actions label > span {
  color: var(--muted);
}

.detail-actions select {
  color: var(--paper);
}

.detail-actions .button-primary {
  border-color: rgba(255, 255, 255, 0.36);
  background: var(--paper);
  color: var(--ink);
}

/* Responsive */

@media (max-width: 900px) {
  .site-header {
    position: absolute;
  }

  .header-home span:last-child {
    display: none;
  }

  .landing {
    grid-template-columns: 1fr;
  }

  .landing-copy {
    min-height: 100svh;
  }

  .landing-image {
    position: relative;
    min-height: 72svh;
  }

  .copy-inner {
    width: 100%;
  }

  .brand-lockup {
    width: min(22rem, 78vw);
  }

  .portal-layout,
  .access-layout {
    grid-template-columns: 1fr;
  }

  .portal-intro {
    min-height: 35rem;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .portal-intro h1,
  .access-panel h1 {
    font-size: clamp(3.3rem, 13vw, 6.5rem);
  }

  .access-panel {
    min-height: 36rem;
  }

  .access-image {
    min-height: 50svh;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .ledger-title-row,
  .admin-heading {
    grid-template-columns: 1fr;
  }

  .ledger-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .site-header,
  .portal-header,
  .ledger-header {
    padding-right: 1.1rem;
    padding-left: 1.1rem;
  }

  .site-header {
    align-items: flex-start;
  }

  .header-actions {
    display: grid;
    gap: 0.7rem;
    justify-items: end;
  }

  .header-actions a,
  .portal-header nav a {
    font-size: 0.65rem;
  }

  .landing-copy {
    min-height: 100svh;
    padding: 6.5rem 1.25rem 1.25rem;
  }

  .brand-lockup {
    margin-bottom: 3rem;
  }

  .thesis h1 {
    font-size: clamp(2.1rem, 8vw, 2.9rem);
  }

  .home-description {
    font-size: 0.96rem;
    line-height: 1.62;
  }

  .path-copy small {
    display: none;
  }

  .portal-header {
    height: 5.75rem;
  }

  .portal-brand img,
  .ledger-brand img {
    width: 8.4rem;
  }

  .portal-header nav {
    gap: 1rem;
  }

  .portal-header nav a:first-child {
    display: none;
  }

  .portal-layout,
  .access-layout {
    min-height: calc(100svh - 5.75rem);
  }

  .portal-intro {
    min-height: 32rem;
    padding: 4rem 1.25rem;
  }

  .form-shell {
    padding: 2rem 1.25rem 3rem;
  }

  .form-progress {
    grid-template-columns: 1fr auto;
    margin-bottom: 3rem;
  }

  .progress-track {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .field-grid {
    grid-template-columns: 1fr;
  }

  .field-wide {
    grid-column: auto;
  }

  .form-actions {
    position: sticky;
    bottom: 0;
    z-index: 4;
    margin-right: -1.25rem;
    margin-left: -1.25rem;
    padding: 1rem 1.25rem calc(1rem + env(safe-area-inset-bottom));
    background: rgba(241, 241, 239, 0.97);
    backdrop-filter: blur(12px);
  }

  .form-actions .button {
    flex: 1;
  }

  .access-panel {
    min-height: calc(100svh - 5.75rem);
    padding: 3rem 1.25rem;
  }

  .access-image {
    min-height: 42svh;
  }

  .ledger-header {
    height: 5.75rem;
  }

  .ledger-identity span:first-child {
    font-size: 0.62rem;
  }

  .ledger-identity span:last-child {
    max-width: 9rem;
    overflow: hidden;
    font-size: 0.68rem;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .ledger-main,
  .admin-main {
    padding: 2.5rem 1.1rem 4rem;
  }

  .ledger-title-row h1,
  .admin-heading h1 {
    font-size: 3.4rem;
  }

  .ledger-tabs {
    display: grid;
  }

  .ledger-tabs button {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .ledger-tabs button:last-child {
    border-bottom: 0;
  }

  .ledger-grid {
    grid-template-columns: 1fr;
  }

  .ledger-card {
    min-height: 20rem;
  }

  .admin-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .admin-stats span {
    padding: 0.7rem;
  }

  .admin-toolbar {
    gap: 1rem;
  }

  .admin-toolbar .button {
    min-height: 2.8rem;
    padding: 0.7rem;
  }

  .submission-table {
    min-width: 48rem;
  }

  .submission-detail {
    width: 100%;
    padding: 4rem 1.25rem 2rem;
  }

  .detail-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .detail-actions .button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
