/* ==========================================================================
   HANDS OF GOD — public stylesheet
   1. tokens   2. base   3. topbar   4. hero   5. cards   6. form
   7. footer   8. a name (profile page)   9. responsive
   ========================================================================== */

/* ------------------------------------------------------------- 1. tokens */

:root {
  /* surface */
  --bg: #060609;
  --bg-soft: #0b0b11;
  --surface: rgba(20, 20, 28, 0.78);
  --surface-2: rgba(11, 11, 16, 0.92);
  --line: rgba(198, 160, 74, 0.18);
  --line-2: rgba(198, 160, 74, 0.42);

  /* ink */
  --gold: #d9b25f;
  --gold-soft: #f3dfa5;
  --gold-deep: #8a6a2a;
  --text: #eae7e0;
  --muted: #908c85;
  --blood: #b3241f;
  --ok: #4bb87a;

  /* type */
  --display: "Cinzel", "Trajan Pro", Georgia, "Times New Roman", serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* space */
  --s-1: 4px;
  --s-2: 8px;
  --s-3: 12px;
  --s-4: 16px;
  --s-5: 24px;
  --s-6: 32px;
  --s-7: 48px;
  --s-8: 72px;

  /* shape */
  --r-sm: 9px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-pill: 999px;

  /* motion */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --fast: 0.22s;
  --slow: 0.45s;

  /* elevation */
  --lift: 0 24px 60px -32px rgba(0, 0, 0, 0.9);
  --glow: 0 0 0 1px rgba(217, 178, 95, 0.24), 0 18px 48px -26px rgba(217, 178, 95, 0.55);
}

/* --------------------------------------------------------------- 2. base */

*,
*::before,
*::after { box-sizing: border-box; }

* { margin: 0; }

/* the whole record sits at the comfortable 110% zoom by default */
html {
  -webkit-text-size-adjust: 100%;
  zoom: 1.1;
}

