/* =====================================================================
   Cyber Gyn MMORPG — site skin built from the game's own UI
   (stone panels, inventory slots, pixel type, notched pixel buttons,
   HP/MP/XP bars, yellow selection frame).
   1 tokens · 2 base · 3 pixel primitives · 4 shell · 5 home
   6 bestiary · 7 items · 8 shop · 9 community · 10 misc · 11 responsive
   ===================================================================== */

/* 1. Tokens ----------------------------------------------------------- */
:root {
  --void: #0d0d0f;
  --bg: #151517;
  --stone: #2c2c30;
  --stone-hi: #3d3d42;
  --stone-lo: #1f1f22;
  --slot: #1a1a1d;
  --slot-line: #4b4b52;
  --edge: #5c5c64;
  --ink: #f4f4f4;
  --muted: #b3b3ba;
  --faint: #7d7d86;

  --select: #e6f000;     /* in-game selection frame */
  --gold: #f6b500;       /* gold coins / prices */
  --coin: #c8ff3c;       /* "GOLD: 1.635.206" green-yellow numbers */
  --hp: #e3191b;
  --mp: #19a3e6;
  --xp: #2fc12f;
  --cyan: #38e1ff;       /* Cyber banner glow */
  --purple: #b13cff;

  --r-common: #d2d2d8;
  --r-uncommon: #2abe5f;
  --r-rare: #3791ff;
  --r-epic: #a55aff;
  --r-legendary: #ffdc41;
  --r-mythic: #ff8723;

  --px: 4px;             /* pixel unit for notches and bevels */
  --notch: polygon(0 var(--px), var(--px) var(--px), var(--px) 0, calc(100% - var(--px)) 0, calc(100% - var(--px)) var(--px), 100% var(--px), 100% calc(100% - var(--px)), calc(100% - var(--px)) calc(100% - var(--px)), calc(100% - var(--px)) 100%, var(--px) 100%, var(--px) calc(100% - var(--px)), 0 calc(100% - var(--px)));
  --bevel: inset 3px 3px 0 rgba(255, 255, 255, .07), inset -3px -3px 0 rgba(0, 0, 0, .35);
  --sink: inset 3px 3px 0 rgba(0, 0, 0, .45), inset -2px -2px 0 rgba(255, 255, 255, .05);

  --wrap: 1180px;
  --head-h: 68px;
  --pixel: "Pixelify Sans", "Silkscreen", monospace;
  --label: "Silkscreen", "Pixelify Sans", monospace;
  --font: "Rubik", system-ui, "Segoe UI", sans-serif;

  /* cobblestone floor, drawn at 1 unit = 4px */
  --cobble: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' shape-rendering='crispEdges'%3E%3Cg fill='%23ffffff' fill-opacity='.025'%3E%3Crect x='4' y='4' width='24' height='20'/%3E%3Crect x='36' y='4' width='24' height='12'/%3E%3Crect x='36' y='20' width='24' height='16'/%3E%3Crect x='4' y='28' width='28' height='12'/%3E%3Crect x='4' y='44' width='16' height='16'/%3E%3Crect x='24' y='44' width='36' height='16'/%3E%3C/g%3E%3Cg fill='%23000000' fill-opacity='.18'%3E%3Crect x='4' y='20' width='24' height='4'/%3E%3Crect x='36' y='12' width='24' height='4'/%3E%3Crect x='36' y='32' width='24' height='4'/%3E%3Crect x='4' y='36' width='28' height='4'/%3E%3Crect x='4' y='56' width='16' height='4'/%3E%3Crect x='24' y='56' width='36' height='4'/%3E%3C/g%3E%3C/svg%3E");
  /* grass tile with blades on top */
  --grass: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='40' shape-rendering='crispEdges'%3E%3Crect y='8' width='64' height='32' fill='%233c8d2f'/%3E%3Cg fill='%2354a93b'%3E%3Crect x='0' y='4' width='4' height='4'/%3E%3Crect x='12' y='0' width='4' height='8'/%3E%3Crect x='16' y='4' width='4' height='4'/%3E%3Crect x='28' y='4' width='4' height='4'/%3E%3Crect x='40' y='0' width='4' height='8'/%3E%3Crect x='52' y='4' width='8' height='4'/%3E%3Crect x='8' y='20' width='4' height='4'/%3E%3Crect x='44' y='28' width='4' height='4'/%3E%3C/g%3E%3Cg fill='%232c6e22'%3E%3Crect x='20' y='16' width='4' height='4'/%3E%3Crect x='24' y='20' width='4' height='4'/%3E%3Crect x='56' y='20' width='4' height='4'/%3E%3Crect x='4' y='32' width='4' height='4'/%3E%3Crect x='36' y='32' width='8' height='4'/%3E%3C/g%3E%3Cg fill='%23e8e8e8'%3E%3Crect x='32' y='16' width='4' height='4'/%3E%3C/g%3E%3C/svg%3E");
}

/* 2. Base ------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh;
  background: var(--cobble) 0 0 / 64px 64px, var(--bg);
  color: var(--ink);
  font: 400 16px/1.6 var(--font);
}
img { max-width: 100%; height: auto; }
a { color: var(--select); text-decoration: none; }
a:hover { color: #fff; }
:focus-visible { outline: 3px solid var(--select); outline-offset: 2px; }
h1, h2, h3, h4 { font-family: var(--pixel); font-weight: 700; color: #fff; line-height: 1.15; margin: 0 0 .55em; letter-spacing: .01em; text-shadow: 3px 3px 0 #000; }
p { margin: 0 0 1em; }
hr { border: 0; height: 4px; background: var(--stone-hi); margin: 28px 0; }
::selection { background: var(--select); color: #000; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* every sprite stays crisp */
img[src$=".png"], img[src$=".gif"], .header-walker { image-rendering: pixelated; }
.cg-smooth { image-rendering: auto !important; }

.cg-wrap { width: min(var(--wrap), 100% - 40px); margin-inline: auto; }
.container { display: contents; }
.container > .banner, .container > .menu, .portal-sidebar, .portal-statusbar { display: none !important; }

/* 3. Pixel primitives ------------------------------------------------- */
/* Stone panel (the game's windows) */
.cg-panel,
.news-ticker, .news-article, .items-section, .shop-item-card, .support-card, .guild-section,
.profile-group, .login-card, .admin-card, .character-card,
.character-search-section, .character-equipment-section, .monster-drops-section,
.bestiary-tools, .arsenal-tools, .support-receipt-card, .guild-directory, .item-info-section, .item-source-section,
.calc-inline, .support-note, .guild-account, .monster-detail-hero, .item-detail-hero,
.support-offer-card, .support-premium-card, .support-launch-hero, .guild-stat-card {
  position: relative;
  background: linear-gradient(180deg, rgba(64, 64, 70, .92), rgba(44, 44, 48, .94));
  border: 4px solid var(--edge);
  box-shadow: var(--bevel);
  clip-path: var(--notch);
  padding: 24px;
}
/* Slot (inventory square) */
.cg-slot, .monster-stat-card, .monster-drop-card, .item-info-card, .item-source-card,
.item-slot, .items-list-entry, .item-variant-row, .character-equipment-slot, .shop-item-art,
.support-trust-item, .monster-detail-figure, .item-detail-art, .cg-pagehead-art, .login-card-emblem, .support-icon {
  background: rgba(20, 20, 23, .85);
  border: 3px solid var(--slot-line);
  box-shadow: var(--sink);
}

