/* ==========================================================================
   Cpudb — v2 design system
   ========================================================================== */

:root {
    --bg: #f5f6f8;
    --surface: #ffffff;
    --surface-2: #f7f8fa;
    --surface-3: #eef0f4;
    --border: #e9ebef;
    --border-2: #dde1e8;
    --ink: #1b2330;
    --ink-2: #4d5768;
    --ink-3: #8b95a6;
    --brand: #2563eb;
    --brand-2: #1d4ed8;
    --brand-soft: #eaf1ff;
    --brand-line: #cddffc;
    --navy: #0c1b2e;
    --navy-2: #12233a;
    --gold: #f5a524;
    --ok: #16a34a;
    --danger: #e5484d;
    --radius-lg: 14px;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow-1: 0 1px 2px rgba(20, 28, 44, 0.04);
    --shadow-2: 0 12px 28px -18px rgba(20, 28, 44, 0.3);
    --wrap: 1180px;
    --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
        'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans CJK SC', 'Source Han Sans SC',
        'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
}

[data-theme="dark"] {
    --bg: #0a1018;
    --surface: #111926;
    --surface-2: #0d1520;
    --surface-3: #17202e;
    --border: #1d2735;
    --border-2: #2a3646;
    --ink: #e8eef8;
    --ink-2: #a6b2c4;
    --ink-3: #78859a;
    --brand: #4b8dff;
    --brand-2: #2f74f0;
    --brand-soft: #152540;
    --brand-line: #26456f;
    --shadow-1: 0 1px 2px rgba(0, 0, 0, 0.35);
    --shadow-2: 0 14px 30px -18px rgba(0, 0, 0, 0.75);
}

/* ---------- base ---------- */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font);
    font-size: 14.5px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}

a,
button,
select,
input,
textarea {
    -webkit-tap-highlight-color: transparent;
}

h1, h2, h3, h4, p, figure {
    margin: 0;
}

a {
    color: inherit;
    text-decoration: none;
}

img, svg {
    max-width: 100%;
}

img {
    display: block;
    height: auto;
}

button {
    font-family: inherit;
}

ul, ol {
    margin: 0;
    padding: 0;
}

:focus-visible {
    outline: 2px solid var(--brand);
    outline-offset: 2px;
    border-radius: 4px;
}

.hidden {
    display: none !important;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    left: 16px;
    top: -60px;
    z-index: 200;
    padding: 10px 16px;
    border-radius: 8px;
    background: var(--brand);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    transition: top 0.2s;
}

.skip-link:focus {
    top: 12px;
}

.wrap {
    width: 100%;
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 0 20px;
}

.main {
    min-height: 62vh;
    padding-bottom: 40px;
}

.mt-1 { margin-top: 6px; }
.mt-3 { margin-top: 14px; }
.mt-4 { margin-top: 20px; }
.mb-4 { margin-bottom: 20px; }
.text-2 { color: var(--ink-3); font-size: 13px; line-height: 1.7; }
.stack-sm > * + * { margin-top: 12px; }
.stack-lg > * + * { margin-top: 20px; }

/* ---------- buttons ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 38px;
    padding: 0 16px;
    border: 1px solid var(--border-2);
    border-radius: 9px;
    background: var(--surface);
    color: var(--ink);
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: background 0.16s, border-color 0.16s, color 0.16s;
    white-space: nowrap;
}

.btn:hover {
    border-color: var(--brand);
    color: var(--brand);
}

.btn-primary {
    background: var(--brand);
    border-color: var(--brand);
    color: #fff;
}

.btn-primary:hover {
    background: var(--brand-2);
    border-color: var(--brand-2);
    color: #fff;
}

.btn-ghost {
    background: transparent;
    border-color: transparent;
    color: var(--ink-2);
}

.btn-ghost:hover {
    background: var(--surface-2);
    border-color: var(--border);
    color: var(--ink);
}

.btn-sm {
    height: 32px;
    padding: 0 12px;
    font-size: 12.5px;
    border-radius: 8px;
}

.btn.is-disabled {
    opacity: 0.45;
    pointer-events: none;
}

/* ---------- header ---------- */

.site-header {
    position: sticky;
    top: 0;
    z-index: 80;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}

[data-theme="dark"] .site-header {
    background: rgba(17, 25, 38, 0.95);
    backdrop-filter: blur(12px);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 26px;
    height: 60px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    flex: none;
    font-size: 16.5px;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--ink);
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: linear-gradient(145deg, #4a8cff, #1f5fd8);
    color: #fff;
}

.brand-mark svg {
    width: 27px;
    height: 27px;
}

.brand-name {
    white-space: nowrap;
}

.nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link {
    padding: 7px 11px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--ink-2);
    white-space: nowrap;
    transition: background 0.16s, color 0.16s;
}

.nav-link:hover {
    background: var(--surface-2);
    color: var(--ink);
}

.nav-link.active {
    color: var(--brand);
    font-weight: 600;
}

.header-tools {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
}

.header-search {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 250px;
    height: 36px;
    padding: 0 12px;
    border: 1px solid var(--border-2);
    border-radius: 9px;
    background: var(--surface-2);
    transition: border-color 0.16s, background 0.16s, box-shadow 0.16s;
}

.header-search:focus-within {
    background: var(--surface);
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--brand-soft);
}

.hs-icon {
    width: 15px;
    height: 15px;
    flex: none;
    color: var(--ink-3);
}

.header-search input {
    flex: 1;
    min-width: 0;
    height: 100%;
    border: 0;
    background: none;
    color: var(--ink);
    font-size: 13px;
    outline: none;
}

.icon-btn {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 9px;
    background: none;
    color: var(--ink-2);
    cursor: pointer;
    transition: background 0.16s, color 0.16s;
}

.icon-btn:hover {
    background: var(--surface-2);
    color: var(--brand);
}

.icon-btn svg {
    width: 17px;
    height: 17px;
}

.icon-xs {
    width: 11px;
    height: 11px;
}

[data-theme="light"] .icon-sun,
[data-theme="dark"] .icon-moon {
    display: none;
}

.menu {
    position: relative;
}

.menu-trigger {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 36px;
    padding: 0 9px;
    border: 0;
    border-radius: 9px;
    background: none;
    color: var(--ink-2);
    font-size: 12.5px;
    font-weight: 500;
    cursor: pointer;
}

.menu-trigger:hover {
    background: var(--surface-2);
    color: var(--ink);
}

.menu-panel {
    position: absolute;
    right: 0;
    top: calc(100% + 6px);
    min-width: 148px;
    padding: 6px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    box-shadow: var(--shadow-2);
    z-index: 90;
}

.menu-item {
    display: block;
    padding: 8px 10px;
    border-radius: 7px;
    font-size: 13px;
    color: var(--ink-2);
}

.menu-item:hover {
    background: var(--surface-2);
    color: var(--ink);
}

.menu-item.active {
    background: var(--brand-soft);
    color: var(--brand);
    font-weight: 600;
}

.mobile-toggle {
    display: none;
}

.mobile-nav {
    display: none;
    flex-direction: column;
    gap: 2px;
    padding: 12px 20px 18px;
    border-top: 1px solid var(--border);
}

.mobile-nav.open {
    display: flex;
}

.mobile-link {
    padding: 10px 2px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
    color: var(--ink-2);
}

.mobile-link.active {
    color: var(--brand);
    font-weight: 600;
}

.mobile-search {
    width: 100%;
    margin-bottom: 8px;
}

.mobile-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 14px;
}

/* ---------- chips / tags ---------- */

.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.chips-sm {
    gap: 6px;
}

.chip {
    display: inline-flex;
    align-items: center;
    height: 30px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface);
    color: var(--ink-2);
    font-size: 12.5px;
    font-weight: 500;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.chip:hover {
    border-color: var(--brand-line);
    color: var(--brand);
}

.chip.active {
    background: var(--brand);
    border-color: var(--brand);
    color: #fff;
    font-weight: 600;
}

.chips-sm .chip {
    height: 28px;
    padding: 0 11px;
    font-size: 12px;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 7px;
    border: 1px solid var(--border);
    border-radius: 5px;
    background: var(--surface-2);
    color: var(--ink-2);
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.tag-brand {
    background: var(--brand-soft);
    border-color: var(--brand-line);
    color: var(--brand);
}

.badge {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 5px;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 11px;
    font-weight: 700;
}

/* ---------- breadcrumb / page head ---------- */

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    padding: 18px 0 12px;
    font-size: 12.5px;
    color: var(--ink-3);
}

.breadcrumb a {
    color: var(--ink-3);
}