body {
  min-height: 100vh;
  background:
    radial-gradient(1200px 560px at 50% -240px, rgba(217, 178, 95, 0.12), transparent 70%),
    radial-gradient(900px 440px at 92% 4%, rgba(179, 36, 31, 0.07), transparent 72%),
    var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* faint engineering grid, fading out below the fold */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.45;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.012) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.012) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(circle at 50% 0%, #000 18%, transparent 74%);
  mask-image: radial-gradient(circle at 50% 0%, #000 18%, transparent 74%);
}

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

a { color: var(--gold-soft); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

h1, h2, h3, h4 { font-weight: 700; }

[hidden] { display: none !important; }

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

.shell {
  position: relative;
  z-index: 1;
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
}

.skip {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 99;
  padding: 10px 16px;
  border-radius: var(--r-sm);
  background: var(--gold);
  color: #14100a;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  transform: translateY(-160%);
  transition: transform var(--fast) var(--ease);
}
.skip:focus-visible { transform: translateY(0); }

/* ------------------------------------------------------------- 4. topbar */

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: linear-gradient(180deg, rgba(6, 6, 9, 0.92), rgba(6, 6, 9, 0.66));
  border-bottom: 1px solid rgba(198, 160, 74, 0.12);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

.topbar-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  padding-block: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-width: 0;
  color: inherit;
  text-decoration: none;
}
.brand:hover { text-decoration: none; }

.brand-mark {
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 50%;
  object-fit: cover;
  background: #0b0b10;
  box-shadow: 0 0 20px rgba(217, 178, 95, 0.28);
  transition: border-color var(--slow) var(--ease), box-shadow var(--slow) var(--ease);
}

.brand:hover .brand-mark,
.brand:focus-visible .brand-mark {
  border-color: var(--line-2);
  box-shadow: 0 0 30px rgba(217, 178, 95, 0.38), inset 0 0 14px rgba(217, 178, 95, 0.16);
}

.brand-copy { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }

.brand-name {
  font-family: var(--display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  /* gothic letters: no case transform, or the glyphs turn into different letters */
  text-transform: none;
  color: var(--gold-soft);
  white-space: nowrap;
  line-height: 1.25;
}

.brand-sub {
  font-size: 9px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

/* music: one button that is play when stopped and pause when playing */
.music {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex: 0 0 auto;
  min-width: 104px;
  justify-content: center;
  padding: 8px 15px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: rgba(217, 178, 95, 0.05);
  color: var(--gold);
  font-family: inherit;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color var(--fast) var(--ease), border-color var(--fast) var(--ease),
    background var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}

.music:hover {
  color: var(--gold-soft);
  border-color: var(--line-2);
}

.music.playing {
  color: #16120a;
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  border-color: var(--gold);
  box-shadow: 0 10px 26px -16px rgba(217, 178, 95, 0.9);
}

.music-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 10px;
  height: 12px;
}

.music-icon svg {
  display: block;
  width: 9px;
  height: 11px;
  fill: currentColor;
}

.music .i-pause { display: none; }
.music.playing .i-play { display: none; }
.music.playing .i-pause { display: block; }

/* Five slim bars centered in the Music button and nudged above the text line.
   JS feeds each one a smoothed value from the live analyser and scales the
   whole group by the current volume. */
.music-bars {
  display: inline-flex;
  align-items: flex-end;
  justify-content: center;
  gap: 2px;
  width: 16px;
  height: 12px;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 180ms var(--ease);
}

.music.playing .music-bars { opacity: 1; }

.music-bars i {
  display: block;
  width: 2px;
  height: max(2px, calc(var(--b, 0) * 11px));
  border-radius: 2px 2px 0 0;
  background: currentColor;
  transform-origin: bottom;
  transition: height 70ms linear;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  min-width: 0;
}

/* One reusable volume component. Its size comes from the space it is given,
   not from a fixed pixel width, so the same markup works in the topbar and in
   any future panel. */
.volume-control {
  /* tokens — override these on a wrapper to rescale the whole component */
  --vol-gap: 0.42em;
  --vol-pad-inline: 0.5em;
  --vol-pad-block: 0.24em;
  --vol-icon-size: 0.95em;
  --vol-track-h: 0.22em;
  --vol-thumb-size: 0.78em;
  --vol-progress: 40%;

  display: flex;
  align-items: center;
  gap: var(--vol-gap);
  flex: 0 1 clamp(9em, 14vw, 13em);
  min-width: 0;
  padding: var(--vol-pad-block) var(--vol-pad-inline);
  border: 1px solid rgba(198, 160, 74, 0.18);
  border-radius: var(--r-pill);
  background: rgba(217, 178, 95, 0.035);
  font-size: clamp(10px, 0.95vw, 12px);
  transition: border-color var(--fast) var(--ease), background var(--fast) var(--ease),
    box-shadow var(--fast) var(--ease);
}

.volume-control:hover,
.volume-control:focus-within {
  border-color: rgba(198, 160, 74, 0.42);
  background: rgba(217, 178, 95, 0.06);
  box-shadow: 0 0 24px -16px rgba(217, 178, 95, 0.7);
}

.volume-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: var(--gold);
  transition: opacity var(--fast) var(--ease), color var(--fast) var(--ease),
    filter var(--fast) var(--ease);
}

.volume-icon svg {
  display: block;
  width: var(--vol-icon-size);
  height: var(--vol-icon-size);
  fill: currentColor;
}

.volume-control.is-muted .volume-icon { opacity: 0.42; }
.volume-control.is-max .volume-icon { filter: drop-shadow(0 0 5px rgba(217, 178, 95, 0.55)); }

@property --vol-progress {
  syntax: "<percentage>";
  inherits: true;
  initial-value: 40%;
}

.volume-slider {
  -webkit-appearance: none;
  appearance: none;
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  height: max(1.4em, calc(var(--vol-thumb-size) + 0.4em));
  margin: 0;
  background: transparent;
  cursor: pointer;
  font-size: 1em;
  transition: --vol-progress 80ms linear;
}

.volume-slider::-webkit-slider-runnable-track {
  height: var(--vol-track-h);
  border: 1px solid rgba(198, 160, 74, 0.22);
  border-radius: var(--r-pill);
  background: linear-gradient(
    90deg,
    var(--gold) 0 var(--vol-progress),
    rgba(255, 255, 255, 0.11) var(--vol-progress) 100%
  );
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.45);
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: var(--vol-thumb-size);
  height: var(--vol-thumb-size);
  margin-top: calc((var(--vol-track-h) - var(--vol-thumb-size)) / 2);
  border: 1px solid rgba(255, 240, 200, 0.65);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--gold-soft), var(--gold) 62%, var(--gold-deep));
  box-shadow: 0 0 9px rgba(217, 178, 95, 0.5);
  transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}

