/* POE2 数据查询共用表样式（对齐宝石利润页） */

/* embed 模式：铺满 iframe，与 hub 顶栏 Tab 左缘对齐（去掉内层 max-w / 额外水平 padding） */
html.query-embed,
html.query-embed body {
    height: 100%;
    margin: 0;
    overflow: hidden;
    background: #111827;
}
html.query-embed body > nav,
html.query-embed #site-footer,
html.query-embed .adsense-sidebar-wrapper {
    display: none !important;
}
html.query-embed body > div.max-w-7xl {
    padding: 0 !important;
    max-width: none !important;
    margin: 0 !important;
    width: 100% !important;
    height: 100% !important;
}
html.query-embed body > div.max-w-7xl > div.max-w-7xl {
    max-width: none !important;
    margin: 0 !important;
    width: 100% !important;
    height: 100% !important;
    padding: 0 !important;
}
html.query-embed aside.sidebar {
    top: 0 !important;
    height: 100% !important;
    border-radius: 0 !important;
}
html.query-embed main.flex-1 {
    height: 100% !important;
    margin-left: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 0 !important;
    background: #111827 !important;
    background-color: #111827 !important;
}

.query-page-shell,
.poe2-query-shell {
    background: #111827;
    color: #e5e7eb;
}

.query-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem 0.85rem;
    align-items: center;
    padding: 0.65rem 0.85rem;
    background: #1f2937;
    border: 1px solid #374151;
    border-radius: 0.5rem;
    margin-bottom: 0.65rem;
}

.query-filter-btn,
.poe2-query-tab,
.rune-filter-btn,
.gem-type-tab,
.attribute-button,
.tag2-filter-btn,
.tag-button {
    appearance: none;
    border: 1px solid #4b5563;
    background: #1f2937;
    color: #d1d5db;
    border-radius: 0.375rem;
    padding: 0.4rem 0.85rem;
    font-size: 0.82rem;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.query-filter-btn:hover,
.poe2-query-tab:hover,
.rune-filter-btn:hover,
.gem-type-tab:hover,
.attribute-button:hover,
.tag2-filter-btn:hover,
.tag-button:hover {
    background: #374151;
    color: #fff;
}

.query-filter-btn.is-active,
.poe2-query-tab.is-active,
.rune-filter-btn.is-active,
.gem-type-tab.bg-blue-600,
.attribute-button.bg-blue-600,
.tag2-filter-btn.bg-blue-600,
.tag-button.bg-blue-600,
button.bg-blue-600 {
    background: #1d4ed8 !important;
    border-color: #2563eb !important;
    color: #fff !important;
}

.query-search {
    flex: 1 1 14rem;
    min-width: 12rem;
    position: relative;
}

.query-search input {
    width: 100%;
    box-sizing: border-box;
    padding: 0.45rem 2rem 0.45rem 2rem;
    background: #111827;
    border: 1px solid #4b5563;
    border-radius: 0.375rem;
    color: #fff;
    font-size: 0.85rem;
}

.query-search input:focus {
    outline: none;
    border-color: #60a5fa;
    box-shadow: 0 0 0 1px #60a5fa;
}

.query-table-wrap {
    background: #1f2937;
    border: 1px solid #374151;
    border-radius: 0.5rem;
    overflow: auto;
}

table.query-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    min-width: 640px;
}

table.query-table th,
table.query-table td {
    padding: 0.55rem 0.65rem;
    text-align: left;
    border-bottom: 1px solid #374151;
    vertical-align: middle;
    font-size: 0.8rem;
    background: #1f2937;
}

table.query-table th {
    position: sticky;
    top: 0;
    z-index: 3;
    background: #111827;
    color: #9ca3af;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: 0 1px 0 #374151;
    text-transform: none;
    letter-spacing: 0;
}

table.query-table tbody tr:hover td {
    background: #374151;
}

.query-item-cell,
.item-with-icon {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-width: 0;
}

.query-item-cell .item-name-display,
.item-with-icon .item-name-display {
    min-width: 0;
}

.query-item-cell .item-name-cn,
.item-with-icon .item-name-cn {
    font-size: 0.875rem;
    font-weight: 500;
    color: #f3f4f6;
    line-height: 1.3;
}

.query-item-cell .item-name-en,
.item-with-icon .item-name-en {
    font-size: 0.8125rem;
    color: #9ca3af;
    line-height: 1.2;
    margin-top: 0.1rem;
}

.query-item-cell img,
.query-item-cell .icon-utils-img,
.item-with-icon img,
.item-with-icon .item-icon {
    flex-shrink: 0;
    object-fit: contain;
}

a.query-detail-link,
button.query-detail-btn {
    display: inline-block;
    font-size: 0.72rem;
    line-height: 1;
    padding: 0.28rem 0.55rem;
    border-radius: 0.25rem;
    background: #1e3a5f;
    color: #93c5fd;
    text-decoration: none;
    font-weight: 600;
    border: none;
    cursor: pointer;
}

a.query-detail-link:hover,
button.query-detail-btn:hover {
    background: #2563eb;
    color: #fff;
}

.query-desc-cell {
    color: #d1d5db;
    font-size: 0.8rem;
    line-height: 1.45;
}

.query-muted {
    color: #9ca3af;
}
