/* Aetheria Origins 1x • Player/Admin platform */
.panel-body,
.auth-result-page {
    min-height: 100vh;
    background:
        linear-gradient(180deg, rgba(3,8,14,.9), rgba(5,11,18,.98)),
        url('../images/site/account-background.jpg') center top / cover fixed no-repeat;
}

.modal-lock { overflow: hidden; }

.panel-shell { min-height: 100vh; }

.panel-header {
    position: sticky;
    top: 0;
    z-index: 100;
    min-height: 82px;
    padding: 0 max(18px, calc((100vw - 1320px) / 2));
    display: grid;
    grid-template-columns: 230px 1fr auto;
    align-items: center;
    gap: 28px;
    border-bottom: 1px solid rgba(213,174,91,.22);
    background: rgba(4,10,17,.88);
    backdrop-filter: blur(20px);
    box-shadow: 0 14px 42px rgba(0,0,0,.24);
}

.panel-brand { display: inline-flex; align-items: center; }
.panel-brand img { width: 190px; max-height: 72px; object-fit: contain; object-position: left center; }

.panel-nav { display: flex; align-items: center; justify-content: center; gap: 6px; }
.panel-nav a {
    position: relative;
    padding: 12px 14px;
    color: #9eabb6;
    font-size: .84rem;
    font-weight: 700;
    transition: color .2s ease;
}
.panel-nav a::after {
    content: '';
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 5px;
    height: 1px;
    background: var(--gold-bright);
    transform: scaleX(0);
    transition: transform .2s ease;
}
.panel-nav a:hover,
.panel-nav a.is-active { color: var(--gold-bright); }
.panel-nav a.is-active::after { transform: scaleX(1); }

