@font-face {
  font-family: DbdArabic;
  src: url("/drawing-game/arabic-d7c65c17615b.woff") format("woff");
  font-display: swap;
}
:root {
  color-scheme: dark;
  --page: #0c0e10;
  --panel: #161a1c;
  --line: #323739;
  --text: #f1f1eb;
  --muted: #b4bbb6;
  --accent: #c6d9ac;
  --edge: #718061;
  --gold: #dcc69a;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  background: var(--page);
  color: var(--text);
  font: 16px/1.55 DbdArabic, Tahoma, Arial, sans-serif;
}
button, input { color: inherit; font: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid #f2d2a0;
  outline-offset: 4px;
}
img { display: block; }
.frame { width: min(1390px, calc(100% - clamp(32px, 8vw, 136px))); margin-inline: auto; }
.skip { position: fixed; z-index: 9; top: -6rem; inset-inline-start: 12px; padding: 10px 18px; background: #283224; }
.skip:focus { top: 8px; }
.topbar { background: #101215; border-bottom: 1px solid #262a2b; }
.bar-inner, .topbar nav, .brand, .crumbs, .section-head, .section-name { display: flex; align-items: center; }
.bar-inner { min-height: 63px; justify-content: space-between; gap: 20px; }
.brand { gap: 8px; }
.brand strong { font: 800 1.4rem/1 Arial, sans-serif; letter-spacing: -.075em; }
.brand em { font-style: normal; color: #f14952; }
.brand small { margin-left: 2px; font-size: .52em; color: #abb0b6; letter-spacing: -.04em; }
.topbar nav { gap: 22px; color: #cccfcf; font-size: .95rem; }
.topbar nav a:hover, .crumbs a:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.masthead {
  position: relative;
  margin: clamp(16px, 2.4vw, 32px) 0 clamp(17px, 2vw, 28px);
  overflow: hidden;
  isolation: isolate;
  display: flex;
  align-items: center;
  min-height: clamp(125px, 12vw, 168px);
  background: linear-gradient(106deg, #2f382b, #222922 38%, #191e1b 69%, #1b201d);
  border: 1px solid #394138;
  border-radius: 13px;
}
.mast-copy { position: relative; z-index: 1; padding: 19px clamp(20px, 3.8vw, 62px) 24px; }
.crumbs { gap: .55rem; color: #c4cbc0; font-size: .87rem; }
.crumbs span { opacity: .5; }
h1, h2, h3, p { margin: 0; }
h1 { margin-top: .28em; font-size: clamp(2.3rem, 4.25vw, 3.9rem); line-height: 1.12; font-weight: 750; }
h1 span { color: var(--accent); }
.mast-ink { pointer-events: none; position: absolute; inset: 0 auto 0 0; width: min(49%, 555px); }
.mast-ink::before {
  content: ""; position: absolute; left: 3%; top: -48%; height: 220%; width: 80%;
  transform: skew(-20deg);
  background: repeating-linear-gradient(90deg, #c8bb8840 0 1px, transparent 1px 39px), linear-gradient(105deg,#5b654b77,#555d4830);
  border-inline: 1px solid #b6b48b46;
}
.portrait { position: absolute; height: 138%; top: 0; width: auto; object-fit: contain; }
.portrait.near { left: 16%; height: 147%; top: 1%; filter: saturate(.82) drop-shadow(8px 0 10px #0d100c75); }
.portrait.far { left: 47%; top: 6%; filter: saturate(.52) brightness(.7); }
.mast-ink::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, #191e1b63, transparent 44%); }
.status, .empty, noscript p { margin-block: 25px; color: var(--muted); }
.status button, .empty button, noscript a { color: var(--accent); text-decoration: underline; background: none; border: 0; }
.layout { display: grid; grid-template-columns: minmax(194px, 244px) minmax(0, 1fr); gap: clamp(20px, 2.9vw, 44px); align-items: start; padding-bottom: 70px; }
.rail {
  border: 1px solid var(--line); border-radius: 12px;
  background: linear-gradient(150deg, #1a1e20, #131719);
  padding: 11px;
}
.rail h2 { margin: 16px 9px 7px; color: #c0c6be; font-size: .88rem; font-weight: 550; }
.group-list { display: grid; gap: 2px; }
.group-choice {
  display: flex; align-items: center; gap: 9px; min-height: 41px;
  padding: 3px 9px; border: 1px solid transparent; border-radius: 6px; color: #dbe0dc;
  font-size: .94rem; line-height: 1.28;
}
.group-choice small { margin-inline-start: auto; color: #bbbfb9; font: 500 .73rem/1.3 Arial, sans-serif; font-variant-numeric: tabular-nums; }
.group-choice:hover { background: #252b29; }
.group-choice[aria-current="page"] { color: #e9f1df; background: #2c342b; border-color: #64715a; }
.home-choice { min-height: 44px; }
.group-asset, .four, .stack { width: 27px; height: 27px; flex: none; }
.group-asset { object-fit: contain; }
.four { display: grid; grid-template-columns: repeat(2, 7px); grid-template-rows: repeat(2, 7px); place-content: center; gap: 2px; transform: rotate(45deg); color: var(--accent); }
.four i { border: 1px solid currentColor; background: #bacaaa25; }
.stack { display: grid; place-content: center; font: bold 23px/1 Arial, sans-serif; color: var(--gold); }
.library { min-width: 0; scroll-margin-top: 15px; outline: 0; }
.section-head { min-height: 42px; gap: 14px; justify-content: space-between; flex-wrap: wrap; }
.section-name { gap: 10px; }
.section-name h2 { color: #f5f4ee; font-size: clamp(1.38rem, 2vw, 1.85rem); line-height: 1.35; }
#result-count { color: var(--muted); font: .8rem Arial,sans-serif; min-width: 1.8rem; padding: 4px 6px; text-align: center; border: 1px solid var(--line); border-radius: 4px; }
.search-box { display: flex; align-items: center; gap: 9px; min-height: 40px; width: min(245px, 100%); padding: 4px 12px; background: #111518; border: 1px solid var(--line); border-radius: 8px; color: #aab4ae; }
.search-box:focus-within { border-color: var(--edge); }
.search-box input { width: 100%; min-width: 0; padding: 0; outline: 0; border: 0; background: none; color: var(--text); font-size: .91rem; }
.search-box input:focus-visible { outline: 0; }
.lens { flex: none; width: 13px; height: 13px; position: relative; border: 1.5px solid currentColor; border-radius: 100%; margin-inline-end: 3px; }
.lens::after { position: absolute; content: ""; left: -4px; bottom: -2px; width: 6px; height: 1.5px; background: currentColor; transform: rotate(-48deg); }
.mobile-nav { display: none; }
.build-help { margin-top: 3px; font-size: .93rem; color: var(--muted); }
#cards { margin-top: 16px; }
.builds-grid, .perk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 305px), 1fr)); gap: 16px; }
.build, .perk-card {
  min-width: 0; border: 1px solid var(--line); border-radius: 11px; overflow: hidden;
  background: var(--panel);
}
.build { border-block-start: 2px solid var(--build-ink, var(--edge)); }
.build-top { padding: 15px 17px 12px; background: linear-gradient(135deg, #ffffff04, transparent); }
.build-group { color: inherit; }
.build-group:hover { text-decoration: underline; }
.build h3 { margin-top: 3px; font-size: 1.31rem; line-height: 1.4; }

.slots { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); padding: 10px 7px 12px; gap: 2px; border-top: 1px solid #303534; background: #101416; }
.slot { background: transparent; border: 0; border-radius: 5px; min-width: 0; padding: 4px 1px 2px; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.slot:hover, .slot:focus-visible { background: #2b302d; }
.slot bdi { overflow-wrap: anywhere; font: 600 .75rem/1.3 Arial, sans-serif; text-align: center; color: #d7ded9; }
.icon-well {
  position: relative; display: grid; place-items: center;
  width: 53px; height: 53px; flex: none; isolation: isolate;
}
.icon-well::before {
  position: absolute; z-index: -1; content: ""; inset: 13%; transform: rotate(45deg);
  background: linear-gradient(145deg, #594463, #332839 72%); border: 1px solid #7b6385;
  border-radius: 3px;
}
.icon-well img { width: 100%; height: 100%; object-fit: contain; }
.perk-grid { align-items: start; }
.perk-card { padding: 16px 18px; }
.perk-heading { display: flex; align-items: center; gap: 10px; }
.perk-heading .icon-well { width: 57px; height: 57px; }
.perk-names { min-width: 0; flex: 1; }
.perk-names h3 { font: 700 1.04rem/1.27 Arial, sans-serif; overflow-wrap: anywhere; text-align: start; direction: rtl; }
.perk-names .arabic { display: block; color: #dfd7c4; font-size: .89rem; margin-top: 2px; }
.owner { display: block; color: #aeb8b0; font-size: .8rem; }
.perk-body { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 11px; font-size: .97rem; white-space: pre-line; line-height: 1.75; color: #e3e6e2; overflow-wrap: anywhere; }
.group-note { color: #b8c0b9; margin-bottom: 15px; font-size: .95rem; }
.subgroup { margin: 22px 0 9px; font-size: 1.07rem; color: var(--accent); }
.subgroup:first-child { margin-top: 0; }
.perk-card .dbding-favorite-button, dialog .dbding-favorite-button { flex: none; }
.aliases { margin-top: 10px; font-size: .86rem; color: #bcb9b0; }
dialog {
  padding: 24px; width: min(460px, calc(100vw - 32px)); max-height: calc(100dvh - 40px); color: var(--text);
  background: #1a1f20; border: 1px solid #58605a; border-radius: 14px; box-shadow: 0 24px 90px #000a;
}
dialog::backdrop { background: #050807d6; }
.dialog-close { position: absolute; inset-block-start: 12px; inset-inline-end: 12px; display: grid; place-items: center; width: 38px; height: 38px; color: #e5e7de; border: 1px solid #4b514e; border-radius: 100%; background: #202525; font: 28px/1 Arial, sans-serif; }
dialog .perk-heading { padding-inline-end: 34px; }
dialog .perk-body { font-size: 1.02rem; }
.dialog-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 13px; }
.native-detail { color: var(--accent); font-size: .9rem; text-decoration: underline; text-underline-offset: 3px; }
@media (min-width: 1450px) {
  .builds-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 900px) {
  .layout { grid-template-columns: minmax(175px, 200px) minmax(0,1fr); gap: 16px; }
  .frame { width: calc(100% - 36px); }
  .rail { padding: 7px; }
  .group-choice { font-size: .88rem; gap: 6px; padding-inline: 6px; }
}
@media (max-width: 720px) {
  .frame { width: calc(100% - 26px); }
  .bar-inner { min-height: 53px; }
  .masthead { min-height: 113px; border-radius: 9px; margin-block: 13px 16px; }
  .mast-copy { padding: 17px 20px; }
  .portrait.near { left: -6%; }
  .portrait.far { left: 34%; }
  .layout { display: block; }
  .rail { margin-bottom: 18px; padding: 9px; }
  .rail h2 { margin: 8px 4px; }
  .group-list { grid-template-columns: repeat(3, minmax(0,1fr)); gap: 4px; }
  .group-choice { font-size: .8rem; min-height: 39px; background: #212625; }
  .group-choice:not(.home-choice) small { display: none; }
  .group-asset, .stack { width: 23px; height: 23px; }
  .home-choice { min-height: 37px; }
  .mobile-nav { display: inline-block; border: 0; background: transparent; padding: 6px; color: var(--accent); font-size: .86rem; }
  .section-head { gap: 5px 12px; }
  .search-box { width: 100%; }
  .slots { padding-inline: 9px; }
  #cards { margin-top: 12px; }
}
@media (max-width: 420px) {
  .group-choice { gap: 4px; padding-inline: 4px; }
  .group-asset { width: 19px; height: 19px; }
  .portrait.far { display: none; }
  .portrait.near { left: 0; height: 128%; top: 7%; }
  .topbar nav { gap: 13px; font-size: .85rem; }
  .perk-card { padding: 14px 12px; }
  .builds-grid, .perk-grid { gap: 12px; }
}