.volume-slider::-moz-range-track {
  height: var(--vol-track-h);
  border: 1px solid rgba(198, 160, 74, 0.22);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.11);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.45);
}

.volume-slider::-moz-range-progress {
  height: var(--vol-track-h);
  border-radius: var(--r-pill);
  background: var(--gold);
}

.volume-slider::-moz-range-thumb {
  width: var(--vol-thumb-size);
  height: var(--vol-thumb-size);
  border: 1px solid rgba(255, 240, 200, 0.65);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--gold-soft), var(--gold) 62%, var(--gold-deep));
  box-shadow: 0 0 9px rgba(217, 178, 95, 0.5);
  transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}

.volume-slider:hover::-webkit-slider-thumb,
.volume-slider:active::-webkit-slider-thumb { transform: scale(1.12); }

.volume-slider:hover::-moz-range-thumb,
.volume-slider:active::-moz-range-thumb { transform: scale(1.12); }

.volume-slider:focus-visible { outline: 2px solid var(--line-2); outline-offset: 3px; }

.volume-value {
  flex: 0 0 auto;
  min-width: 2.7em;
  color: var(--muted);
  font-size: 0.8em;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.1em;
  text-align: right;
  transition: color var(--fast) var(--ease), opacity var(--fast) var(--ease);
}

.volume-control.is-muted .volume-value { opacity: 0.6; }
.volume-control.is-max .volume-value { color: var(--gold-soft); }

.discord-link {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(217, 178, 95, 0.05);
  color: var(--gold);
  transition: color var(--fast) var(--ease), border-color var(--fast) var(--ease),
    background var(--fast) var(--ease), box-shadow var(--fast) var(--ease), transform var(--fast) var(--ease);
  animation: discord-breathe 3.2s ease-in-out infinite;
}

@keyframes discord-breathe {
  0%, 100% {
    filter: brightness(0.82);
    border-color: rgba(198, 160, 74, 0.18);
    background: rgba(217, 178, 95, 0.025);
    box-shadow: 0 0 0 rgba(114, 137, 248, 0);
  }
  50% {
    filter: brightness(1.3);
    border-color: rgba(114, 137, 248, 0.72);
    background: rgba(114, 137, 248, 0.13);
    box-shadow: 0 0 20px -3px rgba(114, 137, 248, 0.85), inset 0 0 9px rgba(114, 137, 248, 0.28);
  }
}

.discord-link svg {
  display: block;
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.discord-link:hover,
.discord-link:focus-visible {
  color: #a6b1ff;
  border-color: rgba(114, 137, 248, 0.7);
  background: rgba(114, 137, 248, 0.12);
  box-shadow: 0 10px 24px -16px rgba(114, 137, 248, 0.9);
  transform: translateY(-1px);
}

/* --------------------------------------------------------------- 5. hero */

.hero {
  padding-block: clamp(56px, 9vw, 104px) clamp(40px, 6vw, 64px);
  text-align: center;
}

.crest {
  font-family: var(--display);
  font-size: clamp(30px, 6.2vw, 66px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.12em;
  background: linear-gradient(180deg, #fff8e2 0%, var(--gold) 48%, var(--gold-deep) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 22px 60px rgba(217, 178, 95, 0.14);
}

.eyebrow {
  display: inline-block;
  margin-top: clamp(18px, 2.4vw, 26px);
  padding: 8px 22px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: rgba(217, 178, 95, 0.05);
  color: var(--gold);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.36em;
  text-transform: uppercase;
}

/* Search and gender/role filters sit directly under the crest. */
.record-search {
  display: flex;
  align-items: center;
  gap: 9px;
  width: min(520px, 100%);
  margin: clamp(20px, 3vw, 30px) auto 0;
  padding: 5px 5px 5px 15px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: rgba(217, 178, 95, 0.035);
  transition: border-color var(--fast) var(--ease), box-shadow var(--fast) var(--ease),
    background var(--fast) var(--ease);
}

.record-search:focus-within {
  border-color: rgba(198, 160, 74, 0.5);
  background: rgba(217, 178, 95, 0.06);
  box-shadow: 0 0 24px -12px rgba(217, 178, 95, 0.8);
}

.record-search svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  fill: var(--gold);
  opacity: 0.85;
}

.record-search input {
  flex: 1;
  min-width: 0;
  padding: 6px 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 12px;
}

.record-search input::placeholder { color: var(--muted); opacity: 0.8; }
.record-search input::-webkit-search-cancel-button { cursor: pointer; }

.record-search .btn {
  flex: 0 0 auto;
  padding: 7px 18px;
  font-size: 10px;
  letter-spacing: 0.18em;
}

.record-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}

.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: rgba(217, 178, 95, 0.035);
  color: var(--muted);
  font-family: inherit;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color var(--fast) var(--ease), border-color var(--fast) var(--ease),
    background var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}

