.eg-mobile-auth-links, .eg-mobile-brand { display: none; }

@media (max-width: 767.98px) {
  :root { --eg-page-gutter: 14px; --eg-touch-size: 44px; }

  .eg-mobile-page .fixed-top { position: sticky; top: 0; }
  .eg-mobile-page .fixed-top .navbar {
    margin-bottom: 0 !important;
    padding: max(5px, env(safe-area-inset-top)) var(--eg-page-gutter) 5px;
  }
  .eg-mobile-page .navbar-brand { display: inline-flex; align-items: center; min-height: var(--eg-touch-size); margin: 0; padding: 0; }
  .eg-mobile-page .navbar-brand img { display: none; }
  .eg-mobile-brand { display: block; font-size: 20px; font-weight: 700; letter-spacing: .04em; }
  .eg-mobile-page .navbar-toggler { min-width: 48px; min-height: var(--eg-touch-size); border: 1px solid #ffffff48; border-radius: 8px; }
  .eg-mobile-page .navbar-collapse { max-height: 68vh; overflow-y: auto; overscroll-behavior: contain; }
  .eg-mobile-page #eg-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; margin: 6px 0 !important; }
  .eg-mobile-page .navbar-collapse .nav-link {
    display: flex; align-items: center; min-height: var(--eg-touch-size); padding: 6px 10px !important; border-radius: 7px;
  }
  .eg-mobile-page .navbar-collapse .nav-link.active { background: #ffffff20; }
  .eg-mobile-page #who-top { min-width: 0; overflow-wrap: anywhere; }

  .eg-mobile-page .home .section-summary { min-height: 0; padding: 12px 0 max(24px, env(safe-area-inset-bottom)); }
  .eg-mobile-page .section-summary > .container { max-width: none; padding-right: var(--eg-page-gutter); padding-left: var(--eg-page-gutter); }
  .eg-mobile-page .section-summary > .container > .row { margin: 0; }
  .eg-mobile-page .section-summary > .container > .row > [class*="col-"] { padding-right: 0; padding-left: 0; }
  .eg-mobile-page .section-summary > .container > .row > .pt-4 { padding-top: 4px !important; }
  .eg-mobile-page h1 { font-size: 24px !important; line-height: 1.25; }
  .eg-mobile-page :is(.home, .home p, .home label, footer, .eg-mobile-brand) {
    font-family: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  }
  .eg-mobile-page :where(button.btn, a.btn, input:not([type=checkbox]):not([type=radio]), select, textarea) {
    min-height: var(--eg-touch-size);
  }
  .eg-mobile-page :is(.home, dialog) :is(input:not([type=checkbox]):not([type=radio]), select, textarea) { font-size: 16px !important; }
  .eg-mobile-page .btn { white-space: normal; line-height: 1.3; padding: 9px 12px; }
  .eg-mobile-page a.btn { display: inline-flex; align-items: center; justify-content: center; }
  .eg-mobile-page [hidden] { display: none !important; }
  .eg-mobile-page :is(a, button, input, select, summary):focus-visible { outline: 2px solid #f4d795; outline-offset: 2px; }

  .eg-home-page .eg-mobile-auth-links { display: flex; justify-content: center; gap: 8px; margin: 0 0 14px; }
  .eg-mobile-auth-links a {
    display: flex; align-items: center; justify-content: center; min-height: var(--eg-touch-size);
    flex: 1; max-width: 180px; border: 1px solid #ffffff38; border-radius: 9px; color: #fff; background: #232b3d;
  }
  .eg-mobile-auth-links a:first-child { background: #315e88; }
  .eg-home-page :is(#card-login, #card-register) { scroll-margin-top: 64px; }
  .eg-home-page :is(#card-login, #card-register) > div { border-radius: 12px; }
  .eg-home-page :is(#login-form, #reg-form, #panel form) { padding: 16px !important; }
  .eg-home-page :is(#login-form, #reg-form) .md-form { text-align: left; margin-top: 12px; }
  .eg-home-page :is(#login-form, #reg-form) .md-form label {
    position: static; display: block; transform: none !important; pointer-events: auto;
    color: #fff; font-size: 13px !important; text-align: left; margin: 0 0 5px;
  }
  .eg-home-page :is(#login-form, #reg-form) .md-form { display: flex; flex-direction: column; }
  .eg-home-page :is(#login-form, #reg-form) .md-form label { order: -1; }
  .eg-home-page :is(#login-form, #reg-form) .md-form input.form-control {
    margin: 0 !important; padding: 8px 10px; height: auto; border: 1px solid #ffffff80;
    border-radius: 8px; box-sizing: border-box; background: #18112952; color: #fff;
  }
  .eg-home-page :is(#login-form, #reg-form) input::placeholder { color: #eee2ffbf; }
  .eg-home-page :is(#login-form, #reg-form) .h4 { margin-bottom: 14px !important; }
  .eg-home-page :is(#login-form, #reg-form) button[type=submit] { margin: 16px 0 12px !important; border-radius: 8px; }
  .eg-home-page #cap-box { margin-top: 8px; }
  .eg-home-page #cap-img { min-height: var(--eg-touch-size); max-width: 100%; object-fit: contain; }
  .eg-home-page #cap-refresh { display: inline-flex; align-items: center; min-height: var(--eg-touch-size); }

  .eg-player-page #page-note { font-size: 13px; line-height: 1.45; color: #dce4ed; margin: 5px 0 12px !important; }
  .eg-player-page #eg-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; }
  .eg-player-page #eg-tabs .nav-item { flex: 1 0 22%; margin: 0; min-width: 0; }
  .eg-player-page #eg-tabs .nav-link {
    display: flex; align-items: center; justify-content: center; min-height: var(--eg-touch-size);
    padding: 5px 3px; background: #202638; color: #eff2f9; border: 1px solid #ffffff33;
    border-radius: 8px; font-size: 13px; line-height: 1.25; transition: none;
  }
  .eg-player-page #eg-tabs .nav-link.active { background: #336a99; border-color: #91bee3; }
  .eg-player-page #view { min-width: 0; overflow-wrap: anywhere; }
  .eg-player-page .eg-card, .eg-player-page .eg-member-hero { padding: 12px; margin-bottom: 12px; border-radius: 10px; background-color: #252431eb; }
  .eg-player-page .eg-card h5 small { display: block; margin: 4px 0 0; line-height: 1.5; }
  .eg-player-page .eg-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  .eg-player-page .eg-stat { min-width: 0; max-width: none; border-radius: 7px; padding: 7px 3px; }
  .eg-player-page .eg-stat .v { font-size: clamp(14px, 4vw, 17px); font-variant-numeric: tabular-nums; }
  .eg-player-page .eg-stat .k { letter-spacing: 0; }
  .eg-player-page .eg-badge { white-space: normal; }
  .eg-player-page .eg-table:not(.eg-rune-list) { table-layout: fixed; }
  .eg-player-page .eg-table th, .eg-player-page .eg-table td { padding: 7px 5px; overflow-wrap: anywhere; }
  .eg-player-page .eg-table th { font-size: 11px; letter-spacing: 0; }
  .eg-player-page .eg-sub { display: flex; }
  .eg-player-page .eg-sub button { flex: 1; min-width: 0; padding: 4px; min-height: var(--eg-touch-size); font-size: 13px; }
  .eg-player-page .eg-filters { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 7px; align-items: center; }
  .eg-player-page .eg-filters label { margin: 0; }
  .eg-player-page .eg-filters :is(input, select) { min-width: 0; width: 100%; max-width: none !important; border-radius: 7px; }
  .eg-player-page .eg-filters > :is(button, .eg-note) { grid-column: 1 / -1; }
  .eg-player-page .eg-filters > :is(input, select):first-child { grid-column: 1 / -1; }
  .eg-player-page .eg-slot { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: center; }
  .eg-player-page .eg-slot .tag { grid-column: 1 / -1; }
  .eg-player-page .eg-slot :is(select, input[type=number]) { width: 100%; min-width: 0; max-width: none; border-radius: 7px; }
  .eg-player-page .eg-pager button, .eg-player-page .eg-pager-nav .page-link { min-height: var(--eg-touch-size); min-width: var(--eg-touch-size); }
  .eg-player-page .eg-pager-nav .pagination { flex-wrap: wrap; gap: 4px; }
  .eg-player-page .eg-pager-nav .page-link { display: grid; place-items: center; margin: 0; padding: 4px; }

  .eg-rune-list thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .eg-rune-list, .eg-rune-list tbody { display: block; }
  .eg-rune-list tbody tr {
    display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 8px; padding: 6px 8px; background: #181924; border: 1px solid #ffffff24; border-radius: 8px;
  }
  .eg-player-page .eg-rune-list td { display: block; border: 0; padding: 4px 6px; text-align: left; }
  .eg-rune-list td:first-child { grid-column: 1 / -1; font-weight: 650; border-bottom: 1px solid #ffffff24; }
  .eg-rune-list td[data-label]::before { display: block; content: attr(data-label); color: #d1c7df; font-size: 11px; }

  .eg-player-page #oc-result .eg-meg-col { padding-right: 5px; padding-left: 5px; }
  .eg-player-page #oc-result > .row { margin: 0 -5px; }
  .eg-player-page #oc-result .card { margin: 0 0 8px !important; border-radius: 9px; }
  .eg-player-page #oc-result summary {
    display: grid; grid-template-columns: 60px minmax(0, 1fr); gap: 3px 10px; align-items: center;
    padding: 10px; min-height: 80px !important; text-align: left !important; list-style: none;
  }
  .eg-player-page #oc-result summary::-webkit-details-marker { display: none; }
  .eg-player-page #oc-result summary > div:first-child { grid-row: span 2; height: 58px !important; }
  .eg-player-page #oc-result summary > div { min-height: 0 !important; margin: 0 !important; }
  .eg-player-page #oc-result summary > div:last-child { font-size: 12px; color: #f0d9a9; }
  .eg-player-page #oc-result summary > div:last-child::after { content: ' ▾'; }
  .eg-player-page #oc-result details[open] summary > div:last-child::after { content: ' ▴'; }
  .eg-player-page #oc-result summary :is(.portrait, .eg-noart) { width: 58px; height: 58px; object-fit: contain; }
  .eg-player-page #oc-result .card-body { padding: 10px; }
  .eg-player-page #oc-result .card-body p { margin: 0 0 5px; }

  .eg-player-page .market-heading, .eg-player-page .market-filters { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; padding: 8px; margin-bottom: 9px; }
  .eg-player-page .market-toolbar { display: flex; gap: 4px; }
  .eg-player-page .market-toolbar .btn {
    flex: 1; margin: 0; min-width: 0; padding: 4px; font-size: 12px; transition: none;
    border: 1px solid #bd9b697d !important; border-radius: 6px; color: #fff0d4 !important;
  }
  .eg-player-page .market-toolbar [aria-pressed="true"] {
    color: #241726 !important; background: #efc476 !important; border-color: #efc476 !important;
  }
  .eg-player-page .market-search { flex-wrap: nowrap; }
  .eg-player-page .market-search input { width: 100%; min-width: 0; flex: 1; }
  .eg-player-page .market-search .btn { flex: none; margin: 0; }
  .eg-player-page .market-wallet { font-size: 13px; }
  .eg-player-page .market-shelves { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .eg-player-page .market-portrait { height: 104px; }
  .eg-player-page .market-rune-art { --rune-picture-size: 76px; }
  .eg-player-page .market-item-body { padding: 8px; }
  .eg-player-page .market-item-body h3 { font-size: 14px; }
  .eg-player-page .market-stats div { padding: 4px 2px; gap: 4px; }
  .eg-player-page .market-stats dd { overflow-wrap: normal; }
  .eg-player-page .market-actions { padding: 5px; gap: 4px; }
  .eg-player-page :is(.market-actions, .market-price-form) .btn { width: 100%; margin: 0; }
  .eg-player-page .market-price-form label { width: 100%; justify-content: space-between; }
  .eg-player-page .market-price-form input { width: min(100%, 5.2rem); }
  .eg-player-page .market-more summary { display: flex; align-items: center; min-height: var(--eg-touch-size); }
  .eg-player-page .market-more summary::after { content: ' ▾'; }
  .eg-player-page .market-more[open] summary::after { content: ' ▴'; }

  .eg-player-page .eg-points-product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 10px 0 16px; }
  .eg-player-page .eg-points-product { min-width: 0; padding: 10px 7px; }
  .eg-player-page .eg-points-product > p { margin: 8px 0; }
  .eg-player-page .eg-points-thumbnail { width: 66px; height: 66px; border-radius: 12px; }
  .eg-player-page .eg-points-thumbnail > img { width: 56px; height: 56px; }
  .eg-player-page .eg-points-quantity { justify-content: flex-start; width: 100%; }
  .eg-player-page .eg-points-quantity label { flex: 1; min-width: 0; }
  .eg-player-page .eg-points-quantity input { width: 100%; min-width: 0; }
  .eg-player-page .eg-points-balance { display: block; margin-left: 0; }
  .eg-player-page .points-member-panel > summary { min-height: var(--eg-touch-size); }

  .eg-download-page section { padding: 16px !important; border-radius: 12px; }
  .eg-download-page section .btn { width: 100%; max-width: 360px; margin: 0 0 8px; }

  .eg-admin-page #admin-wrap :is(.section-light, .indigo) .p-4, .eg-admin-page #admin-wrap > .p-4 { padding: 14px !important; }
  .eg-admin-page #admin-wrap .form-row > .form-group { flex: 1 0 100%; max-width: 100%; padding-bottom: 8px; }
  .eg-admin-page #admin-wrap .table-responsive { overflow-x: auto; overscroll-behavior-inline: contain; }
  .eg-admin-page #admin-wrap .eg-adm-table:not(.eg-user-table) { min-width: 420px; }
  .eg-admin-page #admin-wrap select.form-control { height: auto; }
  .eg-admin-page #admin-wrap .mail-controls { gap: 8px; }
  .eg-admin-page #admin-wrap .mail-controls label { min-width: 0; max-width: 100%; }
  .eg-admin-page #admin-wrap .mail-controls input:not([type=checkbox]), .eg-admin-page #admin-wrap .mail-controls select { max-width: 100%; }
  .eg-admin-page #admin-wrap .eg-fold-btn, .eg-admin-page #admin-wrap summary { min-height: var(--eg-touch-size); }
  .eg-admin-page dialog { width: calc(100% - 2 * var(--eg-page-gutter)); max-width: 400px; max-height: 85vh; padding: 16px !important; overflow-y: auto; }

  .eg-admin-page .eg-user-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .eg-admin-page .eg-user-table, .eg-admin-page .eg-user-table tbody { display: block; }
  .eg-admin-page .eg-user-table tbody tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); text-align: left; margin: 0 0 8px; padding: 6px; border: 1px solid #ffffff35; border-radius: 8px; }
  .eg-admin-page #admin-wrap .eg-user-table tbody td { display: block; text-align: left !important; border-right: 0; padding: 4px; overflow-wrap: anywhere; }
  .eg-admin-page .eg-user-table tbody td[data-label]::before { display: block; content: attr(data-label); color: #f5e9ff; font-size: 11px; opacity: .85; }
  .eg-admin-page .eg-user-table tbody td:is(:first-child, :last-child) { grid-column: 1 / -1; }
  .eg-admin-page .eg-user-table tbody td:last-child { white-space: normal !important; }
  .eg-admin-page .eg-user-table button { margin: 2px; }
}

@media (max-width: 359.98px) {
  .eg-player-page .market-shelves { grid-template-columns: minmax(0, 1fr); }
  .eg-player-page .eg-points-quantity { gap: 4px; }
}