/* Pixel text helpers */
.cg-label, .cg-eyebrow {
  font: 700 12px/1.2 var(--label); letter-spacing: .06em; text-transform: uppercase; color: var(--select);
  text-shadow: 2px 2px 0 #000;
}
.cg-eyebrow { display: inline-flex; align-items: center; gap: 10px; }
.cg-blink { width: 10px; height: 10px; background: var(--xp); box-shadow: 0 0 0 3px #0a3a0a; animation: cg-blink 1.2s steps(2) infinite; }
@keyframes cg-blink { 50% { opacity: .25; } }

/* Buttons — notched, bordered, pixel type */
.cg-btn, .support-btn, .login-primary-button, .admin-button, .news-article-action, .rank-retry, .character-equipment-privacy-button,
main button:not([class*="carousel"]):not(.rarity-chip):not(.rank-group-button):not(.rank-page-button):not(.feature-carousel-dot):not(.arsenal-section-toggle):not(.cg-plain):not(.header-walkers-toggle),
main input[type="submit"] {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 46px; padding: 10px 20px;
  font: 700 15px/1.1 var(--pixel); letter-spacing: .03em; color: #fff; text-align: center; text-shadow: 2px 2px 0 #000;
  background: #0f0f11; border: 4px solid #f2f2f2; border-radius: 0;
  clip-path: var(--notch); cursor: pointer; text-decoration: none;
  transition: transform .08s steps(2), border-color .1s;
}
.cg-btn:hover, .support-btn:hover, .admin-button:hover, .news-article-action:hover, .rank-retry:hover,
main button:not([class*="carousel"]):not(.rarity-chip):not(.rank-group-button):not(.rank-page-button):not(.feature-carousel-dot):not(.arsenal-section-toggle):not(.cg-plain):not(.header-walkers-toggle):hover {
  color: #fff; border-color: var(--select);
}
.cg-btn:active, .support-btn:active, main button:active { transform: translateY(2px); }
.cg-btn img { width: 24px; height: 24px; }
/* Primary: the yellow "selected" button */
.cg-btn-go, .login-primary-button, .support-btn-local, .admin-button:not(.admin-button-secondary) {
  background: var(--select) !important; color: #111 !important; text-shadow: none !important;
  border-color: #111 !important;
  box-shadow: inset 0 -5px 0 #9aa100, inset 0 4px 0 #f8ff8a;
}
.cg-btn-go:hover, .login-primary-button:hover, .support-btn-local:hover { background: #f3ff4d !important; }
.cg-btn-gold { background: linear-gradient(180deg, #5a4316, #3a2a0b); color: var(--gold); border: 3px solid var(--gold); box-shadow: inset 3px 3px 0 rgba(255,255,255,.13), inset -3px -3px 0 rgba(0,0,0,.45); font-family: var(--label); text-transform: uppercase; font-size: 14px; }
.cg-btn-gold::before { content: ""; width: 26px; height: 26px; flex: none; background: url("/Diamond.png") center / 20px no-repeat #141416; image-rendering: pixelated; box-shadow: inset 3px 3px 0 rgba(0,0,0,.55); }
.cg-btn-gold:hover { color: var(--gold); border-color: #ffd34d; }
.cg-btn-sm { min-height: 38px; padding: 6px 14px; font-size: 13.5px; border-width: 3px; }
.support-btn-paypal { border-color: var(--mp); }
main button:disabled { opacity: .45; cursor: not-allowed; }

/* HUD bars (HP / MP / XP) */
.cg-bar { height: 14px; background: #0a0a0b; border: 2px solid #000; box-shadow: inset 0 0 0 2px #2a2a2e; position: relative; overflow: hidden; }
.cg-bar i { position: absolute; inset: 2px auto 2px 2px; background: var(--c, var(--xp)); box-shadow: inset 0 3px 0 rgba(255,255,255,.35), inset 0 -3px 0 rgba(0,0,0,.25); }

/* Section title like the in-game plaques */
.cg-title { display: flex; align-items: center; gap: 16px; margin-bottom: 28px; }
.cg-title h2 { margin: 0; font-size: clamp(26px, 3.4vw, 40px); }
.cg-title::after { content: ""; flex: 1; height: 4px; background: repeating-linear-gradient(90deg, var(--edge) 0 8px, transparent 8px 16px); }
.cg-sub { color: var(--muted); max-width: 62ch; margin: -14px 0 28px; font-size: 17px; }

main h2 { font-size: clamp(24px, 3vw, 34px); }
main h3 { font-size: 21px; }
main h4 { font-size: 17px; }
main p, main li { color: #d6d6dc; }
main strong { color: #fff; }
main ul, main ol { padding-left: 1.3em; }
main li::marker { color: var(--select); }
.lead { font-size: 17px; color: var(--muted); }
.center { text-align: center; }

/* Forms: inputs look like dark slots */
main label { display: block; font: 700 12px/1.2 var(--label); text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: 8px; text-shadow: 2px 2px 0 #000; }
main input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]), main select, main textarea {
  width: 100%; min-height: 46px; padding: 10px 14px; border-radius: 0;
  background: #0f0f11; color: #fff; border: 3px solid var(--slot-line); box-shadow: var(--sink);
  font: 500 15.5px/1.4 var(--font);
}
main input:focus, main select:focus, main textarea:focus { outline: none; border-color: var(--select); }
main select { appearance: none; padding-right: 40px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' shape-rendering='crispEdges'%3E%3Cpath fill='%23e6f000' d='M0 0h12v2H10v2H8v2H6v2H6V6H4V4H2V2H0z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
main textarea { min-height: 120px; resize: vertical; }
main input[type="checkbox"] { width: 22px; height: 22px; accent-color: var(--select); }

/* Tables */
main table { width: 100%; border-collapse: collapse; font-size: 15px; background: rgba(20, 20, 23, .9); border: 4px solid var(--edge); }
main th, main td { padding: 12px 16px; text-align: left; border-bottom: 2px solid #2a2a2f; vertical-align: middle; color: #e2e2e6; }
main th { background: var(--stone-hi); color: var(--select); font: 700 12px/1.2 var(--label); text-transform: uppercase; letter-spacing: .04em; text-shadow: 2px 2px 0 #000; }
main tbody tr:nth-child(even) td { background: rgba(255, 255, 255, .025); }
main tbody tr:hover td { background: rgba(230, 240, 0, .06); }

/* Toolbars */
.bestiary-tools, .arsenal-tools { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 16px; align-items: end; margin-bottom: 18px; }
.bestiary-input-wrap, .arsenal-input-wrap { position: relative; }
.bestiary-input-wrap span, .arsenal-input-wrap span { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--faint); font-size: 18px; pointer-events: none; }
.bestiary-input-wrap input, .arsenal-input-wrap input { padding-left: 42px !important; }
.bestiary-summary, .arsenal-summary { display: flex; align-items: center; gap: 10px; margin: 0 0 18px; }
.bestiary-summary strong, .arsenal-summary strong { font: 700 13px/1.2 var(--label); color: var(--coin); text-transform: uppercase; text-shadow: 2px 2px 0 #000; }
.bestiary-summary-crest, .arsenal-summary-crest { width: 30px; height: 30px; display: grid; place-items: center; background: #0f0f11; border: 3px solid var(--slot-line); color: var(--select); font-size: 13px; }
.bestiary-empty, .arsenal-empty, .item-empty-state, .guild-empty { text-align: center; padding: 48px 20px; border: 4px dashed var(--edge); color: var(--muted); }
.bestiary-empty span, .arsenal-empty span { font-size: 32px; display: block; }

/* Notices = in-game chat messages */
.guild-notice, .admin-notice, .login-status, .character-search-status, .guild-list-status, .profile-status, .support-currency-note, .calc-note {
  padding: 12px 16px; background: rgba(0, 0, 0, .55); border-left: 6px solid var(--mp); color: #cfefff; font-size: 14.5px;
}
.guild-notice:empty, .admin-notice:empty, .login-status:empty, .character-search-status:empty, .guild-list-status:empty, .profile-status:empty { display: none; }
.is-error, .guild-error { color: #ffd0d0 !important; border-left-color: var(--hp) !important; background: rgba(60, 0, 0, .55) !important; }
.calc-help, .admin-help, .login-help { color: var(--muted); font-size: 14.5px; }

/* 4. Shell ------------------------------------------------------------ */
.cg-skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--select); color: #000; padding: 8px 14px; font-family: var(--pixel); }
.cg-skip:focus { left: 12px; }

.cg-header {
  position: sticky; top: 0; z-index: 50; height: var(--head-h);
  background: var(--cobble) 0 0 / 64px 64px, #1c1c1f;
  border-bottom: 4px solid #000;
  box-shadow: inset 0 -4px 0 var(--stone-hi), 0 6px 0 rgba(0, 0, 0, .35);
}
.cg-header-inner { height: 100%; display: flex; align-items: center; gap: 22px; }
.cg-logo { display: flex; align-items: center; flex: none; }
.cg-logo img { height: 50px; width: auto; display: block; mix-blend-mode: screen; image-rendering: auto; }
.cg-nav { display: flex; align-items: center; gap: 4px; flex: 1; }
.cg-nav-item { position: relative; }
.cg-nav-link, .cg-nav-trigger {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px;
  font: 700 13px/1 var(--label); text-transform: uppercase; letter-spacing: .02em; color: #e8e8ec; white-space: nowrap;
  background: none; border: 3px solid transparent; cursor: pointer; text-shadow: 2px 2px 0 #000;
}
.cg-nav-link:hover, .cg-nav-trigger:hover, .cg-nav-item:focus-within .cg-nav-trigger, .cg-nav-item:hover .cg-nav-trigger { color: #fff; border-color: #f2f2f2; background: #0f0f11; }
.cg-nav-link.is-active, .cg-nav-item.is-active > .cg-nav-trigger { color: var(--select); border-color: var(--select); }
.cg-nav-trigger svg { width: 10px; height: 10px; }
.cg-dropdown {
  position: absolute; top: calc(100% + 8px); left: 0; min-width: 300px; padding: 10px;
  background: #2a2a2e; border: 4px solid var(--edge); box-shadow: var(--bevel), 8px 8px 0 rgba(0,0,0,.5);
  opacity: 0; visibility: hidden; transform: translateY(4px); transition: opacity .1s steps(2), transform .1s steps(2), visibility .1s;
}
.cg-dropdown::before { content: ""; position: absolute; inset: -14px 0 auto; height: 14px; }
.cg-nav-item:hover .cg-dropdown, .cg-nav-item:focus-within .cg-dropdown { opacity: 1; visibility: visible; transform: none; }
.cg-dropdown a { display: flex; align-items: center; gap: 12px; padding: 7px; color: #fff; border: 3px solid transparent; }
.cg-dropdown a:hover, .cg-dropdown a.is-active { border-color: var(--select); background: rgba(0,0,0,.35); }
.cg-dd-icon { width: 46px; height: 46px; flex: none; display: grid; place-items: center; background: #141416; border: 3px solid var(--slot-line); box-shadow: var(--sink); }
.cg-dd-icon img { width: 32px; height: 32px; object-fit: contain; }
.cg-dropdown strong { display: block; font: 700 15px/1.2 var(--pixel); text-shadow: 2px 2px 0 #000; }
.cg-dropdown small { display: block; color: var(--muted); font-size: 12.5px; line-height: 1.35; }

.cg-actions { display: flex; align-items: center; gap: 10px; flex: none; }
.cg-lang { display: inline-flex; gap: 2px; }
.cg-lang a, .cg-lang span { font: 700 12px/1 var(--label); padding: 7px 8px; border: 3px solid transparent; color: var(--muted); text-shadow: 2px 2px 0 #000; }
.cg-lang span { color: var(--select); border-color: var(--select); }
.cg-lang a:hover { color: #fff; border-color: #f2f2f2; }
/* Header shortcuts styled like the game's menu tiles (CONFIG / INVENTORY / STATS) */
.cg-tile {
  position: relative; display: inline-flex; align-items: center; gap: 9px; height: 48px; padding: 0 14px 0 5px;
  background: linear-gradient(180deg, #4b4b51, #34343a);
  border: 3px solid #6a6a72; clip-path: var(--notch);
  box-shadow: inset 3px 3px 0 rgba(255, 255, 255, .13), inset -3px -3px 0 rgba(0, 0, 0, .45);
  font: 700 13px/1 var(--label); text-transform: uppercase; color: #fff; text-shadow: 2px 2px 0 #000;
}
.cg-tile:hover { color: #fff; border-color: var(--select); }
.cg-tile:active { transform: translateY(2px); }
.cg-tile-icon { position: relative; width: 34px; height: 34px; display: grid; place-items: center; background: #141416; box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .55), inset -2px -2px 0 rgba(255, 255, 255, .06); }
.cg-tile-icon img { width: 28px; height: 28px; object-fit: contain; }
.cg-tile:hover .cg-tile-icon img { animation: cg-coin .5s steps(2) infinite; }
.cg-tile-shop { border-color: var(--gold); background: linear-gradient(180deg, #5a4316, #3a2a0b); }
.cg-tile-shop .cg-tile-label { color: var(--gold); }
.cg-tile-shop:hover { border-color: #ffd34d; }
/* pixel sparkle that twinkles on the diamond */
.cg-spark { position: absolute; top: 3px; right: 3px; width: 6px; height: 6px; background:
  linear-gradient(#fff, #fff) center / 2px 6px no-repeat, linear-gradient(#fff, #fff) center / 6px 2px no-repeat;
  animation: cg-twinkle 1.6s steps(1) infinite; }
@keyframes cg-twinkle { 0%, 60% { opacity: 0; } 61%, 80% { opacity: 1; } 81%, 100% { opacity: 0; } }
.cg-burger { display: none; width: 46px; height: 46px; background: #0f0f11; border: 4px solid #f2f2f2; color: #fff; cursor: pointer; clip-path: var(--notch); }
.cg-burger svg { width: 20px; height: 20px; }

/* Page head: a slice of the game world */
.cg-pagehead { position: relative; overflow: hidden; border-bottom: 4px solid #000; background: #101012; }
.cg-pagehead::before { content: ""; position: absolute; inset: 0; background: url("/welcome%20to%20cybergyn.png") center 62% / cover no-repeat; image-rendering: pixelated; opacity: .32; filter: saturate(.85); }
.cg-pagehead::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(16,16,18,.95) 25%, rgba(16,16,18,.55)); }
.cg-pagehead .cg-wrap { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 36px 0 32px; }
.cg-crumbs { display: flex; flex-wrap: wrap; gap: 8px; font: 700 11.5px/1.2 var(--label); text-transform: uppercase; color: var(--faint); margin-bottom: 12px; text-shadow: 2px 2px 0 #000; }
.cg-crumbs a { color: var(--muted); }
.cg-crumbs a:hover { color: var(--select); }
.cg-crumbs > span:last-child { color: var(--select); }
.cg-pagehead h1 { font-size: clamp(30px, 4.4vw, 50px); margin: 0; }
.cg-pagehead-art { width: 112px; height: 112px; flex: none; display: grid; place-items: center; }
.cg-pagehead-art img { width: 80px; height: 80px; object-fit: contain; }
.cg-dup-title { display: none !important; }

/* Main canvas */
:where(main.cg-main) { display: block; }
main.cg-main { width: min(var(--wrap), 100% - 40px); margin: 40px auto 80px; }
main.cg-main.home-modern-page { width: 100%; margin: 0; }
.support-language-switch, .home-modern-language { display: none !important; }

/* Footer: grass on top, dirt below */
.cg-footer { position: relative; margin-top: 40px; padding: 64px 0 26px; background: #1e140c; color: #c9b9a6; font-size: 14.5px; }
.cg-footer::before { content: ""; position: absolute; left: 0; right: 0; top: -36px; height: 40px; background: var(--grass) 0 0 / 64px 40px repeat-x; }
.cg-footer-grid { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 40px; }
.cg-footer-brand img { height: 62px; width: auto; display: block; margin-bottom: 14px; mix-blend-mode: screen; image-rendering: auto; }
.cg-footer-brand p { max-width: 36ch; }
.cg-footer h4 { font: 700 13px/1.2 var(--label); text-transform: uppercase; color: var(--gold); margin-bottom: 14px; }
.cg-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.cg-footer ul a { color: #e3d6c5; }
.cg-footer ul a:hover { color: var(--select); }
.cg-social { display: flex; gap: 10px; margin-top: 18px; }
.cg-social a { width: 46px; height: 46px; display: grid; place-items: center; background: #0f0f11; border: 3px solid #6b5640; }
.cg-social a:hover { border-color: var(--select); }
.cg-social img { width: 26px; height: 26px; object-fit: contain; }
.cg-footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 44px; padding-top: 20px; border-top: 4px dotted #4a3524; font-size: 13px; color: #9a8672; }
.cg-footer-bottom a { color: #9a8672; }
.cg-footer-bottom a:hover { color: var(--select); }

/* 5. Home ------------------------------------------------------------- */
.cg-hero { position: relative; min-height: min(820px, 100svh - var(--head-h)); display: flex; flex-direction: column; overflow: hidden; border-bottom: 4px solid #000; background: #0d0d0f; }
/* No z-index on the hero layers: the logo uses mix-blend-mode to drop its black backdrop */
.cg-hero-bg {
  position: absolute; inset: 0; image-rendering: pixelated;
  background:
    radial-gradient(ellipse 70% 60% at 50% 42%, rgba(13,13,15,.5), rgba(13,13,15,.9) 75%),
    linear-gradient(180deg, rgba(13,13,15,.5), transparent 30%, transparent 70%, rgba(13,13,15,.85)),
    url("/welcome%20to%20cybergyn.png") center 58% / cover no-repeat;
}
.cg-hero-inner { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 56px 20px 150px; }
.cg-hero-logo { width: min(620px, 92vw); height: auto; mix-blend-mode: screen; image-rendering: auto; filter: drop-shadow(0 6px 0 rgba(0,0,0,.6)); }
.cg-hero h1 { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.cg-hero-tag { font: 700 clamp(18px, 2.2vw, 24px)/1.35 var(--pixel); color: #fff; text-shadow: 3px 3px 0 #000; max-width: 34ch; margin: 18px 0 30px; }
.cg-hero-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.cg-hero-cta .cg-btn { min-height: 56px; padding: 12px 26px; font-size: 17px; }
.cg-hero-status { display: inline-flex; align-items: center; gap: 12px; margin-bottom: 20px; padding: 8px 14px; background: rgba(0,0,0,.65); border: 3px solid var(--slot-line); }
.cg-hero-meta { margin-top: 22px; font: 700 12px/1.6 var(--label); color: #d0d0d6; text-transform: uppercase; text-shadow: 2px 2px 0 #000; }
.cg-hero-meta b { color: var(--coin); font-weight: 700; }
.cg-hero-ground { position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; height: 150px; }
.cg-hero-ground::before { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 40px; background: var(--grass) 0 0 / 64px 40px repeat-x; box-shadow: 0 -2px 0 rgba(0,0,0,.4); }
.header-walkers { position: absolute; inset: 0; overflow: hidden; }
.header-walker { position: absolute; left: 0; bottom: 22px; width: 96px; height: 96px; background-repeat: no-repeat; will-change: transform; }
.header-walkers-toggle { position: absolute; right: 16px; top: 8px; z-index: 2; width: 34px; height: 34px; background: #0f0f11; color: #fff; border: 3px solid #f2f2f2; cursor: pointer; font-size: 12px; }

/* HUD strip: slots with counts, like potions in the game */
.cg-hud { position: relative; z-index: 4; margin-top: -2px; background: #232326; border-bottom: 4px solid #000; box-shadow: inset 0 4px 0 #3a3a3f; }
.cg-hud .cg-wrap { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; padding: 22px 0; }
.cg-hud-item { display: flex; align-items: center; gap: 14px; }
.cg-hud-slot { position: relative; width: 72px; height: 72px; flex: none; display: grid; place-items: center; background: #141416; border: 3px solid var(--slot-line); box-shadow: var(--sink); }
.cg-hud-slot img { width: 50px; height: 50px; object-fit: contain; }
.cg-hud-slot b { position: absolute; right: 3px; bottom: 0; font: 700 18px/1 var(--pixel); color: #fff; text-shadow: 2px 2px 0 #000, -1px -1px 0 #000; }
.cg-hud-item strong { display: block; font: 700 14px/1.2 var(--label); text-transform: uppercase; color: #fff; text-shadow: 2px 2px 0 #000; }
.cg-hud-item span { font-size: 14px; color: var(--muted); }

.cg-section { padding: 96px 0 0; }
.cg-section:last-child { padding-bottom: 110px; }

/* Character select */
.cg-classes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.cg-class { padding: 0; display: flex; flex-direction: column; }
.cg-class-stage { position: relative; height: 210px; display: grid; place-items: end center; padding-bottom: 34px; background: var(--grass) 0 100% / 64px 40px repeat-x, linear-gradient(180deg, #1b2a3a, #2b4a5a 85%); border-bottom: 4px solid #000; overflow: hidden; }
.cg-class-stage img { position: relative; width: 128px; height: 128px; filter: drop-shadow(4px 4px 0 rgba(0,0,0,.45)); transition: transform .15s steps(3); }
.cg-class:hover .cg-class-stage img { transform: translateY(-8px); }
.cg-class.mage .cg-class-stage { background: var(--grass) 0 100% / 64px 40px repeat-x, linear-gradient(180deg, #24173a, #45306a 85%); }
.cg-class.archer .cg-class-stage { background: var(--grass) 0 100% / 64px 40px repeat-x, linear-gradient(180deg, #13301e, #2a5a3a 85%); }
.cg-class-body { padding: 22px 24px 26px; }
.cg-class h3 { font-size: 28px; margin-bottom: 4px; }
.cg-class .cg-label { display: block; margin-bottom: 12px; }
.cg-class.knight .cg-label { color: var(--hp); }
.cg-class.mage .cg-label { color: #c98bff; }
.cg-class.archer .cg-label { color: var(--xp); }
.cg-class p { color: #d0d0d6; margin: 0 0 16px; }
.cg-class .cg-bar { --c: var(--hp); }
.cg-class.mage .cg-bar { --c: var(--mp); }
.cg-class.archer .cg-bar { --c: var(--xp); }
.cg-class .cg-bar i { width: calc(100% - 4px); }
.cg-class-gear { display: flex; gap: 6px; margin-top: 16px; }
.cg-class-gear span { width: 44px; height: 44px; display: grid; place-items: center; background: #141416; border: 3px solid var(--slot-line); box-shadow: var(--sink); }
.cg-class-gear img { width: 30px; height: 30px; object-fit: contain; }

/* Bestiary = inventory grid */
.cg-bag { padding: 20px; }
.cg-bag-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.cg-bag-head span { font: 700 14px/1 var(--label); color: #fff; text-transform: uppercase; text-shadow: 2px 2px 0 #000; }
.cg-bag-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 10px; }
.cg-mob { position: relative; aspect-ratio: 1; display: grid; place-items: center; background: #141416; border: 3px solid var(--slot-line); box-shadow: var(--sink); }
.cg-mob img { width: 72%; height: 72%; object-fit: contain; transition: transform .12s steps(2); }
.cg-mob b { position: absolute; right: 4px; bottom: 2px; font: 700 15px/1 var(--pixel); color: #fff; text-shadow: 2px 2px 0 #000, -1px -1px 0 #000; }
.cg-mob.is-boss b { color: var(--hp); }
.cg-mob:hover { border-color: var(--select); }
.cg-mob:hover img { transform: scale(1.12); }
.cg-mob-tip { position: absolute; left: 50%; bottom: calc(100% + 6px); transform: translateX(-50%); padding: 5px 9px; background: #000; border: 2px solid #f2f2f2; color: #fff; font: 700 13px/1.2 var(--pixel); white-space: nowrap; pointer-events: none; opacity: 0; z-index: 3; }
.cg-mob:hover .cg-mob-tip, .cg-mob:focus-visible .cg-mob-tip { opacity: 1; }
.cg-bag-foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 16px; font: 700 13px/1.2 var(--label); text-transform: uppercase; color: #fff; text-shadow: 2px 2px 0 #000; }
.cg-bag-foot b { color: var(--coin); }

/* Save comparison */
.cg-versus { display: grid; grid-template-columns: 1fr auto 1fr; gap: 18px; align-items: stretch; }
.cg-versus .cg-panel h3 { font-size: 28px; }
.cg-versus-mid { display: grid; place-items: center; }
.cg-versus-mid b { width: 84px; height: 84px; display: grid; place-items: center; background: var(--hp); color: #fff; font: 700 44px/1 var(--pixel); border: 4px solid #000; box-shadow: inset 0 -6px 0 #8a0b0c, inset 0 5px 0 #ff6a6b; text-shadow: 3px 3px 0 #000; clip-path: var(--notch); }
.cg-checks { list-style: none; padding: 0 !important; margin: 0; display: grid; gap: 12px; }
.cg-checks li { display: flex; gap: 12px; align-items: center; color: #e6e6ea; }
.cg-checks li::before { content: ""; flex: none; width: 26px; height: 26px; background: #141416 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='12' shape-rendering='crispEdges'%3E%3Cpath fill='%23ffffff' d='M12 0h2v2h-2zM10 2h2v2h-2zM8 4h2v2H8zM6 6h2v2H6zM4 8h2v2H4zM2 6h2v2H2zM0 4h2v2H0z'/%3E%3C/svg%3E") center / 14px 12px no-repeat; border: 3px solid var(--slot-line); }
.cg-chip { display: inline-block; margin-bottom: 14px; padding: 6px 10px; font: 700 12px/1 var(--label); text-transform: uppercase; color: #000; background: var(--select); }
.cg-chip.is-blue { background: var(--mp); color: #fff; text-shadow: 2px 2px 0 #000; }
.cg-callout { margin-top: 18px; padding: 16px 20px; background: rgba(0,0,0,.6); border-left: 6px solid var(--hp); font-family: var(--pixel); font-size: 17px; color: #fff; text-shadow: 2px 2px 0 #000; }

/* Quest log */
.cg-quest { padding: 0; }
.cg-quest-head { display: flex; align-items: center; gap: 14px; padding: 16px 22px; background: rgba(0,0,0,.4); border-bottom: 4px solid var(--edge); }
.cg-quest-head img { width: 40px; height: 40px; }
.cg-quest-head span { font: 700 16px/1 var(--label); text-transform: uppercase; color: #fff; text-shadow: 2px 2px 0 #000; }
.cg-quest ol { list-style: none; margin: 0; padding: 8px 0 !important; counter-reset: q; }
.cg-quest li { display: grid; grid-template-columns: 56px 1fr auto; align-items: center; gap: 16px; padding: 16px 22px; border-bottom: 2px solid rgba(0,0,0,.35); }
.cg-quest li:last-child { border-bottom: 0; }
.cg-quest li > span { width: 56px; height: 56px; display: grid; place-items: center; background: #141416; border: 3px solid var(--slot-line); box-shadow: var(--sink); }
.cg-quest li > span img { width: 36px; height: 36px; object-fit: contain; }
.cg-quest h3 { font-size: 19px; margin: 0 0 2px; }
.cg-quest p { margin: 0; color: var(--muted); font-size: 15px; }
.cg-quest li > b { font: 700 13px/1 var(--label); color: var(--select); text-shadow: 2px 2px 0 #000; }
.cg-quest-foot { padding: 14px 22px; background: rgba(0,0,0,.35); border-top: 4px solid var(--edge); color: var(--muted); font-size: 14.5px; }
.cg-feedback { display: flex; align-items: center; gap: 20px; margin-top: 22px; }
.cg-feedback > img { width: 56px; height: 56px; }
.cg-feedback div { flex: 1; }
.cg-feedback h3 { margin: 0 0 4px; }
.cg-feedback p { margin: 0; color: var(--muted); }

/* Promo */
.cg-promo { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; align-items: center; padding: 40px; background: linear-gradient(180deg, rgba(40, 26, 70, .95), rgba(24, 16, 44, .96)); border-color: #7a5ab8; }
.cg-promo h2 { font-size: clamp(26px, 3.2vw, 38px); margin: 12px 0; }
.cg-promo p { color: #ddd4f0; }
.cg-promo .cg-checks { margin: 20px 0 28px; }
.cg-promo-art img { display: block; width: 100%; height: auto; image-rendering: auto; filter: drop-shadow(0 10px 0 rgba(0,0,0,.35)); }
.cg-coins { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 6px; }
.cg-coins span { display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px; background: rgba(0,0,0,.5); border: 3px solid #5b4590; font: 700 13px/1 var(--label); color: #fff; text-transform: uppercase; text-shadow: 2px 2px 0 #000; }
.cg-coins img { width: 22px; height: 22px; }

/* Screenshot window */
.cg-window { padding: 0; }
.cg-window-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px 10px 18px; border-bottom: 4px solid var(--edge); background: rgba(0,0,0,.35); }
.cg-window-bar span { font: 700 14px/1 var(--label); text-transform: uppercase; color: #fff; text-shadow: 2px 2px 0 #000; }
.cg-window-x { width: 34px; height: 34px; display: grid; place-items: center; background: #4a4a50; border: 3px solid #77777f; color: #fff; font: 700 18px/1 var(--pixel); }
.feature-carousel { position: relative; overflow: hidden; background: #000; }
.feature-carousel-track { display: flex; transition: transform .35s steps(8); }
.feature-carousel-slide { flex: 0 0 100%; margin: 0; aspect-ratio: 1600 / 847; }
.feature-carousel-slide img { width: 100%; height: 100%; object-fit: contain; display: block; }
.carousel-hit { position: absolute; top: 50%; transform: translateY(-50%); width: 50px; height: 50px; display: grid; place-items: center; background: #0f0f11; color: #fff; border: 4px solid #f2f2f2; cursor: pointer; font-size: 16px; clip-path: var(--notch); }
.carousel-hit:hover { border-color: var(--select); color: var(--select); }
.carousel-hit-left { left: 14px; }
.carousel-hit-right { right: 14px; }
.feature-carousel-dots { display: flex; justify-content: center; gap: 8px; padding: 14px; background: rgba(0,0,0,.35); border-top: 4px solid var(--edge); }
.cg-window .feature-carousel-dots { position: static; }
.feature-carousel-dot { width: 14px; height: 14px; padding: 0; border: 3px solid var(--slot-line); background: #141416; cursor: pointer; }
.feature-carousel-dot.is-active { background: var(--select); border-color: #000; }

/* Final CTA: back outside, on the grass */
.cg-final { position: relative; text-align: center; padding: 70px 20px 0; }
.cg-final h2 { font-size: clamp(28px, 4vw, 46px); margin: 14px 0 12px; }
.cg-final p { color: #d0d0d6; max-width: 52ch; margin: 0 auto 28px; font-size: 17px; }
.cg-final .cg-hero-cta { margin-bottom: 36px; }
.cg-section.cg-section-final { padding-bottom: 0; }
.cg-party { position: relative; z-index: 1; margin-bottom: 28px; display: flex; justify-content: center; align-items: flex-end; gap: 6px; }
.cg-party img { width: 96px; height: 96px; filter: drop-shadow(4px 4px 0 rgba(0,0,0,.45)); }
.cg-party img.is-mob { width: 112px; height: 112px; transform: scaleX(-1); margin-left: 40px; }

/* 6. Bestiary --------------------------------------------------------- */
.monsters-topbar h2, .monsters-help { display: none; }
.monsters-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.monsters-section-title { font-size: 28px; margin: 48px 0 18px; display: flex; align-items: center; gap: 14px; }
.monsters-section-title::after { content: ""; flex: 1; height: 4px; background: repeating-linear-gradient(90deg, var(--edge) 0 8px, transparent 8px 16px); }
.monster-card-link { color: inherit; display: block; }
.monster-card { height: 100%; position: relative; background: #141416; border: 3px solid var(--slot-line); box-shadow: var(--sink); }
.monster-card-link:hover .monster-card { border-color: var(--select); }
.monster-card-body { display: flex; flex-direction: column-reverse; align-items: center; padding: 14px 10px 12px; text-align: center; }
.monster-card-figure { width: 100%; height: 96px; display: grid; place-items: center; margin-bottom: 8px; }
.monster-card-image { width: 84px; height: 84px; object-fit: contain; transition: transform .12s steps(2); }
.monster-card-link:hover .monster-card-image { transform: scale(1.12); }
.monster-card h3 { font-size: 15px; margin: 0; text-shadow: 2px 2px 0 #000; }
.monster-card-category, .monster-card-action { display: none; }
.monsters-grid-bosses .monster-card { border-color: #7a1f20; background: linear-gradient(180deg, #2a1010, #141416); }
.monsters-grid-bosses .monster-card-link:hover .monster-card { border-color: var(--hp); }

.monster-detail-page { display: grid; gap: 20px; }
.monster-detail-section-title { display: none; }
.monster-detail-hero { display: flex; align-items: center; gap: 28px; }
.monster-detail-figure { order: -1; width: 168px; height: 168px; flex: none; display: grid; place-items: center; }
.monster-detail-image { width: 132px; height: 132px; object-fit: contain; }
.monster-detail-copy { flex: 1; min-width: 0; }
.monster-stats-section { display: contents; }
.monster-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.monster-stat-card { padding: 14px 16px; }
.monster-stat-card strong { display: block; font: 700 12px/1.2 var(--label); text-transform: uppercase; color: var(--muted); text-shadow: 2px 2px 0 #000; }
.monster-stat-card span { display: block; font: 700 28px/1.1 var(--pixel); color: var(--coin); text-shadow: 2px 2px 0 #000; margin-top: 4px; }
.monster-stat-card:nth-child(3) span { color: #ff5a5c; }
.monster-drops-section h3 { font-size: 24px; }
.monster-drops-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.monster-drop-card { display: flex; align-items: center; gap: 12px; padding: 10px 12px; }
.monster-drop-card:hover { border-color: var(--select); }
.monster-drop-card a { color: inherit; }
.monster-drop-icon { width: 52px; height: 52px; flex: none; object-fit: contain; padding: 4px; background: #0b0b0d; border: 2px solid transparent; }
.monster-drop-card h4 { margin: 0 0 2px; font-size: 15px; text-shadow: 2px 2px 0 #000; }
.monster-drop-card p { margin: 0; font-size: 13px; color: var(--muted); }

/* 7. Items ------------------------------------------------------------ */
.arsenal-header h2, .items-page > header .lead { display: none; }
.arsenal-rarity-legend { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.rarity-chip { padding: 8px 12px; font: 700 12.5px/1 var(--label); text-transform: uppercase; cursor: pointer; background: #0f0f11; color: var(--c, var(--r-common)); border: 3px solid var(--c, #888); text-shadow: 2px 2px 0 #000; }
.rarity-chip:hover, .rarity-chip.is-active, .rarity-chip[aria-pressed="true"] { background: var(--c); color: #000; text-shadow: none; }
.rarity-chip-common { --c: var(--r-common); } .rarity-chip-uncommon { --c: var(--r-uncommon); } .rarity-chip-rare { --c: var(--r-rare); }
.rarity-chip-epic { --c: var(--r-epic); } .rarity-chip-legendary { --c: var(--r-legendary); } .rarity-chip-mythic { --c: var(--r-mythic); }
.arsenal-quick-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.arsenal-quick-nav a { padding: 8px 12px; background: #0f0f11; border: 3px solid var(--slot-line); color: #fff; font: 700 14px/1 var(--pixel); }
.arsenal-quick-nav a:hover { border-color: var(--select); color: var(--select); }
.items-page-subtitle, .shop-price-group > h3 { font-size: 28px; margin: 44px 0 18px; display: flex; align-items: center; gap: 14px; }
.items-page-subtitle::after, .shop-price-group > h3::after { content: ""; flex: 1; height: 4px; background: repeating-linear-gradient(90deg, var(--edge) 0 8px, transparent 8px 16px); }
.items-set-grid, .items-section-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }
.items-section { padding: 18px; }
.items-section > h3 { font-size: 21px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.arsenal-section-toggle { background: #0f0f11; border: 3px solid #f2f2f2; color: #fff; padding: 2px 9px; cursor: pointer; font: 700 14px/1 var(--pixel); }
.items-equipment-layout {
  list-style: none; padding: 0 !important; margin: 0; display: grid; gap: 6px; grid-template-columns: repeat(3, 1fr);
  grid-template-areas: "head-left head head-right" "shield robe backpack" ". light-armor ." "left armor right" "sword legs belt" "bow boots ." "wand . .";
}
.items-equipment-layout:not(:has(.slot-backpack)) { grid-template-areas: "head-left head head-right" "shield robe ." ". light-armor ." "left armor right" "sword legs belt" "bow boots ." "wand . ."; }
.items-equipment-layout:not(:has(.slot-shield)) { grid-template-areas: "head-left head head-right" ". robe backpack" ". light-armor ." "left armor right" "sword legs belt" "bow boots ." "wand . ."; }
.items-equipment-layout:not(:has(.slot-backpack)):not(:has(.slot-shield)) { grid-template-areas: "head-left head head-right" ". robe ." ". light-armor ." "left armor right" "sword legs belt" "bow boots ." "wand . ."; }
.slot-head { grid-area: head; } .slot-head-left { grid-area: head-left; } .slot-head-right { grid-area: head-right; }
.slot-armor { grid-area: armor; } .slot-light-armor { grid-area: light-armor; } .slot-robe { grid-area: robe; }
.slot-sword { grid-area: sword; } .slot-bow { grid-area: bow; } .slot-wand { grid-area: wand; }
.slot-legs { grid-area: legs; } .slot-boots { grid-area: boots; } .slot-left-glove { grid-area: right; } .slot-right-glove { grid-area: left; }
.slot-belt { grid-area: belt; } .slot-backpack { grid-area: backpack; } .slot-shield { grid-area: shield; }
.item-slot, .items-list-entry, .item-variant-row {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  min-height: 84px; padding: 8px 4px; text-align: center; color: #e2e2e6; font-size: 12px; font-weight: 600; line-height: 1.25;
  --rarity-color: var(--slot-line); border-color: var(--rarity-color);
}
.item-slot a, .items-list-entry a, .item-variant-row a { color: inherit; display: contents; }
.item-slot:hover, .items-list-entry:hover, .item-variant-row:hover { border-color: var(--select); }
.item-slot img, .items-list-entry img, .item-variant-row img { width: 40px; height: 40px; object-fit: contain; }
.item-variant-slot { padding: 0; min-height: 0; background: none; border: 0; box-shadow: none; }
.item-variant-stack { display: grid; gap: 6px; width: 100%; }
.item-variant-row { min-height: 74px; }
.items-list, .items-upgrade-grid { list-style: none; padding: 0 !important; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; }
.items-set-extra { margin-top: 8px; }
.item-slot:has(.rarity-name-uncommon), .items-list-entry:has(.rarity-name-uncommon), .item-variant-row:has(.rarity-name-uncommon), .items-list-entry[data-item-name*="Uncommon"] { --rarity-color: var(--r-uncommon); }
.item-slot:has(.rarity-name-rare), .items-list-entry:has(.rarity-name-rare), .item-variant-row:has(.rarity-name-rare), .items-list-entry[data-item-name*="Rare"] { --rarity-color: var(--r-rare); }
.item-slot:has(.rarity-name-epic), .items-list-entry:has(.rarity-name-epic), .item-variant-row:has(.rarity-name-epic) { --rarity-color: var(--r-epic); }
.item-slot:has(.rarity-name-legendary), .items-list-entry:has(.rarity-name-legendary), .item-variant-row:has(.rarity-name-legendary) { --rarity-color: var(--r-legendary); }
.item-slot:has(.rarity-name-mythic), .items-list-entry:has(.rarity-name-mythic), .item-variant-row:has(.rarity-name-mythic) { --rarity-color: var(--r-mythic); }
.rarity-uncommon { border-color: var(--r-uncommon) !important; } .rarity-rare { border-color: var(--r-rare) !important; }
.rarity-epic { border-color: var(--r-epic) !important; } .rarity-legendary { border-color: var(--r-legendary) !important; } .rarity-mythic { border-color: var(--r-mythic) !important; }
.rarity-name-uncommon { color: var(--r-uncommon) !important; } .rarity-name-rare { color: var(--r-rare) !important; }
.rarity-name-epic { color: var(--r-epic) !important; } .rarity-name-legendary { color: var(--r-legendary) !important; } .rarity-name-mythic { color: var(--r-mythic) !important; }
.item-rarity-icon[class*="rarity-"] { border: 0 !important; }

.shop-items-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 12px; }
.shop-item-card { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 16px 12px; }
.shop-item-card h4 { font-size: 15px; order: 2; margin: 10px 0 6px; }
.shop-item-art { order: 1; width: 72px; height: 72px; display: grid; place-items: center; }
.shop-item-art img { width: 50px; height: 50px; object-fit: contain; }
.shop-item-no-image { font-size: 10px; color: var(--faint); padding: 4px; }
.shop-item-price { order: 3; margin: 0; font: 700 14px/1.2 var(--pixel); color: var(--cyan); text-shadow: 2px 2px 0 #000; }
.shop-item-diamond::before { content: ""; display: inline-block; width: 18px; height: 18px; margin-right: 6px; vertical-align: -3px; background: url("/Diamond.png") center/contain no-repeat; image-rendering: pixelated; }

.item-detail-page { display: grid; gap: 20px; }
.item-detail-hero { display: flex; align-items: center; gap: 28px; }
.item-detail-art { width: 148px; height: 148px; flex: none; display: grid; place-items: center; }
.item-detail-art img { width: 108px; height: 108px; object-fit: contain; }
.item-info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.item-info-card { padding: 14px 16px; }
.item-info-card strong { display: block; font: 700 12px/1.2 var(--label); text-transform: uppercase; color: var(--muted); text-shadow: 2px 2px 0 #000; }
.item-info-card span { display: block; font: 700 22px/1.2 var(--pixel); color: var(--coin); margin-top: 4px; text-shadow: 2px 2px 0 #000; }
.item-source-list { width: 100%; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.item-source-card { display: flex; align-items: center; gap: 12px; padding: 10px 12px; color: inherit; }
.item-source-card:hover { border-color: var(--select); }
.item-source-image { width: 48px; height: 48px; object-fit: contain; }
.item-source-card strong { flex: 1; color: #fff; font: 700 15px/1.2 var(--pixel); }
.item-source-card span { color: var(--coin); font: 700 12px/1 var(--label); white-space: nowrap; }

/* 8. Shop ------------------------------------------------------------- */
.support-launch-page { display: grid; gap: 28px; }
.support-launch-hero { padding: 40px; background: linear-gradient(180deg, rgba(40, 26, 70, .95), rgba(24, 16, 44, .96)); border-color: #7a5ab8; }
.support-launch-hero h2 { font-size: clamp(28px, 4vw, 46px); max-width: 20ch; }
.support-hero-badge { display: inline-block; padding: 6px 10px; margin-bottom: 18px; background: var(--select); color: #000; font: 700 12px/1 var(--label); text-transform: uppercase; }
.support-hero-lead { max-width: 60ch; color: #ddd4f0 !important; }
.support-dual-version { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 8px 0 14px; font-family: var(--pixel); }
.support-dual-version strong { padding: 6px 10px; background: var(--gold); color: #1b1100; font: 700 13px/1 var(--label); }
.support-dual-version b { color: var(--select); font-size: 22px; }
.support-dual-version span { color: #fff; font-size: 18px; text-shadow: 2px 2px 0 #000; }
.support-launch-note { color: #ddd4f0 !important; max-width: 70ch; }
.support-trust-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.support-trust-item { padding: 14px 16px; }
.support-trust-item strong { display: block; font: 700 16px/1.2 var(--pixel); color: var(--select); margin-bottom: 4px; text-shadow: 2px 2px 0 #000; }
.support-trust-item span { color: var(--muted); font-size: 14.5px; }
.support-launch-urgency, .support-version-benefit { padding: 12px 16px; background: rgba(0,0,0,.5); border-left: 6px solid var(--gold); color: #eee; }
.support-section-head { margin: 16px 0 4px; }
.support-section-head h3, .support-premium-head h3 { font-size: 30px; margin-bottom: 6px; }
.support-section-promise { color: var(--muted); }
.support-offers, .support-vip-block, .support-premium-single { display: grid; gap: 16px; }
.support-offer-grid, .support-vip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.support-premium-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.support-offer-card, .support-premium-card { display: flex; flex-direction: column; gap: 8px; padding: 20px; text-align: center; }
.support-offer-card:hover, .support-premium-card:hover { border-color: var(--select); }
.support-offer-card-featured, .support-offer-card-popular, .support-offer-card-best, .support-premium-card-popular, .support-premium-card-ultimate { border-color: var(--gold); }
.support-offer-tag { align-self: center; padding: 5px 10px; background: var(--gold); color: #1b1100; font: 700 11.5px/1 var(--label); text-transform: uppercase; white-space: nowrap; }
.support-offer-art, .support-premium-art, .support-vip-art { margin: 4px auto; width: 100%; max-width: 200px; aspect-ratio: 1; display: grid; place-items: center; }
.support-offer-art img, .support-premium-art img, .support-vip-art img { width: 100%; height: 100%; object-fit: contain; image-rendering: auto; }
.support-offer-card h4, .support-premium-card h4, .support-offer-card h3, .support-premium-card h3 { font-size: 21px; margin: 0; }
.support-offer-total, .support-saving, .support-bonus-word { color: var(--xp); font-weight: 700; font-size: 14px; }
.support-offer-price { font: 700 30px/1.1 var(--pixel); color: var(--coin); margin: 4px 0; text-shadow: 3px 3px 0 #000; }
.support-premium-equation, .support-premium-highlight { color: #e6e6ea; font-size: 14px; }
.support-premium-equation strong, .support-premium-equation span { display: block; }
.support-premium-highlight { font-family: var(--pixel); color: var(--select); }
.support-payment-actions { display: grid; gap: 10px; margin-top: auto; }

/* ===== Medieval carved pieces (pixel art in /assets/ui, drawn at 1x, shown at 2x) =====
   Generator: C:/site-cybergyn-tools/medieval-ui/generate-medieval-ui.js */
:root { --engrave-gold: 0 -1px 0 #000, 0 2px 0 #0a0603; --carved-gold: #d6bb84; }
@keyframes cg-coin { 50% { transform: translateY(-4px); } }

/* Buy buttons: gold-framed wooden plaque (Pix) and iron-framed stone plaque (PayPal) */
.support-payment-actions .support-btn,
main .cg-btn-gold, .cg-btn-gold {
  width: 100%; min-height: 64px; justify-content: flex-start; gap: 10px; padding: 2px 8px 2px 2px;
  text-align: left; clip-path: none !important; border-radius: 0;
  border: 14px solid transparent !important;
  border-image: url("/assets/ui/plaque-gold.png") 14 fill / 28px / 0 round !important;
  background: none !important; box-shadow: none !important; image-rendering: pixelated;
  color: var(--carved-gold) !important; text-shadow: var(--engrave-gold) !important;
  transition: transform .06s steps(1), filter .12s;
}
.support-payment-actions .support-btn:hover, .cg-btn-gold:hover { filter: brightness(1.18); color: #ead3a0 !important; }
.support-payment-actions .support-btn:active, .cg-btn-gold:active { transform: translateY(2px); filter: brightness(.95); }
.support-payment-actions .support-btn-paypal { border-image-source: url("/assets/ui/plaque-iron.png") !important; color: #c9d0d8 !important; text-shadow: 0 -1px 0 #000, 0 2px 0 #000 !important; }

.cg-buy-icon {
  width: 48px; height: 48px; flex: none; display: grid; place-items: center; margin: -8px 0 -8px -8px;
  background: url("/assets/ui/medallion-gold.png") center / 48px 48px no-repeat; image-rendering: pixelated;
}
.support-btn-paypal .cg-buy-icon { background-image: url("/assets/ui/medallion-iron.png"); }
.cg-buy-icon img, .cg-buy-icon svg { width: 22px; height: 22px; }
.support-btn:hover .cg-buy-icon img { animation: cg-coin .5s steps(2) infinite; }
.cg-buy-text { display: flex; flex-direction: column; min-width: 0; font: 900 18px/1.05 "Cinzel", Georgia, serif; letter-spacing: .04em; text-transform: uppercase; }
.cg-buy-text small { order: 2; margin-top: 4px; font: 600 11.5px/1.2 var(--font); letter-spacing: 0; text-transform: none; color: #bfae8c; text-shadow: 0 1px 0 #000; }
.support-btn-paypal .cg-buy-text small { order: 0; margin: 0 0 3px; font: 700 10.5px/1 var(--label); text-transform: uppercase; color: #8e99a6; }
.support-btn-paypal .cg-buy-text { font-size: 19px; text-transform: none; }
.support-btn-local::after { content: none !important; }

/* The home "see packages" button reuses the gold plaque with a diamond medallion */
.cg-btn-gold { width: auto; padding: 2px 18px 2px 2px; font: 900 16px/1 "Cinzel", Georgia, serif !important; letter-spacing: .04em; text-transform: uppercase; }
.cg-btn-gold::before { content: ""; width: 48px; height: 48px; flex: none; margin: -8px 0 -8px -8px; box-shadow: none; background: url("/Diamond.png") center / 22px no-repeat, url("/assets/ui/medallion-gold.png") center / 48px no-repeat; }

/* Prices: carved cartouche with a gem at each tip */
.support-offer-price, .shop-item-price {
  align-self: center; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 50px; min-width: 140px; padding: 0 4px; margin: 6px auto;
  border: 16px solid transparent; border-width: 16px 24px;
  border-image: url("/assets/ui/cartouche-gold.png") 8 14 fill / 16px 28px / 0 round;
  image-rendering: pixelated; white-space: nowrap;
  font: 900 21px/1 "Cinzel", Georgia, serif; color: var(--carved-gold); text-shadow: var(--engrave-gold);
}
.shop-item-price { min-width: 0; font-size: 14px; }
.shop-item-diamond::before { width: 16px; height: 16px; margin: 0; }

/* Tags ("Most popular", "Best value"): swallow-tailed red ribbon */
.support-offer-tag {
  align-self: center; display: inline-flex; align-items: center; height: 34px; padding: 0 6px;
  background: none !important; border: 12px solid transparent; border-width: 12px 20px;
  border-image: url("/assets/ui/ribbon-red.png") 6 10 fill / 12px 20px / 0 round; image-rendering: pixelated;
  font: 900 12px/1 "Cinzel", Georgia, serif !important; letter-spacing: .06em; color: #e6cf9c !important; text-shadow: 0 2px 0 #12030a;
}

/* Package cards: carved frames, gold for the highlighted ones */
.support-offer-card, .support-premium-card {
  clip-path: none; box-shadow: none; background: none;
  border: 12px solid transparent; padding: 18px 16px 20px;
  border-image: url("/assets/ui/frame-iron.png") 18 fill / 36px / 0 round; image-rendering: pixelated;
  transition: transform .15s steps(3), filter .15s;
}
.support-offer-card:hover, .support-premium-card:hover { transform: translateY(-4px); filter: brightness(1.08); }
.support-offer-card-featured, .support-offer-card-popular, .support-offer-card-best,
.support-premium-card-popular, .support-premium-card-ultimate { border-image-source: url("/assets/ui/frame-gold.png"); }
.support-offer-card > *, .support-premium-card > * { image-rendering: auto; }
.support-offer-card img, .support-premium-card img { image-rendering: auto; }

/* Section title dividers: beaded gold bar ending in a ruby boss */
.cg-title::after, .items-page-subtitle::after, .shop-price-group > h3::after, .monsters-section-title::after {
  height: 34px !important;
  background: url("/assets/ui/divider-cap.png") right center / 34px 34px no-repeat,
              url("/assets/ui/divider-line.png") left center / 16px 12px repeat-x !important;
  image-rendering: pixelated;
}
.support-payment-note, .support-page-footer-note { color: var(--faint); font-size: 13.5px; }
.support-receipt-card { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.support-receipt-kicker { font: 700 12px/1 var(--label); color: var(--select); text-transform: uppercase; }

/* Support / contact */
.support-hero { margin-bottom: 20px; }
.support-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.support-card { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.support-card:hover { border-color: var(--select); }
.support-card .support-btn { margin-top: auto; }
.support-icon { width: 58px; height: 58px; display: grid; place-items: center; font-size: 24px; }
.support-icon-image { width: 34px; height: 34px; object-fit: contain; }
.support-note { margin-top: 20px; color: var(--muted); }

/* 9. Community -------------------------------------------------------- */
.subtabs, .rank-group-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.subtabs a, .subtabs button, .rank-group-button { padding: 9px 14px; background: #0f0f11; border: 3px solid var(--slot-line); color: #e6e6ea; font: 700 14px/1 var(--pixel); cursor: pointer; text-shadow: 2px 2px 0 #000; }
.subtabs a:hover, .subtabs button:hover, .rank-group-button:hover { border-color: #f2f2f2; color: #fff; }
.subtabs .active, .subtabs [aria-selected="true"], .rank-group-button.is-active, .rank-group-button[aria-selected="true"], .rank-group-button[aria-pressed="true"] { border-color: var(--select); color: var(--select); }
.rank-table td:first-child { width: 70px; font: 700 18px/1 var(--pixel); color: var(--muted); }
.rank-table tbody tr:nth-child(1) td:first-child { color: var(--r-legendary); }
.rank-table tbody tr:nth-child(2) td:first-child { color: #e6e6ea; }
.rank-table tbody tr:nth-child(3) td:first-child { color: #e08a3a; }
.rank-player-name, .rank-character-link { font: 700 16px/1.2 var(--pixel); color: #fff; }
.rank-character-link:hover { color: var(--select); }
.rank-score { font: 700 16px/1 var(--pixel); color: var(--coin); }
.rank-role-badge, .badge { display: inline-block; padding: 3px 6px; margin-left: 8px; font: 700 10.5px/1.2 var(--label); text-transform: uppercase; background: #3a3a40; color: #fff; vertical-align: 2px; }
.is-gm .rank-role-badge, .rank-role-badge.is-gm { background: var(--gold); color: #1b1100; }
.is-creator .rank-role-badge, .rank-role-badge.is-creator { background: var(--purple); }
.is-tester .rank-role-badge, .rank-role-badge.is-tester, .badge.tester { background: var(--mp); }
.is-banned .rank-role-badge, .badge.banned { background: var(--hp); }
.rank-pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 18px; }
.rank-page-button { min-width: 42px; height: 42px; padding: 0 12px; background: #0f0f11; border: 3px solid var(--slot-line); color: #fff; font: 700 15px/1 var(--pixel); cursor: pointer; }
.rank-page-button:hover { border-color: #f2f2f2; }
.rank-page-button.is-active, .rank-page-button[aria-current] { border-color: var(--select); color: var(--select); }
.rank-status { color: var(--muted); text-align: center; padding: 20px; }

.search-box { display: block; }
.search-row, .guild-search-form { display: flex; gap: 10px; align-items: flex-end; }
.guild-search-form { flex-wrap: wrap; }
.search-row > *:not(button), .guild-search-form > *:not(button) { flex: 1; min-width: 0; }
.character-search-section { max-width: 760px; margin-inline: auto; }
.character-search-section h2 { font-size: 26px; }
.character-results:empty { display: none; }
.character-results, .character-card { margin-top: 20px; }
.character-info-table th { width: 220px; }
.char-title, .section-title, .character-equipment-title { font-size: 22px; margin: 24px 0 12px; }
.character-equipment-frame { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 6px; }
.character-equipment-slot { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px; font-size: 12px; text-align: center; color: #e2e2e6; }
.character-equipment-slot img { width: 40px; height: 40px; object-fit: contain; }
.character-game-id-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.character-game-id-value { font-family: var(--pixel); color: var(--coin); }
.kill-feed { list-style: none; padding: 0 !important; display: grid; gap: 6px; }

.guild-heading { margin-bottom: 20px; }
.guild-kicker { font: 700 12px/1 var(--label); text-transform: uppercase; color: var(--select); }
.guild-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 20px; }
.guild-stat-card { padding: 16px 18px; }
.guild-stat-card strong { display: block; font: 700 30px/1.1 var(--pixel); color: var(--coin); text-shadow: 2px 2px 0 #000; }
.guild-stat-card span { color: var(--muted); font-size: 13.5px; }
.guild-section { margin-bottom: 16px; }
.guild-section-title { font-size: 22px; }
.guild-list { display: grid; gap: 10px; }

.profile-topbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 20px; }
.profile-title { margin: 0; }
.profile-layout, .profile-groups { display: grid; gap: 16px; }
.profile-group-title { font-size: 22px; }
.profile-subgroup-title { font: 700 12.5px/1.2 var(--label); text-transform: uppercase; color: var(--muted); margin: 18px 0 10px; }
.profile-value-gold { color: var(--coin); font-weight: 700; }
.profile-value-diamonds { color: var(--cyan); font-weight: 700; }
.profile-class-summary { display: flex; align-items: center; gap: 14px; padding: 14px; background: #141416; border: 3px solid var(--slot-line); margin-bottom: 14px; }
.profile-class-summary-icons { display: flex; gap: 6px; }
.profile-class-summary-icon { width: 40px; height: 40px; object-fit: contain; }
.profile-admin-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* 10. Misc pages ------------------------------------------------------ */
.login-page { display: grid; place-items: center; }
.login-card { width: min(460px, 100%); text-align: center; padding: 36px 30px; }
.login-card-emblem { width: 96px; height: 96px; margin: 0 auto 18px; display: grid; place-items: center; }
.login-card-emblem img { width: 72px; height: 72px; }
.login-primary-button { width: 100%; margin: 10px 0 14px; min-height: 54px; }
.store-row { display: flex; justify-content: center; margin-top: 18px; }
.online-count { font-size: 14.5px; }

.calculator-page { max-width: 760px; margin-inline: auto; }
.calc-inline { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.calc-inline > * { flex: 1; min-width: 160px; }
.calc-result { margin-top: 18px; padding: 18px; background: #141416; border: 3px solid var(--select); }
.calc-result:empty { display: none; }
.calc-result-label { color: var(--muted); font-size: 13.5px; }
.calc-result-value { display: block; font: 700 32px/1.1 var(--pixel); color: var(--coin); text-shadow: 2px 2px 0 #000; }

.news-page > h2 { display: none; }
.news-page { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; align-items: start; }
.news-ticker { grid-column: 2; grid-row: 1; position: sticky; top: calc(var(--head-h) + 20px); padding: 18px; }
.news-archive { grid-column: 1; grid-row: 1; display: grid; gap: 22px; }
.news-ticker-title { font: 700 14px/1.2 var(--label); text-transform: uppercase; color: var(--select); }
.news-ticker-list { list-style: none; padding: 0 !important; margin: 0; display: grid; gap: 6px; }
.news-ticker-entry { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 10px; background: #141416; border: 3px solid var(--slot-line); }
.news-ticker-entry:hover { border-color: var(--select); }
.news-ticker-entry time { grid-column: 1 / -1; font: 700 11px/1 var(--label); color: var(--faint); text-transform: uppercase; }
.news-ticker-entry > span { display: none; }
.news-ticker-entry a { color: #fff; font: 700 15px/1.25 var(--pixel); }
.news-ticker-entry small { align-self: start; padding: 3px 6px; font: 700 10px/1.2 var(--label); text-transform: uppercase; background: var(--mp); color: #fff; }
.news-article { padding: 0; scroll-margin-top: calc(var(--head-h) + 20px); }
.news-article-header { display: flex; align-items: center; gap: 14px; padding: 18px 24px; background: rgba(0,0,0,.3); border-bottom: 4px solid var(--edge); }
.news-article-header img { width: 44px; height: 44px; padding: 5px; background: #141416; border: 3px solid var(--slot-line); }
.news-article-header h3 { flex: 1; margin: 0; font-size: 24px; }
.news-article-header time { font: 700 11.5px/1 var(--label); color: var(--coin); text-transform: uppercase; white-space: nowrap; text-shadow: 2px 2px 0 #000; }
.news-article-body { padding: 22px 26px 26px; }
.news-article-image, .news-article-body img { display: block; max-width: 100%; height: auto; border: 4px solid #000; margin: 6px 0 18px; }
.news-article-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }

main.privacy-page { max-width: 880px; }
.privacy-page h2, .privacy-page h3 { margin-top: 1.6em; }

.error-page { text-align: center; padding: 40px 0; }
.error-code { font: 700 clamp(90px, 16vw, 170px)/1 var(--pixel); color: var(--select); text-shadow: 6px 6px 0 #000; }
.error-kicker { font: 700 13px/1.2 var(--label); color: var(--hp); text-transform: uppercase; }
.error-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 24px; }

.admin-page { display: grid; gap: 16px; }
.admin-form-grid, .admin-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.admin-form-wide { grid-column: 1 / -1; }
.admin-actions, .admin-lookup-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.admin-lookup-row > *:not(button) { flex: 1; }
.admin-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
.admin-history-wrap { overflow-x: auto; }

/* 10b. Portal finish: ornate boxes, carved title bars, riveted rails ---------
   Sprites in /assets/ui (box-frame, titlebar-*, rail-steel, slate-tile), shown at 2x. */
.cg-panel, .news-ticker, .news-article, .items-section, .shop-item-card, .support-card, .guild-section,
.profile-group, .login-card, .admin-card, .character-card,
.character-search-section, .character-equipment-section, .monster-drops-section,
.bestiary-tools, .arsenal-tools, .support-receipt-card, .guild-directory, .item-info-section, .item-source-section,
.calc-inline, .support-note, .guild-account, .monster-detail-hero, .item-detail-hero, .support-launch-hero, .guild-stat-card {
  clip-path: none; box-shadow: none;
  border: 14px solid transparent;
  border-image: url("/assets/ui/box-frame.png") 20 / 40px / 0 round;
  background: url("/assets/ui/slate-tile.png") 0 0 / 48px 16px, #1b1d21;
  background-clip: padding-box, padding-box;
  image-rendering: pixelated;
}
.cg-promo, .support-launch-hero {
  background: radial-gradient(ellipse at 80% 30%, rgba(122, 90, 184, .22), transparent 60%), linear-gradient(180deg, #221833, #15101f);
  background-clip: padding-box;
}
.cg-promo-art img, .support-offer-art img, .support-premium-art img, .support-vip-art img, .news-article-body img { image-rendering: auto; }
/* panels whose header is a title bar get a small inner gap so the bar clears the filigree */
.news-article, .cg-quest, .cg-window { padding: 4px; }

/* Carved title bars */
.cg-title, .items-page-subtitle, .shop-price-group > h3, .monsters-section-title,
.news-article-header, .news-ticker-title, .cg-quest-head, .cg-window-bar,
.items-section > h3, .monster-drops-section > h3, .item-info-section > h3, .item-source-section > h3,
.guild-section-title, .profile-group-title, .character-search-section > h2, .support-section-head h3, .support-premium-head h3 {
  display: flex; align-items: center; gap: 12px; min-height: 44px; margin: 0 0 16px; padding: 2px 4px;
  border: 12px solid transparent; border-width: 12px 24px;
  border-image: url("/assets/ui/titlebar-green.png") 6 12 fill / 12px 24px / 0 round;
  background: none; image-rendering: pixelated;
  font: 700 18px/1.15 "Cinzel", Georgia, serif; letter-spacing: .04em; color: #eadcb8; text-shadow: 0 2px 0 #000, 0 0 6px rgba(0,0,0,.6);
}
.cg-title::after, .items-page-subtitle::after, .shop-price-group > h3::after, .monsters-section-title::after { content: none !important; }
.cg-title h2 { margin: 0; font: 700 clamp(19px, 2.2vw, 24px)/1.15 "Cinzel", Georgia, serif; letter-spacing: .04em; color: #eadcb8; text-shadow: 0 2px 0 #000; }
.cg-title { margin-bottom: 22px; }
.cg-sub { margin: -6px 0 26px; }
.items-page-subtitle, .shop-price-group > h3, .monsters-section-title { margin: 40px 0 18px; font-size: 20px; }
/* colour by context: red = news & shop, teal = community & windows */
.news-article-header, .shop-price-group > h3, .support-section-head h3, .support-premium-head h3, .cg-section-red .cg-title { border-image-source: url("/assets/ui/titlebar-red.png"); }
.cg-window-bar, .cg-quest-head, .guild-section-title, .profile-group-title, .character-search-section > h2, .news-ticker-title, .cg-section-teal .cg-title { border-image-source: url("/assets/ui/titlebar-teal.png"); }
.news-article-header { margin: 0; padding: 4px 6px; border-bottom-width: 12px; }
.news-article-header h3 { font: 700 19px/1.2 "Cinzel", Georgia, serif; color: #eadcb8; text-shadow: 0 2px 0 #000; }
.news-article-header time { color: #d8c08a; }
.news-article-header img { border: 0; padding: 0; background: none; width: 30px; height: 30px; }
.cg-quest-head, .cg-window-bar { margin: 0; padding: 2px 6px; }
.cg-quest-head span, .cg-window-bar span { font: 700 16px/1 "Cinzel", Georgia, serif; text-transform: none; letter-spacing: .04em; color: #eadcb8; }
.cg-window-x { width: 30px; height: 30px; }
.news-ticker-title { font-size: 15px; text-transform: none; color: #eadcb8; }

/* Riveted steel rail under the header */
.cg-header { border-bottom: 0; box-shadow: 0 10px 0 -2px rgba(0, 0, 0, .35); }
.cg-header::after { content: ""; position: absolute; left: 0; right: 0; bottom: -10px; height: 20px; background: url("/assets/ui/rail-steel.png") 0 0 / 32px 20px repeat-x; image-rendering: pixelated; pointer-events: none; }
.cg-pagehead .cg-wrap { padding-top: 46px; }
.cg-hero-inner { padding-top: 70px; }

/* 10c. Taste pass: one section per screen, visible labels, focus and contrast ---- */
/* Hero fills exactly the first screen; the number strip and the grass sit inside it */
.cg-hero { min-height: calc(100svh - var(--head-h)); }
.cg-hero-inner { padding: 40px 20px 24px; }
.cg-hero-logo { width: min(560px, 86vw); }
.cg-hero-h1 { position: static !important; width: auto !important; height: auto !important; clip: auto !important; overflow: visible !important;
  margin: 10px 0 6px; font: 700 clamp(20px, 2.4vw, 30px)/1.2 var(--pixel); color: #fff; text-shadow: 3px 3px 0 #000; }
.cg-hero-tag { max-width: 60ch; margin: 0 0 26px; font: 500 clamp(15px, 1.4vw, 18px)/1.5 var(--font); color: #e6e6ea; text-shadow: 2px 2px 0 #000; }
.cg-hero .cg-hud { position: relative; z-index: 3; margin: 0; background: rgba(13, 13, 15, .72); border-top: 4px solid #000; border-bottom: 0; box-shadow: inset 0 4px 0 rgba(255,255,255,.06); }
.cg-hero .cg-hud .cg-wrap { padding: 14px 0; }
.cg-hero-ground { position: relative; height: 112px; flex: none; }

/* Every home section is one screen tall, content centred in it */
html { scroll-padding-top: calc(var(--head-h) + 24px); }
.cg-screen { min-height: 100svh; display: flex; align-items: center; padding: 72px 0 !important; }
.cg-skip { left: 12px !important; transform: translateY(-300%); }
.cg-skip:focus { transform: none; }
.cg-mob b { background: rgba(0, 0, 0, .78); padding: 2px 4px; }
.cg-screen > .cg-wrap { width: min(var(--wrap), 100% - 40px); }
.cg-screen.cg-section-final {
  align-items: stretch; padding-bottom: 0 !important;
  background: linear-gradient(180deg, var(--bg) 0%, rgba(13,13,15,.86) 28%, rgba(13,13,15,.7) 100%), url("/welcome%20to%20cybergyn.png") center 70% / cover no-repeat;
  image-rendering: pixelated;
}
.cg-section-final .cg-final { display: flex; flex-direction: column; align-items: center; min-height: calc(100svh - 72px); padding-top: 0; }
.cg-section-final .cg-final > .cg-label { margin-top: auto; }
.cg-section-final .cg-party { margin-top: auto; }

/* Bestiary: names always visible under each slot (no hover-only text) */
.cg-mob { aspect-ratio: auto; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px 8px; }
.cg-mob img { width: 64px; height: 64px; }
.cg-mob b { right: 6px; bottom: auto; top: 6px; font-size: 14px; }
.cg-mob-tip { position: static; transform: none; opacity: 1; background: none; border: 0; padding: 0; font: 700 13px/1.2 var(--pixel); color: #e6e6ea; white-space: normal; text-align: center; }

/* Screenshots: a gallery, no carousel */
.cg-gallery { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: repeat(2, auto); gap: 8px; padding: 8px; background: #0b0b0d; }
.cg-gallery figure { margin: 0; overflow: hidden; border: 3px solid var(--slot-line); background: #000; aspect-ratio: 1600 / 847; }
.cg-gallery figure.is-main { grid-row: span 2; aspect-ratio: auto; }
.cg-gallery img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.cg-gallery figure:hover img { transform: scale(1.03); }

/* Keyboard focus: always visible, never clipped by the notched shapes */
a:focus-visible, button:focus-visible, [tabindex]:focus-visible { clip-path: none !important; outline: 3px solid var(--select) !important; outline-offset: 3px; }

/* Contrast fixes */
.cg-class.knight .cg-label { color: #ff8577; }
.cg-chip.is-blue { color: #03263a; text-shadow: none; }
.cg-mob.is-boss b { color: #ff8577; }

/* 11. Responsive ------------------------------------------------------ */
.cg-mobile-only { display: none; }
@media (max-width: 1180px) {
  .cg-nav, .cg-actions .cg-hide-md { display: none; }
  .cg-burger { display: grid; place-items: center; }
  .cg-header-inner { justify-content: space-between; }
  .cg-nav.is-open {
    display: flex; flex-direction: column; align-items: stretch; gap: 4px;
    position: fixed; top: var(--head-h); left: 0; right: 0; bottom: 0; overflow-y: auto;
    padding: 16px 20px 40px; background: var(--cobble) 0 0 / 64px 64px, #1c1c1f;
  }
  .cg-nav.is-open .cg-nav-trigger { display: none; }
  .cg-nav.is-open .cg-dropdown { position: static; opacity: 1; visibility: visible; transform: none; min-width: 0; box-shadow: var(--bevel); margin: 8px 0 4px; }
  .cg-nav.is-open .cg-dropdown::before { content: attr(data-label); position: static; display: block; height: auto; padding: 4px 6px 10px; font: 700 12px/1 var(--label); text-transform: uppercase; color: var(--select); text-shadow: 2px 2px 0 #000; }
  .cg-nav.is-open .cg-nav-link { padding: 14px 12px; font-size: 15px; }
  .cg-nav.is-open .cg-mobile-only { display: flex; }
  .cg-hud .cg-wrap { grid-template-columns: repeat(2, 1fr); }
  .cg-bag-grid { grid-template-columns: repeat(6, 1fr); }
  .cg-promo { grid-template-columns: 1fr; padding: 30px; }
  .cg-promo-art { order: -1; max-width: 520px; }
  .cg-footer-grid { grid-template-columns: 1fr 1fr; }
  .news-page { grid-template-columns: 1fr; }
  .news-ticker { grid-column: 1; grid-row: auto; position: static; }
  .news-archive { grid-row: auto; }
}
@media (max-width: 760px) {
  :root { --head-h: 62px; }
  body { font-size: 15.5px; }
  .cg-logo img { height: 42px; }
  .cg-actions .cg-lang { display: none; }
  .cg-nav.is-open .cg-lang { display: inline-flex; margin: 12px 4px; }
  .cg-wrap, main.cg-main { width: calc(100% - 28px); }
  main.cg-main { margin: 26px auto 64px; }
  .cg-pagehead .cg-wrap { padding: 26px 0 22px; }
  .cg-pagehead-art { width: 80px; height: 80px; }
  .cg-pagehead-art img { width: 56px; height: 56px; }
  .cg-hero { min-height: 0; }
  .cg-hero-inner { padding: 44px 16px 140px; }
  .cg-hero-cta .cg-btn { flex: 1 1 100%; }
  .cg-hud .cg-wrap { gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cg-hud-item { gap: 10px; min-width: 0; }
  .cg-hud-item > div { min-width: 0; }
  .cg-hud-item strong { font-size: 11.5px; overflow-wrap: anywhere; }
  .cg-hud-item span { font-size: 12.5px; line-height: 1.35; display: block; }
  .cg-hud-slot { width: 60px; height: 60px; }
  .cg-hud-slot img { width: 40px; height: 40px; }
  .cg-classes { grid-template-columns: 1fr; }
  .cg-class-stage { height: 170px; }
  .cg-bag-grid { grid-template-columns: repeat(3, 1fr); }
  .cg-gallery { grid-template-columns: 1fr 1fr; }
  .cg-gallery figure.is-main { grid-column: 1 / -1; grid-row: auto; aspect-ratio: 1600 / 847; }
  .cg-screen { min-height: 0; padding: 48px 0 !important; }
  .cg-hero-ground { height: 96px; }
  .cg-bag-foot { flex-direction: column; align-items: stretch; }
  .cg-versus { grid-template-columns: 1fr; }
  .cg-versus-mid b { width: 64px; height: 64px; font-size: 32px; }
  .cg-quest li { grid-template-columns: 48px 1fr; padding: 14px 16px; }
  .cg-quest li > span { width: 48px; height: 48px; }
  .cg-quest li > b { display: none; }
  .cg-feedback { flex-direction: column; align-items: flex-start; }
  .cg-section { padding-top: 70px; }
  .cg-party img { width: 72px; height: 72px; }
  .cg-party img.is-mob { width: 84px; height: 84px; margin-left: 16px; }
  .cg-party { gap: 2px; max-width: 100%; }
  @media (max-width: 360px) { .cg-party img { width: 52px; height: 52px; } .cg-party img.is-mob { width: 64px; height: 64px; margin-left: 6px; } }
  .cg-footer-grid { gap: 28px; }
  .cg-footer-brand { grid-column: 1 / -1; }
  .bestiary-tools, .arsenal-tools { grid-template-columns: 1fr; }
  .support-trust-strip { grid-template-columns: 1fr; }
  .support-launch-hero { padding: 24px; }
  .support-offer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .support-offer-grid .support-offer-card { padding: 14px 10px; }
  .shop-items-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shop-item-card { padding: 14px 6px; }
  .shop-item-price { font-size: 11.5px; border-width: 16px 16px; max-width: 100%; letter-spacing: 0; }
  .support-offer-grid .support-offer-price { font-size: 16px; min-width: 0; border-width: 16px 20px; }
  .support-offer-grid .support-offer-card { padding: 12px 6px 14px; }
  .support-offer-grid .support-btn { padding: 2px 4px 2px 0; gap: 4px; min-height: 58px; }
  .support-offer-grid .cg-buy-icon { width: 36px; height: 36px; background-size: 36px; margin: -6px 0 -6px -8px; }
  .support-offer-grid .cg-buy-icon img, .support-offer-grid .cg-buy-icon svg { width: 18px; height: 18px; }
  .support-offer-grid .cg-buy-text { font-size: 13px; }
  .support-offer-grid .cg-buy-text small { font-size: 10px; }
  .support-offer-grid .support-btn-paypal .cg-buy-text { font-size: 14px; }
  .support-offer-grid .support-offer-tag { font-size: 10px !important; border-width: 12px 16px; }
  .monster-detail-hero, .item-detail-hero { flex-direction: column; text-align: center; }
  .items-set-grid, .items-section-grid { grid-template-columns: 1fr; }
  .cg-panel, .news-ticker, .items-section, .support-card, .guild-section, .profile-group, .admin-card, .character-search-section, .monster-drops-section, .bestiary-tools, .arsenal-tools, .monster-detail-hero, .item-detail-hero { padding: 18px; }
  .news-article-header, .news-article-body { padding-inline: 18px; }
  .news-article-header { flex-wrap: wrap; }
  main table { display: block; overflow-x: auto; white-space: nowrap; }
  .character-info-table th { width: auto; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* =====================================================================
   12. Portal (2026-11-30): a town banner, a green bar of plain words, a
   light content panel on a dark page, tables with a cream head row and
   small coloured badges. Overrides sections 1-11 above. The medieval
   sprites in /assets/ui stay on the shop's package cards.
   ===================================================================== */
:root {
  --void: #1c1c1c; --bg: #2b2b2b;
  --stone: #ffffff; --stone-hi: #f1f1ed; --stone-lo: #fafaf8; --slot: #f5f5f1; --slot-line: #d5d5cf; --edge: #d3d3cc;
  --ink: #262626; --muted: #5c5c5c; --faint: #767676;
  --select: #245f94;           /* links and active marks */
  --coin: #2c7a31;             /* game numbers: gold, experience */
  --gold: #946400;
  --panel: #f3f3f0; --line: #d9d9d3; --head: #f3efc6; --head-line: #e2dca4;
  --green: #3e6b30; --green-hi: #4f8240; --green-lo: #2e5224; --green-ink: #f5f0c8;
  --pixel: "Figtree", system-ui, sans-serif;
  --label: "Figtree", system-ui, sans-serif;
  --font: "Figtree", system-ui, "Segoe UI", sans-serif;
  --wrap: 1170px;
}
html { scroll-behavior: auto; scroll-padding-top: 12px; }
body {
  background: radial-gradient(ellipse at 50% 0, #3a3a3a 0, transparent 70%), #2b2b2b;
  color: var(--ink); font: 400 15px/1.55 var(--font);
}
a { color: var(--select); text-decoration: none; }
a:hover { color: #173f63; text-decoration: underline; }
:focus-visible, a:focus-visible, button:focus-visible, [tabindex]:focus-visible { clip-path: none !important; outline: 2px solid #f0c95a !important; outline-offset: 2px; }
::selection { background: #f0c95a; color: #111; }
h1, h2, h3, h4 { font-family: var(--font); font-weight: 500; color: var(--ink); text-shadow: none; letter-spacing: 0; text-transform: none; }

/* the frame: one column, 1170 wide, the banner, the bar, the panel, the footer */
.cg-shell { width: min(var(--wrap), 100% - 16px); margin: 0 auto; padding-top: 6px; }
.cg-skip { position: absolute; left: 12px; top: 8px; z-index: 100; transform: translateY(-300%); background: #f0c95a; color: #111; padding: 8px 14px; border-radius: 4px; font-family: var(--font); }
.cg-skip:focus { transform: none; }

.cg-banner {
  position: relative; aspect-ratio: 1296 / 288; border: 3px solid #161616; border-radius: 8px; overflow: hidden;
  background: #233018 url("/assets/art/banner-town.png?v=2") center / cover no-repeat; image-rendering: pixelated;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06), 0 2px 0 #111;
}
.cg-banner-link { position: absolute; inset: 0; display: grid; place-items: center; }
.cg-banner-link:hover { text-decoration: none; }
.cg-banner-logo { width: min(36%, 420px); height: auto; image-rendering: auto; filter: drop-shadow(0 3px 0 rgba(0, 0, 0, .75)) drop-shadow(0 0 14px rgba(0, 0, 0, .55)); transition: transform .2s ease; }
.cg-banner-link:hover .cg-banner-logo { transform: translateY(-2px); }

.cg-navbar {
  position: relative; z-index: 20; margin: 6px 0; border: 2px solid var(--green-lo); border-radius: 6px;
  background:
    radial-gradient(circle at 2px 2px, rgba(255, 255, 255, .07) 1px, transparent 1.4px) 0 0 / 9px 9px,
    radial-gradient(circle at 6px 7px, rgba(0, 0, 0, .10) 1px, transparent 1.4px) 0 0 / 11px 11px,
    linear-gradient(180deg, var(--green-hi), var(--green) 55%, #386229);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .14), 0 2px 0 #151515;
  display: flex; align-items: stretch; min-height: 48px;
}
.cg-navbar-head { display: flex; align-items: center; justify-content: space-between; }
.cg-brand { display: flex; align-items: center; padding: 0 18px 0 16px; font: 600 21px/1 "Pixelify Sans", "Figtree", sans-serif; color: #f6dc74; text-shadow: 2px 2px 0 #1b2f13; white-space: nowrap; letter-spacing: .01em; }
.cg-brand:hover { color: #ffe98f; text-decoration: none; }
.cg-navbar-links { flex: 1; display: flex; align-items: stretch; justify-content: space-between; }
.cg-navbar ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: stretch; }
.cg-navbar li { position: relative; display: flex; }
.cg-navbar li > a, .cg-dd-toggle {
  display: flex; align-items: center; gap: 6px; padding: 0 12px; min-height: 44px; border: 0; background: none; cursor: pointer;
  font: 500 14px/1 var(--font); color: var(--green-ink); text-shadow: 1px 1px 0 #1d3315; white-space: nowrap;
}
.cg-navbar li > a:hover, .cg-dd-toggle:hover, .cg-dd.is-open > .cg-dd-toggle { color: #fff; background: rgba(0, 0, 0, .14); text-decoration: none; }
.cg-navbar li.is-active > a, .cg-navbar li.is-active > .cg-dd-toggle { color: #fff; background: rgba(0, 0, 0, .24); box-shadow: inset 0 -3px 0 #f6dc74; }
.cg-caret { width: 10px; height: 10px; }
.cg-nav-right .cg-lang a { font-weight: 600; letter-spacing: .04em; }
.cg-dd-menu {
  position: absolute; top: calc(100% + 2px); left: 0; min-width: 210px; padding: 6px 0; display: none !important; flex-direction: column;
  background: #fff; border: 1px solid #c9c9c2; border-radius: 4px; box-shadow: 0 8px 22px rgba(0, 0, 0, .35);
}
.cg-dd-right { left: auto; right: 0; }
.cg-dd.is-open > .cg-dd-menu { display: flex !important; }
.cg-dd-menu li { display: block; }
.cg-dd-menu a, .cg-dd-menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 40px; padding: 8px 16px; border: 0; background: none; text-align: left;
  font: 400 14px/1.3 var(--font); color: #333 !important; text-shadow: none; cursor: pointer;
}
.cg-dd-menu a:hover, .cg-dd-menu button:hover { background: #f2f2ee; text-decoration: none; }
.cg-dd-menu li + li { border-top: 1px solid #eee; }
.cg-g { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; background: #fff; border: 1px solid #ddd; font: 700 12px/1 Arial, sans-serif; color: #4285f4; }
.cg-burger { display: none; width: 46px; height: 38px; margin-right: 10px; border: 2px solid #f6dc74; border-radius: 5px; background: rgba(0, 0, 0, .12); padding: 7px 9px; cursor: pointer; flex-direction: column; justify-content: space-between; }
.cg-burger span { display: block; height: 3px; border-radius: 2px; background: #f6dc74; }

/* the panel */
main.cg-main {
  display: block; width: auto; margin: 0; padding: 22px 26px 30px;
  background: var(--panel); color: var(--ink); border: 1px solid #b9b9b2; border-radius: 6px; box-shadow: 0 2px 0 #151515;
}
main.cg-main.home-modern-page { padding: 26px 26px 30px; }
.cg-ptitle { text-align: center; margin: 0 0 22px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.cg-ptitle-art { display: block; width: 48px; height: 48px; margin: 0 auto 6px; image-rendering: pixelated; object-fit: contain; }
.cg-ptitle h1 { margin: 0 0 6px; font: 500 clamp(24px, 1.2vw + 18px, 30px)/1.2 var(--font); color: #2b2b2b; }
.cg-crumbs { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; font: 400 13px/1.4 var(--font); color: var(--faint); text-transform: none; text-shadow: none; margin: 0; }
.cg-crumbs a { color: var(--select); }
.cg-crumbs > span:last-child { color: var(--muted); }
.cg-dup-title { display: none !important; }

/* text inside the panel */
main.cg-main p, main.cg-main li, main.cg-main td, main.cg-main dd { color: #333; }
main.cg-main strong, main.cg-main b { color: #222; }
main.cg-main h2 { font-size: 22px; margin: 26px 0 12px; }
main.cg-main h3 { font-size: 18px; }
main.cg-main h4 { font-size: 15px; }
main.cg-main li::marker { color: #888; }
main.cg-main hr { height: 1px; background: var(--line); }
.cg-label, .cg-eyebrow, main label, .bestiary-summary strong, .arsenal-summary strong, .support-receipt-kicker, .guild-kicker {
  font: 600 13px/1.3 var(--font) !important; letter-spacing: 0 !important; text-transform: none !important; text-shadow: none !important;
}
.cg-label, .cg-eyebrow, .guild-kicker { color: var(--muted); }
main label { color: #333; }

/* boxes: white panels with one grey line, a heading strip like a table head */
.cg-panel, .news-ticker, .news-article, .items-section, .shop-item-card, .support-card, .guild-section,
.profile-group, .login-card, .admin-card, .character-card,
.character-search-section, .character-equipment-section, .monster-drops-section,
.bestiary-tools, .arsenal-tools, .support-receipt-card, .guild-directory, .item-info-section, .item-source-section,
.calc-inline, .support-note, .guild-account, .monster-detail-hero, .item-detail-hero, .support-launch-hero, .guild-stat-card, .cg-promo {
  background: #fff !important; border: 1px solid var(--line) !important; border-image: none !important; border-radius: 4px;
  clip-path: none !important; box-shadow: 0 1px 1px rgba(0, 0, 0, .04) !important; padding: 16px 18px; color: #333; image-rendering: auto;
}
.cg-slot, .monster-stat-card, .monster-drop-card, .item-info-card, .item-source-card,
.item-slot, .items-list-entry, .item-variant-row, .character-equipment-slot, .shop-item-art,
.support-trust-item, .monster-detail-figure, .item-detail-art, .login-card-emblem, .support-icon {
  background: var(--slot) !important; border: 1px solid var(--slot-line) !important; border-radius: 4px; box-shadow: none !important; clip-path: none !important; color: #333;
}
.cg-title, .items-page-subtitle, .shop-price-group > h3, .monsters-section-title,
.news-article-header, .news-ticker-title, .cg-quest-head, .cg-window-bar,
.items-section > h3, .monster-drops-section > h3, .item-info-section > h3, .item-source-section > h3,
.guild-section-title, .profile-group-title, .character-search-section > h2, .support-section-head h3, .support-premium-head h3 {
  display: flex; align-items: center; gap: 10px; min-height: 0; margin: 0 0 14px !important; padding: 0 0 10px !important;
  border: 0 !important; border-bottom: 1px solid var(--line) !important; border-image: none !important; background: none !important;
  font: 500 19px/1.25 var(--font) !important; letter-spacing: 0 !important; color: #2b2b2b !important; text-shadow: none !important; text-transform: none !important;
}
.cg-title h2, .news-article-header h3, .cg-quest-head span, .cg-window-bar span { margin: 0; font: inherit !important; color: inherit !important; text-shadow: none !important; }
.cg-title::after, .items-page-subtitle::after, .shop-price-group > h3::after, .monsters-section-title::after { content: none !important; }
.items-page-subtitle, .shop-price-group > h3, .monsters-section-title { margin-top: 30px !important; }
.news-article-header time, .news-ticker-entry time { color: var(--muted) !important; }
.cg-sub, .lead, .support-section-promise, .support-hero-lead, .support-launch-note { color: #4a4a4a !important; margin: 0 0 18px; }

/* tables: a cream head row, white rows, one grey line */
main table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 0; font-size: 14px; }
main th { background: var(--head); color: #333; border-bottom: 1px solid var(--head-line); font: 600 13.5px/1.3 var(--font) !important; text-transform: none !important; letter-spacing: 0 !important; text-shadow: none !important; }
main th, main td { padding: 9px 12px; border-bottom: 1px solid #e3e3dd; color: #333; }
main td + td, main th + th { border-left: 1px solid #ececE6; }
main tbody tr:nth-child(even) td { background: #fafaf7; }
main tbody tr:hover td { background: #f3f6fa; }
main td a { font-weight: 500; }

/* forms */
main input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]), main select, main textarea {
  min-height: 38px; padding: 7px 12px; border-radius: 4px; background: #fff; color: #222; border: 1px solid #c4c4bd;
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, .06); font: 400 15px/1.4 var(--font);
}
main input:focus, main select:focus, main textarea:focus { border-color: #5b8fc2; box-shadow: 0 0 0 3px rgba(36, 95, 148, .18); outline: none; }
main select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath fill='%23555' d='M0 0h10L5 6z'/%3E%3C/svg%3E"); }
main input::placeholder { color: #8a8a8a; }

/* buttons: white default, blue primary, 4px corners */
.cg-btn, .support-btn, .login-primary-button, .admin-button, .news-article-action, .rank-retry, .character-equipment-privacy-button,
main button:not([class*="carousel"]):not(.rarity-chip):not(.rank-group-button):not(.rank-page-button):not(.feature-carousel-dot):not(.arsenal-section-toggle):not(.cg-plain):not(.header-walkers-toggle):not(.cg-dd-toggle):not(.cg-logout),
main input[type="submit"], .cg-btn-gold {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 38px; padding: 6px 16px;
  font: 500 14.5px/1.2 var(--font) !important; letter-spacing: 0 !important; text-transform: none !important; text-shadow: none !important;
  color: #333 !important; background: linear-gradient(#fff, #f1f1ec) !important; border: 1px solid #b9b9b1 !important; border-image: none !important;
  border-radius: 4px !important; clip-path: none !important; box-shadow: 0 1px 0 rgba(0, 0, 0, .06) !important; filter: none !important; width: auto;
  transition: background-color .12s ease, border-color .12s ease, transform .08s ease; image-rendering: auto;
}
.cg-btn:hover, .support-btn:hover, .admin-button:hover, .news-article-action:hover, .rank-retry:hover, .cg-btn-gold:hover,
main button:not([class*="carousel"]):not(.rarity-chip):not(.rank-group-button):not(.rank-page-button):not(.feature-carousel-dot):not(.arsenal-section-toggle):not(.cg-plain):not(.header-walkers-toggle):not(.cg-dd-toggle):not(.cg-logout):hover {
  background: #e9e9e3 !important; border-color: #9d9d95 !important; text-decoration: none; color: #222 !important;
}
.cg-btn:active, .support-btn:active, main button:active { transform: translateY(1px); }
.cg-btn-go, .login-primary-button, .support-btn-local, .admin-button:not(.admin-button-secondary), .cg-btn-blue {
  color: #fff !important; background: linear-gradient(#3477b2, #2a6399) !important; border-color: #22547f !important;
}
.cg-btn-go:hover, .login-primary-button:hover, .support-btn-local:hover, .admin-button:not(.admin-button-secondary):hover, .cg-btn-blue:hover {
  color: #fff !important; background: linear-gradient(#2c6aa1, #225482) !important; border-color: #1b4568 !important;
}
.cg-btn-gold::before { content: none !important; }
.cg-btn img { width: 20px; height: 20px; }

/* notices: the blue "please read" box; errors in red */
.guild-notice, .admin-notice, .login-status, .character-search-status, .guild-list-status, .profile-status, .support-currency-note, .calc-note, .support-note {
  background: #dfeef7 !important; color: #2e5c78 !important; border: 1px solid #bcdbea !important; border-left: 1px solid #bcdbea !important; border-radius: 4px; padding: 12px 15px;
}
.is-error, .guild-error { background: #f6dede !important; color: #8a2b29 !important; border-color: #e7b9b8 !important; }
.calc-help, .admin-help, .login-help, .support-payment-note, .support-page-footer-note { color: var(--muted) !important; }
.bestiary-empty, .arsenal-empty, .item-empty-state, .guild-empty { border: 1px dashed #c9c9c2; border-radius: 4px; color: var(--muted); }

/* badges: small, rounded, solid colour, white words */
.badge, .rank-role-badge, .cg-badge {
  display: inline-block; padding: 2px 6px; border-radius: 3px; font: 700 10.5px/1.3 var(--font); color: #fff !important; text-shadow: none; vertical-align: 1px; letter-spacing: .01em;
}
.cg-badge-online { background: #4c9f4c; }
.cg-badge-supporter { background: #2f72b0; font-size: 12px; padding: 3px 7px; }

/* lists of small things: tabs and sub-tabs as a bordered strip */
.subtabs a, .subtabs button, .rank-group-button, .rank-page-button {
  font: 500 14px/1.2 var(--font) !important; text-transform: none !important; text-shadow: none !important; letter-spacing: 0 !important;
  color: var(--select) !important; background: #fff !important; border: 1px solid #d3d3cc !important; border-radius: 4px 4px 0 0 !important; clip-path: none !important; box-shadow: none !important;
}
.subtabs .active, .subtabs [aria-selected="true"], .rank-group-button.is-active, .rank-group-button[aria-selected="true"], .rank-group-button[aria-pressed="true"],
.rank-page-button.is-active, .rank-page-button[aria-current] { color: #333 !important; background: var(--panel) !important; border-bottom-color: var(--panel) !important; }
.rank-page-button { border-radius: 4px !important; }

/* game numbers and names that were light on dark */
.cg-hud-item strong, .cg-mob-tip, .cg-bag-foot, .cg-checks li, .cg-callout, .cg-coins span, .item-source-card strong,
.support-dual-version span, .support-launch-urgency, .support-version-benefit, .support-premium-equation,
.rank-player-name, .rank-character-link, .news-ticker-entry a, .news-ticker-entry small, .character-equipment-slot,
.item-slot, .items-list-entry, .item-variant-row, .arsenal-quick-nav a, .cg-class p, .cg-final p, .cg-promo p { color: #333 !important; text-shadow: none !important; }
.rank-character-link, .news-ticker-entry a, .arsenal-quick-nav a { color: var(--select) !important; }
.rank-table tbody tr:nth-child(2) td:first-child { color: #6d6d6d !important; }
.monster-stat-card span, .item-info-card span, .item-source-card span, .guild-stat-card strong, .calc-result-value, .rank-score, .profile-value-gold, .character-game-id-value { color: var(--coin) !important; text-shadow: none !important; }
.monster-stat-card:nth-child(3) span { color: #c0392b !important; }
.error-code { color: var(--select); }
.arsenal-section-toggle { color: #333 !important; background: #fff !important; border: 1px solid var(--line) !important; text-shadow: none !important; }
.bestiary-summary-crest, .arsenal-summary-crest { background: #fff; border: 1px solid var(--line); color: var(--select); }

/* the shop keeps its medieval package cards: dark carved frames, light words inside */
.support-offer-card, .support-premium-card { color: #eee; }
.support-offer-card :is(p, li, span, strong, small, h3, h4, b), .support-premium-card :is(p, li, span, strong, small, h3, h4, b) { color: #ece6d6 !important; }
.support-offer-card .support-offer-price, .support-premium-card .support-offer-price { color: var(--carved-gold) !important; }
.support-payment-actions .support-btn { min-height: 52px; width: 100%; justify-content: flex-start; text-align: left; }
.support-payment-actions .support-btn .cg-buy-text, .support-payment-actions .support-btn .cg-buy-text small { color: inherit !important; }
.cg-buy-text { font: 600 15px/1.15 var(--font) !important; text-transform: none !important; letter-spacing: 0 !important; }
.cg-buy-text small, .support-btn-paypal .cg-buy-text small { font: 400 12px/1.2 var(--font) !important; text-transform: none !important; order: 2; margin: 2px 0 0 !important; opacity: .85; }
.cg-buy-icon { background: rgba(255, 255, 255, .25) !important; width: 34px; height: 34px; margin: 0; border-radius: 4px; }
.support-offer-tag { color: #f1e3bd !important; }

/* footer: on the dark page under the panel */
.cg-footer { margin: 0; padding: 0 2px 26px; background: none; color: #a9a9a9; font-size: 13.5px; }
.cg-footer::before { content: none; }
.cg-footer-walk { position: relative; height: 72px; }
.cg-footer-walk .header-walkers { position: absolute; inset: 0; overflow: hidden; }
.cg-footer-walk .header-walker { position: absolute; left: 0; bottom: 0; background-repeat: no-repeat; image-rendering: pixelated; }
.cg-footer-walk .header-walkers-toggle { position: absolute; left: 0; top: 10px; z-index: 2; width: 32px; height: 32px; border-radius: 4px; background: #222; color: #ddd; border: 1px solid #444; cursor: pointer; font-size: 12px; }
.cg-footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 10px 24px; border-top: 1px solid #3c3c3c; padding-top: 14px; }
.cg-footer-copy { margin: 0; }
.cg-footer-copy a { color: #e8e8e8; font-weight: 500; }
.cg-footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.cg-footer-links a { color: #7fb0dd; }
.cg-footer-links a:hover { color: #b5d4f0; }

/* pixel art everywhere stays crisp */
main img[src$=".png"]:not(.cg-smooth), .cg-ptitle-art { image-rendering: pixelated; }

@media (max-width: 991px) {
  .cg-navbar { flex-direction: column; }
  .cg-navbar-head { min-height: 52px; }
  .cg-burger { display: flex; }
  .cg-navbar-links { display: none; flex-direction: column; border-top: 1px solid rgba(255, 255, 255, .25); }
  .cg-navbar.is-open .cg-navbar-links { display: flex; }
  .cg-navbar ul { flex-direction: column; }
  .cg-navbar li { flex-direction: column; }
  .cg-navbar li > a, .cg-dd-toggle { min-height: 48px; padding: 0 18px; font-size: 16px; }
  .cg-dd-menu { position: static; border-radius: 0; box-shadow: none; margin: 0 10px 8px; }
  .cg-nav-right { border-top: 1px solid rgba(255, 255, 255, .18); }
}
@media (max-width: 600px) {
  .cg-shell { width: calc(100% - 8px); padding-top: 4px; }
  .cg-banner { aspect-ratio: 1296 / 400; border-width: 2px; }
  .cg-banner-logo { width: min(66%, 300px); }
  .cg-brand { font-size: 22px; }
  main.cg-main, main.cg-main.home-modern-page { padding: 16px 12px 22px; }
  main table { font-size: 13px; }
  main th, main td { padding: 7px 8px; }
  .cg-footer-row { flex-direction: column; align-items: flex-end; text-align: right; }
}
@media (prefers-reduced-motion: reduce) { .cg-banner-logo { transition: none; } }
.cg-footer .cg-footer-links { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.cg-footer .cg-footer-links a { color: #7fb0dd; }
@media (max-width: 600px) { .cg-footer .cg-footer-links { justify-content: flex-end; } }
main select { background-repeat: no-repeat !important; background-position: right 12px center !important; background-size: 10px 6px !important; padding-right: 34px; appearance: none; }
main .rank-error-row td, main .rank-empty-row td, .rank-error-row, .rank-empty-row { font: 400 14px/1.5 var(--font) !important; color: #6b4b12 !important; text-shadow: none !important; text-transform: none !important; letter-spacing: 0 !important; }
main.cg-main { font-family: var(--font); }
main.cg-main [class*="pixel"], main.cg-main .cg-mob-tip { font-family: var(--font) !important; }

/* 12c. Portal: the remaining dark tiles inside the panel go light */
.bestiary-summary-crest, .arsenal-summary-crest, .cg-class-gear span, .cg-checks li::before, .cg-quest li > span, .monster-drop-icon,
.rarity-chip, .arsenal-quick-nav a, .profile-class-summary, .calc-result, .news-ticker-entry, .news-article-header img, .cg-dd-icon {
  background-color: #fff !important; border-color: var(--line) !important; box-shadow: none !important; color: #333; text-shadow: none !important;
}
.cg-callout, .cg-quest-foot, .cg-coins span, .support-launch-urgency, .support-version-benefit, .support-page-footer-note {
  background: #fcf8e3 !important; border: 1px solid #efe3b0 !important; border-left: 1px solid #efe3b0 !important; border-radius: 4px; color: #5d4b16 !important;
}
.support-launch-urgency *, .support-version-benefit *, .support-page-footer-note * { color: #5d4b16 !important; }
.monster-card { background: #fff !important; border: 1px solid var(--line) !important; border-radius: 4px; box-shadow: none !important; transition: border-color .12s ease, transform .12s ease; }
.monster-card-link:hover { text-decoration: none; }
.monster-card-link:hover .monster-card { border-color: #9fb3c8 !important; transform: translateY(-2px); }
.monster-card h3 { color: var(--select) !important; text-shadow: none !important; font: 600 14px/1.3 var(--font) !important; }
.monster-card [class*="level"], .monster-card small, .monster-card span { color: #666 !important; text-shadow: none !important; font-family: var(--font) !important; }
.monsters-grid-bosses .monster-card { background: #fdf3e6 !important; border-color: #ecd4b0 !important; }
.monsters-grid-bosses .monster-card [class*="level"], .monsters-grid-bosses .monster-card span { color: #b2551c !important; }
.rarity-chip { font-family: var(--font) !important; }
.rank-role-badge { background: #6c757d; }
.support-launch-hero { background: #fff !important; }
.support-launch-hero * { text-shadow: none !important; }
.news-article-header time { margin-left: auto; padding: 4px 11px; border-radius: 12px; background: #3f7fbf; color: #fff !important; font: 600 12.5px/1.2 var(--font) !important; text-shadow: none !important; letter-spacing: 0 !important; white-space: nowrap; }
.news-ticker-entry { border-width: 1px !important; border-style: solid !important; }
.news-ticker-entry time { font: 500 12px/1.2 var(--font) !important; text-shadow: none !important; }

/* 12d. No text has a shadow anywhere (user's rule, 2026-11-30) */
*, *::before, *::after { text-shadow: none !important; }
.cg-banner-logo { filter: none !important; }

/* 12e. The menu button (phone/tablet): rounded frame and three bars in pale gold, like the bar's words */
@media (max-width: 991px) {
  .cg-navbar .cg-burger {
    display: flex !important; flex-direction: column; justify-content: center; align-items: center; gap: 6px;
    width: 58px; height: 46px; margin-right: 12px; padding: 0; clip-path: none !important;
    background: linear-gradient(180deg, rgba(255, 255, 255, .10), rgba(0, 0, 0, .10)) !important;
    border: 2px solid #f3e7a0 !important; border-radius: 7px !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18), 0 1px 0 rgba(0, 0, 0, .25) !important; cursor: pointer;
    transition: background-color .15s ease, transform .1s ease;
  }
  .cg-navbar .cg-burger span {
    display: block; width: 30px; height: 4px; border-radius: 2px; background: #f3e7a0; flex: none;
    transition: transform .2s ease, opacity .2s ease;
  }
  .cg-navbar .cg-burger:hover { background: rgba(255, 255, 255, .16) !important; }
  .cg-navbar .cg-burger:active { transform: translateY(1px); }
  .cg-navbar.is-open .cg-burger { background: rgba(0, 0, 0, .18) !important; }
  .cg-navbar.is-open .cg-burger span:nth-child(1) { transform: translateY(10px) rotate(45deg); }
  .cg-navbar.is-open .cg-burger span:nth-child(2) { opacity: 0; }
  .cg-navbar.is-open .cg-burger span:nth-child(3) { transform: translateY(-10px) rotate(-45deg); }
}
@media (prefers-reduced-motion: reduce) { .cg-navbar .cg-burger span { transition: none; } }

/* 12f. The menu button is a drawn piece: gold frame, green panel, bars; it turns into the X when open */
@media (max-width: 991px) {
  .cg-navbar-head { min-height: 64px; }
  .cg-navbar .cg-burger {
    width: 76px; height: 60px; margin-right: 8px; padding: 0; gap: 0;
    background: url("/assets/art/btn-menu.svg?v=1") center / contain no-repeat !important;
    border: 0 !important; border-radius: 0 !important; box-shadow: none !important;
    transition: transform .1s ease, filter .15s ease;
  }
  .cg-navbar .cg-burger span { display: none; }
  .cg-navbar .cg-burger:hover { background: url("/assets/art/btn-menu.svg?v=1") center / contain no-repeat !important; filter: brightness(1.08); }
  .cg-navbar.is-open .cg-burger, .cg-navbar.is-open .cg-burger:hover { background: url("/assets/art/btn-close.svg?v=1") center / contain no-repeat !important; }
  .cg-navbar .cg-burger:active { transform: translateY(1px) scale(.97); }
  .cg-navbar .cg-burger:focus-visible { outline-offset: 0; border-radius: 10px !important; }
}

/* 12g. The bar: dark, framed and named in ASCII (letters and numbers), no green ground */
.cg-navbar {
  background: #17150f !important; border: 0 !important; border-radius: 4px; box-shadow: 0 2px 0 #0b0b0b !important;
  padding: 11px 14px; overflow: hidden;
}
.cg-frame {
  position: absolute; z-index: 0; pointer-events: none; overflow: hidden; white-space: nowrap;
  font: 700 10px/10px "Courier New", Consolas, monospace; letter-spacing: 0; color: #b8913f; user-select: none;
}
.cg-frame-t { top: 0; left: 0; right: 0; height: 10px; }
.cg-frame-b { bottom: 0; left: 0; right: 0; height: 10px; color: #8a6a2a; }
.cg-frame-l, .cg-frame-r { top: 10px; bottom: 10px; width: 8px; writing-mode: vertical-rl; text-orientation: upright; letter-spacing: -2px; color: #a07c36; }
.cg-frame-l { left: 2px; }
.cg-frame-r { right: 2px; }
.cg-navbar > :not(.cg-frame) { position: relative; z-index: 1; }
.cg-brand { padding: 0 16px 0 8px !important; }
.cg-ascii {
  margin: 0; font: 700 12px/8px "Courier New", Consolas, monospace; letter-spacing: -1.9px; white-space: pre;
  background: linear-gradient(180deg, #fff1c2 0%, #ecc97c 35%, #c99a4c 55%, #8f6427 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.cg-brand:hover .cg-ascii { background: linear-gradient(180deg, #fffbe6, #f3d68f 40%, #d8ad5c 60%, #a5773a); -webkit-background-clip: text; background-clip: text; }
.cg-navbar li > a, .cg-dd-toggle { color: #e9d9a8 !important; }
.cg-navbar li > a:hover, .cg-dd-toggle:hover, .cg-dd.is-open > .cg-dd-toggle { color: #fff6d6 !important; background: rgba(233, 217, 168, .08) !important; }
.cg-navbar li.is-active > a, .cg-navbar li.is-active > .cg-dd-toggle { color: #fff6d6 !important; background: rgba(233, 217, 168, .10) !important; box-shadow: inset 0 -2px 0 #d9b25e !important; }
@media (max-width: 991px) {
  .cg-navbar { padding: 10px 12px; }
  .cg-navbar-links { border-top: 1px dashed rgba(217, 178, 94, .35) !important; }
  .cg-nav-right { border-top: 1px dashed rgba(217, 178, 94, .25) !important; }
}
@media (max-width: 420px) { .cg-ascii { font-size: 8.6px; line-height: 6px; letter-spacing: -1.3px; } }
/* the synchronised wave: cells under the band light up pale gold */
.cg-ascii span.w { color: #fff6d2; -webkit-text-fill-color: #fff6d2; }
.cg-frame span.w { color: #fff1b8; }

/* 12h. The ASCII engine in more places (menu.js): page titles, 404, loading and error boxes,
   the ranking's top three, the shop's buy buttons, the footer line */
.cg-ptitle-ax, .error-page .error-code { display: block; text-align: center; }
.cg-ptitle h1 { margin-bottom: 10px; }
.cg-ascii.cg-ascii-title {
  display: inline-block; text-align: left; font: 700 12px/7.8px "Courier New", Consolas, monospace; letter-spacing: -2.4px;
  background: linear-gradient(180deg, #8a6420 0%, #6b4a14 45%, #3d2a0a 100%); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.cg-ascii.cg-ascii-title span.w { color: #d9971c; -webkit-text-fill-color: #d9971c; }
.cg-ascii.cg-ascii-404 {
  display: inline-block; text-align: left; font: 700 13px/8.2px "Courier New", Consolas, monospace; letter-spacing: -2.6px;
  background: linear-gradient(180deg, #a9781f, #6b4a14 55%, #3d2a0a); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.cg-ascii.cg-ascii-404 span.w { color: #d9971c; -webkit-text-fill-color: #d9971c; }
.error-page .error-code { font-size: 0; margin: 8px 0 18px; }

.cg-axhost { position: relative; padding: 18px 24px !important; overflow: hidden; }
.cg-axbox { position: absolute; inset: 0; pointer-events: none; overflow: hidden; border-radius: inherit; }
.cg-axbox .cg-frame { color: #a07c36; }
.cg-axbox .cg-frame-l { left: 3px; } .cg-axbox .cg-frame-r { right: 3px; }
.cg-axhost .cg-axbox span.w { color: #d9971c; }
.cg-ax-err .cg-axbox .cg-frame { color: #b04a44; }
.cg-ax-err .cg-axbox span.w { color: #e0592f; }
.cg-ax-load { color: #5d4b16 !important; background: #fcf8e3 !important; border-color: #efe3b0 !important; }

.rank-table tr.cg-top td { background: #fbf3d9 !important; }
.rank-table tr.cg-top-1 td { background: #f8ebc0 !important; }
.cg-medal { display: inline-block; }
.cg-medal pre { margin: 0; font: 700 14px/12px "Courier New", Consolas, monospace; letter-spacing: 0; color: #8a6420; white-space: pre; }
.cg-top-1 .cg-medal pre { color: #b07d12; }
.cg-medal pre span.w { color: #e8a41c; }

.support-payment-actions { gap: 24px !important; padding: 12px 10px 8px; }
.cg-axbtn { position: relative; overflow: visible !important; }
.cg-axbtn > .cg-axbtn-frame { inset: -25px -22px; border-radius: 0; }
.cg-axbtn-frame .cg-frame { color: #c9a35a; font-size: 9px; line-height: 9px; }
.cg-axbtn-frame .cg-frame-t, .cg-axbtn-frame .cg-frame-b { height: 9px; }
.cg-axbtn-frame .cg-frame-l, .cg-axbtn-frame .cg-frame-r { top: 9px; bottom: 9px; }
.cg-axbtn-frame span.w { color: #fff1b8 !important; }

.cg-footer-ax { overflow: hidden; white-space: nowrap; height: 12px; font: 700 10px/12px "Courier New", Consolas, monospace; color: #6f5a2c; margin-bottom: 12px; }
.cg-footer-ax span.w { color: #f0cf7c; }
.cg-footer-row { border-top: 0 !important; padding-top: 0 !important; }
@media (max-width: 600px) {
  .cg-ascii.cg-ascii-title { font-size: 10px; line-height: 6.4px; letter-spacing: -2px; }
  .cg-ascii.cg-ascii-404 { font-size: 10px; line-height: 6.4px; letter-spacing: -2px; }
}
/* the medal: the frame of changing characters, the rank large in its middle */
.cg-medal { position: relative; display: inline-block; vertical-align: middle; }
.cg-medal-n { position: absolute; inset: 0; display: grid; place-items: center; font: 800 22px/1 var(--font); color: #7a5410; }
.cg-top-1 .cg-medal-n { color: #a8730a; font-size: 24px; }
/* the bar keeps its dropdowns on top: nothing clips them, they sit above the panel */
.cg-navbar { overflow: visible !important; z-index: 40; }
.cg-navbar .cg-dd-menu { z-index: 60; }
.cg-frame-t, .cg-frame-b { border-radius: 4px 4px 0 0; }
/* the medal: five rows tall, the rank big and coloured between the frame lines */
.cg-medal pre { line-height: 9px !important; font-size: 11px !important; }
main.cg-main .cg-medal-n, .cg-medal-n { color: #7a5410 !important; font: 800 22px/1 var(--font) !important; }
main.cg-main .cg-top-1 .cg-medal-n { color: #a8730a !important; font-size: 24px !important; }
.cg-navbar .cg-dd-menu li > a, .cg-navbar .cg-dd-menu button { color: #333 !important; background: none !important; box-shadow: none !important; min-height: 40px; padding: 8px 16px; }
.cg-navbar .cg-dd-menu li > a:hover, .cg-navbar .cg-dd-menu button:hover { color: #111 !important; background: #f2f2ee !important; }
.cg-navbar .cg-dd-menu a[aria-current="page"] { font-weight: 600; color: #111 !important; }
@media (max-width: 991px) { .cg-navbar .cg-dd-menu li > a, .cg-navbar .cg-dd-menu button { color: #333 !important; } }
/* inside the shop's dark carved cards, notes sit on a dark plate with light words */
.support-offer-card :is(.support-version-benefit, .support-launch-urgency, .cg-callout, .support-note),
.support-premium-card :is(.support-version-benefit, .support-launch-urgency, .cg-callout, .support-note) {
  background: rgba(0, 0, 0, .42) !important; border: 1px solid #7a6030 !important; border-left: 3px solid #d6b25e !important; border-radius: 4px; color: #f3e6c2 !important;
}
.support-offer-card :is(.support-version-benefit, .support-launch-urgency) *, .support-premium-card :is(.support-version-benefit, .support-launch-urgency) * { color: #f3e6c2 !important; }
/* the outline sits under the changing characters */
.cg-axo { z-index: 0; }
.cg-ascii { position: relative; z-index: 1; }
.cg-brand { position: relative; }
/* tables fill their card on a phone too (the old theme turned them into blocks) */
@media (max-width: 760px) {
  main table { display: table !important; width: 100% !important; white-space: normal !important; overflow: visible; }
  main .admin-history-wrap table { display: block !important; overflow-x: auto; white-space: nowrap !important; }
}
