/* ============================================================
   WONO item tooltip (web replica of the in-game item tooltip)
   + /items card grid + /item/{id} detail layout
   ============================================================ */

/* ---------- floating layer ---------- */
.wono-tooltip-layer {
    position: fixed;
    z-index: 9999;
    display: none;
    pointer-events: none;
}

/* ---------- tooltip panel (client: FlatPanel + gold border #D6A12B) ---------- */
.wono-tooltip {
    min-width: 158px;
    max-width: 360px;
    background: rgba(18, 18, 18, 0.96);
    border: 1px solid #D6A12B;
    border-radius: 3px;
    padding: 6px 8px;
    font-family: Verdana, Geneva, sans-serif;
    font-size: 11px;
    line-height: 15px;
    color: #ffffff;
    text-align: center;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6);
}

.wono-tooltip--inline {
    display: inline-block;
    min-width: 240px;
}

.wono-tooltip .wt-title {
    background: rgba(0, 0, 0, 0.4);
    color: #ffffff;
    padding: 3px 6px;
    margin: -2px -4px 0 -4px;
    font-weight: bold;
}

.wono-tooltip .wt-sprite {
    margin-top: 4px;
}

.wono-tooltip .wt-sprite img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    image-rendering: pixelated;
}

.wono-tooltip .wt-line {
    white-space: nowrap;
}

.wono-tooltip .wt-line.wt-wrap {
    white-space: normal;
    word-wrap: break-word;
}

.wono-tooltip .wt-separator {
    border-top: 1px solid rgba(255, 255, 255, 0.18);
    margin: 5px 0 4px 0;
}

.wono-tooltip .wt-row {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    height: 15px;
}

.wono-tooltip .wt-stat-name {
    color: #b3a98f;
    white-space: nowrap;
}

.wono-tooltip .wt-stat-value {
    white-space: nowrap;
}

.wono-tooltip .wt-footer {
    margin-top: 2px;
}

/* ============================================================
   /items page — toolbar, category pills, card grid
   ============================================================ */

.wono-items {
    --wono-accent: #f0902e;
    --wono-card-bg: rgba(20, 20, 24, 0.78);
    --wono-card-border: rgba(255, 255, 255, 0.10);
    font-family: Verdana, Geneva, sans-serif;
    color: #e8e4da;
}

.wono-items * {
    box-sizing: border-box;
}

/* toolbar: search + sort */
.wono-items .wi-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-bottom: 12px;
}

.wono-items .wi-search {
    flex: 1 1 220px;
    max-width: 340px;
    position: relative;
}

.wono-items .wi-search input {
    width: 100%;
    padding: 8px 12px 8px 32px;
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid var(--wono-card-border);
    border-radius: 6px;
    color: #e8e4da;
    font-size: 13px;
    outline: none;
}

.wono-items .wi-search input:focus {
    border-color: var(--wono-accent);
}

.wono-items .wi-search::before {
    content: "\1F50D";
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    opacity: 0.6;
}

.wono-items .wi-sort {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: #b9b3a6;
}

.wono-items .wi-sort select {
    padding: 7px 10px;
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid var(--wono-card-border);
    border-radius: 6px;
    color: #e8e4da;
    font-size: 12px;
    outline: none;
    cursor: pointer;
}

.wono-items .wi-count {
    margin-left: auto;
    font-size: 11px;
    color: #8d8778;
}

/* category pills */
.wono-items .wi-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}

.wono-items .wi-cat {
    padding: 6px 13px;
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid var(--wono-card-border);
    border-radius: 999px;
    color: #c9c3b4;
    font-size: 12px;
    cursor: pointer;
    user-select: none;
    text-transform: capitalize;
    transition: border-color .15s, color .15s, background .15s;
}

.wono-items .wi-cat:hover {
    border-color: var(--wono-accent);
    color: #ffffff;
}

.wono-items .wi-cat.active {
    background: var(--wono-accent);
    border-color: var(--wono-accent);
    color: #1a1206;
    font-weight: bold;
}

/* card grid */
.wono-items .wi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 10px;
}

.wono-items .wi-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 12px 8px 10px 8px;
    background: var(--wono-card-bg);
    border: 1px solid var(--wono-card-border);
    border-radius: 8px;
    text-decoration: none;
    color: #e8e4da;
    position: relative;
    transition: border-color .15s, transform .1s, box-shadow .15s;
}

.wono-items .wi-card:hover {
    border-color: var(--wono-accent);
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.45);
    color: #ffffff;
    text-decoration: none;
}

.wono-items .wi-card img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    image-rendering: pixelated;
}

.wono-items .wi-card .wi-name {
    font-size: 11.5px;
    text-align: center;
    text-transform: capitalize;
    line-height: 1.25;
    min-height: 28px;
    display: flex;
    align-items: center;
}

.wono-items .wi-card .wi-lv {
    position: absolute;
    top: 6px;
    right: 6px;
    padding: 2px 6px;
    background: rgba(0, 0, 0, 0.55);
    border-radius: 4px;
    font-size: 10px;
    color: #abface;
}

.wono-items .wi-card .wi-stat {
    font-size: 10.5px;
    color: #9fd3ff;
}

.wono-items .wi-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 30px 0;
    color: #8d8778;
    font-size: 13px;
}

/* ============================================================
   /item/{id} detail page
   ============================================================ */

.wono-item-detail {
    --wono-accent: #f0902e;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: flex-start;
    justify-content: center;
    font-family: Verdana, Geneva, sans-serif;
    color: #e8e4da;
}

.wono-item-detail .wid-tooltip {
    flex: 0 0 auto;
}

.wono-item-detail .wid-info {
    flex: 1 1 320px;
    max-width: 560px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.wono-item-detail .wid-box {
    background: rgba(20, 20, 24, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 8px;
    padding: 12px 14px;
    font-size: 12px;
    line-height: 1.5;
}

.wono-item-detail .wid-box h3 {
    margin: 0 0 8px 0;
    font-size: 12px;
    color: var(--wono-accent);
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    padding-bottom: 6px;
}

.wono-item-detail .wid-prices {
    display: flex;
    gap: 24px;
}

.wono-item-detail .wid-prices .label {
    color: #b3a98f;
    margin-right: 6px;
}

.wono-item-detail .wid-prices .value {
    color: #49d96b;
}

.wono-item-detail .wid-muted {
    color: #8d8778;
}