.filter-chip:hover {
  color: var(--gold-soft);
  border-color: var(--line-2);
}

.filter-chip.active {
  color: #16120a;
  border-color: var(--gold);
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  box-shadow: 0 8px 22px -16px rgba(217, 178, 95, 0.9);
}

.filter-chip img {
  width: 13px;
  height: 13px;
  object-fit: contain;
}

.filter-chip .filter-dot {
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--role-color, var(--gold));
}

/* ---------------------------------------------------------- 6. views/tabs */

.body-grid { padding-bottom: var(--s-8); }

.tabwrap { display: flex; justify-content: center; margin-bottom: var(--s-6); }

.tabs {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: rgba(12, 12, 18, 0.72);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.tab {
  appearance: none;
  border: 0;
  padding: 11px 22px;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--muted);
  font-family: var(--body);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color var(--fast) var(--ease), background var(--fast) var(--ease);
}

.tab:hover { color: var(--gold-soft); }

.tab.active {
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  color: #16120a;
  box-shadow: 0 10px 26px -16px rgba(217, 178, 95, 0.9);
}

.view { animation: view-in 0.4s var(--ease) both; }

@keyframes view-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}

.empty {
  padding: var(--s-7) var(--s-5);
  border: 1px dashed rgba(198, 160, 74, 0.16);
  border-radius: var(--r-md);
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-align: center;
}

/* -------------------------------------------------------------- 7. cards */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(228px, 1fr));
  gap: var(--s-4);
}

.card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: var(--s-6) var(--s-4) var(--s-5);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background:
    linear-gradient(180deg, rgba(24, 24, 32, 0.86), rgba(11, 11, 16, 0.94));
  display: block;
  color: inherit;
  text-decoration: none;
  text-align: center;
  transition: transform var(--slow) var(--ease), border-color var(--slow) var(--ease), box-shadow var(--slow) var(--ease);
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(120% 70% at 50% -10%, rgba(217, 178, 95, 0.16), transparent 62%);
  opacity: 0;
  transition: opacity var(--slow) var(--ease);
}

.card:hover,
.card:focus-visible {
  transform: translateY(-4px);
  border-color: var(--line-2);
  box-shadow: var(--lift);
}
.card:hover::before { opacity: 1; }
.card:hover,
.card:focus-visible { text-decoration: none; }

.card-flare {
  position: absolute;
  top: -40%;
  left: 50%;
  width: 140%;
  height: 80%;
  z-index: -1;
  transform: translateX(-50%);
  background: radial-gradient(50% 50% at 50% 50%, rgba(243, 223, 165, 0.12), transparent 70%);
  opacity: 0;
  transition: opacity var(--slow) var(--ease);
}
.card:hover .card-flare { opacity: 1; }

.avatar-ring {
  --decoration-size: 118px;
  position: relative;
  width: 82px;
  height: 82px;
  margin: 0 auto var(--s-3);
  padding: 3px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: rgba(217, 178, 95, 0.06);
}

/* the PFP is scaled on its own layer; the frame is a fixed-size sibling */
.avatar-zoom {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  transform: scale(1.1);
}

.avatar-zoom img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: #14141c;
}

/* all card copy is zoomed visually; the card's layout box stays the same */
.card-copy {
  width: calc(100% / 1.1);
  margin-inline: auto;
  transform: scale(1.1);
  transform-origin: center top;
}

.card h3 {
  font-family: var(--display);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--gold-soft);
  overflow-wrap: anywhere;
}

.handle {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  overflow-wrap: anywhere;
}

.role {
  min-height: 14px;
  margin-top: var(--s-2);
  color: var(--gold);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  opacity: 0.85;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  margin-top: var(--s-3);
}

