/* ==================================================================
   THE DOCKET: the fighter profile (fighter.php) as one sheet of paper.
   ==================================================================
   Ported from the design mock-up (the-docket.html) with its class names kept,
   so the page can be checked against the mock-up element by element.

   EVERYTHING is under .docket. The mock-up styles html, body, *, h1, h2, h3,
   table, th, td and a directly, which on a page that already has a header,
   a footer and its own idea of what a heading looks like would restyle all of
   it. Nothing here can reach outside the sheet.

   The paper, the ink and the one accent colour are variables on .docket. The
   accent (--moral) is the fighter's alignment: it colours the seal on the photo
   and the win stamps. */

.docket {
  --moral: #ff2faf;
  --ink: #140c1e;
  --paper: #f5f4f7;
  --muted: #8a8496;
  --rule: #b9b4c2;
  --rule-soft: #d9ccb4;
  padding: 24px 0 56px;
  color: var(--ink);
  font-family: "Inter", "Segoe UI", sans-serif;
  line-height: 1.5;
}
.docket *,
.docket *::before,
.docket *::after { box-sizing: border-box; }

/* The site sets its own line-height directly on every paragraph, which beats
   the 1.5 this sheet inherits and made every block a few pixels taller than
   the design. Paragraphs take the sheet's instead. */
.docket p { line-height: inherit; }

/* Alignment, darkened for paper. The site's own colours (steel blue, tan, red,
   green) are chosen to glow on a dark page and are too faint on this one.
   A wrestler with no alignment set takes the sheet's default. */