.breadcrumb a:hover {
    color: var(--brand);
}

.breadcrumb .sep {
    opacity: 0.55;
}

.breadcrumb > span:last-child {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--ink-2);
}

.page-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.page-head h1 {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.page-head .lead {
    margin-top: 4px;
    color: var(--ink-3);
    font-size: 13px;
}

/* ---------- hero ---------- */

.hero {
    margin-top: 20px;
    border-radius: var(--radius-lg);
    background:
        radial-gradient(700px 320px at 82% -30%, rgba(59, 130, 246, 0.28), transparent 65%),
        linear-gradient(120deg, #0b1a2c 0%, #0f2539 60%, #123049 100%);
    color: #fff;
    overflow: hidden;
}

.hero-inner {
    padding: 38px 40px 34px;
}

.hero-title {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.3;
}

.hero-sub {
    margin-top: 8px;
    max-width: 42em;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.62);
}

.hero-search {
    display: flex;
    align-items: center;
    gap: 8px;
    width: min(620px, 100%);
    margin-top: 22px;
    padding: 5px 5px 5px 14px;
    border-radius: 10px;
    background: #fff;
}

.hero-search input {
    flex: 1;
    min-width: 0;
    height: 36px;
    border: 0;
    background: none;
    color: #16202e;
    font-size: 13.5px;
    outline: none;
}

.hero-search input::placeholder {
    color: #98a3b3;
}

.hero-search input::-webkit-search-cancel-button {
    -webkit-appearance: none;
    appearance: none;
}

[data-theme="dark"] .hero-search {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.16);
    transition: border-color 0.16s, background 0.16s;
}

[data-theme="dark"] .hero-search:focus-within {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(140, 180, 255, 0.55);
}

[data-theme="dark"] .hero-search input {
    color: #ffffff;
}

[data-theme="dark"] .hero-search input::placeholder {
    color: rgba(255, 255, 255, 0.46);
}