.chip {
  padding: 3px 9px;
  border: 1px solid rgba(198, 160, 74, 0.16);
  border-radius: var(--r-pill);
  color: var(--muted);
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
}

.chip.gold  { color: var(--gold); border-color: rgba(217, 178, 95, 0.42); background: rgba(217, 178, 95, 0.07); }
.chip.ok    { color: var(--ok); border-color: rgba(75, 184, 122, 0.36); background: rgba(75, 184, 122, 0.07); }
.chip.blood { color: #e0645f; border-color: rgba(179, 36, 31, 0.42); background: rgba(179, 36, 31, 0.09); }
.chip.blue { color: #8ecbff; border-color: rgba(94, 168, 255, 0.45); background: rgba(94, 168, 255, 0.1); }
.chip.pink { color: #ffa6d6; border-color: rgba(255, 140, 200, 0.45); background: rgba(255, 140, 200, 0.1); }

/* Discord frames stay centered on the PFP; keepers may tune scale and offset */
.decoration-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  max-width: none;
  width: calc(var(--decoration-size, 118px) * var(--deco-scale, 0.85));
  height: calc(var(--decoration-size, 118px) * var(--deco-scale, 0.85));
  transform: translate(-50%, -50%) translate(var(--deco-x, 0px), var(--deco-y, 0px));
  z-index: 2;
  pointer-events: none;
  object-fit: contain;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.55));
}

.role-chip {
  --role-color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--role-color);
  border-color: var(--role-color);
  background: color-mix(in srgb, var(--role-color) 12%, transparent);
}

.role-icon {
  width: 14px;
  height: 14px;
  object-fit: contain;
  border-radius: 3px;
  flex: 0 0 auto;
}

.role-glyph { font-size: 12px; line-height: 1; }

/* -------------------------------------------------------------- 8. deeds */

.reports { display: grid; gap: var(--s-3); }

.report {
  padding: var(--s-5);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: linear-gradient(180deg, rgba(22, 22, 30, 0.72), rgba(11, 11, 16, 0.82));
  transition: border-color var(--slow) var(--ease);
}

.report:hover { border-color: rgba(198, 160, 74, 0.3); }

.report-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-2) var(--s-4);
}

.report h4 {
  font-family: var(--display);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--gold-soft);
  overflow-wrap: anywhere;
}

.report-meta {
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.report p {
  margin-top: var(--s-3);
  color: #c8c4bc;
  font-size: 14px;
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* --------------------------------------------------------------- 9. form */

.panel {
  padding: clamp(20px, 3.4vw, 36px);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, rgba(22, 22, 30, 0.82), rgba(10, 10, 15, 0.9));
  box-shadow: var(--lift);
}

.panel-head { margin-bottom: var(--s-5); }

.panel h2,
.editor h2 {
  font-family: var(--display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-soft);
}

.hint {
  margin-top: var(--s-2);
  max-width: 64ch;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-3); }
.row-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-3); }

.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: var(--s-4); }

.field label,
.kv dt {
  color: var(--gold);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  opacity: 0.85;
}

.field label em {
  font-style: normal;
  letter-spacing: 0.08em;
  text-transform: none;
  color: var(--muted);
  opacity: 0.9;
}

input,
select,
textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: rgba(7, 7, 11, 0.82);
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  transition: border-color var(--fast) var(--ease), box-shadow var(--fast) var(--ease), background var(--fast) var(--ease);
}

input::placeholder,
textarea::placeholder { color: #5f5c57; }

input:hover,
select:hover,
textarea:hover { border-color: rgba(198, 160, 74, 0.3); }

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--line-2);
  background: rgba(12, 12, 18, 0.95);
  box-shadow: 0 0 0 3px rgba(217, 178, 95, 0.12);
}

textarea {
  min-height: 128px;
  line-height: 1.65;
  resize: vertical;
}

select {
  appearance: none;
  padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none' stroke='%23d9b25f' stroke-width='1.6' stroke-linecap='round'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  cursor: pointer;
}

.form-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-4);
  margin-top: var(--s-2);
}

.btn {
  appearance: none;
  padding: 12px 24px;
  border: 1px solid var(--gold);
  border-radius: var(--r-sm);
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  color: #171208;
  font-family: inherit;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease), opacity var(--fast) var(--ease);
}