.docket.is-face { --moral: #2b4a6b; }
.docket.is-tweener { --moral: #7a5a1e; }
.docket.is-heel  { --moral: #ff2faf; }

.docket .sheet {
  position: relative;
  overflow: hidden;
  /* The width of every page on the site, the Booking Office's included (this one number
     is the only place it is set). The page container, 80rem, holds it with room to spare. */
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 36px 32px;
  background: var(--paper);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.38);
  /* Any one word too long for its box breaks instead of spilling out of it:
     a hometown, a nickname or a move name is typed in by a person, and a
     single 40-letter word would otherwise widen the whole sheet on a phone. */
  overflow-wrap: anywhere;
}

/* The Transparent Full cut-out, ghosted behind the whole sheet. Multiplied
   into the paper at 16% so it reads as a watermark, and faded at both edges so
   it has no hard side. The cut-out has no background of its own, so only the
   figure shows. */
.docket .ghost {
  position: absolute;
  top: 12%;
  right: -2%;
  width: min(52%, 480px);
  height: 70%;
  object-fit: contain;
  object-position: center 8%;
  opacity: 0.16;
  filter: grayscale(1) contrast(1.2);
  mix-blend-mode: multiply;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 28% 70%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 28% 70%, transparent);
}

.docket .head,
.docket .id,
.docket .facts,
.docket .block,
.docket .end { position: relative; z-index: 1; }

/* ---- Head ---- */
.docket .head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--rule);
}
.docket .kicker {
  margin: 0;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 0.75rem;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.docket .kind {
  margin: 4px 0 0;
  font-family: "Inter", system-ui, sans-serif;
  font-style: italic;
  font-size: 1.05rem;
}
.docket .no {
  margin: 0;
  text-align: right;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.docket .no strong {
  display: block;
  margin-top: 2px;
  font-family: "Oswald", "Arial Narrow", sans-serif;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--ink);
}

/* ---- Name and photo ---- */
.docket .id {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 168px;
  gap: 28px;
  margin-top: 22px;
  align-items: start;
}
.docket .kick {
  margin: 0 0 8px;
  font-family: "Inter", system-ui, sans-serif;
  font-style: italic;
  font-size: 1.45rem;
}
.docket h1 {
  margin: 0;
  font-family: "Inter", system-ui, sans-serif;
  font-weight: 500;
  font-size: clamp(2.7rem, 6vw, 4.8rem);
  letter-spacing: -0.03em;
  line-height: 0.92;
  text-transform: none;
  color: var(--ink);
  overflow-wrap: anywhere;
}
.docket .aka {
  margin: 10px 0 0;
  font-family: "Inter", system-ui, sans-serif;
  font-style: italic;
  font-size: 1.15rem;
  color: #2a2236;
}

/* Dominions held: stamps, the same kind as the seal on the photo. */
.docket .holds { margin: 10px 0 0; }
.docket .stamp {
  display: inline-block;
  padding: 1px 6px;
  border: 2px solid var(--moral);
  color: var(--moral);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transform: rotate(-8deg);
}
.docket .holds .stamp {
  margin: 4px 10px 4px 0;
  padding: 3px 8px;
  transform: rotate(-3deg);
}
/* A fight result is a stamp too. Wins take the alignment colour; the rest are
   in plain ink so a win is the thing that stands out. */
.docket .stamp.is-loss,
.docket .stamp.is-draw {
  border-color: var(--muted);
  color: var(--muted);
}

.docket .mug-wrap { position: relative; margin-bottom: 22px; }
.docket .mug {
  /* Inline, as in the mock-up. That leaves the small gap under the photo that
     the spacing below it was set against; the site makes every image a block,
     which removes the gap and pulls the rest of the sheet up by 7px. */
  display: inline;
  width: 168px;
  height: 214px;
  object-fit: cover;
  object-position: center 12%;
  filter: grayscale(0.2) contrast(1.04);
  background: #d7cbb4;
}
.docket .seal {
  position: absolute;
  left: 8px;
  bottom: -16px;
  padding: 5px 8px;
  border: 3px solid var(--moral);
  color: var(--moral);
  background: rgba(245, 244, 247, 0.94);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transform: rotate(-8deg);
}

/* ---- The facts strip ---- */
.docket .facts {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px 12px;
  margin: 22px 0 0;
  padding: 14px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.docket .facts dt,
.docket h2,
.docket h3 {
  margin: 18px 0 8px;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.docket .facts dt { margin: 0; }
.docket .facts dd {
  margin: 3px 0 0;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 1.12rem;
}
/* Section headings keep the 18px above them that every other heading here
   has (the rule above). The mock-up's HTML file also has h2 { margin-top: 0 },
   which packs the sections tight against each other, but the screenshot that
   came with it has the roomier spacing, so that rule is left out. To get the
   tight version back, add  .docket h2 { margin-top: 0; }  here. */

/* ---- Sections ---- */
.docket .block { margin-top: 0; }
.docket .bio {
  max-width: 66ch;
  margin: 0;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 1.22rem;
  line-height: 1.55;
}
.docket .bio p { margin: 0 0 0.8em; font: inherit; }
.docket .bio p:last-child { margin-bottom: 0; }
.docket .bio ul,
.docket .bio ol { margin: 0 0 0.8em; padding-left: 1.3em; }

.docket .moves { list-style: none; margin: 0; padding: 0; }
.docket .moves li { margin: 0 0 14px; }
.docket .moves strong {
  display: block;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 1.35rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
.docket .moves span { display: block; margin-top: 3px; line-height: 1.45; }

.docket .ties p {
  display: grid;
  grid-template-columns: 7.5rem minmax(0, 1fr);
  gap: 10px;
  margin: 0 0 8px;
}
.docket .ties span {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Classified: the words are in the page from the start and covered by a bar,
   so revealing them is a visual change, not a fetch. It is a button so it can
   be reached and announced. The bar is as wide as the text under it, which is
   what makes it look like a real excision. */
.docket .redacted {
  display: inline-block;
  margin: 0;
  padding: 0 0.35em;
  border: 0;
  border-radius: 2px;
  background: var(--ink);
  color: transparent;
  font: inherit;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 1.12rem;
  text-align: left;
  cursor: pointer;
}
.docket .redacted:focus-visible { outline: 2px solid var(--moral); outline-offset: 3px; }
/* NOT disabled once revealed: a browser forces its own colour on a disabled
   button, which would grey the text just uncovered. Pointer events go off
   instead. */
.docket .redacted.is-revealed {
  background: transparent;
  color: var(--ink);
  padding: 0;
  cursor: default;
  pointer-events: none;
}

/* Threat assessment: the heat bar, ink on a paper track. */
.docket .threat { display: flex; align-items: center; gap: 12px; }
.docket .threat-label {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.docket .threat-bar {
  position: relative;
  flex: 1 1 auto;
  max-width: 22rem;
  height: 8px;
  background: var(--rule-soft);
}
.docket .threat-bar span {
  display: block;
  height: 100%;
  background: var(--moral);
}
.docket .threat-num {
  font-family: "Oswald", "Arial Narrow", sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.06em;
}

/* ---- The Book ---- */
.docket table { width: 100%; border-collapse: collapse; margin: 0; }
.docket th,
.docket td {
  text-align: left;
  vertical-align: baseline;
  padding: 10px 12px 10px 0;
  background: transparent;
}
.docket th {
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid var(--rule);
}
.docket td {
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: normal;
  text-transform: none;
  color: var(--ink);
  border-bottom: 1px solid var(--rule-soft);
}
.docket .stip { margin-left: 0.4em; color: var(--muted); }
.docket .dim { color: var(--muted); }
.docket .current { color: var(--moral); font-weight: 600; }

.docket .timeline { list-style: none; margin: 0; padding: 0; }
.docket .timeline li {
  display: flex;
  gap: 16px;
  padding: 8px 0;
  border-bottom: 1px solid var(--rule-soft);
}
.docket .timeline time { min-width: 7.2rem; color: var(--muted); }

.docket .end {
  margin: 28px 0 0;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.docket .quiet { margin: 0; color: var(--muted); }

/* ---- Links ----
   The site paints every link in its accent colour with a rule written as
   a:not(.btn):not(.nav-link):not(.apply-link):not(.wordmark), which is more
   specific than .docket a would be. Repeating that selector is how this beats
   it. On paper a link keeps the ink colour, and says it is a link when
   pointed at or reached by keyboard. */
.docket a:not(.btn):not(.nav-link):not(.apply-link):not(.wordmark) {
  color: inherit;
  text-decoration: none;
}
.docket a:not(.btn):not(.nav-link):not(.apply-link):not(.wordmark):hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.docket a:not(.btn):not(.nav-link):not(.apply-link):not(.wordmark):focus-visible {
  outline: 2px solid var(--moral);
  outline-offset: 2px;
}

/* ---- Narrow screens ---- */
@media (max-width: 800px) {
  .docket .sheet { padding: 22px 18px 28px; }
  /* minmax(0, 1fr) rather than 1fr: a plain 1fr will not shrink below its
     longest word, which is what let a long hometown widen the grid. */
  .docket .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .docket .id { grid-template-columns: minmax(0, 1fr); }
  .docket .mug { width: min(100%, 240px); height: 300px; }
  /* The watermark's box is a share of the sheet's width, which on a phone left
     a small figure floating beside the facts. Wider here, so it reads as a
     figure standing behind the first sections. */
  .docket .ghost { width: 90%; right: -10%; top: 20%; height: 46%; }
  /* Each row becomes a small card, with the column name above each value
     (the data-label on every cell). */
  .docket thead { display: none; }
  .docket table,
  .docket tbody,
  .docket tr,
  .docket td { display: block; width: 100%; }
  .docket tr { padding: 10px 0; border-bottom: 1px solid var(--rule); }
  .docket td { border: 0; padding: 3px 0; }
  .docket td::before {
    content: attr(data-label);
    display: block;
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
  }
}