.panel-user { display: flex; align-items: center; gap: 16px; }
.panel-user > div { display: grid; text-align: right; line-height: 1.2; }
.panel-user small { color: #73828f; font-size: .67rem; text-transform: uppercase; letter-spacing: .12em; }
.panel-user strong { color: #e8e3da; font-size: .87rem; }

.panel-home-link {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 8px 12px;
    border: 1px solid rgba(240,210,141,.62);
    color: #07111d;
    background: linear-gradient(135deg, var(--gold-bright), var(--gold));
    box-shadow: 0 8px 22px rgba(213,174,91,.16);
    font-size: .75rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
    transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
}
.panel-home-link:visited { color: #07111d; }
.panel-home-link:hover,
.panel-home-link:focus-visible {
    color: #07111d;
    transform: translateY(-1px);
    background: linear-gradient(135deg, #f7dda0, #dcb55f);
    box-shadow: 0 10px 26px rgba(213,174,91,.24);
}
.panel-home-link:active { transform: translateY(0); }
.panel-home-link__arrow { font-size: 1rem; line-height: 1; }
.panel-home-link__mobile { display: none; }
.panel-logout,
.table-action,
.coin-send-shortcut {
    border: 0;
    cursor: pointer;
    color: var(--gold-bright);
    background: transparent;
}
.panel-logout { padding: 9px 12px; border: 1px solid rgba(213,174,91,.25); font-weight: 700; font-size: .78rem; }
.panel-logout:hover { border-color: var(--gold-bright); }

.panel-main {
    width: min(1320px, calc(100% - 36px));
    margin: 0 auto;
    padding: 42px 0 90px;
}

.beta-banner {
    position: relative;
    display: grid;
    grid-template-columns: 82px 1fr auto;
    align-items: center;
    gap: 26px;
    padding: 30px 32px;
    border: 1px solid rgba(213,174,91,.42);
    background:
        linear-gradient(100deg, rgba(11,28,44,.96), rgba(7,15,24,.88)),
        url('../images/site/account-banner.jpg') center 42% / cover no-repeat;
    box-shadow: 0 24px 70px rgba(0,0,0,.32);
    overflow: hidden;
}
.beta-banner::after {
    content: '';
    position: absolute;
    inset: auto -60px -130px auto;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: rgba(213,174,91,.12);
    filter: blur(55px);
}
.beta-banner__icon,
.beta-modal-emblem {
    display: grid;
    place-items: center;
    width: 68px;
    height: 68px;
    color: #07111d;
    background: linear-gradient(135deg, var(--gold-bright), var(--gold));
    font-family: 'Cinzel', Georgia, serif;
    font-size: 2.1rem;
    clip-path: polygon(50% 0, 90% 25%, 90% 75%, 50% 100%, 10% 75%, 10% 25%);
    box-shadow: 0 0 30px rgba(213,174,91,.25);
}
.beta-banner span { color: var(--gold-bright); font-weight: 800; font-size: .7rem; letter-spacing: .18em; }
.beta-banner h1 { margin: 4px 0 6px; font: 600 clamp(1.5rem, 2.7vw, 2.45rem)/1.12 'Cinzel', Georgia, serif; }
.beta-banner p { max-width: 880px; margin: 0; color: #aab6c0; font-size: .91rem; }
.beta-banner .button { position: relative; z-index: 2; white-space: nowrap; }

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin: 20px 0 0;
}
.metric-card {
    min-height: 142px;
    display: grid;
    align-content: center;
    padding: 24px;
    border: 1px solid rgba(255,255,255,.08);
    background: linear-gradient(145deg, rgba(11,24,38,.88), rgba(5,13,22,.9));
    box-shadow: 0 16px 42px rgba(0,0,0,.18);
}
.metric-card small { color: #778794; text-transform: uppercase; letter-spacing: .12em; font-size: .65rem; font-weight: 700; }
.metric-card strong { margin-top: 5px; color: #f0ebe2; font: 600 clamp(1.55rem, 2.5vw, 2.3rem)/1 'Cinzel', Georgia, serif; }
.metric-card strong em { margin-left: 5px; color: #6f7e89; font: normal .85rem 'Inter', sans-serif; }
.metric-card span { margin-top: 9px; color: #8795a0; font-size: .76rem; }
.metric-card span b { color: #aeb9c2; font-weight: 700; }
.metric-card--coins { border-color: rgba(213,174,91,.28); background: linear-gradient(145deg, rgba(39,31,18,.75), rgba(7,17,28,.94)); }
.metric-card--coins strong { color: var(--gold-bright); }

.panel-section { scroll-margin-top: 105px; padding-top: 64px; }
.panel-section__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 28px;
    margin-bottom: 24px;
}
.panel-section__head h2 { margin: 0; font: 600 clamp(1.75rem, 3vw, 2.8rem)/1.08 'Cinzel', Georgia, serif; }
.panel-section__head p:not(.kicker) { max-width: 760px; margin: 10px 0 0; color: #8997a3; }
.panel-section__head .kicker { margin-bottom: 7px; }

.button--compact { min-height: 38px; padding: 8px 13px; font-size: .75rem; }
.button--danger { color: #fff; border-color: rgba(195,72,72,.65); background: linear-gradient(135deg, #9f3434, #642222); }
.button:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.button.is-loading { cursor: wait; }
.button.is-loading::before {
    content: '';
    width: 14px;
    height: 14px;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: formSpin .7s linear infinite;
}
@keyframes formSpin { to { transform: rotate(360deg); } }

.game-account-list { display: grid; gap: 15px; }
.game-account-card {
    border: 1px solid rgba(255,255,255,.085);
    background: rgba(5,13,22,.85);
    box-shadow: 0 18px 52px rgba(0,0,0,.2);
}
.game-account-card > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 20px 22px;
    border-bottom: 1px solid rgba(255,255,255,.07);
    background: linear-gradient(90deg, rgba(18,38,57,.72), rgba(5,13,22,.5));
}
.game-account-card header > div { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.game-account-card header small { color: #71818e; text-transform: uppercase; letter-spacing: .12em; font-size: .62rem; }
.game-account-card h3 { margin: 0; color: var(--gold-bright); font: 600 1.2rem 'Cinzel', Georgia, serif; }
.game-account-card header span { color: #7f8d99; font-size: .76rem; }

.character-list { display: grid; }
.character-row {
    display: grid;
    grid-template-columns: 18px minmax(180px, 1fr) 100px 145px 132px;
    align-items: center;
    gap: 18px;
    min-height: 72px;
    padding: 13px 22px;
    border-bottom: 1px solid rgba(255,255,255,.055);
}
.character-row:last-child { border-bottom: 0; }
.character-row:hover { background: rgba(213,174,91,.025); }
.character-row > div { display: grid; line-height: 1.3; }
.character-row small { color: #6f7f8b; font-size: .68rem; }
.character-row strong { color: #dbe2e7; font-size: .88rem; }
.character-main strong { color: #f1eadf; font: 600 1rem 'Cinzel', Georgia, serif; }
.online-dot { width: 8px; height: 8px; border-radius: 50%; background: #4b5660; box-shadow: 0 0 0 5px rgba(75,86,96,.09); }
.online-dot.is-online { background: #70b997; box-shadow: 0 0 0 5px rgba(112,185,151,.09), 0 0 14px rgba(112,185,151,.55); }
.coin-send-shortcut {
    width: auto;
    min-width: 118px;
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid rgba(213,174,91,.3);
    background: linear-gradient(135deg, rgba(213,174,91,.09), rgba(58,130,174,.05));
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .02em;
    transition: border-color .2s ease, background .2s ease, transform .2s ease, box-shadow .2s ease;
}
.coin-send-shortcut:hover {
    border-color: var(--gold-bright);
    background: linear-gradient(135deg, rgba(213,174,91,.18), rgba(58,130,174,.1));
    box-shadow: 0 0 20px rgba(213,174,91,.1);
    transform: translateY(-1px);
}
.coin-send-shortcut__icon,
.button__coin-icon {
    width: 20px;
    height: 20px;
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
}
.coin-send-shortcut__icon svg,
.button__coin-icon svg {
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.button--coin {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}
.button--coin .button__coin-icon { width: 22px; height: 22px; }
.character-empty { padding: 22px; color: #71818d; font-size: .85rem; }

.empty-state {
    min-height: 300px;
    display: grid;
    place-items: center;
    align-content: center;
    padding: 42px;
    text-align: center;
    border: 1px dashed rgba(213,174,91,.25);
    background: rgba(5,13,22,.68);
}
.empty-state > span { color: var(--gold); font-size: 2.6rem; }
.empty-state h3 { margin: 12px 0 4px; font: 600 1.35rem 'Cinzel', Georgia, serif; }
.empty-state p { margin: 0 0 22px; color: #7c8b97; }

.wallet-layout,
.beta-grid { display: grid; grid-template-columns: .75fr 1.25fr; gap: 16px; align-items: stretch; }
.wallet-card {
    position: relative;
    min-height: 320px;
    display: grid;
    align-content: center;
    padding: 38px;
    border: 1px solid rgba(213,174,91,.35);
    background:
        linear-gradient(155deg, rgba(34,28,17,.82), rgba(6,15,25,.95)),
        url('../images/site/account-wallet.jpg') center / cover no-repeat;
    box-shadow: 0 22px 62px rgba(0,0,0,.28);
    overflow: hidden;
}
.wallet-card::after { content:'◈'; position:absolute; right:28px; top:20px; color:rgba(240,210,141,.18); font-size:5.5rem; }
.wallet-card small { color: #8c9aa6; text-transform: uppercase; letter-spacing: .15em; font-size: .68rem; }
.wallet-card strong { margin: 8px 0 0; color: var(--gold-bright); font: 600 clamp(2.3rem, 5vw, 4.3rem)/1 'Cinzel', Georgia, serif; }
.wallet-card span { color: #d6c397; font-size: .9rem; }
.wallet-card p { max-width: 410px; margin: 28px 0 0; color: #82919d; font-size: .8rem; }

.wallet-stack { display:grid; gap:16px; }
.wallet-converter {
    position:relative;
    min-height:76px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:18px;
    padding:12px 16px 12px 18px;
    border:1px solid rgba(213,174,91,.34);
    border-left:2px solid rgba(230,190,98,.78);
    background:radial-gradient(circle at 50% 0%, rgba(213,174,91,.11), transparent 62%),linear-gradient(90deg, rgba(9,20,31,.96), rgba(13,26,39,.92));
    box-shadow:0 12px 30px rgba(0,0,0,.18);
    overflow:hidden;
}
.wallet-converter::before,.wallet-converter::after {
    content:'';
    position:absolute;
    left:42px;
    width:1px;
    height:16px;
    background:linear-gradient(to bottom, transparent, rgba(213,174,91,.52));
}
.wallet-converter::before { top:-16px; }
.wallet-converter::after { bottom:-16px; transform:rotate(180deg); }
.wallet-converter__rate { min-width:0; display:grid; gap:2px; }
.wallet-converter__rate small { color:#7f94a3; font-size:.56rem; font-weight:900; letter-spacing:.16em; }
.wallet-converter__rate strong { color:#e9c46d; font:700 .98rem 'Cinzel', Georgia, serif; white-space:nowrap; }
.wallet-converter__rate strong span { display:inline-block; margin:0 5px; color:#7d8c98; }
.wallet-converter__rate em { color:#647786; font-size:.62rem; font-style:normal; }
.wallet-converter__button {
    min-height:40px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:10px;
    padding:0 15px;
    border:1px solid rgba(219,178,80,.66);
    background:linear-gradient(180deg, rgba(195,139,39,.28), rgba(72,47,15,.25));
    color:#efca70;
    font-weight:900;
    font-size:.72rem;
    white-space:nowrap;
    cursor:pointer;
    transition:.18s ease;
}
.wallet-converter__button:hover:not(:disabled),.wallet-converter__button:focus-visible:not(:disabled) {
    border-color:#e8c56c;
    color:#ffe2a0;
    transform:translateY(-1px);
    box-shadow:0 8px 20px rgba(0,0,0,.24);
}
.wallet-converter__button:disabled { opacity:.42; cursor:not-allowed; }

.wallet-conversion-summary { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; margin-bottom:18px; }
.wallet-conversion-summary > div,.wallet-conversion-preview { padding:14px 15px; border:1px solid rgba(255,255,255,.08); background:rgba(5,13,22,.58); }
.wallet-conversion-summary small,.wallet-conversion-preview > span { display:block; color:#728491; font-size:.62rem; font-weight:900; text-transform:uppercase; letter-spacing:.1em; }
.wallet-conversion-summary strong { display:block; margin-top:5px; color:#e7c56e; }
.wallet-conversion-preview { margin:14px 0; border-color:rgba(213,174,91,.22); }
.wallet-conversion-preview strong { display:block; margin-top:4px; color:var(--gold-bright); font:700 1.6rem 'Cinzel', Georgia, serif; }
.wallet-conversion-preview small { display:block; margin-top:5px; color:#748897; }
.wallet-conversion-preview small.is-error { color:#e88989; }

.panel-table-card {
    min-width: 0;
    padding: 24px;
    border: 1px solid rgba(255,255,255,.085);
    background: rgba(5,13,22,.86);
    box-shadow: 0 18px 52px rgba(0,0,0,.2);
}
.panel-table-card h3 { margin: 0 0 18px; font: 600 1.1rem 'Cinzel', Georgia, serif; }
.responsive-table { width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .79rem; }
th { padding: 10px 12px; color: #71818d; text-align: left; font-size: .63rem; text-transform: uppercase; letter-spacing: .1em; border-bottom: 1px solid rgba(255,255,255,.08); }
td { padding: 13px 12px; color: #aab5be; border-bottom: 1px solid rgba(255,255,255,.055); white-space: nowrap; }
td strong, td small { display: block; }
td strong { color: #e6e0d7; }
td small { color: #6e7c88; }
.status-tag { display: inline-flex; padding: 5px 8px; border: 1px solid rgba(255,255,255,.12); font-size: .66rem; }
.status-tag--delivered { color: #80c6a4; border-color: rgba(112,185,151,.35); background: rgba(112,185,151,.08); }
.status-tag--pending { color: #e4c472; border-color: rgba(213,174,91,.35); background: rgba(213,174,91,.08); }
.status-tag--processing { color: #70b6dd; border-color: rgba(83,168,216,.35); background: rgba(83,168,216,.08); }
.status-tag--failed,
.status-tag--cancelled { color: #e88989; border-color: rgba(199,75,75,.35); background: rgba(199,75,75,.08); }
.status-tag--refunded { color: #aeb8c1; }

/* Wallet transfer reconciliation: a compact Aetheria action, not a native browser button.
   Only applies to pending wallet history rows; never alters other submit controls. */
.panel-table-card .wallet-reconcile-form {
    display: block;
    width: max-content;
    max-width: 100%;
    margin: 7px 0 0;
}
.panel-table-card .wallet-reconcile-form .wallet-reconcile-button {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 32px;
    max-width: 100%;
    padding: 7px 10px;
    border: 1px solid rgba(221, 177, 92, .52);
    border-radius: 5px;
    background: linear-gradient(180deg, rgba(34, 41, 42, .98), rgba(10, 24, 34, .98));
    box-shadow: inset 0 1px rgba(255, 234, 177, .08), 0 2px 9px rgba(0, 0, 0, .18);
    color: #ecca83;
    font: 700 .69rem/1.2 system-ui, -apple-system, "Segoe UI", sans-serif;
    letter-spacing: .005em;
    text-transform: none;
    white-space: nowrap;
    cursor: pointer;
    transition: color .18s ease, border-color .18s ease,
                background .18s ease, box-shadow .18s ease, transform .18s ease;
}
.panel-table-card .wallet-reconcile-form .wallet-reconcile-button::before {
    content: "\21BB";
    font: 700 1.02rem/0.8 Arial, sans-serif;
    color: #ecc775;
    flex: none;
}
.panel-table-card .wallet-reconcile-form .wallet-reconcile-button:hover:not(:disabled) {
    border-color: rgba(255, 210, 119, .82);
    background: linear-gradient(180deg, rgba(75, 60, 31, .98), rgba(23, 37, 44, .98));
    color: #ffdfa0;
    box-shadow: inset 0 1px rgba(255, 226, 147, .12), 0 4px 14px rgba(0,0,0,.28);
    transform: translateY(-1px);
}
.panel-table-card .wallet-reconcile-form .wallet-reconcile-button:active:not(:disabled) {
    transform: translateY(0);
}
.panel-table-card .wallet-reconcile-form .wallet-reconcile-button:focus-visible {
    outline: 2px solid #ecca83;
    outline-offset: 3px;
}
.panel-table-card .wallet-reconcile-form .wallet-reconcile-button:disabled {
    opacity: .52;
    cursor: wait;
    transform: none;
}
@media (prefers-reduced-motion: reduce) {
    .panel-table-card .wallet-reconcile-form .wallet-reconcile-button {
        transition: none;
    }
}
.delivery-status-cell { min-width: 210px; }
.delivery-status-cell > small {
    display: block;
    max-width: 260px;
    margin-top: 6px;
    color: #71818d;
    font-size: .65rem;
    line-height: 1.4;
}
.table-action { padding: 5px; font-size: .72rem; text-decoration: underline; text-underline-offset: 3px; }
.table-empty { color: #6e7e8a; font-size: .84rem; }

.beta-progress-card {
    padding: 28px;
    border: 1px solid rgba(213,174,91,.28);
    background: linear-gradient(145deg, rgba(22,32,40,.9), rgba(6,15,24,.96));
}
.beta-rank { padding-bottom: 22px; border-bottom: 1px solid rgba(255,255,255,.08); }
.beta-rank span, .beta-rank small { display: block; color: #7b8a96; }
.beta-rank span { font-size: .65rem; text-transform: uppercase; letter-spacing: .14em; }
.beta-rank strong { display:block; margin:5px 0; color:var(--gold-bright); font:600 1.55rem 'Cinzel',Georgia,serif; }
.beta-rank small { font-size: .72rem; }
.quest-list { display: grid; gap: 10px; margin-top: 20px; }
.quest-item { display: grid; grid-template-columns: 34px 1fr; align-items: center; gap: 12px; padding: 12px; border: 1px solid rgba(255,255,255,.065); background: rgba(255,255,255,.015); }
.quest-item > span { width: 29px; height: 29px; display:grid; place-items:center; color:#70808c; border:1px solid rgba(255,255,255,.12); font-size:.72rem; }
.quest-item > div { display:grid; }
.quest-item strong { color:#aeb9c2; font-size:.79rem; }
.quest-item small { color:#697985; font-size:.68rem; }
.quest-item.is-done { border-color:rgba(112,185,151,.18); background:rgba(112,185,151,.035); }
.quest-item.is-done > span { color:#07111d; border-color:#70b997; background:#70b997; }
.quest-item.is-done strong { color:#d9e6df; }

.bug-list { display: grid; gap: 10px; }
.bug-list > div { display:grid; gap:3px; padding:13px 14px; border:1px solid rgba(255,255,255,.065); }
.bug-list span { width:max-content; padding:3px 6px; color:var(--gold-bright); background:rgba(213,174,91,.07); font-size:.59rem; text-transform:uppercase; letter-spacing:.08em; }
.bug-list strong { color:#dfe4e8; font-size:.84rem; }
.bug-list small { color:#6f7e89; font-size:.68rem; }

.panel-notice { margin: 18px 0; padding: 13px 16px; border: 1px solid rgba(112,185,151,.35); color: #bfe1cf; background: rgba(112,185,151,.08); }
.panel-notice--error { border-color: rgba(194,75,75,.4); color: #efb1b1; background: rgba(194,75,75,.08); }

.panel-modal {
    position: fixed;
    inset: 0;
    z-index: 500;
    display: grid;
    place-items: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity .22s ease, visibility .22s ease;
}
.panel-modal.is-open { opacity: 1; visibility: visible; }
.panel-modal__backdrop { position:absolute; inset:0; background:rgba(1,4,8,.84); backdrop-filter:blur(14px); }
.panel-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(560px, 100%);
    max-height: min(90vh, 820px);
    overflow-y: auto;
    padding: 38px;
    border: 1px solid rgba(224,190,111,.48);
    background:
        radial-gradient(circle at 50% 0, rgba(45,131,181,.14), transparent 32%),
        #07111d;
    box-shadow: 0 40px 110px rgba(0,0,0,.7);
    transform: translateY(24px) scale(.97);
    transition: transform .28s cubic-bezier(.2,.8,.2,1);
}
.panel-modal.is-open .panel-modal__dialog { transform: translateY(0) scale(1); }
.panel-modal__dialog::before { content:none; }
.panel-modal__dialog { outline:1px solid rgba(213,174,91,.1); outline-offset:-11px; }
.panel-modal__dialog--wide { width: min(760px, 100%); }
.panel-modal__close { position:absolute; top:11px; right:14px; z-index:3; width:38px; height:38px; border:0; color:#8796a2; background:transparent; cursor:pointer; font-size:1.7rem; }
.panel-modal h2 { margin: 2px 0 9px; font: 600 clamp(1.65rem,4vw,2.5rem)/1.12 'Cinzel',Georgia,serif; }
.panel-modal__dialog > p:not(.kicker) { margin:0 0 22px; color:#8e9ca7; }
.beta-modal-emblem { margin: 0 auto 20px; }
.panel-modal .kicker { margin-bottom: 5px; }

.modal-stepper { display:flex; align-items:center; width:min(260px,72%); margin:0 auto 25px; }
.modal-stepper span { width:28px; height:28px; display:grid; place-items:center; border:1px solid rgba(255,255,255,.14); color:#6f7f8b; border-radius:50%; font-size:.67rem; }
.modal-stepper span.is-active { color:#07111d; background:var(--gold); border-color:var(--gold); }
.modal-stepper i { flex:1; height:1px; background:rgba(255,255,255,.12); }

.panel-form { position:relative; z-index:2; display:grid; gap:14px; margin-top:20px; }
.panel-form label { display:grid; gap:7px; color:#a8b4bd; font-size:.75rem; font-weight:700; }
.panel-form input,
.panel-form select,
.panel-form textarea {
    width:100%;
    min-height:48px;
    padding:11px 13px;
    border:1px solid rgba(255,255,255,.12);
    outline:0;
    color:#eff2f4;
    background:rgba(2,8,14,.72);
    transition:border-color .2s ease, box-shadow .2s ease;
}
.panel-form textarea { min-height:100px; resize:vertical; }
.panel-form input:focus,
.panel-form select:focus,
.panel-form textarea:focus { border-color:rgba(213,174,91,.65); box-shadow:0 0 0 3px rgba(213,174,91,.07); }
.panel-form .button { width:100%; margin-top:4px; }
.form-grid { display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.form-feedback { min-height:0; padding:0; font-size:.76rem; }
.form-feedback.is-error { min-height:40px; padding:10px 12px; color:#efaaaa; border:1px solid rgba(195,72,72,.32); background:rgba(195,72,72,.08); }
.form-feedback.is-success { min-height:40px; padding:10px 12px; color:#b8dec9; border:1px solid rgba(112,185,151,.3); background:rgba(112,185,151,.08); }
.selected-target,
.coin-review { padding:12px 14px; border:1px solid rgba(213,174,91,.18); background:rgba(213,174,91,.04); color:#8998a4; font-size:.78rem; }
.selected-target strong { color:var(--gold-bright); }
.coin-review { display:grid; }
.coin-review span,.coin-review small { color:#72828e; }
.coin-review strong { color:var(--gold-bright); font:600 1.2rem 'Cinzel',Georgia,serif; }
.beta-rules { display:grid; grid-template-columns:repeat(3,1fr); gap:10px; margin:24px 0; }
.beta-rules > div { padding:18px; border:1px solid rgba(255,255,255,.075); background:rgba(255,255,255,.018); }
.beta-rules strong { color:var(--gold-bright); font:600 .86rem 'Cinzel',Georgia,serif; }
.beta-rules p { margin:8px 0 0; color:#82919c; font-size:.75rem; }

.auth-result { min-height:100vh; display:grid; place-items:center; padding:24px; }
.auth-result__card { width:min(560px,100%); padding:44px; text-align:center; border:1px solid rgba(213,174,91,.36); background:rgba(6,15,24,.94); box-shadow:0 35px 100px rgba(0,0,0,.55); }
.auth-result__card > img { width:210px; margin:0 auto 20px; }
.auth-result__sigil { width:64px; height:64px; display:grid; place-items:center; margin:0 auto 18px; color:var(--gold-bright); border:1px solid rgba(213,174,91,.55); font-size:1.8rem; transform:rotate(45deg); }
.auth-result__sigil::first-letter { transform:rotate(-45deg); }
.auth-result h1 { margin:5px 0 10px; font:600 clamp(1.8rem,5vw,2.8rem)/1.1 'Cinzel',Georgia,serif; }
.auth-result p { color:#8e9ca7; }
.auth-result .button { margin-top:18px; }
.auth-result__card--form { text-align:left; }
.auth-result__card--form > img { margin-left:auto; margin-right:auto; }
.auth-result__card--form h1,
.auth-result__card--form > p { text-align:center; }

.panel-live-toast {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 900;
    max-width: min(390px, calc(100vw - 32px));
    padding: 15px 18px;
    border: 1px solid rgba(112,185,151,.45);
    color: #cce9da;
    background: rgba(7,17,29,.96);
    box-shadow: 0 20px 60px rgba(0,0,0,.48);
    opacity: 0;
    transform: translateY(16px);
    pointer-events: none;
    transition: opacity .24s ease, transform .24s ease;
    font-size: .82rem;
}
.panel-live-toast::before {
    content: '';
    display: inline-block;
    width: 7px;
    height: 7px;
    margin-right: 10px;
    border-radius: 50%;
    background: #70b997;
    box-shadow: 0 0 12px rgba(112,185,151,.7);
}
.panel-live-toast--error {
    border-color: rgba(199,75,75,.45);
    color: #efb1b1;
}
.panel-live-toast--error::before {
    background: #c74b4b;
    box-shadow: 0 0 12px rgba(199,75,75,.7);
}
.panel-live-toast.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1050px) {
    .panel-header { grid-template-columns: 190px 1fr auto; gap:14px; }
    .panel-nav a { padding-inline:8px; }
    .dashboard-grid { grid-template-columns:repeat(2,1fr); }
    .wallet-layout,.beta-grid { grid-template-columns:1fr; }
}

@media (max-width: 780px) {
    .panel-header { position:relative; grid-template-columns:1fr auto; gap:10px; padding:10px 16px; }
    .panel-brand img { width:155px; }
    .panel-nav { grid-column:1/-1; justify-content:flex-start; overflow-x:auto; padding-bottom:4px; }
    .panel-nav a { white-space:nowrap; }
    .panel-user { gap:8px; }
    .panel-user > div { display:none; }
    .panel-home-link__desktop { display:none; }
    .panel-home-link__mobile { display:inline; }
    .panel-main { width:min(100% - 24px,1320px); padding-top:22px; }
    .beta-banner { grid-template-columns:56px 1fr; padding:22px; }
    .beta-banner__icon { width:50px; height:50px; font-size:1.5rem; }
    .beta-banner .button { grid-column:1/-1; width:100%; }
    .panel-section { padding-top:48px; }
    .panel-section__head { align-items:stretch; flex-direction:column; gap:15px; }
    .panel-section__head .button { width:100%; }
    .character-row { grid-template-columns:14px 1fr 70px 42px; gap:10px; padding-inline:14px; }
    .character-row > div:nth-of-type(3) { display:none; }
    .coin-send-shortcut { min-width:42px; width:42px; padding:8px; }
    .coin-send-shortcut__label { display:none; }
    .beta-rules { grid-template-columns:1fr; }
}


@media (max-width: 420px) {
    .panel-header { padding-inline: 10px; }
    .panel-brand img { width: 126px; }
    .panel-user { gap: 6px; }
    .panel-home-link { min-height: 36px; padding: 8px 9px; }
    .panel-logout { padding: 8px 9px; }
}

@media (max-width: 560px) {
    .dashboard-grid { grid-template-columns:1fr; }
    .metric-card { min-height:118px; }
    .game-account-card > header { align-items:flex-start; flex-direction:column; }
    .game-account-card header .button { width:100%; }
    .character-row { grid-template-columns:12px 1fr 58px 38px; }
    .character-row > div:nth-of-type(3) { display:none; }
    .coin-send-shortcut { min-width:38px; width:38px; min-height:38px; padding:7px; }
    .wallet-card { min-height:260px; padding:26px; }
    .wallet-converter { align-items:stretch; flex-direction:column; gap:10px; padding:14px; }
    .wallet-converter__button { width:100%; }
    .wallet-conversion-summary { grid-template-columns:1fr; }
    .panel-table-card { padding:17px; }
    .panel-modal { padding:8px; align-items:end; }
    .panel-modal__dialog { width:100%; max-height:94vh; padding:32px 20px 24px; border-bottom:0; }
    .panel-modal__dialog--wide { width:100%; }
    .form-grid { grid-template-columns:1fr; }
    .auth-result__card { padding:34px 20px; }
    .panel-live-toast { left:16px; right:16px; bottom:16px; max-width:none; }
}

@media (prefers-reduced-motion: reduce) {
    .panel-modal,
    .panel-modal__dialog,
    .button { transition:none!important; }
}

.game-login-help {
    display: block;
    margin-top: 7px;
    color: #82919d;
    font-size: .72rem;
    font-weight: 500;
    line-height: 1.5;
}

.game-login-help strong {
    color: #d8e2e9;
    font-weight: 700;
}

/* ===== v2.5.0 • Master Account center layout ===== */
.panel-account-button {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 8px 11px;
    border: 1px solid rgba(83,168,216,.25);
    background: rgba(83,168,216,.065);
    color: #b7c9d5;
    font: inherit;
    font-size: .75rem;
    font-weight: 800;
    white-space: nowrap;
    cursor: pointer;
    transition: border-color .2s ease, color .2s ease, background .2s ease, transform .2s ease;
}
.panel-account-button:hover,
.panel-account-button:focus-visible {
    color: #eef7fb;
    border-color: rgba(83,168,216,.48);
    background: rgba(83,168,216,.12);
    transform: translateY(-1px);
}
.panel-account-button > span:first-child { color: #79b8db; font-size: .95rem; }
.panel-user__identity { display: grid; text-align: right; line-height: 1.2; }

.metric-card--coins span {
    max-width: 260px;
    line-height: 1.45;
}

.character-main__name {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 9px;
}

.character-coin-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-height: 26px;
    padding: 4px 8px;
    border: 1px solid rgba(213,174,91,.24);
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(213,174,91,.10), rgba(213,174,91,.035));
    color: #f0d28d;
    font-size: .72rem;
    line-height: 1;
    box-shadow: inset 0 1px rgba(255,255,255,.025);
}

.character-coin-badge__icon {
    width: 15px;
    height: 15px;
    display: inline-flex;
    color: #d5ae5b;
}
.character-coin-badge__icon svg,
.button__coin-icon svg,
.coin-send-shortcut__icon svg {
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.character-coin-badge b { color: #f4d98f; font-weight: 800; }
.character-coin-badge__label {
    color: rgba(240, 210, 141, .82);
    font-weight: 700;
    white-space: nowrap;
}

.panel-session-note {
    display: grid;
    grid-template-columns: 26px 1fr;
    align-items: center;
    gap: 10px;
    padding: 12px 13px;
    border: 1px solid rgba(112,185,151,.18);
    background: rgba(112,185,151,.055);
    color: #a8c8b9;
}
.panel-session-note > span {
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(112,185,151,.12);
    color: #80c6a4;
    font-weight: 900;
}
.panel-session-note p { margin: 0; font-size: .76rem; line-height: 1.45; }

.master-account-dialog {
    max-width: 980px;
    padding: 10px;
}
.master-account-dialog::before { display: none; }
.master-account-frame {
    min-height: 100%;
    padding: 28px;
    border: 1px solid rgba(213,174,91,.1);
    background: transparent;
}
.master-account-summary {
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 12px;
    margin: 18px 0;
}
.master-account-summary > div {
    display: grid;
    gap: 5px;
    padding: 15px 16px;
    border: 1px solid rgba(255,255,255,.065);
    background: rgba(255,255,255,.025);
}
.master-account-summary small,
.master-account-section__head > span {
    color: #7f94a2;
    font-size: .66rem;
    font-weight: 800;
    letter-spacing: .13em;
    text-transform: uppercase;
}
.master-account-summary strong { color: #e8edf1; font-size: .9rem; overflow-wrap:anywhere; }
.master-account-summary span { color: #75b994; font-size: .72rem; }

.master-account-primary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 18px;
    align-items: stretch;
}
.master-account-primary-grid > .master-account-section {
    height: 100%;
}
.master-account-section {
    min-width: 0;
    padding: 20px;
    border: 1px solid rgba(255,255,255,.075);
    border-radius: 2px;
    background: linear-gradient(145deg, rgba(10,24,37,.76), rgba(5,13,22,.84));
    box-shadow: inset 0 1px rgba(255,255,255,.018), 0 12px 28px rgba(0,0,0,.10);
}
.master-account-section--email {
    display: block;
    width: 100%;
    margin-top: 24px;
    clear: both;
    position: relative;
    z-index: 1;
    border-color: rgba(213,174,91,.15);
    background: linear-gradient(145deg, rgba(10,24,37,.82), rgba(7,14,22,.92));
    box-shadow: inset 0 1px rgba(240,210,141,.035), 0 16px 34px rgba(0,0,0,.14);
}
.master-account-section__head { margin-bottom: 13px; }
.master-account-section__head h3 {
    margin: 5px 0 0;
    color: #f0ebe2;
    font: 600 1.14rem 'Cinzel', Georgia, serif;
}
.master-account-warning {
    margin: 0 0 14px;
    padding: 11px 12px;
    border-left: 2px solid rgba(213,174,91,.55);
    background: rgba(213,174,91,.045);
    color: #aeb9c1;
    font-size: .78rem;
    line-height: 1.5;
}
.master-account-section .button { width: 100%; }

.master-email-flow {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 0 0 18px;
    padding: 0;
    list-style: none;
}
.master-email-flow li {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    padding: 12px;
    border: 1px solid rgba(255,255,255,.055);
    background: rgba(255,255,255,.022);
}
.master-email-flow li > span {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(213,174,91,.30);
    background: rgba(213,174,91,.08);
    color: #e8c873;
    font-weight: 900;
    font-size: .74rem;
}
.master-email-flow strong,
.master-email-flow small { display: block; }
.master-email-flow strong {
    color: #e8edf1;
    font-size: .78rem;
    line-height: 1.35;
}
.master-email-flow small {
    margin-top: 4px;
    color: #8fa1ad;
    font-size: .70rem;
    line-height: 1.45;
}
.master-email-form {
    padding-top: 18px;
    border-top: 1px solid rgba(255,255,255,.065);
}

@media (max-width: 1050px) {
    .panel-account-button > span:last-child { display: none; }
    .panel-account-button { width: 38px; padding: 8px; }
}

@media (max-width: 780px) {
    .panel-user__identity { display: none; }
    .master-account-primary-grid { grid-template-columns: 1fr; }
    .master-account-section--email { margin-top: 18px; }
}

@media (max-width: 560px) {
    .master-account-summary { grid-template-columns: 1fr; }
    .master-email-flow { grid-template-columns: 1fr; }
    .character-main__name { gap: 6px; }
    .character-coin-badge { padding: 4px 7px; }
}

/* ===== v2.6.0 • sliding pagination ===== */
.panel-table-card--deliveries {
    overflow: hidden;
}

.delivery-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.panel-table-card--deliveries .delivery-card-head h3 {
    margin: 0;
}

.delivery-page-summary {
    color: #70818d;
    font-size: .67rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.delivery-carousel__viewport {
    width: 100%;
    min-width: 0;
    overflow: hidden;
}

.delivery-carousel__track {
    display: flex;
    align-items: stretch;
    width: 100%;
    transform: translate3d(0, 0, 0);
    transition: transform .38s cubic-bezier(.22, .75, .25, 1);
    will-change: transform;
}

.delivery-carousel__page {
    flex: 0 0 100%;
    width: 100%;
    min-width: 100%;
}

.delivery-carousel__page[aria-hidden="true"] {
    pointer-events: none;
}

.delivery-pagination {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 9px;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid rgba(255,255,255,.06);
}

.delivery-pagination__pages {
    display: flex;
    align-items: center;
    gap: 7px;
}

.delivery-pagination button {
    min-width: 34px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    padding: 0 9px;
    border: 1px solid rgba(255,255,255,.09);
    background: rgba(255,255,255,.025);
    color: #8797a3;
    font: inherit;
    font-size: .72rem;
    font-weight: 800;
    cursor: pointer;
    transition: color .18s ease, border-color .18s ease, background .18s ease, transform .18s ease;
}

.delivery-pagination button:hover,
.delivery-pagination button:focus-visible {
    color: #eef5f8;
    border-color: rgba(83,168,216,.38);
    background: rgba(83,168,216,.09);
    transform: translateY(-1px);
}

.delivery-pagination__page.is-current {
    color: #07111d;
    border-color: #dfbd6c;
    background: linear-gradient(135deg, #f0d28d, #d5ae5b);
    box-shadow: 0 7px 20px rgba(213,174,91,.16);
}

.delivery-pagination__arrow {
    font-size: 1.15rem !important;
    line-height: 1;
}

.delivery-pagination button:disabled {
    opacity: .34;
    cursor: default;
    transform: none;
}

@media (max-width: 560px) {
    .delivery-card-head {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
    }

    .delivery-pagination {
        justify-content: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .delivery-carousel__track { transition: none; }
}


/* ===== v2.6.3 • continuous My Account inner frame ===== */
@media (max-width: 780px) {
    .master-account-dialog { padding: 8px; }
    .master-account-frame { padding: 24px 20px; }
}

@media (max-width: 560px) {
    .master-account-frame { padding: 22px 16px; }
}

/* Patch 07.18: clearer security path from the Master Account panel. */
.beta-banner__actions{position:relative;z-index:2;display:flex;gap:10px;align-items:center;justify-content:flex-end;flex-wrap:wrap}
.beta-banner__actions .button{margin:0}
.panel-notice--security{border-color:rgba(213,174,91,.28);background:linear-gradient(90deg,rgba(213,174,91,.075),rgba(29,109,158,.045));color:#aab7c0}
.panel-notice--security strong{color:#e8ca78}.panel-notice--security a{color:#74bee8;text-decoration:none;font-weight:800}.panel-notice--security a:hover{text-decoration:underline}
@media(max-width:760px){.beta-banner__actions{display:grid;grid-template-columns:1fr;width:100%}.beta-banner__actions .button{width:100%}}


/* ===== Performance pass v3.6: responsive modal compositor =====
   Keep the Aetheria visual language, but avoid full-screen blur/opacity layers
   that make focus, TAB and close actions repaint the whole viewport. */
.panel-header {
    backdrop-filter: none !important;
    background: rgba(4,10,17,.97) !important;
}

.beta-banner::after {
    filter: none !important;
    background: radial-gradient(circle, rgba(213,174,91,.12) 0%, rgba(213,174,91,.04) 42%, transparent 72%) !important;
}

/* The full-screen shell appears/disappears immediately. Only the card gets a
   tiny entrance motion, so closing never waits on a viewport-sized fade. */
.panel-modal {
    opacity: 1 !important;
    visibility: hidden;
    pointer-events: none;
    transition: none !important;
    contain: layout paint style;
}
.panel-modal.is-open {
    visibility: visible;
    pointer-events: auto;
}
.panel-modal__backdrop {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    background:
        radial-gradient(circle at 50% 38%, rgba(31,91,126,.11), transparent 44%),
        rgba(1,4,8,.93) !important;
}
.panel-modal__dialog {
    box-shadow: 0 18px 48px rgba(0,0,0,.52) !important;
    transform: translate3d(0,8px,0) !important;
    opacity: .985;
    transition: transform .11s ease-out, opacity .11s ease-out !important;
    will-change: transform;
    contain: layout paint;
}
.panel-modal.is-open .panel-modal__dialog {
    transform: translate3d(0,0,0) !important;
    opacity: 1;
}

/* Focus should feel immediate. The old shadow transition forced a repaint of
   the large modal card whenever TAB changed fields. */
.panel-form input,
.panel-form select,
.panel-form textarea {
    transition: border-color .08s linear, background-color .08s linear !important;
}
.panel-form input:focus,
.panel-form select:focus,
.panel-form textarea:focus {
    box-shadow: none !important;
    border-color: rgba(240,210,141,.78) !important;
    background: rgba(3,10,17,.94) !important;
}

.password-assistant,
.password-assistant__meter span {
    transition-duration: .10s !important;
}
.password-assistant__meter span {
    box-shadow: none !important;
}

/* Pause nonessential page effects while any panel modal is open. */
body.modal-lock .panel-header,
body.modal-lock .beta-banner,
body.modal-lock .metric-card,
body.modal-lock .game-account-card {
    box-shadow: none !important;
}

@media (prefers-reduced-motion: reduce) {
    .panel-modal__dialog { transition: none !important; transform: none !important; }
}

/* ===== v3.7.0 • checkbox control isolation =====
   Generic panel input dimensions are for text fields only. */
.panel-form input[type="checkbox"] {
    display:block !important;
    width:18px !important;
    min-width:18px !important;
    max-width:18px !important;
    height:18px !important;
    min-height:18px !important;
    max-height:18px !important;
    padding:0 !important;
    margin:2px 0 0 !important;
    border:0 !important;
    background:transparent !important;
    box-shadow:none !important;
    appearance:auto !important;
    -webkit-appearance:checkbox !important;
    accent-color:var(--gold);
}
.panel-form input[type="checkbox"]:focus {
    border:0 !important;
    background:transparent !important;
    box-shadow:0 0 0 2px rgba(240,210,141,.20) !important;
}


/* ===== V8 • account navigation polish ===== */
.panel-header{grid-template-columns:minmax(170px,210px) minmax(420px,1fr) auto;gap:18px;padding-inline:max(18px,calc((100vw - 1500px)/2))}
.panel-nav{justify-content:flex-start;min-width:0;overflow-x:auto;overflow-y:hidden;scrollbar-width:none;white-space:nowrap;padding:0 2px}
.panel-nav::-webkit-scrollbar{display:none}.panel-nav a{flex:0 0 auto;white-space:nowrap;padding-inline:12px}
.panel-user{gap:10px;white-space:nowrap}.panel-user__identity{min-width:96px}.panel-language-switcher{flex:0 0 auto}.panel-main{width:min(1480px,calc(100% - 40px))}
@media(max-width:1180px){.panel-header{grid-template-columns:160px minmax(280px,1fr) auto}.panel-brand img{width:155px}.panel-user__identity{display:none!important}.panel-account-button span:last-child{display:none}.panel-nav a{padding-inline:10px;font-size:.78rem}}
@media(max-width:820px){.panel-header{grid-template-columns:auto 1fr;grid-template-areas:'brand user' 'nav nav';min-height:auto;padding-block:9px}.panel-brand{grid-area:brand}.panel-user{grid-area:user;justify-content:flex-end}.panel-nav{grid-area:nav;width:100%;padding-bottom:4px}.panel-language-switcher{display:none}}

/* V8 final gate: keep the shared language selector available on small screens. */
@media(max-width:820px){.panel-header .panel-language-switcher{display:block;min-width:0}.panel-user{min-width:0;gap:5px}.panel-language-switcher .language-switcher__toggle{padding-inline:8px;min-height:36px}.panel-user__identity{display:none}}
@media(max-width:510px){.panel-header{grid-template-columns:minmax(92px,1fr) auto;gap:7px}.panel-brand img{width:min(115px,100%)}.panel-user .panel-home-link,.panel-user .panel-account-button{display:none}.panel-language-switcher .language-switcher__label{max-width:95px;overflow:hidden;text-overflow:ellipsis}}

/* V8.1 account header: keep all primary nav items visible after Support Shop addition. */
@media (max-width:1700px) and (min-width:821px){
  .panel-header{grid-template-columns:minmax(145px,170px) minmax(0,1fr) auto;gap:10px;padding-inline:16px}
  .panel-brand img{width:150px}
  .panel-nav{gap:1px;justify-content:center;overflow:visible}
  .panel-nav a{padding-inline:8px;font-size:.77rem}
  .panel-user{gap:7px}
  .panel-user__identity{display:none!important}
  .panel-home-link{padding-inline:10px}
  .panel-account-button{padding-inline:9px}
}
@media (max-width:1380px) and (min-width:821px){
  .panel-nav{justify-content:flex-start;overflow-x:auto;scrollbar-width:none}
  .panel-nav::-webkit-scrollbar{display:none}
  .panel-nav a{padding-inline:7px;font-size:.74rem}
  .panel-account-button>span:last-child{display:none}
}

/* V8.2 Account header: at notebook/standard desktop widths give navigation its own full-width row. */
@media (max-width:1580px) and (min-width:821px){
  .panel-header{
    grid-template-columns:minmax(145px,180px) minmax(0,1fr);
    grid-template-areas:'brand user' 'nav nav';
    gap:5px 14px;
    min-height:auto;
    padding:8px 16px 6px;
  }
  .panel-brand{grid-area:brand}
  .panel-user{grid-area:user;justify-content:flex-end;min-width:0}
  .panel-nav{
    grid-area:nav;
    width:100%;
    min-width:0;
    justify-content:flex-start;
    overflow-x:auto;
    overflow-y:hidden;
    white-space:nowrap;
    scrollbar-width:none;
    padding:3px 0 1px;
    border-top:1px solid rgba(255,255,255,.045);
  }
  .panel-nav::-webkit-scrollbar{display:none}
  .panel-nav a{flex:0 0 auto;white-space:nowrap;padding:9px 12px;font-size:.78rem}
  .panel-nav a::after{bottom:2px}
}

/* ===== MASTER ACCOUNT NAV V009 - VISIBLE SHOP, NO HIDDEN SCROLL ===== */
.panel-buy-link{
  display:inline-flex;align-items:center;justify-content:center;gap:7px;
  flex:0 0 auto;white-space:nowrap;text-decoration:none;
  min-height:38px;padding:8px 13px;border-radius:7px;
  border:1px solid rgba(249,215,132,.68);
  background:linear-gradient(130deg,#f0d188,#c69a46);
  color:#0d1822!important;font-weight:800;font-size:.78rem;
  box-shadow:0 3px 15px rgba(183,126,39,.16);
  transition:filter .18s ease,transform .18s ease;
}
.panel-buy-link:hover,.panel-buy-link:focus-visible{filter:brightness(1.12);transform:translateY(-1px)}
.panel-buy-link__icon{font-size:1.04rem;line-height:1}
.panel-buy-link__short{display:none}
.panel-nav a.panel-nav__shop{color:#f1d08b}
.panel-nav a.panel-nav__shop:hover{color:#fff0c9}
.panel-mobile-menu{display:none}

/* Two clear, fully-visible rows at common desktop/notebook widths.
   Never hide links behind a scrollbar with an invisible track. */
@media (min-width:821px) and (max-width:1880px){
  .panel-header{
    grid-template-columns:minmax(130px,185px) minmax(0,1fr);
    grid-template-areas:"brand user" "nav nav";
    gap:4px 12px;min-height:auto;
    padding:7px clamp(12px,1.5vw,26px) 6px;
  }
  .panel-brand{grid-area:brand}
  .panel-brand img{width:150px;max-height:57px}
  .panel-user{grid-area:user;justify-content:flex-end;min-width:0;gap:9px}
  .panel-user__identity{display:none!important}
  .panel-nav{
    grid-area:nav;display:flex;flex-wrap:wrap;
    justify-content:center;align-items:center;
    width:100%;min-width:0;gap:2px 8px;
    overflow:visible;white-space:normal;
    padding:5px 0 1px;border-top:1px solid rgba(255,255,255,.065);
  }
  .panel-nav a{flex:0 0 auto;white-space:nowrap;font-size:.78rem;padding:7px 10px}
  .panel-nav a::after{bottom:2px}
}
@media (min-width:821px) and (max-width:1110px){
  .panel-user{gap:5px}
  .panel-home-link__desktop{display:none}
  .panel-home-link__mobile{display:inline}
  .panel-account-button{width:38px;padding:8px}
  .panel-account-button>span:last-child{display:none}
  .panel-tour-button{padding-inline:8px}
}
@media (max-width:820px){
  .panel-header{
    position:sticky;top:0;z-index:100;
    display:grid;grid-template-columns:minmax(85px,1fr) auto;
    grid-template-areas:"brand user";gap:7px;align-items:center;
    min-height:64px;padding:8px 12px;
  }
  .panel-brand{grid-area:brand;min-width:0}
  .panel-brand img{width:126px;max-width:100%;max-height:55px}
  .panel-nav{display:none!important}
  .panel-user{grid-area:user;display:flex;min-width:0;align-items:center;justify-content:flex-end;gap:7px}
  .panel-user>.panel-home-link,.panel-user>.panel-tour-button,
  .panel-user>.panel-account-button,.panel-user>.panel-user__identity,
  .panel-user>form.ajax-form{display:none!important}
  .panel-mobile-menu{display:block;position:relative;flex:0 0 auto;text-align:left}
  .panel-mobile-menu summary{
    display:inline-flex;align-items:center;justify-content:center;gap:6px;
    list-style:none;cursor:pointer;min-height:38px;min-width:77px;
    padding:8px 11px;border:1px solid #496377;border-radius:7px;
    background:#102332;color:#d9eaf6;font-size:.79rem;font-weight:800;
  }
  .panel-mobile-menu summary::-webkit-details-marker{display:none}
  .panel-mobile-menu summary:hover,.panel-mobile-menu summary:focus-visible{border-color:#d4b777;color:#fff0cf}
  .panel-mobile-menu__links{
    position:absolute;top:calc(100% + 10px);right:0;
    display:grid;gap:2px;z-index:150;
    min-width:228px;width:min(310px,calc(100vw - 24px));
    max-height:calc(100dvh - 95px);overflow-y:auto;
    padding:8px;border:1px solid #55718a;border-radius:12px;
    background:#0a1725;box-shadow:0 22px 44px #000a;
  }
  .panel-mobile-menu__links a,.panel-mobile-menu__links button{
    display:block;width:100%;text-align:left;
    padding:11px 12px;border:0;border-radius:7px;
    background:transparent;color:#ceddeb!important;
    font-weight:700;font-size:.86rem;line-height:1.25;font-family:inherit;cursor:pointer;text-decoration:none;
  }
  .panel-mobile-menu__links a:hover,.panel-mobile-menu__links button:hover,
  .panel-mobile-menu__links a:focus-visible,.panel-mobile-menu__links button:focus-visible{
    background:#1b3245;color:#fff!important
  }
  .panel-mobile-menu__links .panel-mobile-menu__shop{
    background:linear-gradient(120deg,#f0d188,#c69a46);
    color:#101921!important;font-weight:900;
  }
  .panel-mobile-menu__links form{margin:0;border-top:1px solid #2f4353;padding-top:5px}
  .panel-mobile-menu__links form button{color:#eab0ab!important}
}
@media (max-width:540px){
  .panel-header{gap:5px;padding-inline:9px}
  .panel-brand img{width:105px}
  .panel-user{gap:5px}
  .panel-buy-link{min-height:36px;padding:7px 9px;font-size:.76rem}
  .panel-buy-link__full{display:none}
  .panel-buy-link__short{display:inline}
  .panel-language-switcher .language-switcher__label{display:none}
  .panel-language-switcher .language-switcher__toggle{padding:7px;min-height:36px;min-width:36px}
  .panel-mobile-menu summary{min-width:65px;padding:7px 8px;min-height:36px}
}

/* V010: persistent GNB and Founder actions, without duplicated purchase navigation. */
.panel-nav a.panel-nav__founder{
 display:inline-flex;align-items:center;gap:6px;padding:7px 11px;
 border:1px solid rgba(231,190,99,.5);border-radius:8px;
 background:linear-gradient(130deg,rgba(110,75,26,.4),rgba(44,34,23,.2));
 color:#ffe5a6!important;font-weight:850;
}
.panel-nav a.panel-nav__founder:hover,.panel-nav a.panel-nav__founder.is-active{
 background:linear-gradient(135deg,rgba(162,107,28,.55),rgba(70,47,26,.48));
 border-color:#f2c778;color:#fff2ce!important;
}
.panel-founder-mark{font-size:1.16em;color:#ffdc8c;line-height:1}
.panel-nav a.panel-nav__founder small{
 font-size:.59rem;letter-spacing:.04em;text-transform:uppercase;
 background:#d2a64c;color:#201408;border-radius:4px;padding:4px 5px;font-weight:900;
}
.panel-founder-header-link{
 display:inline-flex;align-items:center;gap:5px;white-space:nowrap;min-height:38px;
 border:1px solid #967439;border-radius:7px;background:rgba(93,65,26,.34);
 padding:7px 10px;color:#ffe1a4!important;text-decoration:none;font-size:.78rem;font-weight:800;
}
.panel-founder-header-link:hover,.panel-founder-header-link:focus-visible{
 border-color:#e9bc67;background:rgba(132,93,34,.45);
}
.panel-mobile-menu__links .panel-mobile-menu__founder{
 background:linear-gradient(110deg,#503918,#2b261e);color:#ffe0a1!important;
 border:1px solid rgba(226,174,69,.55);
}
.account-security-shortcuts{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.account-security-shortcuts a{
 display:inline-flex;align-items:center;justify-content:center;text-decoration:none;
 padding:10px 13px;border-radius:8px;font-weight:800;font-size:.82rem;
}
.account-security-shortcuts__founder{
 color:#ffe2a4!important;border:1px solid rgba(224,171,67,.65);
 background:linear-gradient(135deg,#543a1d,#2b241c);
}
.account-security-shortcuts__gnb{
 color:#171b20!important;border:1px solid #d0ab5d;
 background:linear-gradient(130deg,#f0d188,#c69a46);
}
@media(max-width:820px){.panel-founder-header-link span{display:none}}
@media(max-width:540px){.panel-founder-header-link{min-height:36px;padding:7px 8px}.account-security-shortcuts{width:100%}}
/* Master wallet V001: two independent game-themed artworks without changing dynamic balances. */
.wallet-stack > .wallet-card--kc {
    background:
        linear-gradient(90deg, rgba(4,10,18,.95) 0%, rgba(4,11,18,.84) 45%, rgba(4,11,18,.18) 100%),
        url('../images/site/account-wallet-kc-v001.webp') center center / cover no-repeat;
}
.wallet-stack > .wallet-card--gnb {
    background:
        linear-gradient(90deg, rgba(3,12,22,.95) 0%, rgba(3,13,23,.83) 45%, rgba(3,13,24,.18) 100%),
        url('../images/site/account-wallet-gnb-v001.webp') center center / cover no-repeat;
}
.wallet-stack > .wallet-card--kc::after,
.wallet-stack > .wallet-card--gnb::after { content: none; }
.wallet-stack > .wallet-card--kc > *,
.wallet-stack > .wallet-card--gnb > * {
    position: relative;
    z-index: 1;
    text-shadow: 0 1px 6px rgba(0,0,0,.52);
}
.wallet-stack > .wallet-card--kc p,
.wallet-stack > .wallet-card--gnb p { color: #b9c8d5; }
.wallet-stack > .wallet-card--kc small,
.wallet-stack > .wallet-card--gnb small { color: #a6bacc; }
@media (max-width: 560px) {
    .wallet-stack > .wallet-card--kc,
    .wallet-stack > .wallet-card--gnb {
        background-position: center center, 60% center;
    }
}