.btn:hover { transform: translateY(-1px); box-shadow: 0 14px 30px -16px rgba(217, 178, 95, 0.9); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: 0.55; cursor: progress; transform: none; box-shadow: none; }

/* small pill buttons — admin toggles, secondary actions */
.mini {
  display: inline-block;
  padding: 9px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: color var(--fast) var(--ease), background var(--fast) var(--ease),
    border-color var(--fast) var(--ease), box-shadow var(--fast) var(--ease), transform var(--fast) var(--ease);
}

.mini:hover {
  color: var(--gold);
  border-color: var(--line-2);
  text-decoration: none;
}

.mini:active { transform: translateY(1px); }

.mini.on {
  color: #171208;
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  border-color: var(--gold);
  box-shadow: 0 8px 22px -14px rgba(217, 178, 95, 0.95);
}

.mini.pink.on {
  color: #2b0716;
  background: linear-gradient(180deg, #ffc9e8, #ff8ecb);
  border-color: #ff8ecb;
  box-shadow: 0 8px 22px -14px rgba(255, 142, 203, 0.95);
}

.mini.blue.on {
  color: #04141f;
  background: linear-gradient(180deg, #a9dbff, #5aa9ff);
  border-color: #5aa9ff;
  box-shadow: 0 8px 22px -14px rgba(90, 169, 255, 0.95);
}

.form-msg { font-size: 12.5px; line-height: 1.5; color: var(--muted); }
.form-msg.ok  { color: var(--ok); }
.form-msg.err { color: #e0645f; }

/* ------------------------------------------------------------- 10. footer */

.site-foot {
  position: relative;
  z-index: 1;
  margin-top: var(--s-8);
  border-top: 1px solid rgba(198, 160, 74, 0.12);
  background: linear-gradient(180deg, transparent, rgba(6, 6, 9, 0.9));
}

.foot-in {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2) var(--s-5);
  padding-block: var(--s-6);
}

.foot-brand {
  font-family: var(--display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.24em;
  color: var(--gold-soft);
}

.foot-line { color: var(--muted); font-size: 12px; }

.foot-link {
  color: var(--gold);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}

/* ----------------------------------------------------- 11. profile sheet */

/* ---------------------------------------------------------- 11. a name */

.page { padding-block: var(--s-6) var(--s-8); }

.back {
  display: inline-block;
  margin-bottom: var(--s-5);
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  transition: color var(--fast) var(--ease);
}

.back:hover { color: var(--gold); text-decoration: none; }

.profile {
  max-width: 720px;
  margin-inline: auto;
  text-align: center;
}

.profile-head {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: var(--s-3);
  margin-bottom: var(--s-5);
  text-align: center;
}

.profile-avatar-wrap {
  --decoration-size: 161px;
  position: relative;
  width: 112px;
  height: 112px;
  flex: 0 0 auto;
}

.profile-avatar {
  width: 100%;
  height: 100%;
  border: 1px solid var(--line-2);
  border-radius: 50%;
  object-fit: cover;
  background: #14141c;
}

/* profile text grows visually without changing the box it sits in */
.profile-id {
  min-width: 0;
  transform: scale(1.1);
  transform-origin: center center;
}

.profile-id h1 {
  font-family: var(--display);
  font-size: clamp(24px, 5vw, 38px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: 0.08em;
  color: var(--gold-soft);
  text-shadow: 0 0 18px rgba(217, 178, 95, 0.34), 0 0 40px rgba(217, 178, 95, 0.14);
  overflow-wrap: anywhere;
}

.profile-id .handle {
  color: #c9a86a;
  text-shadow: 0 0 14px rgba(217, 178, 95, 0.18);
}

.profile-id .chip-row { justify-content: center; margin-top: var(--s-2); }

.block { margin-top: var(--s-6); }

.block h2 {
  margin-bottom: var(--s-3);
  color: var(--gold);
  font-family: var(--display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

.prose {
  color: #d7d3cb;
  font-size: 15px;
  line-height: 1.8;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.prose a {
  color: var(--gold-soft);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.prose.muted { color: var(--muted); font-style: italic; }

/* the About area: hand-drawn, monochrome grey */
.about-block {
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 560px;
  margin: var(--s-6) auto 0;
  padding: 22px 24px;
  text-align: center;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px 14px 22px 12px;
  background:
    repeating-linear-gradient(115deg, rgba(255, 255, 255, 0.022) 0 2px, transparent 2px 9px),
    linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.012));
  box-shadow: 3px 3px 0 rgba(255, 255, 255, 0.08), -3px 3px 0 rgba(255, 255, 255, 0.05),
    0 0 0 1px rgba(217, 178, 95, 0.12), 0 0 34px -14px rgba(217, 178, 95, 0.3),
    0 10px 30px -20px rgba(255, 255, 255, 0.28);
  transform: rotate(-0.35deg);
}

.about-block::before {
  content: "";
  position: absolute;
  inset: -5px;
  z-index: -1;
  border-radius: 22px;
  background: conic-gradient(from 20deg, #6f6f6f, #cfcfcf, #6f6f6f, #cfcfcf, #6f6f6f);
  filter: blur(13px);
  opacity: 0.22;
}

.about-zoom {
  width: calc(100% / 1.1);
  transform: scale(1.1);
  transform-origin: left top;
}

.crayon-title {
  margin-bottom: 12px !important;
  font-size: 12px !important;
  letter-spacing: 0.16em !important;
  background: linear-gradient(90deg, #8f8f8f, #e2e2e2, #8f8f8f);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
}

.crayon-prose {
  color: #e8e8e8;
  font-weight: 500;
  text-shadow: 1px 0 rgba(255, 255, 255, 0.18), -1px 0 rgba(0, 0, 0, 0.35),
    0 1px rgba(255, 255, 255, 0.12);
}

.crayon-prose a {
  color: #d6d6d6;
  text-decoration-color: #9a9a9a;
  text-decoration-thickness: 2px;
}

.crayon-field label {
  background: linear-gradient(90deg, #8f8f8f, #e2e2e2, #8f8f8f);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
  opacity: 1 !important;
}

.claim {
  padding-top: var(--s-5);
  border-top: 1px solid rgba(198, 160, 74, 0.14);
}

.claim .hint { margin-bottom: var(--s-4); }

.kv {
  display: grid;
  grid-template-columns: minmax(96px, auto) 1fr;
  gap: 1px;
  margin-top: var(--s-5);
  border: 1px solid rgba(198, 160, 74, 0.12);
  border-radius: var(--r-sm);
  overflow: hidden;
  background: rgba(198, 160, 74, 0.08);
}

.kv dt,
.kv dd {
  margin: 0;
  padding: 11px 14px;
  background: rgba(10, 10, 15, 0.94);
  font-size: 13px;
}

.kv dt { display: flex; align-items: center; }

.kv dd { color: var(--text); overflow-wrap: anywhere; }

.editor {
  margin-top: var(--s-5);
  padding-top: var(--s-5);
  border-top: 1px solid rgba(198, 160, 74, 0.14);
}

.editor h2 { margin-bottom: var(--s-2); }

.editor .hint { margin-bottom: var(--s-4); }

/* --------------------------------------------------------- 12. responsive */

@media (max-width: 860px) {
  .row-3 { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 680px) {
  .shell { width: calc(100% - 32px); }
  .topbar-in { flex-wrap: wrap; }
  .topbar-actions { flex-wrap: wrap; justify-content: flex-end; margin-left: auto; }
  .volume-control { flex-basis: 100%; }
  .row-2,
  .row-3 { grid-template-columns: 1fr; }
  .tab { padding: 10px 16px; letter-spacing: 0.18em; }
  .tabs { width: 100%; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: var(--s-3); }
  .card { padding: var(--s-5) var(--s-3); }
  .avatar-ring { --decoration-size: 95px; width: 66px; height: 66px; }
  .foot-in { flex-direction: column; align-items: flex-start; }
  .kv { grid-template-columns: 1fr; }
  .profile-avatar-wrap { --decoration-size: 121px; width: 84px; height: 84px; }
  .profile-head { gap: var(--s-4); }
  .kv dt { padding-bottom: 0; background: rgba(10, 10, 15, 0.94); }
}

@media (max-width: 420px) {
  .brand-sub { display: none; }
  .topbar-actions { gap: 6px; }
  .volume-control { --vol-gap: 0.38em; --vol-pad-inline: 0.45em; font-size: 10px; }
  .discord-link { width: 30px; height: 30px; }
  .music { padding: 7px 12px; letter-spacing: 0.2em; min-width: 92px; }
  .form-foot .btn { width: 100%; }
}

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