[data-theme="dark"] .btn-hero {
    background: linear-gradient(180deg, #3d7bff 0%, #2a5fe0 100%);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 6px 16px -8px rgba(61, 123, 255, 0.9);
}

[data-theme="dark"] .btn-hero:hover {
    background: linear-gradient(180deg, #4d87ff 0%, #3168ea 100%);
}

[data-theme="dark"] .btn-hero:active {
    background: #2a5fe0;
}

[data-theme="dark"] :focus-visible {
    outline-color: rgba(255, 255, 255, 0.7);
}

.btn-hero {
    height: 36px;
    padding: 0 22px;
    border: 0;
    border-radius: 7px;
    background: var(--brand);
    color: #fff;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    flex: none;
    transition: background 0.16s;
}

.btn-hero:hover {
    background: var(--brand-2);
}

/* ---------- brand strip ---------- */

.brand-strip {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    margin-top: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
    overflow: hidden;
}

.brand-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 13px 10px;
    border-left: 1px solid var(--border);
    transition: background 0.16s;
}

.brand-item:first-child {
    border-left: 0;
}

.brand-item:hover {
    background: var(--surface-2);
}

.brand-logo {
    display: grid;
    place-items: center;
    width: 26px;
    height: 26px;
    flex: none;
    border-radius: 7px;
    background: var(--surface-3);
    color: var(--ink-2);
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
    overflow: hidden;
}

.brand-logo svg {
    width: 15px;
    height: 15px;
}

.brand-logo.brand-amd { background: #fff0ee; color: #d92d20; }
.brand-logo.brand-intel { background: #eaf3fd; color: #0a68b5; }
.brand-logo.brand-nvidia { background: #f1f9e4; color: #5a9e06; }
.brand-logo.brand-apple { background: var(--surface-3); color: var(--ink-2); }
.brand-logo.brand-generic { background: var(--surface-3); color: var(--ink-2); }

[data-theme="dark"] .brand-logo.brand-amd { background: #33161a; color: #ff8d84; }
[data-theme="dark"] .brand-logo.brand-intel { background: #10243a; color: #6faee0; }
[data-theme="dark"] .brand-logo.brand-nvidia { background: #1c2a14; color: #9ac96b; }

.brand-text {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink-2);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ---------- sections / panels ---------- */

.section {
    margin-top: 26px;
}

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 12px;
}

.section-title {
    font-size: 17px;
    font-weight: 700;
    letter-spacing: -0.015em;
}

.section-more {
    font-size: 12.5px;
    color: var(--ink-3);
}

.section-more:hover {
    color: var(--brand);
}

.home-cols {
    display: grid;
    grid-template-columns: minmax(0, 1.18fr) minmax(0, 1fr);
    gap: 14px;
}

.panel {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
    overflow: hidden;
}

.panel-head {
    flex: none;
}

.hot-list,
.new-list,
.rank-body {
    flex: 1 1 auto;
}

.panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 48px;
    padding: 11px 16px;
    border-bottom: 1px solid var(--border);
}

.panel-title {
    flex: none;
    font-size: 14.5px;
    font-weight: 700;
    letter-spacing: -0.01em;
    white-space: nowrap;
}

.panel-link {
    font-size: 12px;
    color: var(--ink-3);
}

.panel-link:hover {
    color: var(--brand);
}

.panel-more {
    display: block;
    margin-top: auto;
    padding: 11px 16px;
    border-top: 1px solid var(--border);
    font-size: 12.5px;
    color: var(--brand);
    text-align: center;
}

.panel-more:hover {
    background: var(--surface-2);
}

/* hot compare */

.hot-list {
    padding: 4px 8px 8px;
}

.hot-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 8px;
    border-radius: 8px;
    transition: background 0.15s;
}

.hot-item + .hot-item {
    border-top: 1px solid var(--border);
}

.hot-item:hover {
    background: var(--surface-2);
}

.hot-side {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

.hot-side.is-right {
    justify-content: flex-end;
}

.hot-name {
    font-size: 13px;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.hot-vs {
    flex: none;
    padding: 1px 6px;
    border-radius: 4px;
    background: var(--surface-3);
    color: var(--ink-3);
    font-size: 9.5px;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.hot-arrow {
    flex: none;
    color: var(--ink-3);
    font-size: 15px;
    line-height: 1;
}

/* new releases */

.new-list {
    padding: 4px 8px 8px;
}

.new-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    border-radius: 8px;
    transition: background 0.15s;
}

.new-item + .new-item {
    border-top: 1px solid var(--border);
}

.new-item:hover {
    background: var(--surface-2);
}

.new-icon {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    flex: none;
    border-radius: 8px;
    background: var(--surface-3);
    color: var(--ink-2);
}

.new-icon svg {
    width: 17px;
    height: 17px;
}

.new-icon.brand-amd { background: #fff0ee; color: #d92d20; }
.new-icon.brand-intel { background: #eaf3fd; color: #0a68b5; }
.new-icon.brand-nvidia { background: #f1f9e4; color: #5a9e06; }

[data-theme="dark"] .new-icon.brand-amd { background: #33161a; color: #ff8d84; }
[data-theme="dark"] .new-icon.brand-intel { background: #10243a; color: #6faee0; }
[data-theme="dark"] .new-icon.brand-nvidia { background: #1c2a14; color: #9ac96b; }

.new-body {
    display: flex;
    flex-direction: column;
    gap: 1px;
    flex: 1;
    min-width: 0;
}

.new-name {
    font-size: 13px;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.new-meta {
    font-size: 11px;
    color: var(--ink-3);
}

.new-type {
    flex: none;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--ink-3);
}

/* ranking panel */

.rank-tabs {
    display: flex;
    flex: 0 1 auto;
    gap: 2px;
    min-width: 0;
    margin-left: auto;
    padding: 2px;
    border-radius: 7px;
    background: var(--surface-2);
    overflow-x: auto;
    scrollbar-width: none;
}

.rank-tabs::-webkit-scrollbar {
    display: none;
}

.rank-tab {
    padding: 4px 10px;
    border: 0;
    border-radius: 6px;
    background: none;
    color: var(--ink-3);
    font-size: 11.5px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.15s, color 0.15s;
}

.rank-tab:hover {
    color: var(--ink-2);
}

.rank-tab.active {
    background: var(--surface);
    color: var(--brand);
    box-shadow: var(--shadow-1);
}

.rank-body {
    display: flex;
    flex-direction: column;
    padding: 4px 8px 0;
}

.rank-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    border-radius: 8px;
    transition: background 0.15s;
}

.rank-item + .rank-item {
    border-top: 1px solid var(--border);
}

.rank-item:hover {
    background: var(--surface-2);
}

.rank-num {
    width: 20px;
    flex: none;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--ink-3);
    font-variant-numeric: tabular-nums;
}

.rank-num.is-top {
    color: var(--brand);
}

.rank-brand {
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    flex: none;
    border-radius: 5px;
    background: var(--surface-3);
    color: var(--ink-2);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.rank-brand.brand-amd { background: #fff0ee; color: #d92d20; }
.rank-brand.brand-intel { background: #eaf3fd; color: #0a68b5; }
.rank-brand.brand-nvidia { background: #f1f9e4; color: #5a9e06; }

.rank-name {
    flex: 1;
    min-width: 0;
    font-size: 12.5px;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-bar {
    width: 112px;
    height: 5px;
    flex: none;
    border-radius: 99px;
    background: var(--surface-3);
    overflow: hidden;
}

.rank-bar i {
    height: 100%;
    border-radius: 99px;
    background: linear-gradient(90deg, #6ba8ff, #2563eb);
}

.rank-val {
    width: 48px;
    flex: none;
    text-align: right;
    font-size: 12px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

/* promo */

.promo {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 210px;
    padding: 26px;
    border-radius: var(--radius);
    background:
        radial-gradient(360px 240px at 88% 30%, rgba(216, 60, 47, 0.45), transparent 70%),
        linear-gradient(135deg, #10202f 0%, #16232f 55%, #241517 100%);
    color: #fff;
    overflow: hidden;
}

.promo-badge {
    position: absolute;
    right: 12px;
    top: 12px;
    z-index: 2;
    padding: 1px 5px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 3px;
    font-size: 9px;
    color: rgba(255, 255, 255, 0.65);
}

.promo-art {
    position: absolute;
    right: -10px;
    top: 50%;
    width: 220px;
    height: 220px;
    transform: translateY(-50%);
    color: #ffffff;
}

.promo-body {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 7px;
    max-width: 62%;
}

.promo-brand {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.16em;
    color: #ff8b7e;
}

.promo-title {
    font-size: 19px;
    font-weight: 700;
    line-height: 1.35;
    letter-spacing: -0.01em;
}

.promo-text {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.55);
}

/* GPU 广告位：绿色系，与热门排行榜的红蓝配色区分 */
.promo-gpu {
    background:
        radial-gradient(360px 240px at 88% 30%, rgba(118, 185, 0, 0.42), transparent 70%),
        linear-gradient(135deg, #0b1a12 0%, #12241a 55%, #17301c 100%);
}

.promo-gpu .promo-brand {
    color: #a8e05f;
}

.promo-gpu .promo-art {
    color: #d6ffbe;
}

/* ---------- post cards ---------- */

.posts-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.post-card {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
    overflow: hidden;
    transition: border-color 0.16s, box-shadow 0.16s;
}

.post-card:hover {
    border-color: var(--brand-line);
    box-shadow: var(--shadow-2);
}

.post-cover {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    background: linear-gradient(150deg, #e8eefb, #f2f5fa);
    overflow: hidden;
}

[data-theme="dark"] .post-cover {
    background: linear-gradient(150deg, #16243a, #101d2e);
}

.post-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.post-card:hover .post-cover img {
    transform: scale(1.03);
}

.post-fallback {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #a8b8d0;
}

.post-fallback svg {
    width: 42px;
    height: 42px;
}

.post-body {
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 13px 14px 14px;
}

.post-cat,
.art-cat {
    align-self: flex-start;
    padding: 1px 7px;
    border-radius: 4px;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 10.5px;
    font-weight: 700;
}

.post-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.5;
}

.post-card:hover .post-title {
    color: var(--brand);
}

.post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: auto;
    font-size: 11px;
    color: var(--ink-3);
}

/* ---------- product visual ---------- */

.pv {
    position: relative;
    display: grid;
    place-items: center;
    aspect-ratio: 1 / 1;
    flex: none;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: linear-gradient(150deg, #f4f7fc, #eaeff7);
    overflow: hidden;
}

[data-theme="dark"] .pv {
    background: linear-gradient(150deg, #16243a, #101d2e);
    border-color: var(--border);
}

.pv-xxs { width: 28px; border-radius: 6px; }
.pv-xs { width: 38px; border-radius: 7px; }
.pv-sm { width: 56px; border-radius: 8px; }
.pv-md { width: 84px; border-radius: 10px; }
.pv-lg { width: 100%; max-width: 220px; border-radius: 12px; }

.pv-chip {
    width: 56%;
    height: 56%;
    margin-top: -4%;
    color: #9aabc4;
}

.pv-mono {
    position: absolute;
    bottom: 6%;
    font-size: 8.5px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #7e8ea6;
}

.pv-type {
    position: absolute;
    top: 5%;
    right: 5%;
    font-size: 7.5px;
    font-weight: 800;
    letter-spacing: 0.04em;
    color: #94a3b8;
}

.pv-xxs .pv-mono,
.pv-xxs .pv-type,
.pv-xs .pv-mono,
.pv-xs .pv-type {
    display: none;
}

.pv.brand-amd { background: linear-gradient(150deg, #fff4f1, #ffe6e0); border-color: #fbd8d0; }
.pv.brand-amd .pv-chip { color: #d92d20; }
.pv.brand-amd .pv-mono { color: #b83a2f; }

.pv.brand-intel { background: linear-gradient(150deg, #f2f8ff, #e2eefc); border-color: #d4e5f8; }
.pv.brand-intel .pv-chip { color: #0a68b5; }
.pv.brand-intel .pv-mono { color: #0d568f; }

.pv.brand-nvidia { background: linear-gradient(150deg, #f5fbe9, #eaf6d4); border-color: #dceec2; }
.pv.brand-nvidia .pv-chip { color: #5a9e06; }
.pv.brand-nvidia .pv-mono { color: #4c8407; }

[data-theme="dark"] .pv.brand-amd,
[data-theme="dark"] .pv.brand-intel,
[data-theme="dark"] .pv.brand-nvidia {
    background: linear-gradient(150deg, #16243a, #101d2e);
    border-color: var(--border);
}

/* ---------- list page ---------- */

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 10px 12px;
    padding: 4px 0 16px;
}

.filter-field {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.filter-field-growth {
    flex: 1 1 220px;
    margin-left: auto;
    max-width: 300px;
}

.filter-label {
    font-size: 11.5px;
    color: var(--ink-3);
}

.filter-field .select {
    width: 116px;
}

.filter-field-growth .input {
    width: 100%;
    height: 34px;
}

.btn-dark {
    background: var(--navy);
    border-color: var(--navy);
    color: #fff;
}

.btn-dark:hover {
    background: #16283d;
    border-color: #16283d;
    color: #fff;
}

.cat-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 26px;
    padding: 16px 0 2px;
}

.cat-link {
    font-size: 13px;
    line-height: 1.5;
    color: var(--ink-2);
    transition: color 0.15s;
}

.cat-link:hover {
    color: var(--brand);
}

.cat-link.active {
    color: var(--brand);
    font-weight: 600;
}

.cat-more {
    display: none;
}

.cat-count {
    margin-left: 5px;
    font-size: 11px;
    color: var(--ink-3);
}

.series-hero {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px 24px;
    margin-bottom: 16px;
    padding: 18px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
}

.series-intro {
    flex: 1 1 340px;
    margin: 0;
    max-width: 60ch;
    font-size: 13.5px;
    line-height: 1.75;
    color: var(--ink-2);
}

.series-stats {
    display: flex;
    flex: none;
    gap: 30px;
}

.series-stat {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.series-stat-label {
    font-size: 11.5px;
    color: var(--ink-3);
}

.series-stat-value {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.list-sort {
    display: flex;
    align-items: center;
    margin: 14px 0 12px;
}

.sort-form {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sort-label {
    font-size: 12.5px;
    color: var(--ink-3);
}

.select {
    height: 34px;
    padding: 0 30px 0 11px;
    border: 1px solid var(--border-2);
    border-radius: 8px;
    background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238b95a6' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center;
    -webkit-appearance: none;
    appearance: none;
    color: var(--ink);
    font-size: 12.5px;
    outline: none;
}

.select-sm {
    height: 32px;
}

.data-table {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
    overflow: hidden;
}

.data-head,
.data-row {
    display: grid;
    grid-template-columns: 48px minmax(0, 1.9fr) 76px 88px 88px 88px 68px 92px;
    align-items: center;
    gap: 10px;
    padding: 0 16px;
}

.data-head {
    height: 38px;
    border-bottom: 1px solid var(--border);
    font-size: 11.5px;
    font-weight: 500;
    color: var(--ink-3);
}

.data-row {
    min-height: 54px;
    border-bottom: 1px solid var(--border);
    transition: background 0.14s;
}

.data-row:last-child {
    border-bottom: 0;
}

.data-row:hover {
    background: var(--surface-2);
}

.cell-rank {
    font-size: 12.5px;
    font-weight: 500;
    color: var(--ink-3);
    font-variant-numeric: tabular-nums;
}

.cell-rank.is-top {
    color: var(--ink);
    font-weight: 700;
}

.cell-name {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.name-body {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
}

.name-main {
    font-size: 13.5px;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.data-row:hover .name-main {
    color: var(--brand);
}

.name-logo {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    flex: none;
    border-radius: 7px;
    background: #141b25;
    color: #fff;
}

.name-logo svg {
    width: 17px;
    height: 17px;
}

.name-logo.brand-amd {
    color: #ff6a5c;
}

.name-logo.brand-intel {
    color: #6fb3ff;
}

.name-logo.brand-nvidia {
    color: #9ede4a;
}

.name-sub {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 3px;
    font-size: 11px;
    color: var(--ink-3);
}

.cat-tag {
    display: inline-block;
    padding: 0 6px;
    border-radius: 4px;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 10px;
    font-weight: 600;
    line-height: 16px;
}

.cell-brand,
.cell-spec,
.cell-date {
    font-size: 12.5px;
    color: var(--ink-2);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cell-spec {
    font-variant-numeric: tabular-nums;
}

.cell-date {
    font-size: 12px;
    color: var(--ink-3);
}

.list-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 16px;
}

.list-foot .pagination {
    margin-top: 0;
    justify-content: flex-start;
}

.per-page {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-left: auto;
    font-size: 12px;
    color: var(--ink-3);
}

.empty {
    padding: 40px 20px;
    border: 1px dashed var(--border-2);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--ink-3);
    text-align: center;
    font-size: 13.5px;
}

.empty h1 {
    margin-bottom: 6px;
    color: var(--ink);
    font-size: 22px;
}

.card-body.empty {
    border: 0;
    background: none;
}

/* pagination */

.pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 5px;
    margin-top: 20px;
}

.page {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 9px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: var(--surface);
    color: var(--ink-2);
    font-size: 12.5px;
    transition: border-color 0.15s, color 0.15s;
}

.page:hover {
    border-color: var(--brand);
    color: var(--brand);
}

.page.active {
    background: var(--brand);
    border-color: var(--brand);
    color: #fff;
    font-weight: 600;
}

.page.disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* ---------- cards ---------- */

.card {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
    overflow: hidden;
}

.card + .card {
    margin-top: 14px;
}

/* 栅格内的卡片间距由 gap 控制，避免第二张被额外顶下去 */
.compare-layout > .card + .card,
.grid-2 > .card + .card,
.grid-3 > .card + .card,
.rank-grid > .card + .card {
    margin-top: 0;
}

.card-body {
    padding: 18px;
}

.card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border);
}

.card-head-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}

.card-title {
    font-size: 14px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.card-note {
    font-size: 11.5px;
    color: var(--ink-3);
}

.card-link {
    font-size: 11.5px;
    letter-spacing: .08em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--brand);
}

.card-link:hover {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.card-foot {
    padding: 13px 16px;
    border-top: 1px solid var(--border);
    background: var(--surface-2);
}

.card-foot .chips {
    margin-top: 8px;
}

.card-head .section-title {
    font-size: 14px;
}

/* ---------- detail page ---------- */

.detail-hero {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 24px;
    padding: 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
}

.detail-gallery {
    position: relative;
    display: grid;
    place-items: center;
    aspect-ratio: 1 / 1;
    border-radius: 10px;
    background: linear-gradient(150deg, #12233a, #0b1a2c);
    color: rgba(255, 255, 255, 0.85);
    overflow: hidden;
}

.detail-gallery svg {
    width: 52%;
    height: 52%;
    color: rgba(120, 170, 255, 0.55);
}

.detail-gallery.brand-amd {
    background: linear-gradient(150deg, #2a1114, #140a0b);
}

.detail-gallery.brand-amd svg { color: rgba(230, 70, 55, 0.65); }

.detail-gallery.brand-intel {
    background: linear-gradient(150deg, #0d1f33, #08131f);
}

.detail-gallery.brand-intel svg { color: rgba(70, 150, 225, 0.65); }

.gallery-img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-label {
    position: absolute;
    left: 12px;
    bottom: 10px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.55);
}

.gallery-type {
    position: absolute;
    right: 12px;
    top: 10px;
    padding: 1px 6px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: rgba(255, 255, 255, 0.6);
}

.detail-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.detail-brand {
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--brand);
}

.detail-title {
    margin: 5px 0 12px;
    font-size: 25px;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.spec-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.spec-chip {
    display: inline-flex;
    align-items: baseline;
    gap: 5px;
    padding: 4px 9px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--surface-2);
    font-size: 12px;
    color: var(--ink-3);
}

.spec-chip b {
    color: var(--ink);
    font-weight: 600;
}

.spec-chip-label {
    font-size: 11px;
    color: var(--ink-3);
}

.detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
}

.share-qr {
    text-align: center;
}

.share-qr-canvas {
    display: inline-block;
    padding: 8px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid var(--border);
    line-height: 0;
}

.share-qr-canvas img,
.share-qr-canvas canvas {
    display: block;
    width: 200px;
    height: 200px;
}

.share-qr-tip {
    margin: 10px 0 0;
    font-size: 12.5px;
    color: var(--ink-3);
}

.share-links {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.share-links a {
    flex: 1;
    padding: 9px 0;
    text-align: center;
    border-radius: 10px;
    font-size: 13px;
    text-decoration: none;
    border: 1px solid transparent;
    transition: transform 0.15s;
}

.share-links a:hover {
    transform: translateY(-1px);
}

.share-links a[data-share="qzone"] {
    color: #b07a00;
    background: rgba(245, 183, 61, 0.14);
    border-color: rgba(245, 183, 61, 0.35);
}

.share-links a[data-share="weibo"] {
    color: #d21f34;
    background: rgba(230, 22, 45, 0.09);
    border-color: rgba(230, 22, 45, 0.28);
}

[data-theme="dark"] .share-links a[data-share="qzone"] {
    color: #fbbf24;
}

[data-theme="dark"] .share-links a[data-share="weibo"] {
    color: #fb7185;
}

.fav-icon {
    width: 14px;
    height: 14px;
}

[data-favorite].is-on {
    color: #e5484d;
}

[data-favorite].is-on .fav-icon {
    fill: currentColor;
}

.tabbar {
    display: flex;
    gap: 2px;
    margin-top: 16px;
    border-bottom: 1px solid var(--border);
    overflow-x: auto;
    scrollbar-width: none;
}

.tabbar::-webkit-scrollbar {
    display: none;
}

.tabbar .tab {
    position: relative;
    padding: 10px 13px;
    border: 0;
    background: none;
    color: var(--ink-3);
    font-size: 13.5px;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
}

.tabbar .tab:hover {
    color: var(--ink);
}

.tabbar .tab.active {
    color: var(--brand);
}

.tabbar .tab.active::after {
    content: "";
    position: absolute;
    left: 11px;
    right: 11px;
    bottom: -1px;
    height: 2px;
    border-radius: 2px;
    background: var(--brand);
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    margin-top: 14px;
}

.detail-main > .card + .card {
    margin-top: 14px;
}

.detail-side {
    position: sticky;
    top: 76px;
}

.spec-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 22px;
    padding: 6px 16px 12px;
}

.spec-cell {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px dashed var(--border);
    min-width: 0;
}

.spec-label {
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
    font-size: 12.5px;
    color: var(--ink-3);
}

.spec-value {
    font-size: 12.5px;
    font-weight: 600;
    text-align: right;
    word-break: break-word;
}

.spec-value a {
    color: var(--brand);
}

.desc-btn {
    width: 14px;
    height: 14px;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--border-2);
    border-radius: 50%;
    background: none;
    color: var(--ink-3);
    font-size: 8.5px;
    font-style: italic;
    font-weight: 700;
    cursor: pointer;
}

.desc-btn.active {
    border-color: var(--brand);
    color: var(--brand);
}

.desc-text {
    flex-basis: 100%;
    padding: 6px 9px;
    border-radius: 6px;
    background: var(--surface-2);
    font-size: 11.5px;
    line-height: 1.6;
    color: var(--ink-3);
}

/* 参数说明弹层（fixed 定位，避免被 .card 的 overflow 裁切） */
.spec-pop {
    position: fixed;
    z-index: 200;
    max-width: min(280px, calc(100vw - 32px));
    padding: 9px 11px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: 0 18px 40px -18px rgba(13, 21, 36, 0.55);
    font-size: 11.5px;
    line-height: 1.65;
    color: var(--ink-2);
    pointer-events: none;
}

.bench-list {
    padding: 8px 16px 14px;
}

.bench-row {
    display: grid;
    grid-template-columns: minmax(0, 108px) minmax(0, 1fr) 52px;
    align-items: center;
    gap: 10px;
    padding: 7px 0;
    font-size: 12.5px;
}

.bench-name {
    color: var(--ink-2);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bench-track {
    position: relative;
    display: block;
    height: 7px;
    border-radius: 99px;
    background: var(--surface-3);
    overflow: hidden;
}

.bench-fill {
    height: 100%;
    border-radius: 99px;
    background: linear-gradient(90deg, #6ba8ff, #2563eb);
}

.bench-fill.is-alt {
    background: linear-gradient(90deg, #b9d3ff, #7fadf7);
}

.bench-value {
    text-align: right;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.pos-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 14px 16px 16px;
}

.pos-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 6px;
}

.pos-name {
    font-size: 12.5px;
    color: var(--ink-2);
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.pos-badge {
    flex: none;
    padding: 1px 6px;
    border-radius: 4px;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 10.5px;
    font-weight: 700;
}

.pos-track {
    display: block;
    height: 6px;
    border-radius: 99px;
    background: var(--surface-3);
    overflow: hidden;
}

.pos-track i {
    height: 100%;
    border-radius: 99px;
    background: linear-gradient(90deg, #6ba8ff, #2563eb);
}

.pos-meta {
    display: block;
    margin-top: 5px;
    font-size: 11px;
    color: var(--ink-3);
}

.rel-list {
    padding: 4px 8px 8px;
}

.rel-item {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px;
    border-radius: 8px;
}

.rel-item + .rel-item {
    border-top: 1px solid var(--border);
}

.rel-item:hover {
    background: var(--surface-2);
}

.rel-body {
    display: flex;
    flex-direction: column;
    gap: 1px;
    flex: 1;
    min-width: 0;
}

.rel-name {
    font-size: 12.5px;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rel-date {
    font-size: 11px;
    color: var(--ink-3);
}

.rel-arrow {
    color: var(--ink-3);
    font-size: 14px;
}

.detail-side .rank-list {
    padding: 4px 8px 8px;
}

.rank-list {
    padding: 4px 8px 8px;
}

.rank-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    border-radius: 8px;
    font-size: 12.5px;
    color: var(--ink-2);
}

a.rank-row:hover {
    background: var(--surface-2);
    color: var(--ink);
}

.rank-row.current {
    background: var(--brand-soft);
    color: var(--brand);
    font-weight: 600;
}

.rank-no {
    width: 20px;
    flex: none;
    text-align: center;
    font-size: 11.5px;
    font-weight: 700;
    color: var(--ink-3);
    font-variant-numeric: tabular-nums;
}

.rank-no.is-top {
    color: var(--brand);
}

.rank-name {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-score {
    flex: none;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

/* ---------- compare page ---------- */

.cmp-products {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.cmp-product {
    display: flex;
    align-items: center;
    gap: 13px;
    flex: 1 1 300px;
    min-width: 0;
    padding: 13px 15px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
}

.cmp-product-body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    min-width: 0;
}

.cmp-product-name {
    font-size: 14.5px;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.35;
}

.cmp-product-name:hover {
    color: var(--brand);
}

.cmp-product-meta {
    font-size: 11.5px;
    color: var(--ink-3);
}

.cmp-product-change {
    margin-top: 2px;
    font-size: 11.5px;
    color: var(--brand);
}

.vs-badge {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    flex: none;
    border-radius: 50%;
    background: var(--surface-3);
    color: var(--ink-3);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.03em;
}

.verdict {
    margin-top: 14px;
}

.verdict-body {
    padding: 14px 16px 16px;
}

.verdict-lead {
    margin: 0 0 10px;
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.6;
    color: var(--ink);
}

.verdict-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 0;
    border-bottom: 1px dashed var(--border);
    font-size: 12.5px;
}

.verdict-row:last-child {
    border-bottom: 0;
}

.verdict-head {
    border-bottom: 1px solid var(--border);
    font-size: 11.5px;
    color: var(--ink-3);
}

.verdict-name {
    flex: 1;
    min-width: 0;
    color: var(--ink-2);
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.verdict-val {
    width: 104px;
    flex: none;
    text-align: right;
    font-variant-numeric: tabular-nums;
    color: var(--ink-3);
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.verdict-val.is-best {
    color: var(--brand);
    font-weight: 700;
}

.verdict-diff {
    width: 52px;
    flex: none;
    text-align: right;
    font-weight: 600;
    color: var(--ink-3);
}

.compare-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    margin-top: 14px;
}

.table-scroll {
    overflow-x: auto;
}

.cmp-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12.5px;
}

.cmp-table th,
.cmp-table td {
    padding: 9px 12px;
    border-bottom: 1px solid var(--border);
    text-align: center;
    vertical-align: top;
}

.cmp-table th {
    background: var(--surface-2);
    color: var(--ink-2);
    font-size: 11.5px;
    font-weight: 600;
    white-space: nowrap;
}

.cmp-key {
    width: 30%;
    text-align: left !important;
    color: var(--ink-3) !important;
    font-weight: 500 !important;
    white-space: nowrap;
}

.cmp-val {
    color: var(--ink);
    font-weight: 500;
}

.cmp-win {
    color: var(--brand);
    font-weight: 700;
    background: var(--brand-soft);
}

.cmp-group td {
    background: var(--surface-2);
    color: var(--ink-3);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    text-align: left;
}

.bench-compare {
    padding: 6px 16px 16px;
}

.bench-group {
    padding: 10px 0;
    border-bottom: 1px dashed var(--border);
}

.bench-group-title {
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--ink-2);
}

.bench-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 52px;
    align-items: center;
    gap: 10px;
    padding: 3px 0;
}

.bench-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding-top: 12px;
    font-size: 11.5px;
    color: var(--ink-3);
}

.legend-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.legend-dot {
    width: 9px;
    height: 9px;
    border-radius: 3px;
    background: linear-gradient(90deg, #6ba8ff, #2563eb);
}

.legend-dot.is-alt {
    background: linear-gradient(90deg, #b9d3ff, #7fadf7);
}

/* ---------- ranking page ---------- */

.rank-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 16px;
}

/* ---------- blog ---------- */

.blog-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 288px;
    gap: 16px;
    align-items: start;
}

.blog-main {
    min-width: 0;
}

.blog-side {
    position: sticky;
    top: 76px;
}

.featured-post {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    gap: 0;
    margin-bottom: 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
    overflow: hidden;
    transition: border-color 0.16s, box-shadow 0.16s;
}

.featured-post:hover {
    border-color: var(--brand-line);
    box-shadow: var(--shadow-2);
}

.featured-cover {
    position: relative;
    display: block;
    min-height: 210px;
    background: linear-gradient(150deg, #e8eefb, #f2f5fa);
    overflow: hidden;
}

[data-theme="dark"] .featured-cover {
    background: linear-gradient(150deg, #16243a, #101d2e);
}

.featured-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-cover .post-fallback svg {
    width: 64px;
    height: 64px;
}

.featured-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 18px 20px;
}

.featured-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.45;
    letter-spacing: -0.015em;
}

.featured-post:hover .featured-title {
    color: var(--brand);
}

.featured-summary {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 12.5px;
    line-height: 1.65;
    color: var(--ink-3);
}

.side-articles {
    padding: 4px 8px 8px;
}

.side-article {
    display: flex;
    gap: 9px;
    padding: 8px;
    border-radius: 8px;
}

.side-article + .side-article {
    border-top: 1px solid var(--border);
}

.side-article:hover {
    background: var(--surface-2);
}

.side-thumb {
    display: grid;
    place-items: center;
    width: 48px;
    height: 40px;
    flex: none;
    border-radius: 6px;
    background: linear-gradient(150deg, #e8eefb, #f2f5fa);
    color: #a8b8d0;
    overflow: hidden;
}

.side-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.side-thumb svg {
    width: 18px;
    height: 18px;
}

.side-body {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.side-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.5;
}

.side-article:hover .side-title {
    color: var(--brand);
}

.side-date {
    font-size: 10.5px;
    color: var(--ink-3);
}

/* ---------- article page ---------- */

.article-layout {
    display: grid;
    grid-template-columns: 176px minmax(0, 1fr) 252px;
    gap: 20px;
    align-items: start;
}

.article-layout.no-toc {
    grid-template-columns: minmax(0, 1fr) 252px;
}

.toc {
    position: sticky;
    top: 76px;
    font-size: 12.5px;
}

.toc-title {
    margin-bottom: 9px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--ink-3);
}

.toc-list {
    display: flex;
    flex-direction: column;
    border-left: 2px solid var(--border);
}

.toc-link {
    padding: 5px 0 5px 11px;
    margin-left: -2px;
    border-left: 2px solid transparent;
    color: var(--ink-3);
    line-height: 1.5;
}

.toc-link:hover {
    color: var(--brand);
}

.toc-link.level-3 {
    padding-left: 22px;
    font-size: 12px;
}

.toc-link.active {
    border-left-color: var(--brand);
    color: var(--brand);
    font-weight: 600;
}

.article {
    padding: 24px 28px 30px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
}

.article-title {
    margin: 9px 0 11px;
    font-size: 25px;
    font-weight: 700;
    line-height: 1.32;
    letter-spacing: -0.02em;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 12px;
    color: var(--ink-3);
}

.article-cover {
    margin: 18px 0;
    border-radius: 10px;
    overflow: hidden;
}

.article-side {
    display: flex;
    flex-direction: column;
    gap: 14px;
    position: sticky;
    top: 76px;
}

.aside-card {
    padding: 13px 15px 15px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-1);
}

.aside-title {
    margin-bottom: 9px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--ink-3);
}

.aside-post {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 7px 0;
    border-bottom: 1px dashed var(--border);
}

.aside-post:last-child {
    border-bottom: 0;
}

.aside-post-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.45;
}

.aside-post:hover .aside-post-title {
    color: var(--brand);
}

.aside-post-date {
    font-size: 10.5px;
    color: var(--ink-3);
}

.aside-product {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 6px 0;
}

.aside-product-name {
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;
}

.aside-product:hover .aside-product-name {
    color: var(--brand);
}

/* ---------- prose ---------- */

.prose {
    font-size: 14.5px;
    line-height: 1.85;
    color: var(--ink-2);
    word-wrap: break-word;
}

.prose > *:first-child {
    margin-top: 0;
}

.prose h2 {
    margin: 26px 0 10px;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: -0.01em;
    color: var(--ink);
    scroll-margin-top: 76px;
}

.prose h3 {
    margin: 22px 0 9px;
    font-size: 15.5px;
    font-weight: 700;
    color: var(--ink);
    scroll-margin-top: 76px;
}

.prose h4 {
    margin: 18px 0 8px;
    font-size: 14.5px;
    font-weight: 700;
    color: var(--ink);
}

.prose p {
    margin: 0 0 13px;
}

.prose a {
    color: var(--brand);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.prose ul,
.prose ol {
    margin: 0 0 13px;
    padding-left: 20px;
}

.prose li {
    margin-bottom: 5px;
}

.prose img {
    margin: 16px 0;
    border-radius: 10px;
}

.prose figure {
    margin: 16px 0;
}

.prose figcaption {
    margin-top: 7px;
    font-size: 12px;
    color: var(--ink-3);
    text-align: center;
}

.prose blockquote {
    margin: 16px 0;
    padding: 11px 16px;
    border-left: 3px solid var(--brand);
    border-radius: 0 8px 8px 0;
    background: var(--brand-soft);
    color: var(--ink-2);
}

.prose blockquote p:last-child {
    margin-bottom: 0;
}

.prose table {
    width: 100%;
    margin: 16px 0;
    border-collapse: collapse;
    font-size: 13px;
}

.prose th,
.prose td {
    padding: 8px 11px;
    border: 1px solid var(--border);
    text-align: left;
}

.prose th {
    background: var(--surface-2);
    font-weight: 600;
    color: var(--ink);
}

.prose code {
    padding: 1px 5px;
    border-radius: 4px;
    background: var(--surface-3);
    font-size: 12.5px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.prose pre {
    margin: 16px 0;
    padding: 13px 15px;
    border-radius: 10px;
    background: var(--surface-3);
    overflow-x: auto;
}

.prose pre code {
    padding: 0;
    background: none;
}

.prose hr {
    margin: 22px 0;
    border: 0;
    border-top: 1px solid var(--border);
}

.prose-sm {
    padding: 14px 16px;
    font-size: 13.5px;
}

/* ---------- forms ---------- */

.field {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.label {
    font-size: 12px;
    font-weight: 600;
    color: var(--ink-2);
}

.input,
.textarea {
    width: 100%;
    padding: 8px 11px;
    border: 1px solid var(--border-2);
    border-radius: 8px;
    background: var(--surface);
    color: var(--ink);
    font-family: inherit;
    font-size: 13.5px;
    outline: none;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.input {
    height: 38px;
}

.textarea {
    min-height: 104px;
    resize: vertical;
    line-height: 1.6;
}

.input:focus,
.textarea:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--brand-soft);
}

.form-action {
    display: flex;
    align-items: flex-end;
}

.search-form {
    display: flex;
    gap: 8px;
    align-items: center;
}

.alert {
    padding: 9px 11px;
    border-radius: 8px;
    font-size: 12.5px;
    line-height: 1.5;
}

.alert-ok {
    background: rgba(22, 163, 74, 0.1);
    color: var(--ok);
}

.alert-error {
    background: rgba(229, 72, 77, 0.1);
    color: var(--danger);
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.box {
    display: block;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface-2);
    font-weight: 600;
    transition: border-color 0.15s, color 0.15s;
}

.box:hover {
    border-color: var(--brand-line);
    color: var(--brand);
}

/* legacy page rail (static pages) */

.section-grid {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

.rail {
    position: sticky;
    top: 76px;
}

.rail-num {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--brand);
}

.rail-title {
    margin-top: 3px;
    font-size: 16px;
    font-weight: 700;
}

.rail-note {
    margin-top: 5px;
    font-size: 12px;
    line-height: 1.6;
    color: var(--ink-3);
}

.rail-more {
    display: inline-block;
    margin-top: 9px;
    font-size: 12px;
    color: var(--brand);
}

/* ---------- autocomplete ---------- */

.autocomplete-wrap {
    position: relative;
    flex: 1;
    min-width: 0;
}

.autocomplete {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 6px);
    z-index: 40;
    max-height: 260px;
    overflow: auto;
    padding: 5px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--surface);
    box-shadow: var(--shadow-2);
}

.autocomplete-item {
    padding: 8px 10px;
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
}

.autocomplete-item:hover {
    background: var(--brand-soft);
    color: var(--brand);
}

/* ---------- compare bar ---------- */

.compare-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 70;
    background: var(--navy);
    color: #fff;
}

.compare-bar-inner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 0;
}

.compare-bar .label-text {
    font-size: 12.5px;
    color: rgba(255, 255, 255, 0.7);
}

.compare-bar .count {
    display: inline-block;
    min-width: 18px;
    padding: 0 5px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    font-weight: 700;
    text-align: center;
}

.compare-bar .btn-ghost {
    color: rgba(255, 255, 255, 0.85);
    border-color: rgba(255, 255, 255, 0.18);
}

.compare-bar .btn-ghost:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.3);
    color: #fff;
}

.compare-bar .spacer {
    flex: 1;
}

.compare-bar .btn-primary {
    background: #fff;
    border-color: #fff;
    color: var(--navy);
}

.compare-bar .btn-primary:hover {
    background: #eaf1ff;
    border-color: #eaf1ff;
    color: var(--navy);
}

.compare-drawer {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0 0 12px;
}

.compare-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 8px 4px 10px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
    font-size: 12px;
}

.compare-item-del {
    border: 0;
    background: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
}

.compare-item-del:hover {
    color: #fff;
}

/* ---------- toast / modal ---------- */

.toast {
    position: fixed;
    left: 50%;
    bottom: 74px;
    z-index: 120;
    transform: translate(-50%, 10px);
    padding: 9px 16px;
    border-radius: 8px;
    background: rgba(12, 27, 46, 0.95);
    color: #fff;
    font-size: 12.5px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s, transform 0.2s;
}

.toast.show {
    opacity: 1;
    transform: translate(-50%, 0);
}

.modal {
    position: fixed;
    inset: 0;
    z-index: 110;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(10, 18, 30, 0.5);
    backdrop-filter: blur(2px);
}

.modal-box {
    width: min(440px, 100%);
    max-height: 88vh;
    overflow: auto;
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.5);
}

.modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
    font-weight: 700;
}

.modal-close {
    border: 0;
    background: none;
    color: var(--ink-3);
    font-size: 19px;
    line-height: 1;
    cursor: pointer;
}

.modal-body {
    padding: 16px 18px;
}

.modal-foot {
    display: flex;
    justify-content: flex-end;
    gap: 9px;
    padding: 13px 18px;
    border-top: 1px solid var(--border);
    background: var(--surface-2);
}

/* ---------- footer ---------- */

.site-footer {
    margin-top: 48px;
    background: #0c1b2e;
    color: rgba(255, 255, 255, 0.7);
}

.foot-grid {
    display: grid;
    grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr));
    gap: 30px;
    padding: 38px 0 28px;
}

.site-footer .brand {
    color: #fff;
}

.site-footer .brand-mark {
    background: linear-gradient(145deg, #4a8cff, #1f5fd8);
}

.foot-desc {
    margin-top: 12px;
    max-width: 330px;
    font-size: 12.5px;
    line-height: 1.75;
    color: rgba(255, 255, 255, 0.5);
}

.foot-title {
    margin-bottom: 11px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.9);
}

.foot-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.foot-links a {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.58);
    transition: color 0.15s;
}

.foot-links a:hover {
    color: #fff;
}

.foot-bottom {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 0 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.09);
    font-size: 12px;
    color: rgba(255, 255, 255, 0.42);
}

.foot-legal {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.foot-legal a {
    color: inherit;
    transition: color 0.15s;
}

.foot-legal a:hover {
    color: #fff;
}

.foot-link-btn {
    padding: 0;
    border: 0;
    background: none;
    color: rgba(255, 255, 255, 0.58);
    font: inherit;
    font-size: 13px;
    text-align: left;
    cursor: pointer;
    transition: color 0.15s;
}

.foot-link-btn:hover {
    color: #fff;
}

/* ---------- responsive ---------- */

@media (max-width: 1080px) {
    .header-search {
        width: 190px;
    }

    .home-cols {
        grid-template-columns: minmax(0, 1fr);
    }

    .detail-layout,
    .compare-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .detail-side,
    .blog-side {
        position: static;
    }

    .detail-side {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }

    .detail-side .card + .card {
        margin-top: 0;
    }

    .article-layout,
    .article-layout.no-toc {
        grid-template-columns: minmax(0, 1fr);
    }

    .toc,
    .article-side {
        position: static;
    }

    .article-side {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }

    .data-head,
    .data-row {
        grid-template-columns: 44px minmax(0, 1.9fr) 70px 82px 82px 82px 64px;
    }

    .h-date,
    .cell-date {
        display: none;
    }

    .rank-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .foot-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 24px;
    }

    .foot-brand {
        grid-column: 1 / -1;
    }
}

@media (max-width: 860px) {
    .nav,
    .header-tools > .header-search {
        display: none;
    }

    .mobile-nav .header-search {
        display: flex;
        width: 100%;
    }

    .mobile-toggle {
        display: grid;
    }

    .header-inner {
        gap: 12px;
        height: 56px;
    }

    .hero-inner {
        padding: 28px 22px 26px;
    }

    .hero-title {
        font-size: 22px;
    }

    .brand-strip {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .brand-item:nth-child(4) {
        border-left: 0;
        border-top: 1px solid var(--border);
    }

    .brand-item:nth-child(5) {
        grid-column: span 2;
        border-top: 1px solid var(--border);
    }

    .posts-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .blog-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .featured-post {
        grid-template-columns: minmax(0, 1fr);
    }

    .featured-cover {
        min-height: 170px;
    }

    .detail-hero {
        grid-template-columns: 150px minmax(0, 1fr);
        gap: 16px;
    }

    .detail-title {
        font-size: 20px;
    }

    .section-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
    }

    .rail {
        position: static;
        display: flex;
        align-items: baseline;
        gap: 9px;
        flex-wrap: wrap;
    }

    .data-head,
    .data-row {
        grid-template-columns: 36px minmax(0, 1fr) 76px 82px 82px 62px;
        gap: 8px;
    }

    .h-brand,
    .cell-brand {
        display: none;
    }
}

@media (max-width: 640px) {
    .wrap {
        padding: 0 14px;
    }

    .page-head h1 {
        font-size: 20px;
    }

    .hero {
        border-radius: 12px;
    }

    .hero-title {
        font-size: 19px;
    }

    .hero-search {
        flex-wrap: wrap;
        padding: 6px;
    }

    .hero-search input {
        padding-left: 6px;
    }

    .btn-hero {
        width: 100%;
    }

    .brand-strip {
        display: flex;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .brand-strip::-webkit-scrollbar {
        display: none;
    }

    .brand-item {
        flex: 0 0 46%;
    }

    .brand-item:nth-child(4),
    .brand-item:nth-child(5) {
        border-top: 0;
    }

    .brand-item:nth-child(4) {
        border-left: 1px solid var(--border);
    }

    .hot-side .pv-xxs {
        display: none;
    }

    .data-head,
    .data-row {
        grid-template-columns: 30px minmax(0, 1fr);
        gap: 8px;
        padding: 0 12px;
    }

    .data-row {
        min-height: 52px;
    }

    .h-brand,
    .h-cores,
    .h-base,
    .h-boost,
    .h-tdp,
    .h-date,
    .cell-brand,
    .cell-cores,
    .cell-base,
    .cell-boost,
    .cell-tdp,
    .cell-date {
        display: none;
    }

    .filter-field-growth {
        flex-basis: 100%;
        max-width: none;
        margin-left: 0;
    }

    .filter-field {
        flex: 1 1 40%;
    }

    .filter-field .select {
        width: 100%;
    }

    .filter-bar .btn-dark {
        flex: 1 1 100%;
    }

    .list-foot {
        justify-content: center;
    }

    .per-page {
        margin-left: 0;
    }

    .cat-cloud {
        gap: 10px 18px;
        padding-top: 12px;
        max-height: 96px;
        overflow: hidden;
    }

    .series-hero {
        padding: 15px 16px;
    }

    .series-stats {
        gap: 20px;
    }

    .series-stat-value {
        font-size: 16px;
    }

    .verdict-val {
        width: 76px;
    }

    .verdict-diff {
        width: 44px;
    }

    .cat-cloud.is-open {
        max-height: none;
    }

    .cat-link {
        font-size: 12.5px;
    }

    .cat-more {
        display: inline-flex;
        align-items: center;
        margin: 2px 0 0;
        padding: 0;
        border: 0;
        background: none;
        color: var(--brand);
        font-family: inherit;
        font-size: 12.5px;
        font-weight: 600;
        cursor: pointer;
    }

    .posts-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .detail-hero {
        grid-template-columns: minmax(0, 1fr);
    }

    .detail-gallery {
        max-width: 150px;
    }

    .spec-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .spec-strip {
        gap: 5px;
    }

    .panel-head {
        flex-wrap: wrap;
        gap: 8px;
    }

    .rank-bar {
        display: none;
    }

    .promo {
        min-height: 170px;
        padding: 20px;
    }

    .promo-title {
        font-size: 16px;
    }

    .promo-body {
        max-width: 100%;
    }

    .promo-art {
        opacity: 0.35;
        right: -60px;
    }

    .cmp-products {
        flex-direction: column;
        align-items: stretch;
    }

    .cmp-product {
        flex: 0 0 auto;
    }

    .vs-badge {
        align-self: center;
    }

    .article {
        padding: 18px 16px 22px;
    }

    .article-title {
        font-size: 20px;
    }

    .grid-2,
    .grid-3,
    .article-side {
        grid-template-columns: minmax(0, 1fr);
    }

    .detail-side {
        grid-template-columns: minmax(0, 1fr);
    }

    .foot-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 20px 16px;
        padding: 24px 0 18px;
    }

    .foot-brand {
        grid-column: 1 / -1;
    }

    .foot-desc {
        margin-top: 10px;
        font-size: 12px;
        line-height: 1.65;
    }

    .foot-title {
        margin-bottom: 8px;
    }

    .foot-links {
        gap: 6px;
    }

    .foot-links a {
        font-size: 12.5px;
    }

    .foot-bottom {
        justify-content: flex-start;
        padding: 12px 0 18px;
        font-size: 11.5px;
    }
}

/* ---------- mobile compatibility ---------- */

@media (max-width: 1080px) {
    .nav-link {
        padding: 7px 9px;
        font-size: 13.5px;
    }

    .header-search {
        width: 200px;
    }
}

@media (max-width: 1080px) {
    .nav {
        display: none;
    }

    .mobile-toggle {
        display: grid;
    }

    .header-inner {
        gap: 10px;
    }
}

@media (max-width: 860px) {
    .header-tools > .header-search {
        display: none;
    }

    .mobile-nav .header-search {
        display: flex;
        width: 100%;
    }
}

@media (max-width: 760px) {
    .cmp-products {
        flex-direction: column;
        align-items: stretch;
    }

    .cmp-product {
        flex: 0 0 auto;
    }

    .vs-badge {
        align-self: center;
    }
}

@media (max-width: 860px) {
    .toc {
        display: none;
    }

    .article-layout,
    .article-layout.no-toc {
        grid-template-columns: minmax(0, 1fr);
    }

    .detail-side,
    .blog-side,
    .article-side {
        position: static;
    }
}

@media (max-width: 640px) {
    .input,
    .textarea,
    .select,
    .header-search input,
    .hero-search input {
        font-size: 16px;
    }

    .select {
        height: 38px;
    }

    .hero-search input {
        height: 40px;
        padding-left: 6px;
    }

    .prose table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    .prose img {
        width: 100%;
    }

    .rank-tabs {
        max-width: 100%;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .rank-tabs::-webkit-scrollbar {
        display: none;
    }

    .tabbar {
        -webkit-overflow-scrolling: touch;
    }

    .compare-bar-inner {
        flex-wrap: wrap;
        row-gap: 6px;
    }

    .compare-bar .spacer {
        display: none;
    }

    .compare-bar .btn-sm {
        height: 30px;
        padding: 0 10px;
        font-size: 12px;
    }

    .compare-bar .label-text {
        font-size: 12px;
    }

    .modal {
        padding: 12px;
    }

    .modal-box {
        max-height: 84vh;
    }

    .toast {
        bottom: 86px;
        max-width: calc(100% - 24px);
        text-align: center;
    }

    .detail-gallery {
        margin: 0 auto;
    }

    .name-logo {
        width: 28px;
        height: 28px;
    }

    .name-logo svg {
        width: 15px;
        height: 15px;
    }

    .cell-rank {
        font-size: 12px;
    }

    .pagination .page {
        min-width: 30px;
        height: 30px;
        font-size: 12px;
    }
}

/* ---------- tools ---------- */

.tool-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 12px;
    margin-bottom: 4px;
}

/* 天梯图第二组（子分类）单独占一行 */
.tool-bar > .chips:not(:first-child) {
    flex-basis: 100%;
}

.tool-form {
    display: flex;
    gap: 10px;
    max-width: 620px;
    margin-bottom: 18px;
}

.tool-form .input {
    height: 42px;
    font-size: 14px;
}

.tool-form .btn {
    flex: none;
    height: 42px;
    padding: 0 22px;
}

/* ladder */

.ladder-panel {
    margin-top: 4px;
}

.ladder-list {
    padding: 6px 0;
}

.ladder-row {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) minmax(120px, 36%) 78px;
    align-items: center;
    gap: 12px;
    padding: 8px 16px;
    font-size: 13px;
    color: var(--ink-2);
    transition: background 0.14s;
}

.ladder-row:hover {
    background: var(--surface-2);
    color: var(--ink);
}

.ladder-rank {
    font-size: 12px;
    font-weight: 600;
    color: var(--ink-3);
    font-variant-numeric: tabular-nums;
    text-align: center;
}

.ladder-rank.is-top {
    color: var(--brand);
    font-weight: 700;
}

.ladder-name {
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.ladder-track {
    height: 8px;
    border-radius: 99px;
    background: var(--surface-3);
    overflow: hidden;
}

.ladder-track i {
    height: 100%;
    border-radius: 99px;
    background: linear-gradient(90deg, #6ba8ff, #2563eb);
}

.ladder-score {
    text-align: right;
    font-weight: 600;
    color: var(--ink);
    font-variant-numeric: tabular-nums;
}

/* decoder */

.decode-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 16px 0;
}

.decode-raw {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.decode-parts {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 14px 16px 6px;
}

.decode-part {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 10px 16px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface-2);
}

.decode-part b {
    font-size: 17px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.decode-part span {
    font-size: 11px;
    color: var(--ink-3);
}

.decode-note {
    margin: 8px 16px 0;
    font-size: 13px;
    color: var(--ink-2);
}

.decode-note b {
    color: var(--brand);
}

.decode-found {
    padding: 12px 16px 16px;
}

.suffix-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px 18px;
    padding: 14px 16px 18px;
}

.suffix-item {
    display: flex;
    align-items: baseline;
    gap: 10px;
    font-size: 12.5px;
    color: var(--ink-2);
}

.suffix-item b {
    min-width: 44px;
    color: var(--brand);
    font-weight: 700;
}

/* equivalent */

.equiv-summary {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
}

.equiv-score {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.equiv-score-label {
    font-size: 12px;
    color: var(--ink-3);
}

.equiv-score b {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.equiv-bench {
    font-size: 11.5px;
    color: var(--ink-3);
}

.equiv-hint {
    margin: 0;
    font-size: 12px;
    color: var(--ink-3);
}

.equiv-list {
    padding: 4px 8px 8px;
}

.equiv-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 9px 8px;
    border-radius: 8px;
    font-size: 12.5px;
}

.equiv-item + .equiv-item {
    border-top: 1px solid var(--border);
}

.equiv-item:hover {
    background: var(--surface-2);
}

.equiv-name {
    flex: 1;
    min-width: 0;
    font-weight: 600;
    color: var(--ink);
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.equiv-date {
    flex: none;
    font-size: 11.5px;
    color: var(--ink-3);
}

.equiv-item-score {
    flex: none;
    width: 70px;
    text-align: right;
    color: var(--ink-2);
    font-variant-numeric: tabular-nums;
}

.equiv-diff {
    flex: none;
    width: 54px;
    text-align: right;
    font-weight: 600;
    color: var(--ink-3);
    font-variant-numeric: tabular-nums;
}

.equiv-diff.is-up {
    color: var(--ok);
}

.equiv-diff.is-down {
    color: var(--danger);
}

/* ---------- cookie consent ---------- */

.consent {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 130;
    padding: 14px 16px calc(14px + env(safe-area-inset-bottom));
    pointer-events: none;
}

.consent-box {
    display: flex;
    align-items: center;
    gap: 18px;
    width: min(960px, 100%);
    margin: 0 auto;
    padding: 14px 18px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: 0 24px 56px -28px rgba(13, 21, 36, 0.55);
    pointer-events: auto;
}

.consent-body {
    flex: 1;
    min-width: 0;
}

.consent-title {
    margin: 0 0 3px;
    font-size: 13.5px;
    font-weight: 700;
    color: var(--ink);
}

.consent-text {
    margin: 0;
    font-size: 12.5px;
    line-height: 1.6;
    color: var(--ink-3);
}

.consent-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: none;
}

.consent-link {
    margin-right: 4px;
    font-size: 12px;
    color: var(--brand);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.consent-btn {
    height: 34px;
    padding: 0 14px;
    border: 1px solid var(--border-2);
    border-radius: 8px;
    background: var(--surface);
    color: var(--ink);
    font-family: inherit;
    font-size: 12.5px;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.consent-btn:hover {
    border-color: var(--brand);
    color: var(--brand);
}

.consent-btn--primary {
    background: var(--brand);
    border-color: var(--brand);
    color: #fff;
}

.consent-btn--primary:hover {
    background: var(--brand-2);
    border-color: var(--brand-2);
    color: #fff;
}

@media (max-width: 720px) {
    .consent-box {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .consent-actions {
        flex-wrap: wrap;
        justify-content: flex-end;
    }

    .consent-link {
        margin-right: auto;
    }
}

/* 工具页移动端（需置于工具基础样式之后） */
@media (max-width: 640px) {
    .tool-form {
        flex-wrap: wrap;
    }

    .tool-form .btn {
        flex: 1 1 100%;
    }

    .ladder-row {
        grid-template-columns: 26px minmax(0, 1fr) 54px;
        grid-template-areas:
            'rank name score'
            'track track track';
        gap: 5px 8px;
        padding: 8px 12px;
        font-size: 12.5px;
    }

    .ladder-rank { grid-area: rank; }
    .ladder-name { grid-area: name; }
    .ladder-track { grid-area: track; height: 6px; }
    .ladder-score { grid-area: score; }

    .decode-part {
        padding: 8px 12px;
    }

    .equiv-item-score {
        width: 64px;
    }

    .equiv-diff {
        width: 46px;
    }
}
