/* FortifyMe — styles built from the Figma "Fortnite Locker" designs. */
:root {
  --bg: #0b0d12;
  --header: #101219;
  --panel: #151820;
  --panel-2: #20242e;
  --panel-3: #242934;
  --deep: #10131a;
  --line: #292d38;
  --line-2: #2c3240;
  --text: #f5f6fa;
  --muted: #969caa;
  --muted-2: #bcc1cd;
  --accent: #d7fb76;
  --accent-ink: #0b0d12;
  --accent-soft: #242a21;
  --fav: #fb8da5;
  --danger-soft: #bca1a1;

  --r-common: #8b929e;
  --r-uncommon: #6fae4f;
  --r-rare: #4f8fd6;
  --r-epic: #8d78ac;
  --r-legendary: #c98a55;
  --r-mythic: #cfb35a;
  --r-other: #618e89;

  --gutter: 80px;
  --max: 1280px;
}
@media (max-width: 1200px) { :root { --gutter: 40px; } }
@media (max-width: 640px) { :root { --gutter: 16px; } }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--text);
  font: 400 14px/1.45 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  overflow-x: hidden;
}
h1, h2, h3, p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
img { max-width: 100%; }
a { color: inherit; }
.hidden { display: none !important; }
.muted { color: var(--muted); font-size: 13px; }
.small { font-size: 12px; }
.xsmall { font-size: 11px; }
.divider { border: 0; height: 1px; background: var(--line); margin: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Buttons & inputs ---------- */
.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: 44px; padding: 0 16px; border-radius: 8px;
  background: var(--accent); color: var(--accent-ink); font-size: 14px; font-weight: 600; white-space: nowrap;
}
.btn-primary, .btn-secondary { text-decoration: none; }
.btn-primary:hover { filter: brightness(1.06); }
.btn-primary.wide { width: 100%; font-size: 13px; }
.btn-secondary {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: 44px; padding: 0 16px; border-radius: 8px; background: var(--panel-3); font-size: 13px; font-weight: 600;
}
.btn-secondary:hover { background: #2b313e; }
.text-btn { display: inline-flex; align-items: center; gap: 9px; color: var(--muted); font-size: 12px; font-weight: 500; }
.text-btn:hover { color: var(--text); }
.field {
  width: 100%; height: 44px; padding: 0 13px; border-radius: 8px;
  background: var(--accent-ink); border: 1px solid var(--line); font-size: 13px;
}
.field::placeholder, input::placeholder { color: var(--muted); }
textarea.field { height: auto; padding: 11px 13px; resize: vertical; }

.search-box {
  display: flex; align-items: center; gap: 12px; height: 52px; padding: 0 16px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
}
.search-box.tall { height: 48px; }
.search-box input { flex: 1; min-width: 0; height: 100%; background: none; border: 0; outline: none; font-size: 14px; }
.search-box:focus-within { border-color: var(--muted); }

.select-box, .sort-box { position: relative; display: inline-flex; align-items: center; }
.select-box select, .sort-box select { appearance: none; -webkit-appearance: none; cursor: pointer; outline: none; }
.select-box select {
  height: 52px; width: 100%; padding: 0 44px 0 15px; border-radius: 10px;
  background: var(--panel); border: 1px solid var(--line); font-size: 13px; font-weight: 500;
}
.select-box > img, .sort-box > img { position: absolute; right: 16px; pointer-events: none; }
.select-box.small select { height: 36px; border-radius: 8px; padding: 0 38px 0 13px; font-size: 12px; }
.select-box.small > img { right: 14px; }
.sort-box select { background: none; border: 0; padding: 8px 32px 8px 8px; font-size: 13px; font-weight: 500; text-align: right; }
.sort-box.small select { font-size: 12px; }
.sort-box > img { right: 2px; }
select option { background: var(--panel); color: var(--text); }

.toggle-box {
  display: inline-flex; align-items: center; gap: 10px; height: 52px; padding: 0 16px 0 15px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
  color: var(--muted); font-size: 13px; font-weight: 500; white-space: nowrap;
}
.toggle-box.small { height: 36px; border-radius: 8px; padding: 0 14px 0 11px; font-size: 12px; gap: 10px; }
.toggle-box:hover { border-color: #3a404d; }
.toggle-box[aria-pressed="true"] { border-color: var(--accent); color: var(--text); background: var(--accent-soft); }
.checkbox { width: 16px; height: 16px; border: 1px solid #737d8c; border-radius: 4px; display: grid; place-items: center; }
.check-toggle[aria-pressed="true"] .checkbox { background: var(--accent) url("assets/icons/check.svg") center / 14px no-repeat; border-color: var(--accent); }

/* Heart (favorite) and star (wishlist) buttons over artwork */
.fav-btn, .wish-btn { width: 28px; height: 28px; border-radius: 14px; display: grid; place-items: center; flex: none; }
.fav-btn { background: rgba(13, 17, 23, .72); }
.fav-btn img { width: 14px; height: 14px; }
.wish-btn img { width: 28px; height: 28px; }
.fav-btn:hover, .wish-btn:hover { filter: brightness(1.25); }
.marks { position: absolute; top: 10px; right: 10px; display: grid; gap: 4px; z-index: 2; }

/* ---------- Header ---------- */
.topbar { position: sticky; top: 0; z-index: 20; background: var(--header); border-bottom: 1px solid var(--line); }
.topbar-in { height: 88px; max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); display: flex; align-items: center; }
.brand { display: flex; align-items: center; gap: 13px; text-decoration: none; }
.monogram { width: 38px; height: 38px; border-radius: 10px; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; font-weight: 800; font-size: 16px; }
.brand-name { font-size: 21px; font-weight: 700; }
.main-nav { display: flex; gap: 12px; margin-left: 169px; }
.side-nav { display: flex; align-items: center; gap: 53px; margin-left: auto; }
.nav-btn { height: 44px; padding: 0 16px; border-radius: 9px; color: var(--muted); font-size: 14px; font-weight: 500; }
a.nav-btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.nav-btn:hover { color: var(--text); }
.nav-btn.active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.nav-account { background: var(--panel); color: var(--text); font-weight: 600; min-width: 150px; text-align: left; }
.nav-account.active { background: var(--accent-soft); }
.nav-link { display: inline-flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; font-weight: 500; }
.nav-link:hover { color: var(--text); }
@media (max-width: 1100px) { .main-nav { margin-left: 48px; } .side-nav { gap: 24px; } }
@media (max-width: 760px) {
  .topbar-in { height: auto; flex-wrap: wrap; padding-top: 12px; padding-bottom: 10px; row-gap: 10px; }
  .main-nav { order: 3; width: 100%; margin: 0; gap: 4px; }
  .main-nav .nav-btn { flex: 1; height: 40px; }
  .side-nav { gap: 14px; }
  .nav-account { min-width: 0; height: 38px; }
  .brand-name { font-size: 18px; }
}
@media (max-width: 400px) { .nav-link { font-size: 0; gap: 0; } .brand-name { font-size: 16px; } }

/* ---------- Page shell ---------- */
.view { flex: 1; width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; padding: 31px 0 26px; }
.eyebrow { color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: 1.43px; text-transform: uppercase; }
.eyebrow.small { font-size: 10px; letter-spacing: .4px; }
.page-head h1 { margin-top: 12px; font-size: 40px; font-weight: 700; line-height: 1.2; }
.lead { margin-top: 6px; color: var(--muted); font-size: 15px; }
@media (max-width: 640px) {
  .page-head { flex-direction: column; padding: 22px 0 18px; gap: 16px; }
  .page-head h1 { font-size: 30px; }
}

/* ---------- Item shop ---------- */
.shop-date { width: 322px; flex: none; margin-top: 11px; }
.date-card { display: flex; align-items: center; gap: 14px; height: 75px; padding: 0 17px; border-radius: 12px; background: var(--panel); }
.date-main { font-size: 14px; font-weight: 600; }
.date-sub { margin-top: 4px; color: var(--muted); font-size: 12px; white-space: pre; }
.date-note { margin-top: 12px; color: var(--muted); font-size: 11px; padding-left: 2px; }
@media (max-width: 640px) { .shop-date { width: 100%; margin: 0; } }

.featured { display: grid; grid-template-columns: 844fr 416fr; gap: 20px; margin-bottom: 24px; }
.feature {
  position: relative; height: 376px; border-radius: 20px; overflow: hidden; cursor: pointer; text-align: left;
}
.feature-bundle { background: linear-gradient(142.86deg, #35275f 0%, #171325 74%); }
.feature-bundle .kicker { position: absolute; left: 32px; top: 29px; color: #d8ccff; font-size: 11px; font-weight: 700; letter-spacing: .88px; text-transform: uppercase; }
.feature-bundle .art { position: absolute; left: 43%; right: -1%; top: -25px; height: 460px; width: auto; object-fit: contain; object-position: center top; pointer-events: none; }
.feature-bundle .save { position: absolute; right: 32px; top: 29px; height: 30px; padding: 0 12px; display: grid; place-items: center; border-radius: 6px; background: var(--accent); color: var(--accent-ink); font-size: 10px; font-weight: 700; text-transform: uppercase; z-index: 1; }
.feature-bundle .body { position: absolute; left: 34px; bottom: 10px; z-index: 1; max-width: 50%; }
.feature-bundle .name { font-size: 30px; font-weight: 600; line-height: 1.2; }
.feature-bundle .items { margin-top: 8px; color: #c0b5d6; font-size: 14px; }
.feature-bundle .price { margin-top: 16px; display: flex; align-items: baseline; gap: 12px; }
.feature-bundle .price strong { font-size: 27px; font-weight: 700; }
.feature-bundle .price span { color: #d6cde6; font-size: 12px; }
.feature-bundle .price s { color: #aea1c1; font-size: 12px; }
.feature-bundle .btn-primary { margin: 12px 0 0; }

.feature-sidekick { background: linear-gradient(123.06deg, #204b47 0%, #11252d 74%); }
.feature-sidekick .kicker { position: absolute; left: 26px; top: 27px; color: #bfe6dd; font-size: 10px; font-weight: 700; z-index: 1; }
.feature-sidekick .art { position: absolute; left: 19%; top: 44px; width: 72%; height: 230px; object-fit: contain; pointer-events: none; }
.feature-sidekick .body { position: absolute; left: 26px; right: 80px; bottom: 19px; }
.feature-sidekick .name { font-size: 30px; font-weight: 700; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feature-sidekick .sub { margin-top: 4px; color: #c0d7d1; font-size: 13px; }
.feature-sidekick .price { margin-top: 10px; font-size: 15px; font-weight: 600; }
.feature-sidekick .round { position: absolute; right: 26px; bottom: 25px; width: 44px; height: 44px; border-radius: 22px; background: #294842; display: grid; place-items: center; }
.feature-sidekick .gone { color: #e9c9a0; }
@media (max-width: 1000px) {
  .featured { grid-template-columns: 1fr; }
  .feature-sidekick { height: 320px; }
}
@media (max-width: 640px) {
  .feature { height: 420px; }
  .feature-bundle .art { left: 20%; height: 330px; top: 30px; }
  .feature-bundle .body { max-width: none; right: 20px; }
  .feature-bundle .kicker { right: 20px; }
  .feature-bundle .save { top: 56px; left: 32px; right: auto; }
  .feature-sidekick { height: 340px; }
}

.browse { padding-top: 14px; }
.browse-head { display: flex; justify-content: space-between; align-items: center; }
.browse-head h2 { font-size: 17px; font-weight: 600; }
.all-link { display: inline-flex; align-items: center; gap: 43px; color: var(--muted); font-size: 12px; }
.all-link:hover { color: var(--text); }
.chips { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 21px; }
.chip {
  height: 43px; padding: 0 17px; border-radius: 22px; background: var(--panel); border: 1px solid var(--line);
  color: var(--muted-2); font-size: 13px; font-weight: 500; white-space: nowrap;
}
.chip:hover { border-color: #3a404d; color: var(--text); }
.chip.active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 600; }
.browse .divider { margin-top: 29px; }
.shop-controls { display: flex; gap: 12px; margin: 31px 0 40px; align-items: center; }
.shop-controls .search-box { flex: 0 1 480px; }
.shop-controls .select-box { flex: 0 0 171px; }
.shop-controls #shop-wish { flex: 0 0 170px; }
.shop-controls #shop-tracks { flex: 0 0 181px; font-size: 12px; }
.shop-controls .sort-box { margin-left: auto; }
@media (max-width: 1200px) {
  .shop-controls { flex-wrap: wrap; }
  .shop-controls .search-box { flex: 1 1 100%; }
}
@media (max-width: 640px) {
  .chips { flex-wrap: nowrap; overflow-x: auto; margin-right: calc(-1 * var(--gutter)); padding-right: var(--gutter); scrollbar-width: none; }
  .shop-controls .select-box, .shop-controls #shop-wish, .shop-controls #shop-tracks { flex: 1 1 calc(50% - 6px); }
  .shop-controls .sort-box { margin-left: 0; }
}

.shop-section { margin-bottom: 40px; scroll-margin-top: 104px; }
.section-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 24px; }
.section-head h2 { display: flex; align-items: center; gap: 18px; font-size: 27px; font-weight: 700; line-height: 1.2; }
.count { display: inline-grid; place-items: center; min-width: 28px; height: 26px; padding: 0 9px; border-radius: 6px; background: var(--panel-2); color: var(--muted); font-size: 12px; font-weight: 500; }
.link-accent { display: inline-flex; align-items: center; gap: 22px; color: var(--accent); font-size: 13px; font-weight: 600; white-space: nowrap; }
.link-accent:hover { text-decoration: underline; }
@media (max-width: 640px) {
  .section-head h2 { font-size: 22px; gap: 12px; }
  .link-accent { gap: 10px; }
  .link-accent .long { display: none; }
}

.shop-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.shop-grid.lead-bundle { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1100px) { .shop-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 860px) { .shop-grid, .shop-grid.lead-bundle { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; } }
@media (max-width: 420px) { .shop-grid.lead-bundle .bundle-card { grid-column: 1 / -1; min-height: 240px; } }

.offer-card {
  position: relative; display: flex; flex-direction: column; min-width: 0; text-align: left; cursor: pointer;
  background: var(--panel); border: 1px solid var(--line); border-radius: 14px; overflow: hidden;
}
.offer-card:hover { border-color: #3a404d; }
.offer-card .art { position: relative; height: 236px; background: linear-gradient(90deg, var(--c1, #2b3240), var(--c2, #181d26)); overflow: hidden; }
.offer-card .art img.render { position: absolute; left: 50%; top: 0; height: 121%; transform: translateX(-50%); max-width: none; object-fit: contain; }
.shop-grid.lead-bundle .offer-card .art { height: 246px; }
.offer-card .tag { position: absolute; left: 11px; top: 12px; z-index: 2; height: 25px; padding: 0 9px; display: grid; place-items: center; border-radius: 5px; background: var(--accent); color: var(--accent-ink); font-size: 10px; font-weight: 600; max-width: calc(100% - 64px); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.offer-card .info { padding: 16px 17px 13px; }
.offer-card .name { font-size: 17px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.shop-grid.lead-bundle .offer-card .name { font-size: 18px; }
.offer-card .sub { margin-top: 6px; color: var(--muted); font-size: 12px; }
.price-row { display: flex; align-items: baseline; gap: 10px; margin-top: 12px; white-space: nowrap; }
.price-row strong { font-size: 14px; font-weight: 700; }
.price-row span, .price-row s { color: var(--muted); font-size: 10px; }
.price-row .view { margin-left: auto; }
.leaves-soon { color: #f0b37e; }
@media (max-width: 640px) {
  .offer-card .art { height: 190px; }
  .offer-card .info { padding: 12px; }
  .offer-card .name { font-size: 15px; }
  .price-row .view { display: none; }
}

.bundle-card {
  display: flex; flex-direction: column; text-align: left; cursor: pointer; min-height: 352px; padding: 47px 27px 22px;
  border-radius: 16px; background: color-mix(in srgb, var(--c1, #476836) 22%, #12160f); border: 1px solid color-mix(in srgb, var(--c1, #476836) 40%, #1b2117);
}
.bundle-card:hover { border-color: color-mix(in srgb, var(--c1, #476836) 70%, #1b2117); }
.bundle-card .name { font-size: 30px; font-weight: 800; line-height: 1.2; }
.bundle-card .count-line { margin-top: 10px; color: #e0e9d6; font-size: 16px; font-weight: 600; }
.bundle-card .price { margin-top: auto; display: flex; align-items: baseline; gap: 12px; }
.bundle-card .price strong { font-size: 24px; font-weight: 700; }
.bundle-card .price span, .bundle-card .price s { color: #aab89e; font-size: 12px; }
.bundle-card .explore { margin-top: 28px; display: flex; justify-content: space-between; align-items: center; color: var(--accent); font-size: 14px; font-weight: 600; }

.shop-empty { color: var(--muted); padding: 40px 0; text-align: center; }

.invite {
  display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 18px 0 29px;
  min-height: 104px; padding: 21px 23px; border-radius: 13px; background: #191f18; border: 1px solid #30392b;
}
.invite h2 { font-size: 23px; font-weight: 700; }
.invite p { margin-top: 8px; color: #a3ad9a; font-size: 13px; }
.invite .btn-primary { min-width: 221px; height: 46px; justify-content: space-between; font-size: 13px; color: #10160c; }
@media (max-width: 640px) { .invite { flex-direction: column; align-items: stretch; } .invite .btn-primary { min-width: 0; } }

/* ---------- Item details pop-up ---------- */
.entry-dialog {
  width: min(1040px, calc(100vw - 32px)); max-height: calc(100vh - 32px); padding: 0; overflow: auto;
  background: var(--panel); color: var(--text); border: 1px solid var(--line); border-radius: 20px;
}
.entry-dialog::backdrop { background: rgba(5, 6, 9, .72); }
.entry { display: grid; grid-template-columns: 416px 1fr; min-height: 704px; }
.entry-preview { position: relative; display: flex; flex-direction: column; align-items: center; padding: 30px 28px 20px; background: linear-gradient(90deg, #293d4a, #141f2b); }
.entry-preview .kicker { align-self: flex-start; color: #b0c2cf; font-size: 10px; font-weight: 700; text-transform: uppercase; }
.entry-preview .big { flex: 1; width: 100%; min-height: 0; height: 522px; margin-top: 21px; object-fit: contain; }
.entry-thumbs { display: flex; gap: 12px; margin-top: 10px; flex-wrap: wrap; justify-content: center; }
.entry-thumbs button { width: 56px; height: 56px; padding: 4px; border-radius: 9px; background: #0f141c; border: 1px solid #3b4a57; }
.entry-thumbs button.on { border-color: var(--accent); }
.entry-thumbs img { width: 100%; height: 100%; object-fit: contain; }
.entry-preview .caption { margin-top: 20px; color: #b0c2cf; font-size: 10px; font-weight: 500; white-space: pre; }
.entry-info { position: relative; padding: 32px 40px 36px; display: flex; flex-direction: column; }
.entry-info .close { position: absolute; right: 20px; top: 20px; width: 36px; height: 36px; border-radius: 18px; background: var(--panel-3); display: grid; place-items: center; }
.entry-info .kicker { color: var(--accent); font-size: 10px; font-weight: 700; text-transform: uppercase; }
.entry-info h3 { margin-top: 8px; font-size: 36px; font-weight: 700; line-height: 1.2; padding-right: 40px; }
.entry-info .types { margin-top: 6px; color: #a2a9b6; font-size: 14px; }
.entry-price { display: flex; align-items: center; gap: 16px; margin-top: 14px; }
.entry-price strong { font-size: 30px; font-weight: 700; }
.entry-price span { color: #a2a9b6; font-size: 13px; font-weight: 500; }
.entry-price s { color: #a2a9b6; font-size: 13px; }
.entry-price .pill { margin-left: auto; height: 28px; padding: 0 20px; border-radius: 14px; display: grid; place-items: center; background: #29262a; color: #d6bdc2; font-size: 11px; font-weight: 500; }
.entry-until { margin-top: 4px; color: #a2a9b6; font-size: 12px; }
.entry-info .divider { background: var(--line-2); margin: 20px 0 19px; }
.included-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 14px; }
.included-head h4 { margin: 0; font-size: 17px; font-weight: 600; }
.included-head span { color: #a2a9b6; font-size: 11px; }
.included { display: grid; gap: 12px; }
.inc-row { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 11px 16px 11px 13px; min-height: 104px; border-radius: 12px; background: #1c202a; border: 1px solid var(--line-2); }
.inc-thumb { width: 64px; height: 64px; padding: 4px; border-radius: 8px; background: #10151e; }
.inc-thumb img { width: 100%; height: 100%; object-fit: contain; }
.inc-row strong { display: block; font-size: 14px; font-weight: 600; }
.inc-row .t { color: #a2a9b6; font-size: 12px; }
.inc-row .note { margin-top: 6px; color: #a2a9b6; font-size: 10px; }
.inc-acts { display: grid; justify-items: end; gap: 16px; }
.inc-acts .pair { display: flex; gap: 8px; }
.inc-acts .btn-primary { height: 36px; font-size: 13px; padding: 0 21px; }
.entry-history { margin-top: 30px; color: #a2a9b6; font-size: 12px; }
.entry-foot { display: flex; align-items: center; gap: 24px; margin-top: auto; padding-top: 20px; border-top: 1px solid var(--line-2); }
.entry-foot .btn-secondary { height: 42px; width: 120px; border: 1px solid var(--line-2); background: #242a35; font-weight: 500; }
.entry-foot span { color: #a2a9b6; font-size: 11px; }
.entry-history + .entry-foot { margin-top: 32px; }
@media (max-width: 900px) {
  .entry { grid-template-columns: 1fr; min-height: 0; }
  .entry-preview .big { height: 300px; flex: none; }
  .entry-info { padding: 24px 20px 24px; }
  .entry-info h3 { font-size: 28px; }
}
@media (max-width: 520px) {
  .entry-dialog { width: 100vw; max-width: 100vw; max-height: 100vh; height: 100vh; border-radius: 0; }
  .inc-row { grid-template-columns: 52px minmax(0, 1fr); }
  .inc-thumb { width: 52px; height: 52px; }
  .inc-acts { grid-column: 1 / -1; grid-template-columns: auto 1fr; align-items: center; }
  .entry-price { flex-wrap: wrap; }
  .entry-price .pill { margin-left: 0; }
}

/* ---------- Combo builder ---------- */
.status-pill { margin-top: 60px; height: 34px; padding: 0 18px; border-radius: 17px; background: var(--panel); color: var(--muted); font-size: 12px; font-weight: 500; display: inline-grid; place-items: center; white-space: nowrap; }
.status-pill.saved { color: var(--accent); background: var(--accent-soft); }
@media (max-width: 640px) { .status-pill { margin-top: 0; } }
.builder > * { min-width: 0; }
.builder { display: grid; grid-template-columns: 416px minmax(0, 1fr); gap: 32px; align-items: start; padding-top: 16px; padding-bottom: 48px; }
@media (max-width: 1100px) { .builder { grid-template-columns: 360px minmax(0, 1fr); gap: 24px; } }
@media (max-width: 900px) { .builder { grid-template-columns: 1fr; } }

.preview-card { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.preview-stage { position: relative; height: 354px; background: linear-gradient(90deg, #262d3a, #181d26); overflow: hidden; }
.preview-stage .label { position: absolute; left: 22px; top: 22px; color: #b6beca; font-size: 10px; font-weight: 600; letter-spacing: .8px; text-transform: uppercase; z-index: 1; }
.preview-stage .count-pill { position: absolute; right: 19px; top: 16px; height: 25px; padding: 0 14px; border-radius: 12px; background: #131820; color: var(--accent); font-size: 10px; font-weight: 500; display: grid; place-items: center; z-index: 1; }
.preview-stage .art { position: absolute; left: 27px; right: 27px; top: 18px; height: 343px; width: calc(100% - 54px); object-fit: contain; }
.preview-stage .art.item { top: 56px; height: 260px; }
.preview-stage .back { position: absolute; left: 16px; bottom: 14px; z-index: 1; height: 30px; padding: 0 12px; border-radius: 15px; background: rgba(13, 17, 23, .72); color: var(--text); font-size: 11px; font-weight: 500; }
.preview-empty { position: absolute; inset: 0; width: 100%; display: grid; place-content: center; justify-items: center; gap: 12px; color: var(--muted); font-size: 13px; }
.preview-empty .slot-icon { width: 56px; height: 56px; border-radius: 12px; }
.thumb-strip { display: grid; grid-template-columns: repeat(5, 72px); justify-content: space-between; gap: 6px; padding: 10px 16px; background: var(--deep); }
.thumb { width: 72px; height: 66px; padding: 1px 8px 0; border-radius: 7px; background: var(--panel); border: 1px solid var(--line); display: grid; grid-template-rows: 43px auto; justify-items: center; }
.thumb img { width: 54px; height: 43px; object-fit: contain; }
.thumb span { margin-top: 3px; color: var(--muted); font-size: 9px; font-weight: 500; white-space: nowrap; }
.thumb.on { border-color: var(--accent); }
.thumb.on span { color: var(--text); }
.thumb.empty { opacity: .35; cursor: default; }
.preview-info { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 21px 20px; min-height: 76px; }
.preview-info .name { font-size: 23px; font-weight: 700; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.preview-info .type { margin-top: 6px; color: var(--muted); font-size: 12px; }
.shop-chip { flex: none; height: 27px; padding: 0 10px; border-radius: 6px; background: var(--accent-soft); color: var(--accent); font-size: 10px; font-weight: 500; display: inline-grid; place-items: center; white-space: nowrap; }
@media (max-width: 1100px) { .thumb-strip { grid-template-columns: repeat(5, minmax(0, 1fr)); } .thumb { width: auto; } }

.loadout-head { display: flex; justify-content: space-between; align-items: baseline; margin: 24px 0 18px; padding-right: 10px; }
.loadout-head h2 { font-size: 18px; font-weight: 600; }
.loadout-head span { color: var(--muted); font-size: 12px; }
.loadout-head span.full { color: var(--accent); }
.loadout { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; }
.slot-row {
  display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; align-items: center; gap: 14px; height: 56px; padding: 0 14px 0 7px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px; cursor: pointer;
}
.slot-row:hover { border-color: #3a404d; }
.slot-row.active { background: #1d241a; border-color: #546a38; }
.slot-thumb { width: 42px; height: 42px; border-radius: 7px; background: var(--panel-2); display: grid; place-items: center; overflow: hidden; }
.slot-row.active .slot-thumb { background: #313c29; }
.slot-thumb img.item { width: 42px; height: 42px; object-fit: contain; }
.slot-icon { display: grid; place-items: center; background: var(--panel-2); }
.slot-label { color: var(--muted); font-size: 9px; font-weight: 600; text-transform: uppercase; letter-spacing: .3px; }
.slot-row.active .slot-label { color: var(--accent); }
.slot-name { margin-top: 3px; font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.slot-name.empty { color: #bbc1cc; font-weight: 400; }
.slot-acts { display: flex; align-items: center; gap: 28px; }
.slot-acts .replace { color: var(--accent); font-size: 11px; font-weight: 500; }
.slot-acts .replace:hover { text-decoration: underline; }
.slot-acts .icon { width: 20px; height: 20px; display: grid; place-items: center; }
.slot-acts .icon:hover { filter: brightness(1.6); }

.save-card { margin-top: 16px; padding: 19px 19px 18px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; }
.save-card label { display: block; font-size: 14px; font-weight: 600; }
.save-card input { margin-top: 12px; width: 100%; height: 44px; padding: 0 13px; border-radius: 8px; background: var(--deep); border: 1px solid var(--line); font-size: 13px; outline: none; }
.save-card input:focus { border-color: var(--muted); }
.save-row { display: grid; grid-template-columns: 214fr 150fr; gap: 12px; margin-top: 14px; }
.save-links { display: flex; justify-content: space-between; margin-top: 25px; padding-right: 7px; }
.text-btn.clear { color: var(--danger-soft); }
.text-btn.clear:hover { color: #e5c4c4; }
.disclaimer { display: flex; gap: 9px; margin-top: 21px; color: var(--muted); font-size: 11px; line-height: 18px; }
.disclaimer img { margin-top: 1px; flex: none; }

.browser h2 { font-size: 24px; font-weight: 700; line-height: 1.2; }
.browser-sub { margin-top: 6px; color: var(--muted); font-size: 13px; }
.tabs { display: grid; grid-template-columns: 112fr 156fr 148fr 144fr 116fr 148fr; margin-top: 16px; padding: 4px; border-radius: 10px; background: #11141b; }
.tab { height: 40px; border-radius: 7px; color: var(--muted); font-size: 13px; font-weight: 500; white-space: nowrap; }
.tab:hover { color: var(--text); }
.tab.active { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.browser .search-box { margin-top: 16px; }
.browser-filters { display: flex; align-items: center; gap: 12px; margin-top: 16px; }
.browser-filters .select-box.small select { width: 158px; }
.browser-filters .sort-box { margin-left: auto; }
.result-row { display: flex; justify-content: space-between; margin: 21px 0 22px; color: var(--muted); font-size: 12px; font-weight: 500; }
.result-row #result-hint { font-size: 11px; font-weight: 400; padding-right: 36px; }
@media (max-width: 760px) {
  .tabs { display: flex; overflow-x: auto; scrollbar-width: none; }
  .tab { flex: none; padding: 0 16px; }
  .browser-filters { flex-wrap: wrap; }
  .browser-filters .sort-box { margin-left: 0; }
  .result-row #result-hint { display: none; }
}

.item-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 1250px) { .item-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 560px) { .item-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }
.item-card {
  position: relative; display: flex; flex-direction: column; min-width: 0; height: 256px; text-align: left; cursor: pointer;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden;
}
.item-card:hover { border-color: #3a404d; }
.item-card .art { position: relative; height: 184px; flex: none; background: linear-gradient(90deg, color-mix(in srgb, var(--rc) 22%, #1f232c), #1c2029); border-bottom: 2px solid var(--rc); overflow: hidden; }
.item-card .art img.pic { position: absolute; left: 2px; right: 2px; top: 0; width: calc(100% - 4px); height: 205px; object-fit: contain; }
.item-card .name { margin: 11px 12px 0; font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-card .meta { margin: 9px 12px 0; color: var(--muted); font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-card .meta.price { color: var(--accent); font-weight: 500; }
.item-card .marks { top: 8px; right: 8px; }
.item-card .badge { position: absolute; left: 9px; top: 9px; z-index: 2; height: 23px; padding: 0 9px; border-radius: 5px; display: inline-flex; align-items: center; gap: 6px; background: #263020; color: var(--accent); font-size: 10px; font-weight: 600; }
.item-card.equipped { border: 2px solid var(--accent); }
.item-card.equipped .art { border-bottom-color: var(--accent); }
.item-card.equipped .badge { background: var(--accent); color: var(--accent-ink); height: 25px; padding: 0 9px 0 7px; }
.r-common { --rc: var(--r-common); }
.r-uncommon { --rc: var(--r-uncommon); }
.r-rare { --rc: var(--r-rare); }
.r-epic { --rc: var(--r-epic); }
.r-legendary { --rc: var(--r-legendary); }
.r-mythic, .r-exotic, .r-transcendent { --rc: var(--r-mythic); }
.r-other { --rc: var(--r-other); }

.pager { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 32px; padding-top: 19px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
.pager-btns { display: flex; align-items: center; gap: 6px; }
.pager-btns button { width: 36px; height: 36px; border-radius: 7px; background: var(--panel); color: var(--muted); font-size: 12px; display: grid; place-items: center; }
.pager-btns button.edge { border: 1px solid var(--line); margin: 0 6px; }
.pager-btns button.on { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.pager-btns button:disabled { opacity: .45; cursor: default; }
.pager-btns .gap { width: 30px; text-align: center; font-size: 14px; }
@media (max-width: 560px) { .pager { flex-direction: column; } }

/* ---------- My account ---------- */
.account-head { padding-top: 44px; }
.account-head h1 { margin-top: 8px; }
.proto-badge { margin-top: 10px; height: 30px; padding: 0 17px; border-radius: 15px; background: var(--accent-soft); color: var(--accent); font-size: 10px; font-weight: 700; display: inline-grid; place-items: center; text-transform: uppercase; }
.stats { display: flex; margin-top: 26px; }
.stats > div { display: flex; align-items: center; gap: 18px; padding-right: 32px; margin-right: 32px; border-right: 1px solid var(--line); height: 28px; }
.stats > div:last-child { border: 0; }
.stats strong { font-size: 22px; font-weight: 600; }
.stats span { color: var(--muted); font-size: 12px; min-width: 110px; }
@media (max-width: 640px) {
  .stats > div { flex-direction: column; align-items: flex-start; gap: 0; height: auto; padding-right: 16px; margin-right: 16px; }
  .stats span { min-width: 0; }
  .proto-badge { margin-top: 0; }
}
.account { display: grid; grid-template-columns: 824fr 424fr; gap: 32px; padding-top: 16px; padding-bottom: 60px; align-items: start; }
@media (max-width: 1100px) { .account { grid-template-columns: 1fr; } }
.block-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.block-head h2 { display: flex; align-items: center; gap: 18px; font-size: 22px; font-weight: 700; }
.block-head > span { color: var(--muted); font-size: 12px; padding-right: 30px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; }
.empty-state { padding: 23px 27px 23px; }
.empty-state h3 { margin-top: 6px; font-size: 26px; font-weight: 700; }
.empty-state p.muted { margin-top: 6px; }
.empty-state .btn-primary { margin-top: 24px; height: 42px; font-size: 13px; gap: 24px; }
.combo-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 640px) { .combo-cards { grid-template-columns: 1fr; } }
.combo-card { padding: 18px 20px; }
.combo-card h3 { font-size: 17px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.combo-card .thumbs { display: flex; flex-wrap: wrap; gap: 6px; margin: 14px 0; }
.combo-card .thumbs img { width: 52px; height: 52px; padding: 3px; border-radius: 8px; background: var(--deep); border: 1px solid var(--line); object-fit: contain; }
.combo-card .acts { display: flex; gap: 10px; align-items: center; }
.combo-card .acts .btn-primary, .combo-card .acts .btn-secondary { height: 36px; font-size: 12px; }
.combo-card .acts .text-btn { margin-left: auto; }
.lists { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; margin-top: 44px; }
@media (max-width: 760px) { .lists { grid-template-columns: 1fr; } }
.mini-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.mini-grid .empty-msg { grid-column: 1 / -1; color: var(--muted); font-size: 13px; }
.mini-card { position: relative; height: 256px; text-align: left; cursor: pointer; display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.mini-card:hover { border-color: #3a404d; }
.mini-card .art { position: relative; height: 186px; flex: none; background: linear-gradient(90deg, color-mix(in srgb, var(--rc) 40%, #1c2333), #19202f); }
.mini-card .art img.pic { position: absolute; left: 8px; top: 2px; width: calc(100% - 16px); height: 184px; object-fit: contain; }
.mini-card .name { margin: 11px 11px 0; font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-card .meta { margin: 13px 11px 0; color: var(--muted); font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.account-side { display: grid; gap: 24px; }
.alerts { padding: 23px; }
.alerts h3 { font-size: 22px; font-weight: 700; }
.alerts > p.muted { margin-top: 10px; }
.field-label { display: block; margin: 36px 0 9px; font-size: 12px; font-weight: 500; }
.switch-row { display: flex; justify-content: space-between; align-items: center; margin-top: 24px; font-size: 14px; font-weight: 500; }
.alerts #alert-status { margin-top: 4px; }
.alerts .btn-primary { margin-top: 28px; }
.switch { appearance: none; -webkit-appearance: none; position: relative; width: 46px; height: 26px; margin: 0; border-radius: 13px; background: #353b48; cursor: pointer; transition: background .15s; }
.switch::after { content: ""; position: absolute; left: 4px; top: 4px; width: 18px; height: 18px; border-radius: 50%; background: #b8beca; transition: transform .15s, background .15s; }
.switch:checked { background: var(--accent); }
.switch:checked::after { transform: translateX(20px); background: var(--accent-ink); }
.adfree { padding: 23px; }
.adfree h3 { font-size: 22px; font-weight: 700; }
.adfree > p.muted { margin-top: 10px; }
.adfree-plans { display: grid; gap: 10px; margin-top: 22px; }
.adfree-plans .per { opacity: .7; font-weight: 500; }
#btn-billing-portal { margin-top: 22px; }
.adfree-plans:not(.hidden) + #btn-billing-portal { margin-top: 10px; }
.adfree-fine { margin-top: 14px; }
#adfree-section { margin-bottom: 28px; }

/* Ad slots: fixed minimum height so the page doesn't jump when an ad loads. */
.ad-slot { margin: 0 0 24px; }
#view-build > .ad-slot { margin: 0 0 48px; }
.ad-label { display: flex; justify-content: space-between; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.ad-label .ad-remove { color: var(--accent); text-transform: none; letter-spacing: 0; font-size: 12px; }
.ad-box { min-height: 100px; border-radius: 12px; overflow: hidden; background: var(--deep); }
@media (min-width: 768px) { .ad-box { min-height: 250px; } }
.ad-free .ad-slot { display: none !important; }

.notice { padding: 19px 23px 22px; background: #11151b; }
.notice h3 { margin-top: 10px; font-size: 17px; font-weight: 600; }
.notice #check-text { margin-top: 8px; }
.notice .divider { margin: 24px 0 18px; }
.notice ul { margin: 10px 0 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.notice li button { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; font-size: 12px; }
.notice li img { width: 32px; height: 32px; object-fit: contain; border-radius: 6px; background: var(--panel); }
.notice li span { color: var(--accent); margin-left: auto; white-space: nowrap; }

/* ---------- Contact ---------- */
.contact { max-width: 640px; padding: 40px 0 60px; }
.contact h1 { margin-top: 12px; font-size: 36px; font-weight: 700; }
.contact .lead { margin-bottom: 20px; }
.contact-form { display: grid; gap: 16px; padding: 22px; margin-bottom: 12px; }
.contact-form label { display: grid; gap: 8px; font-size: 13px; font-weight: 500; }
.contact-form .opt { color: var(--muted); font-weight: 400; }
.contact-form .select-box select { height: 44px; background: var(--accent-ink); }
.contact-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Guest header (Sign up, Log in) ---------- */
.guest-btn { width: 134px; background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.guest-btn:hover { color: var(--accent); filter: brightness(1.15); }
.guest-nav { display: none; align-items: center; gap: 0; margin-left: auto; }
.guest-q { color: var(--muted); font-size: 13px; width: 216px; }
body.guest .side-nav { display: none; }
body.guest .guest-nav { display: flex; }
body.signed-in .nav-login, body:not(.signed-in) .nav-account { display: none; }
@media (max-width: 1100px) { .guest-q { width: auto; margin-right: 20px; } }
@media (max-width: 760px) { .guest-q { display: none; } .guest-btn { width: auto; height: 38px; } }

/* ---------- Sign up & Log in (Figma 73:2, 73:19) ---------- */
.auth-split { display: grid; grid-template-columns: 600px 480px; align-items: start; gap: 40px 120px; padding: 100px 0 80px; }
.auth-intro .eyebrow, .auth-head .eyebrow { letter-spacing: 0; }
.auth-intro h1 { margin-top: 17px; font-size: 44px; line-height: 51.04px; font-weight: 700; }
.auth-lead { margin-top: 23px; max-width: 540px; color: var(--muted); font-size: 16px; line-height: 24px; }
.auth-previews { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 38px; }
.auth-preview { height: 268px; display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.auth-preview .art { position: relative; height: 204px; margin: -1px -1px 0; flex: none; }
.auth-preview .art img { position: absolute; left: 4px; top: 4px; width: calc(100% - 8px); height: 196px; object-fit: contain; }
.auth-preview .name { margin: 11px 12px 0; font-size: 14px; font-weight: 600; line-height: 21px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.auth-preview .meta { margin: 4px 12px 0; color: var(--muted); font-size: 11px; line-height: 16.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.auth-benefits { margin: 34px 0 0; }
.auth-benefits dt { font-size: 16px; font-weight: 600; line-height: 24px; }
.auth-benefits dd { margin: 4px 0 0; color: var(--muted); font-size: 13px; line-height: 19.5px; }
.auth-benefits dd + dt { margin-top: 22px; }

.auth-card { display: flex; flex-direction: column; gap: 24px; padding: 36px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; }
.auth-head { display: grid; gap: 8px; }
.auth-head h2 { font-size: 28px; line-height: 42px; font-weight: 700; }
.auth-head p:not(.eyebrow) { color: var(--muted); font-size: 14px; line-height: 21px; }
.auth-fields { display: grid; gap: 20px; }
.auth-field { display: grid; gap: 8px; }
.auth-field label, .label-row label { font-size: 13px; font-weight: 500; line-height: 19.5px; }
.label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.link-btn { color: var(--accent); font-size: 12px; font-weight: 500; line-height: 18px; }
.link-btn:hover { text-decoration: underline; }
.auth-input {
  width: 100%; height: 52px; padding: 0 13px; border-radius: 8px;
  background: var(--bg); border: 1px solid var(--line); font-size: 14px;
}
.auth-input:focus { outline: none; border-color: var(--accent); }
.auth-input[aria-invalid="true"] { border-color: var(--fav); }
.pw-wrap { position: relative; }
.pw-wrap .auth-input { padding-right: 80px; }
.pw-toggle { position: absolute; right: 1px; top: 1px; height: 50px; padding: 0 21px 0 16px; border-radius: 0 8px 8px 0; color: var(--accent); font-size: 13px; font-weight: 600; }
.auth-hint { color: var(--muted); font-size: 12px; line-height: 18px; }
.auth-optin { display: grid; gap: 8px; }
.check-row { display: flex; align-items: flex-start; gap: 12px; min-height: 44px; font-size: 13px; line-height: 19.5px; cursor: pointer; }
.check {
  appearance: none; -webkit-appearance: none; flex: none; width: 18px; height: 18px; margin: 1px 0 0;
  border: 1px solid var(--line); border-radius: 4px; background: var(--bg); cursor: pointer;
}
.check:checked { background: var(--accent) url("assets/icons/check.svg") center / 14px no-repeat; border-color: var(--accent); }
.auth-actions { display: grid; gap: 16px; }
.auth-submit { width: 100%; height: 52px; }
.auth-legal { color: var(--muted); font-size: 12px; line-height: 18px; }
.auth-legal a { color: var(--text); text-decoration: none; }
.auth-legal a:hover, .auth-switch a:hover { text-decoration: underline; }
.auth-switch { color: var(--muted); font-size: 13px; line-height: 19.5px; text-align: center; }
.auth-switch a { color: var(--accent); text-decoration: none; }
.auth-error { color: var(--fav); font-size: 13px; }
.auth-error:empty { display: none; }
.auth-error.ok { color: var(--accent); }
.auth-error .link-btn { margin-left: 6px; font-size: 13px; }
.auth-split .auth-sent { grid-column: 2; grid-row: 1; }
.auth-sent .auth-head p strong { color: var(--text); font-weight: 600; word-break: break-all; }
.auth-submit:disabled { opacity: .6; cursor: progress; }
.alert-to { margin-top: -2px; font-size: 14px; font-weight: 600; word-break: break-all; }

.auth-center { display: flex; flex-direction: column; align-items: center; padding: 134px 0 80px; }
.login-card { width: 100%; max-width: 480px; gap: 28px; }
.login-card h1 { font-size: 30px; line-height: 45px; font-weight: 700; }
.login-actions { gap: 20px; }
.auth-browse { margin-top: 24px; }

@media (max-width: 1200px) {
  .auth-split { grid-template-columns: minmax(0, 1fr) minmax(0, 480px); }
}
@media (max-width: 960px) {
  .auth-split { grid-template-columns: 1fr; padding-top: 40px; }
  .auth-split .auth-card { order: -1; max-width: 560px; width: 100%; justify-self: center; }
  .auth-split .auth-sent { grid-column: 1; grid-row: auto; }
  .auth-intro { max-width: 600px; justify-self: center; width: 100%; }
}
@media (max-width: 640px) {
  .auth-center { padding-top: 32px; }
  .auth-card { padding: 24px 20px; }
  .auth-intro h1 { font-size: 32px; line-height: 1.2; }
  .auth-previews { gap: 8px; }
  .auth-preview { height: auto; }
  .auth-preview .art { height: auto; aspect-ratio: 192 / 204; }
  .auth-preview .art img { height: calc(100% - 8px); }
  .auth-preview .name { font-size: 12px; margin: 8px 8px 0; }
  .auth-preview .meta { font-size: 10px; margin: 2px 8px 10px; }
}

/* ---------- Privacy ---------- */
.legal { max-width: 760px; padding: 40px 0 72px; }
.legal h1 { margin-top: 12px; font-size: 36px; font-weight: 700; }
.legal-date { display: flex; align-items: center; gap: 14px; margin-top: 18px; color: var(--muted); font-size: 12px; }
.legal-date .proto-badge { margin: 0; height: 24px; padding: 0 12px; }
.legal-toc { display: flex; flex-wrap: wrap; gap: 8px; margin: 28px 0 8px; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.legal-toc a { padding: 7px 12px; border-radius: 8px; background: var(--panel); border: 1px solid var(--line); color: var(--muted); font-size: 12px; text-decoration: none; }
.legal-toc a:hover { color: var(--text); border-color: #3a404d; }
.legal section { padding-top: 32px; scroll-margin-top: 100px; }
.legal h2 { font-size: 22px; font-weight: 700; margin-bottom: 12px; }
.legal h3 { font-size: 14px; font-weight: 600; margin: 18px 0 6px; }
.legal p, .legal li { color: var(--muted-2); font-size: 14px; line-height: 1.65; }
.legal p + p { margin-top: 10px; }
.legal strong { color: var(--text); font-weight: 600; }
.legal ul { margin: 0; padding-left: 20px; display: grid; gap: 6px; }
.legal a { color: var(--accent); }
.legal .eyebrow { color: var(--accent); font-size: 11px; }
.legal .legal-date { color: var(--muted); font-size: 12px; }
.legal .legal-toc a { color: var(--muted); }
.legal .legal-toc a:hover { color: var(--text); }
.legal .lead { margin-top: 8px; color: var(--muted); }
.legal-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.legal-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 13px; }
.legal-table th, .legal-table td { padding: 12px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); line-height: 1.5; }
.legal-table th { background: var(--panel); color: var(--text); font-size: 12px; font-weight: 600; }
.legal-table td { color: var(--muted-2); }
.legal-table tr:last-child td { border-bottom: 0; }
@media (max-width: 640px) { .legal { padding-top: 28px; } .legal h1 { font-size: 30px; } }

/* ---------- Page not found ---------- */
.notfound { max-width: 640px; margin: 0 auto; padding: 96px 0 120px; text-align: center; }
.nf-code {
  font-size: 160px; line-height: 1; font-weight: 800; letter-spacing: -6px; color: var(--accent);
}
.notfound .eyebrow { margin-top: 20px; }
.notfound h1 { margin-top: 12px; font-size: 36px; font-weight: 700; line-height: 1.2; }
.notfound .lead { margin: 12px auto 0; max-width: 520px; line-height: 1.55; }
.nf-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin: 32px 0 28px; }
.nf-actions a { text-decoration: none; }
.notfound .muted a { color: var(--accent); }
@media (max-width: 640px) {
  .notfound { padding: 56px 0 80px; }
  .nf-code { font-size: 110px; letter-spacing: -4px; }
  .notfound h1 { font-size: 28px; }
  .nf-actions a { flex: 1 1 100%; }
}

/* ---------- Cookie consent banner ---------- */
.consent { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; padding: 0 var(--gutter) 20px; pointer-events: none; }
.consent-in {
  pointer-events: auto; max-width: var(--max); margin: 0 auto; padding: 20px 24px;
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 32px; align-items: center;
  background: var(--panel); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 16px 48px rgba(0, 0, 0, .5);
}
.consent-text h2 { font-size: 16px; font-weight: 700; }
.consent-text p { margin-top: 4px; color: var(--muted); font-size: 13px; line-height: 1.5; max-width: 720px; }
.consent-text a { color: var(--accent); }
.consent-actions { display: flex; align-items: center; gap: 12px; }
.consent-actions .btn-primary { min-width: 120px; }
.consent-opts { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.consent-opt { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding: 14px 16px; border-radius: 10px; background: var(--bg); border: 1px solid var(--line); cursor: pointer; }
.consent-opt strong { display: block; font-size: 13px; font-weight: 600; }
.consent-opt small { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.consent-opt .switch { flex: none; }
.switch:disabled { opacity: .55; cursor: not-allowed; }
.consent.managing .consent-in { grid-template-columns: 1fr; }
.consent.managing .consent-actions { justify-content: flex-end; }
@media (max-width: 900px) {
  .consent-in { grid-template-columns: 1fr; }
  .consent-opts { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .consent { padding-bottom: 12px; }
  .consent-in { padding: 16px; max-height: calc(100vh - 24px); overflow-y: auto; }
  .consent-actions { flex-wrap: wrap; }
  .consent-actions .btn-primary { flex: 1; min-width: 0; }
  .consent-actions .text-btn { width: 100%; justify-content: center; order: 3; height: 32px; }
}

.account-tools { display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
@media (max-width: 640px) { .account-tools { flex-direction: row; align-items: center; } }

/* ---------- Footer & toast ---------- */
.footer { margin-top: auto; }
.footer-in { max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
.footer-in { display: flex; justify-content: space-between; gap: 24px; position: relative; }
.footer-in::before { content: ""; position: absolute; top: 0; left: var(--gutter); right: var(--gutter); height: 1px; background: var(--line); }
.footer-in > div { flex: 1; padding: 21px 0 26px; }
.footer-in > nav { padding: 27px 5px 0 0; }
.footer-brand { color: var(--muted); font-size: 15px; font-weight: 700; margin-bottom: 14px; }
.footer p { color: var(--muted); font-size: 10px; line-height: 1.8; }
.footer a { color: var(--muted); }
.footer-links { display: flex; gap: 40px; align-items: flex-start; }
.footer-links a { font-size: 11px; text-decoration: none; white-space: nowrap; }
.footer-links a:hover { color: var(--text); }
@media (max-width: 640px) {
  .footer-in { flex-direction: column-reverse; gap: 0; }
  .footer-in > div { padding-top: 14px; }
  .footer-links { flex-wrap: wrap; gap: 12px 24px; padding: 20px 0 0; }
}

.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; z-index: 50;
  padding: 11px 16px; border-radius: 10px; background: var(--accent); color: var(--accent-ink); font-size: 13px; font-weight: 600;
  transition: opacity .2s, transform .2s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
