.bot-home {
  --bg: #111215;
  --bg2: #191a1f;
  --bg3: #22242a;
  --line: #2e3038;
  --mu: #b0b2be;
  --ac: #a7adff;
  background: var(--bg);
}
.bot-home .wrap { max-width: 1160px; }
.bot-home header.nav { background: #15161b; }
.bot-home .nav .wrap { justify-content: space-between; overflow: visible; }
.bot-home nav { display: flex; gap: 24px; }
.bot-home nav a, .bot-home footer a { color: var(--mu); text-decoration: none; }
.bot-home nav a:hover, .bot-home footer a:hover { color: var(--tx); }
.bot-home .btn { background: #7078f6; color: #0d1030; }
.bot-home .btn.g { background: #252730; color: var(--tx); }
.bot-intro { display: grid; grid-template-columns: 1fr .86fr; align-items: center; gap: clamp(24px, 6vw, 80px); padding: 88px 0 76px; }
.bot-kicker { color: var(--ac); font-size: .88rem; font-weight: 650; margin: 0 0 10px; }
.bot-intro h1 { font-size: clamp(3rem, 8vw, 5rem); letter-spacing: -.065em; margin: 0; }
.bot-lead { max-width: 480px; color: var(--mu); font-size: 1.06rem; }
.bot-chat { background: #1c1e25; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.chat-channel { padding: 11px 16px; background: #252730; font-weight: 650; }
.chat-channel span { color: var(--mu); margin-right: 6px; }
.chat-body { padding: 20px; }
.chat-command { margin: 0 0 14px 48px; font-size: .8rem; }
.bot-home code { color: #c7caff; background: #292b40; padding: 3px 7px; border-radius: 4px; overflow-wrap: anywhere; }
.chat-message { display: flex; gap: 12px; align-items: flex-start; }
.chat-message > div { flex: 1; min-width: 0; }
.app-tag { color: #f8f8ff; background: #535cc5; font-size: .64rem; padding: 2px 4px; border-radius: 3px; }
.chat-embed { margin-top: 8px; border-left: 3px solid #8189ff; border-radius: 4px; padding: 12px; background: #14151a; }
.chat-embed dl { display: grid; grid-template-columns: auto 1fr; gap: 3px 18px; font-size: .85rem; margin: 8px 0 0; }
.chat-embed dt { color: var(--mu); }
.chat-embed dd { margin: 0; }
.bot-section { border-top: 1px solid var(--line); padding: 32px 0 48px; }
.bot-section h2 { font-size: 1.45rem; margin-bottom: 18px; }
.bot-features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.bot-features article { background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 20px; }
.bot-features h3 { font-size: 1rem; }
.bot-features p { margin: 0; color: var(--mu); font-size: .92rem; }
.bot-commands { margin: 0; }
.bot-commands > div { display: grid; grid-template-columns: minmax(160px, 1fr) 2fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.bot-commands dd { margin: 0; color: var(--mu); }
@media(max-width:760px) {
  .bot-home nav { display: none; }
  .bot-intro { grid-template-columns: 1fr; padding: 42px 0; }
  .bot-features { grid-template-columns: 1fr; gap: 10px; }
}
@media(max-width:460px) {
  .bot-commands > div { grid-template-columns: 1fr; gap: 6px; }
}

.bot-home {
  --bg: #17130f;
  --bg2: #241c14;
  --bg3: #302519;
  --line: #5c462e;
  --mu: #cbb795;
  --ac: #ffcb58;
  background: var(--bg);
}
.bot-home header.nav { background: #211910; }
.bot-home .btn { background: #e4a73c; color: #271706; }
.bot-home .btn.g { background: #382b1d; color: var(--tx); }
.bot-intro { padding: clamp(42px, 8vw, 96px) 0 58px; }
.bot-intro h1 { letter-spacing: 0; }
.bot-kicker { font-size: 1rem; }
.bot-lead { font-size: 1.18rem; }
.bot-chat {
  border: 2px solid #795932;
  border-radius: 0;
  background: #282017;
  box-shadow: 5px 5px #100c08;
}
.chat-channel { background: #392b1c; border-bottom: 2px solid #795932; }
.chat-embed { background: #1c160f; border-color: #e4a73c; border-radius: 0; }
.app-tag { background: #705027; border-radius: 0; }
.bot-home code { color: #ffda84; background: #392b1c; border-radius: 0; }
.bot-features article { border-radius: 0; border-top: 3px solid #aa7938; background: var(--bg2); }
.bot-features p { font-size: 1rem; }
.bot-section { scroll-margin-top: 72px; }
.chat-channel { display: flex; align-items: center; gap: 10px; padding: 8px 12px; }
.chat-brand { flex: 0 0 64px; display: block; image-rendering: pixelated; }
.chat-channel-name { display: block; font-size: .85rem; font-weight: 400; }
.chat-command { margin-left: 0; }
.support-page { max-width: 840px; }
.support-page .bot-lead { margin-bottom: 28px; }
.support-page details[open] { border-color: var(--ac2); }
.support-page details p { max-width: 68ch; }
.bot-home .support-page { max-width: 1160px; }
.support-heading {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 20px 0; margin-bottom: 24px; border-bottom: 2px solid var(--line);
}
.support-heading h1 {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: .025em;
  margin: 0;
}
.support-heading p { margin: 10px 0 0; color: #e1cfb2; font-size: 18px; line-height: 1.55; }
.support-heading img { image-rendering: pixelated; flex-shrink: 0; }
.support-layout { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); gap: 22px; }
.support-main,.support-sidebar { display: grid; align-content: start; gap: 20px; min-width: 0; }
.support-page .support-box {
  padding: clamp(15px, 3vw, 24px); background: var(--bg2);
  border: 1px solid var(--line); border-top: 3px solid #aa7938;
}
.support-box h2 { font-size: 24px; font-weight: 500; line-height: 1.25; color: var(--ac); }
.support-box label,
.support-box input,
.support-box select,
.support-box textarea,
.support-box details summary { font-size: 18px; line-height: 1.5; }
.support-box label { color: #e1cfb2; }
.support-box details summary { font-weight: 500; }
.support-box details { background: #19140f; overflow-wrap: anywhere; }
.support-box details:last-child { margin-bottom: 0; }
.support-box details summary { color: var(--tx); }
.support-box details summary:focus-visible { outline: 2px solid var(--ac); outline-offset: 4px; }
.support-context { margin-top: 14px; }
.support-page .ticket-fields { grid-template-columns: repeat(auto-fit, minmax(min(100%, 130px), 1fr)); }
.support-page #ticket-feedback { color: #e1cfb2; overflow-wrap: anywhere; margin: 8px 0 12px; font-size: 18px; }
.support-page #ticket-hint { margin: 6px 0 14px; color: #e1cfb2; font-size: 17px; line-height: 1.55; }
.support-page textarea { resize: vertical; }
.support-form-section { background: #1d1711; border: 1px solid var(--line); padding: 16px; }
.support-form-section > label:first-child, .support-attachment > label { margin-top: 0; color: var(--ac); }
.support-box input::placeholder,.support-box textarea::placeholder { color: var(--mu); opacity: .9; }
.support-field-note { text-align: right; color: #e1cfb2; font-size: 16px; }
.support-attachment { border: 1px dashed #927043; background: #2d2114; padding: 14px 16px; margin-top: 14px; }
.support-attachment p { margin: 4px 0 10px; overflow-wrap: anywhere; }
.support-attachment .support-file-limit { color: #e1cfb2; font-size: 17px; line-height: 1.5; }
.support-attachment input[type=file] { padding: 6px; font-size: 17px; }
.support-attachment input::file-selector-button {
  border: 1px solid #997039; padding: 6px 9px; background: #49331c; color: var(--tx);
  font: inherit; margin-right: 8px; cursor: pointer;
}
.support-submit { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.support-page [hidden], #ticket-nav[hidden], #ticket-total-unread[hidden] { display: none; }
.support-nav { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 6px; }
.support-nav .support-profile {
  display: flex; align-items: center; gap: 9px; padding: 4px 10px 4px 5px;
  background: #312318; border: 1px solid #805b35; color: #ffe2b2;
}
.support-profile-menu { position: relative; margin: 0; padding: 0; border: 0; }
.support-profile-menu[hidden] { display: none; }
.support-profile-menu summary { cursor: pointer; list-style: none; }
.support-profile-menu summary::-webkit-details-marker { display: none; }
.support-profile-links { position: absolute; right: 0; top: calc(100% + 8px); min-width: 170px; padding: 5px; background: #241a12; border: 1px solid #805b35; box-shadow: 0 8px 18px #0008; z-index: 10; }
.bot-home .support-profile-links a { display: block; padding: 9px 12px; color: #ffe2b2; }
.bot-home .support-profile-links a:hover, .bot-home .support-profile-links a:focus-visible { background: #46301b; }
.support-profile:hover, .support-profile:focus-visible { border-color: #efb352; }
.support-profile canvas { width: 32px; height: 32px; image-rendering: pixelated; flex: none; }
.support-profile small, .support-profile strong { display: block; }
.support-profile small { color: #d9a864; font-size: .75rem; }
.support-profile strong { max-width: 20ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.support-heading { flex-wrap: wrap; gap: 16px; }
.support-new-ticket { flex-shrink: 0; }
.support-layout.support-browse { grid-template-columns: minmax(0, 1fr); }
.support-layout.support-create {
  grid-template-columns: minmax(0, 1fr);
  max-width: 760px;
  margin-inline: auto;
}
.support-browse .support-main { display: none; }
.support-browse .support-sidebar { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
#ticket-history { margin-bottom: 24px; }
.ticket-list-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.ticket-list-heading h2, .ticket-list-heading p { margin: 0; }
.ticket-list-heading p, .ticket-list-card small, .ticket-bubble time, .ticket-facts dt { color: #e1cfb2; }
#my-tickets { display: grid; gap: 10px; }
.ticket-list-card { position: relative; display: grid; gap: 5px; padding: 14px 36px 14px 16px; background: #19140f; border: 1px solid var(--line); border-left: 4px solid #927043; color: var(--tx); text-decoration: none; overflow-wrap: anywhere; }
.ticket-list-card::after { content: '›'; position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--ac); }
.ticket-list-card:hover, .ticket-list-card:focus-visible { border-color: var(--ac); }
.ticket-list-card.unread { border-left-color: var(--ac); background: #302316; }
.ticket-card-top { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.ticket-state { display: inline-block; padding: 2px 8px; border: 1px solid #927043; color: #ffd88d; font: 600 .8rem system-ui,sans-serif; }
.ticket-view { max-width: 850px; margin: 0 auto; }
.ticket-view article { margin-top: 18px; overflow-wrap: anywhere; }
.ticket-view-heading, .ticket-facts > div, .ticket-view form { background: #251d14; border: 1px solid var(--line); padding: 16px; }
.ticket-view-heading { border-top: 3px solid var(--ac); }
.ticket-view-heading h1 { margin: 8px 0 0; }
.ticket-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 155px), 1fr)); gap: 10px; margin: 16px 0 24px; }
.ticket-facts dd { margin: 4px 0 0; }
.ticket-bubble { margin: 0 0 14px clamp(0px, 5vw, 46px); padding: 15px; background: #221a12; border: 1px solid var(--line); }
.ticket-bubble.staff { margin-left: 0; margin-right: clamp(0px, 5vw, 46px); border-color: #927043; background: #302316; }
.ticket-bubble header { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ticket-bubble time { margin-left: auto; font: .8rem system-ui,sans-serif; }
.ticket-bubble p { margin: 8px 0 0; font: 1rem/1.6 system-ui,sans-serif; }
.ticket-bubble a { display: inline-block; margin-top: 8px; }
.ticket-view form label { display: block; margin-bottom: 10px; }
@media(max-width:760px) { .support-layout { grid-template-columns: 1fr; } }
@media(max-width:400px) { .support-heading img { width: 52px; height: 52px; } }
.bot-home.account-screen {
  background: #15110e;
  min-height: 100vh;
}
.bot-home .account-page {
  position: relative;
  isolation: isolate;
  max-width: none;
  min-height: calc(100vh - 68px);
  display: grid;
  place-items: center;
  padding: clamp(28px, 6vw, 70px) 20px;
}
.home-header-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-inline-start: auto; }
.account-card {
  width: min(100%, 460px);
  padding: clamp(22px, 5vw, 36px);
  overflow: hidden;
  border: 1px solid #7b5531;
  border-top: 3px solid #efb352;
  background: #211913;
  box-shadow: 0 6px #110e0a, 0 22px 60px #0008;
}
.account-brand {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  margin-bottom: 22px;
}
.account-landscape {
  position: absolute; inset: 0; z-index: -1; overflow: hidden;
  background: linear-gradient(#231828, #512c33 55%, #9b5836);
}
.account-landscape::before {
  content: ''; position: absolute; width: clamp(50px, 9vw, 112px); aspect-ratio: 1; right: 14%; top: 19%;
  background: #f2aa66; box-shadow: 0 0 70px #ffbd7170;
}
.account-landscape span {
  position: absolute; inset: 42% 0 0; background: #4a2e2a;
  clip-path: polygon(0 45%, 12% 45%, 12% 30%, 22% 30%, 22% 15%, 34% 15%, 34% 40%, 46% 40%, 46% 63%, 65% 63%, 65% 50%, 78% 50%, 78% 32%, 90% 32%, 90% 20%, 100% 20%, 100% 100%, 0 100%);
}
.account-landscape span + span {
  inset: 56% 0 0; background: linear-gradient(#302320, #191310); transform: scaleX(-1);
}
.account-wordmark { display: block; width: min(184px, 65%); height: auto; filter: drop-shadow(0 4px 0 #321c12); }
.account-content { text-align: center; }
.account-content h1 { margin: 0; font-size: clamp(1.65rem, 5vw, 2.15rem); line-height: 1.15; }
.account-content p { color: #e1cfb2; font: 1rem/1.55 system-ui, sans-serif; }
.bot-home .account-modes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px; margin: 22px 0 16px; padding: 4px; border: 1px solid #644a30; background: #16110d; }
.account-modes a { padding: 9px 4px; }
.account-modes a[aria-current="page"] { background: #46301b; color: #ffd58d; }
.account-form { text-align: left; }
.account-form label { display: block; margin: 12px 0 6px; color: #f1ddbe; }
.account-form input { width: 100%; font: 1rem/1.4 system-ui,sans-serif; }
.account-form button { width: 100%; margin-top: 20px; }
.account-content [hidden] { display: none; }
#account-feedback { color: #ffab94; }
#account-logout { margin-top: 18px; }
.account-license-list { padding: 0; list-style: none; }
.account-license-list li { margin-top: 8px; padding: 12px; border: 1px solid #644a30; background: #19140f; }
.account-back { display: inline-block; margin-top: 18px; color: #e1cfb2; }
.account-session { display: flex; justify-content: center; align-items: center; gap: 12px; margin-top: 16px; font: .95rem/1.45 system-ui,sans-serif; overflow-wrap: anywhere; text-align: left; }
.account-session[hidden] { display: none; }
.account-session span, .account-session strong { display: block; }
.account-session span { color: #e1cfb2; }
.account-online { flex: 0 0 8px; height: 8px; background: #85cc70; box-shadow: 0 0 0 4px #85cc7025; }
.account-ticket-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 18px 0 0; }
.account-ticket-stats[hidden] { display: none; }
.account-ticket-stats > div { padding: 12px; background: #19140f; border: 1px solid #644a30; }
.account-ticket-stats dt { color: #e1cfb2; font: .85rem system-ui, sans-serif; }
.account-ticket-stats dd { margin: 4px 0 0; color: #ffc56d; font-size: 1.3rem; }
.guide-steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; counter-reset: guide-step; }
.guide-steps li { counter-increment: guide-step; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 24px; padding: clamp(16px, 3vw, 30px); background: #221a12; border: 1px solid #62482c; }
.guide-steps h3 { margin-top: 0; color: #ffc56d; }
.guide-steps h3::before { content: counter(guide-step) '. '; }
.guide-steps p { color: #e9dbc8; font: 1rem/1.65 system-ui, sans-serif; }
.guide-steps figure { margin: 0; min-width: 0; }
.guide-steps figure a { display: block; border: 1px solid #805b35; }
.guide-steps figure a:hover { border-color: #efb352; }
.guide-steps img { display: block; width: 100%; height: auto; }
.guide-steps figcaption { margin-top: 8px; color: #e1cfb2; font: .85rem/1.4 system-ui, sans-serif; }
@media (max-width: 700px) { .guide-steps li { grid-template-columns: minmax(0, 1fr); } }

@media (prefers-reduced-motion: no-preference) {
  .bot-intro h1 .brand-wordmark { animation: rancai-logo 1.6s ease-out both; }
  .bot-intro .bot-chat { animation: rancai-chat 490ms ease-out both; }
  .bot-intro .chat-command { animation: rancai-chat 320ms ease-out .28s both; }
  .bot-intro .chat-message { animation: rancai-chat 420ms ease-out .63s both; }
  .bot-intro .btn { transition: transform 170ms ease, filter 170ms ease; }
  .bot-intro .btn:active { transform: translateY(2px); }
  .guide-steps figure img { transition: transform 220ms ease; }
  .guide-steps figure a { overflow: hidden; }
  .bot-features article, .guide-steps li {
    transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
  }
  .guide-steps li:focus-within {
    border-color: #ad783e;
    box-shadow: 0 4px #100c09;
  }
  @media (hover: hover) {
    .bot-intro .btn:hover { filter: brightness(1.12); }
    .guide-steps figure a:hover img { transform: scale(1.025); }
    .bot-features article:hover, .guide-steps li:hover {
      transform: translateY(-5px);
      border-color: #ad783e;
      box-shadow: 0 4px #100c09;
    }
  }
}

@keyframes rancai-logo {
  0% { transform: translateY(7px); filter: drop-shadow(0 0 0 #efa94700); }
  35% { transform: translateY(-3px); filter: drop-shadow(0 0 16px #efa94790); }
  100% { transform: translateY(0); filter: drop-shadow(0 0 0 #efa94700); }
}

@keyframes rancai-chat {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero-pixels { display: none; }
.bot-home.rancai-animated {
  background:
    radial-gradient(ellipse 48rem 28rem at 74% 11rem, #8f54282e, transparent 75%),
    radial-gradient(ellipse 38rem 25rem at 18% 20rem, #6c443027, transparent 76%),
    linear-gradient(180deg, #211810 0, #17130f 44rem, #14110e 100%);
}
.rancai-animated main.wrap { position: relative; isolation: isolate; }
.rancai-animated main.wrap::before {
  content: '';
  position: absolute;
  z-index: -1;
  inset: 0 auto auto 50%;
  width: 100vw;
  height: clamp(420px, 52vw, 690px);
  transform: translateX(-50%);
  pointer-events: none;
  background:
    linear-gradient(180deg, #17130f18 0%, #17130f08 54%, #17130f 100%),
    linear-gradient(90deg, #140e0b91, #140e0b34 58%, #140e0b08),
    url('/pazar-manzarasi.png') center 58% / cover no-repeat;
}
.rancai-animated { overflow-x: clip; }
.rancai-animated .bot-lead, .rancai-animated .bot-kicker { text-shadow: 0 2px 5px #090604, 0 0 14px #090604; }
.rancai-animated .bot-lead { color: #fff0d7; }
.rancai-animated .bot-chat { box-shadow: 0 6px #0d0906a0, 0 14px 42px #0d090680; }
@media (max-width: 700px) {
  .rancai-animated main.wrap::before { height: 640px; background-position: center, center, 64% center; }
}
.rancai-animated main.wrap { max-width: 1090px; }
.rancai-animated #ozellikler,
.rancai-animated .mod-guide { position: relative; isolation: isolate; }
.rancai-animated .mod-guide::before {
  content: '';
  position: absolute;
  z-index: -1;
  inset: -115px auto 0 50%;
  width: 100vw;
  transform: translateX(-50%);
  pointer-events: none;
  background:
    linear-gradient(180deg, #17130f 0%, #17130f16 15%, #17130f16 84%, #17130f 100%),
    linear-gradient(90deg, #140e0b22, #140e0b52 50%, #140e0b22),
    url('/pazar-manzarasi.png') center 60% / cover no-repeat;
}
.rancai-animated .guide-steps li {
  background: linear-gradient(115deg, #2c2015, #1d1711 72%);
  box-shadow: 0 8px 22px #0c09075c;
}
@media (max-width: 700px) {
  .rancai-animated .mod-guide::before {
    inset-block-start: -40px;
    background-size: auto, auto, auto min(100%, 850px);
    background-repeat: no-repeat, no-repeat, repeat-y;
  }
}
.rancai-animated .bot-intro { padding-block: clamp(36px, 7vw, 82px) 48px; }
.rancai-animated .bot-intro h1 .brand-wordmark { max-width: min(100%, 385px); }

@media (prefers-reduced-motion: no-preference) {
  .rancai-animated .bot-intro { position: relative; isolation: isolate; }
  .hero-pixels { display: block; position: absolute; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
  .hero-pixels i {
    position: absolute; left: var(--x); top: var(--y);
    width: var(--size, 5px); aspect-ratio: 1; background: #ffc16a;
    box-shadow: 0 0 12px #ffac57;
    animation: rancai-drift var(--speed, 5s) steps(18) infinite var(--delay, 0s);
  }
  .hero-pixels i:nth-child(1) { --x: 7%; --y: 15%; --delay: -2s; }
  .hero-pixels i:nth-child(2) { --x: 36%; --y: 26%; --size: 7px; --speed: 6s; --delay: -3s; }
  .hero-pixels i:nth-child(3) { --x: 49%; --y: 78%; --delay: -1s; }
  .hero-pixels i:nth-child(4) { --x: 62%; --y: 16%; --size: 4px; --speed: 4s; --delay: -2.5s; }
  .hero-pixels i:nth-child(5) { --x: 91%; --y: 88%; --size: 7px; --delay: -4s; }
  .hero-pixels i:nth-child(6) { --x: 19%; --y: 94%; --speed: 7s; --delay: -5s; }
  .rancai-animated .bot-intro h1 .brand-wordmark { animation: rancai-logo 4s ease-in-out infinite; }
  .rancai-animated .bot-chat { position: relative; overflow: hidden; }
  .rancai-animated .bot-chat::after {
    content: ''; position: absolute; top: 0; left: 0; width: 30%; height: 2px;
    background: linear-gradient(90deg, transparent, #ffc56d, transparent);
    pointer-events: none; animation: rancai-sweep 4s linear infinite;
  }
  .rancai-animated .chat-embed .ok::before {
    content: ''; display: inline-block; width: 6px; height: 6px; margin-right: 7px;
    background: currentColor; vertical-align: middle; animation: rancai-status 2s ease-in-out infinite;
  }
}

@keyframes rancai-drift {
  0%, 100% { opacity: 0; transform: translate(0, 12px); }
  35% { opacity: .8; }
  80% { opacity: .5; transform: translate(14px, -28px); }
}
@keyframes rancai-sweep {
  from { transform: translateX(-100%); }
  to { transform: translateX(340%); }
}
@keyframes rancai-status {
  50% { opacity: .45; box-shadow: 0 0 8px currentColor; }
}

.guide-embers { display: none; }
.guide-compatibility, .guide-keys dl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.guide-compatibility { margin-bottom: 16px; }
.guide-compatibility > div, .guide-keys dl > div, .help-contact, #help-answers details {
  background: #211910; border: 1px solid #65492c; padding: 14px;
}
.guide-compatibility small { display: block; color: #d7b588; margin-bottom: 4px; }
.guide-compatibility strong { color: #ffd38e; }
.guide-checklist { padding: 14px; margin-bottom: 16px; background: #211910; border: 1px solid #65492c; }
.guide-checklist summary { cursor: pointer; color: #ffd38e; }
.guide-checklist output { margin-inline-start: 8px; color: #e9dbc8; }
.guide-checklist fieldset { border: 0; margin: 12px 0 0; padding: 0; }
.guide-checklist label { display: flex; align-items: baseline; gap: 8px; margin: 8px 0; }
.guide-checklist input { width: auto; accent-color: #e4a73c; }
.guide-keys, .guide-install { margin-top: 24px; }
.guide-install details { background: #211910; border-color: #65492c; }
.guide-install summary { color: #ffd38e; }
.guide-install p { color: #e9dbc8; font: 1rem/1.6 system-ui, sans-serif; }
.guide-keys dl > div { display: flex; flex-wrap: wrap; gap: 9px; align-items: baseline; }
.guide-keys dd { margin: 0; color: #e9dbc8; }
.guide-keys kbd { padding: 3px 7px; border: 1px solid #906433; background: #382619; color: #ffcc79; }
.help-layout { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.help-search { display: grid; grid-template-columns: minmax(0, 1fr) minmax(115px, .42fr); gap: 6px 10px; margin-bottom: 12px; }
.help-search[hidden] { display: none; }
.help-search label { grid-row: 1; }
.help-search input, .help-search select { width: 100%; font: 1rem system-ui, sans-serif; }
#help-answers details { margin: 0 0 8px; }
#help-answers summary { cursor: pointer; color: #ffd38e; }
#help-answers p, .help-contact p { color: #e9dbc8; font: 1rem/1.6 system-ui, sans-serif; }
.help-contact h3 { margin-top: 0; }
.help-contact a { margin: 0 5px 5px 0; }
@media (max-width: 700px) {
  .guide-compatibility, .guide-keys dl, .help-layout { grid-template-columns: minmax(0, 1fr); }
}
.bot-home .guide-jumps { gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.guide-steps li { scroll-margin-top: 96px; }
.guide-steps li:target { border-color: #efb352; }
.guide-preview {
  width: min(94vw, 1200px); max-width: none; max-height: 92vh;
  padding: 12px; margin: auto; border: 1px solid #bc853c; background: #211910; color: #ffe3b5;
}
.guide-preview::backdrop { background: #100c08e8; }
.guide-preview-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-bottom: 10px; }
.guide-preview img { display: block; width: 100%; max-height: 67vh; object-fit: contain; }
.guide-preview-navigation { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding-top: 10px; }
@media (prefers-reduced-motion: no-preference) {
  .guide-step-visible { animation: guide-step-enter 560ms ease-out; }
  .guide-preview[open] { animation: guide-step-enter 220ms ease-out; }
}
@media (min-width: 1200px) and (prefers-reduced-motion: no-preference) {
  .guide-embers {
    display: block; position: absolute; inset: 0 auto 0 50%; width: 100vw;
    transform: translateX(-50%); overflow: hidden; pointer-events: none; z-index: -1;
  }
  .guide-embers i {
    position: absolute; left: var(--ember-x); top: var(--ember-y);
    width: 5px; height: 5px; background: #ffc477;
    box-shadow: 0 0 12px #ff9c48;
    animation: rancai-drift var(--ember-speed) steps(18) var(--ember-delay) infinite;
  }
  .guide-embers i:nth-child(1) { --ember-x: 4%; --ember-y: 15%; --ember-speed: 5s; --ember-delay: -3s; }
  .guide-embers i:nth-child(2) { --ember-x: 8%; --ember-y: 49%; --ember-speed: 7s; --ember-delay: -2s; }
  .guide-embers i:nth-child(3) { --ember-x: 3%; --ember-y: 81%; --ember-speed: 6s; --ember-delay: -4s; }
  .guide-embers i:nth-child(4) { --ember-x: 93%; --ember-y: 24%; --ember-speed: 7s; --ember-delay: -5s; }
  .guide-embers i:nth-child(5) { --ember-x: 96%; --ember-y: 56%; --ember-speed: 5s; --ember-delay: -1s; }
  .guide-embers i:nth-child(6) { --ember-x: 92%; --ember-y: 88%; --ember-speed: 8s; --ember-delay: -6s; }
}
@keyframes guide-step-enter {
  from { opacity: .65; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.rancai-animated .bot-intro {
  min-height: clamp(410px, 42vw, 550px);
  padding-block: clamp(48px, 7vw, 86px) clamp(42px, 6vw, 72px);
}
.rancai-animated .bot-kicker { color: #ffe0a8; }
.rancai-animated .bot-lead { font-size: clamp(1rem, 1.8vw, 1.2rem); line-height: 1.65; }
.rancai-animated .bot-chat { border-color: #bc874f; background: #211810f5; }
.rancai-animated .chat-channel { background: linear-gradient(105deg, #54371d, #2a2017); }
.rancai-animated .bot-section > h2 {
  font-size: clamp(1.65rem, 3vw, 2.25rem);
  line-height: 1.15;
  margin: 0 0 20px;
}
.rancai-animated .bot-features article {
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 10px;
  padding: clamp(16px, 2vw, 25px);
  background: linear-gradient(155deg, #382819, #211912 78%);
}
.rancai-animated .bot-features h3 { margin: 0; color: #ffd595; font-size: 1.2rem; }
.rancai-animated .bot-features p { color: #eadbc8; font: .95rem/1.6 system-ui, sans-serif; }
.rancai-animated .bot-features a { justify-self: start; margin-top: 4px; color: #ffc879; text-underline-offset: 4px; }
.rancai-animated .guide-steps li { border-left: 3px solid #a06a33; }
.rancai-animated .guide-steps h3 { font-size: 1.28rem; line-height: 1.3; }
.rancai-animated .guide-steps figure a { box-shadow: 0 5px 14px #08060478; }
.rancai-animated .help-center { scroll-margin-top: 84px; }
.rancai-animated .help-contact { background: linear-gradient(135deg, #3c2a19, #211910); }
.bot-home .site-footer {
  padding: 42px 0 110px;
  border-top: 1px solid #78583a;
  background: linear-gradient(125deg, #2a2016, #19140f 65%);
}
.site-footer .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: clamp(24px, 5vw, 72px);
}
.site-footer .footer-brand p {
  max-width: 32ch;
  margin: 14px 0 0;
  color: #eadbc8;
  font: 1rem/1.65 system-ui, sans-serif;
}
.site-footer nav.footer-column { display: block; }
.site-footer h2 { margin: 0 0 12px; color: #ffdb99; font-size: 1.2rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li a { display: inline-block; padding-block: 5px; font: 1rem/1.45 system-ui, sans-serif; }
.site-footer li a:hover { text-decoration: underline; text-underline-offset: 4px; }
@media (max-width: 620px) {
  .site-footer .wrap { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .rancai-animated .bot-intro { min-height: 0; }
  .rancai-animated .bot-lead { max-width: 40ch; }
}

@media (any-pointer: fine) {
  .bot-home { cursor: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAZklEQVR4nGNQFOH6D8IMtAJ0s4BmFtHNgv/PpoMx1S2iuwUfV5iDMdUsGjALqGbRgFuwOFIajMm2aNBYQLZFA24BelGCCw8+C2DiFCdXulmAbgC6BRRHMs0tICQ/eC0g1gGDts4GAK5trBQnqfUPAAAAAElFTkSuQmCC") 0 0, auto; }
  .bot-home :is(a[href], button:not(:disabled), summary, select, input[type="checkbox"], input[type="file"]) {
    cursor: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAb0lEQVR4nGNgwAEURbj+I2Nc6sgGNLMAZuD/Z9PBeOha8HGFORiPWjB4LKBash0wC9CTLdkWUt0CXBpgFqBbRIhPfwvQLYIFBboFhPDgsYBUgwePBeRaRHE+oLoF6BYtjpTGiqlWZNDcAkJ4wC0AALXzGeN7dDH2AAAAAElFTkSuQmCC") 6 1, pointer;
  }
  .bot-home :is(input:not([type]), input[type="text"], input[type="password"], input[type="search"], textarea) { cursor: text; }
}

/* License storefront */
.license-shop { scroll-margin-top: 90px; }
.shop-heading { display:flex; justify-content:space-between; align-items:end; gap:24px; margin-bottom:28px; }
.shop-heading > p,.shop-note { color:#d9cbb9; font:15px/1.7 system-ui,sans-serif; }
.shop-eyebrow { color:#ffc86a; margin:0 0 12px; }
.license-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:16px; }
.license-plan { position:relative; padding:26px 22px; background:linear-gradient(150deg,#342619f5,#19140ff5); border:1px solid #775630; border-top:3px solid #ac7a39; box-shadow:0 14px 32px #0004; display:flex; flex-direction:column; align-items:flex-start; }
.license-plan h3 { margin:18px 0 12px; font-size:22px; }
.license-plan .license-price { font-size:38px; line-height:1.2; color:#ffcf70; margin:0 0 12px; }
.license-plan > p:not(.license-price),.license-plan ul { font:15px/1.8 system-ui,sans-serif; color:#eee1cf; }
.license-plan ul { padding-left:18px; margin:18px 0 28px; }
.license-plan .btn { margin-top:auto; width:100%; box-sizing:border-box; text-align:center; }
.lifetime-plan { border-color:#f3bd54; background:linear-gradient(150deg,#59401ef5,#241b10f5); }
.shop-note { margin-top:20px; }
.bot-home a:focus-visible,.bot-home button:focus-visible { outline:3px solid #ffe4a5; outline-offset:4px; }
@media (hover:hover) and (prefers-reduced-motion:no-preference) {
 .license-plan { transition:transform .2s,border-color .2s; }
 .license-plan:hover { transform:translateY(-5px); border-color:#ffce79; }
}
@media(max-width:1000px) { .license-grid { grid-template-columns:repeat(2,minmax(0,1fr)); } .nav .wrap { flex-wrap:wrap; } }
@media(max-width:560px) { .license-grid { grid-template-columns:1fr; } .shop-heading { flex-direction:column; align-items:start; } .license-plan { padding:24px; } }
@media(prefers-reduced-motion:reduce) { .bot-home *, .bot-home *::before, .bot-home *::after { animation:none!important; scroll-behavior:auto!important; transition:none!important; } }

/* In-game product showcase */
.mobile-menu { display:none; }
.bot-home .bot-intro { grid-template-columns:1fr 1fr; gap:42px; padding-top:92px; padding-bottom:92px; }
.mod-showcase { min-width:0; background:#19150fee; border:1px solid #ba8a48; box-shadow:0 22px 70px #0009,0 0 0 6px #17100c60; transform:rotate(1deg); }
.showcase-top { display:flex; align-items:center; justify-content:space-between; gap:12px; background:#38291b; border-bottom:1px solid #725530; padding:15px 18px; color:#ffe0a0; }
.showcase-version { font:12px/1.5 system-ui,sans-serif; color:#d1bf9f; }
.showcase-image { display:block; padding:12px; background:#0e100e; }
.showcase-image img { display:block; width:100%; height:auto; aspect-ratio:16/10; object-fit:contain; }
.showcase-options { display:flex; border-top:1px solid #725530; }
.showcase-choice { flex:1; padding:15px 8px; background:transparent; color:#d6c4a5; border:0; border-bottom:2px solid transparent; font:inherit; }
.showcase-choice[aria-pressed="true"] { color:#ffda85; background:#352719; border-bottom-color:#e6b04f; }
.showcase-choice:hover { background:#30251a; }
#showcase-caption { font:14px/1.6 system-ui,sans-serif; color:#dacbb5; margin:0; padding:14px 18px 18px; min-height:3.2em; }
.bot-home .license-shop { padding-top:60px; padding-bottom:60px; }
.bot-home .license-plan { overflow:hidden; }
.bot-home .license-plan > img { width:52px; height:52px; object-fit:contain; filter:drop-shadow(0 4px 10px #eaa33a30); }
.bot-home .license-plan h3 { color:#fff0d5; }
.bot-home .lifetime-plan::after { content:""; position:absolute; right:-40px; top:-40px; width:120px; height:120px; background:radial-gradient(circle,#ffce6c25,transparent 70%); pointer-events:none; }
.bot-home .shop-heading h2 { font-size:clamp(25px,3vw,36px); max-width:20ch; line-height:1.3; margin:0; }
.bot-home .bot-features article { border-top:3px solid #c08a3d; padding:26px; background:linear-gradient(145deg,#392b1bee,#211b14f5); }
@media(max-width:1050px) {
 .bot-home .nav .wrap { gap:12px; padding-top:12px; padding-bottom:12px; }
 .bot-home .nav nav { gap:15px; }
 .bot-home .home-header-actions { margin-left:auto; }
}
@media(max-width:760px) {
 .mobile-menu { display:inline-flex; margin-left:auto; }
 .bot-home .nav nav { display:none; order:4; flex-basis:100%; }
 .bot-home .nav nav.menu-open { display:flex; flex-wrap:wrap; padding:12px 0; }
 .bot-home .nav nav a { padding:8px 0; }
 .bot-home .home-header-actions { margin-left:0; }
 .bot-home .bot-intro { grid-template-columns:1fr; padding:40px 0 52px; gap:36px; }
 .mod-showcase { transform:none; }
}
@media(prefers-reduced-motion:no-preference) {
 .mod-showcase { animation:showcase-float 8s ease-in-out infinite; }
 @keyframes showcase-float { 0%,100%{transform:translateY(0) rotate(1deg)} 50%{transform:translateY(-7px) rotate(.4deg)} }
}
@media(max-width:420px) {
 .showcase-version { display:none; }
 .showcase-choice { font-size:13px; }
 .bot-home .nav .brand-wordmark { max-width:105px; }
}

/* RANC package emblems and readable pixel typography */
.bot-home .license-letter {
 display:block; position:relative; isolation:isolate; margin:0 0 6px;
 font-family:Pixelify,monospace; font-size:76px; line-height:1; font-weight:700;
 color:#ffd45a; letter-spacing:0;
 text-shadow:0 -2px 0 #fff2ac,2px 0 0 #b16b0c,-2px 0 0 #b16b0c,
 0 3px 0 #b8750d,0 6px 0 #743b08,3px 8px 0 #39200d;
 filter:drop-shadow(0 0 14px #ffc64d30);
}
.bot-home .lifetime-plan .license-letter {
 display:grid; align-items:center; width:.76em; height:1em;
 font-size:76px; color:transparent; text-shadow:none;
 filter:drop-shadow(0 4px 0 #8b4a09) drop-shadow(2px 3px 0 #39200d) drop-shadow(0 0 12px #ffc64d30);
}
.bot-home .lifetime-plan .license-letter::before {
 content:""; position:absolute; left:0; top:15%; width:.55em; height:.67em;
 background:linear-gradient(#fff0aa 0 9%,#ffdb59 9% 55%,#ffbd36 55% 100%);
 clip-path:polygon(17% 0,84% 0,84% 12%,100% 12%,100% 27%,69% 27%,69% 23%,
  33% 23%,33% 33%,27% 33%,27% 67%,33% 67%,33% 77%,69% 77%,69% 73%,
  100% 73%,100% 88%,84% 88%,84% 100%,17% 100%,17% 89%,0 89%,0 11%,17% 11%);
}
.bot-home .license-plan h3 {
 font-family:Pixelify,monospace; font-size:28px; font-weight:500;
 line-height:1.35; letter-spacing:.025em; margin:20px 0 12px; text-shadow:none;
}
.bot-home .license-plan .license-price {
 font-family:system-ui,sans-serif; font-size:clamp(36px,4vw,44px); font-weight:750;
 line-height:1.2; letter-spacing:0; font-variant-numeric:tabular-nums;
 color:#ffda83; text-shadow:none; white-space:nowrap;
}
.bot-home .license-plan > p:not(.license-price),.bot-home .license-plan ul {
 font-family:Pixelify,system-ui,sans-serif; font-size:20px; font-weight:400;
 line-height:1.5; color:#fff0dc; letter-spacing:.025em; text-shadow:none;
}
.bot-home .license-plan ul { padding-left:19px; }
.bot-home .license-plan li + li { margin-top:6px; }
.bot-home .license-plan .btn {
 font-family:Pixelify,system-ui,sans-serif; font-size:20px; font-weight:500;
 line-height:1.45; padding:13px 10px; letter-spacing:.035em; text-shadow:none;
}
.bot-home .license-plan { padding:28px 24px; }
.bot-home .shop-heading > p,.bot-home .shop-note {
 font:400 19px/1.5 Pixelify,system-ui,sans-serif; letter-spacing:.025em; color:#f4e8d6;
}
.bot-home .license-plan:focus-within { border-color:#ffce79; }
.bot-home .license-plan .btn:focus-visible { outline-offset:3px; }
@media(prefers-reduced-motion:no-preference) {
 .bot-home .license-plan { transition:transform 220ms ease-out,border-color 220ms,box-shadow 220ms; }
 .bot-home .license-plan:is(:hover,:focus-within) { box-shadow:0 16px 36px #0007,0 0 22px #e8ab372b; }
 .bot-home .license-letter { transition:transform 240ms ease-out; }
 .bot-home .license-plan:is(:hover,:focus-within) .license-letter { transform:translateY(-5px) rotate(-5deg); }
 .bot-home .lifetime-plan .license-letter::before {
  background:linear-gradient(140deg,#ffbd36 12%,#ffd956 40%,#fff0aa 50%,#ffd956 60%,#ffbd36 88%);
  background-size:240% 240%;
  animation:license-letter-shimmer 5s ease-in-out infinite;
 }
 @keyframes license-letter-shimmer {
  0%,70%,100% { background-position:100% 100%; }
  35% { background-position:0 0; }
 }
}
@media(max-width:1100px) and (min-width:761px) {
 .bot-home .license-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media(max-width:560px) {
 .bot-home .license-letter,.bot-home .lifetime-plan .license-letter { font-size:68px; }
}

.music-corner {
  position: fixed;
  z-index: 20;
  right: max(12px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  width: max-content;
  max-width: calc(100vw - 24px);
  border: 1px solid #74522d;
  background: radial-gradient(ellipse at 15% 22%, #48311c, transparent 65%), #211911;
  box-shadow: 0 10px 28px #0008;
}
.music-corner:has(details[open]) { width: min(360px, calc(100vw - 24px)); }
.music-corner summary {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  list-style: none;
  cursor: pointer;
}
.music-corner summary::-webkit-details-marker { display: none; }
.music-corner summary:focus-visible { outline: 2px solid #ffd581; outline-offset: 2px; }
.music-label { min-width: 0; }
.music-title { display: block; color: #ffe6a2; font: 600 23px/1.05 Pixelify, sans-serif; }
.music-label small { display: block; margin-top: 2px; color: #e4d8bf; font: 14px/1.3 system-ui,sans-serif; }
.music-chevron {
  margin-left: auto;
  width: 8px;
  height: 8px;
  border-top: 2px solid #ffc86a;
  border-left: 2px solid #ffc86a;
  transform: rotate(45deg);
}
.music-corner details[open] .music-chevron { transform: rotate(225deg); }
.music-disc {
  position: relative;
  flex: 0 0 46px;
  aspect-ratio: 1;
  clip-path: polygon(25% 0,75% 0,75% 12%,88% 12%,88% 25%,100% 25%,100% 75%,88% 75%,88% 88%,75% 88%,75% 100%,25% 100%,25% 88%,12% 88%,12% 75%,0 75%,0 25%,12% 25%,12% 12%,25% 12%);
  background: radial-gradient(circle, #2a1b0d 0 8%, #fff2b3 9% 19%, #a25212 20% 24%, #f8bf4c 25% 34%, #b77722 35% 40%, #ffd973 41% 47%, #df972a 48% 55%, #ffc24e 56% 63%, #95511b 64%);
}
.music-disc::after {
  content: "";
  position: absolute;
  width: 9px;
  height: 2px;
  top: 27%;
  left: 18%;
  background: #fff1ab;
  box-shadow: 4px 3px 0 #ffe184, -2px 3px 0 #f7d166;
}
.music-player-panel {
  display: grid;
  gap: 8px;
  padding: 0 7px 7px;
  max-height: calc(100dvh - 100px);
  overflow-y: auto;
}
.spotify-player { display: block; width: 100%; border: 0; border-radius: 12px; }
.music-playlist-controls:not([hidden]) {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 36px;
  gap: 6px;
}
.music-playlist-controls :is(button, select) {
  min-width: 0;
  min-height: 38px;
  border: 1px solid #74522d;
  background: #2d2216;
  color: #ffe6a2;
}
.music-playlist-controls select { padding: 0 8px; font: 14px system-ui,sans-serif; }
.music-playlist-controls button { font: 600 22px system-ui,sans-serif; }
.music-playlist-controls button:disabled { opacity: .45; cursor: default; }
@media (prefers-reduced-motion: no-preference) {
  .music-disc { animation: music-disc-spin 9s linear infinite; }
  .music-title { animation: music-title-glow 3.6s ease-in-out infinite; }
  @keyframes music-disc-spin { to { transform: rotate(360deg); } }
  @keyframes music-title-glow {
    0%, 100% { text-shadow: 0 1px 0 #683b13; }
    50% { text-shadow: 0 1px 0 #683b13, 0 0 9px #ffb8409c; }
  }
}
