﻿.shop-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 16px;
    flex-shrink: 0;
}

.shop-card {
    background-color: #161b26;
    border: 1px solid #242d40;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform 0.15s ease, border-color 0.2s, box-shadow 0.2s;
    cursor: pointer;
}
.shop-card:hover {
    border-color: #d97706;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.card-top {
    display: flex;
    align-items: center;
    gap: 12px;
}
.item-icon-wrapper {
    width: 44px;
    height: 44px;
    background: #0f1219;
    border: 1px solid #242d40;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}
.item-icon {
    width: 36px;
    height: 36px;
    max-width: 100%;
    max-height: 100%;
    image-rendering: auto;
    transform: translateZ(0);
    object-fit: contain;
    display: block;
}

.item-info {
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.item-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #ffffff;
    text-transform: capitalize;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.item-owner {
    font-size: 0.78rem;
    color: #64748b;
}

.card-details {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.8rem;
    color: #64748b;
    padding-top: 10px;
    border-top: 1px solid #242d40;
}
.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.price-tag {
    font-weight: 600;
    font-size: 0.8rem;
}
.price-buy { color: #4ade80; }
.price-sell { color: #f87171; }

.coords {
    font-family: monospace;
    cursor: pointer;
    color: #64748b;
    font-size: 0.75rem;
    transition: color 0.2s;
}
.coords:hover { color: #f59e0b; }

.stock-meter-container {
    position: relative;
    width: 100%;
    height: 18px;
    background-color: #111827;
    border-radius: 4px;
    overflow: hidden;
    margin: 8px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #1f2937;
}
.stock-meter-bar {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    transition: width 0.3s ease;
}
.stock-meter-bar.stock-bar-green {
    background-color: rgba(34, 197, 94, 0.25);
    border-right: 2px solid #22c55e;
}
.stock-meter-bar.stock-bar-yellow {
    background-color: rgba(234, 179, 8, 0.25);
    border-right: 2px solid #eab308;
}
.stock-meter-bar.stock-bar-red {
    background-color: rgba(239, 68, 68, 0.25);
    border-right: 2px solid #ef4444;
}
.stock-meter-text {
    position: relative;
    z-index: 1;
    font-size: 0.75rem;
    font-weight: 600;
    color: #ffffff;
    letter-spacing: 0.02em;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9), 0 0 2px rgba(0, 0, 0, 0.9);
}

.pack-badge {
    margin-left: auto;
    font-size: 0.75rem;
    font-weight: 500;
    color: #64748b;
    background: rgba(30, 38, 56, 0.5);
    border: 1px solid transparent;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
    align-self: flex-start;
    cursor: pointer;
    transition: all 0.15s ease;
}
.pack-badge:hover {
    background: rgba(51, 65, 85, 0.8);
    color: #ffffff;
}
.pack-badge.active {
    color: #f59e0b;
    background: rgba(217, 119, 6, 0.15);
    border-color: rgba(245, 158, 11, 0.3);
}

.all-shops-card {
    background-color: #161b26;
    border: 1px solid #242d40;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform 0.15s ease, border-color 0.2s, box-shadow 0.2s;
    cursor: pointer;
}
.all-shops-card:hover {
    border-color: #d97706;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}
.range-highlight {
    font-weight: 600;
    color: #4ade80;
}

.grid-loader-container {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 0;
    width: 100%;
}
.grid-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top-color: #f59e0b;
    animation: spin 0.8s linear infinite;
}
.grid-loader-text {
    margin-top: 16px;
    color: #64748b;
    font-size: 0.9em;
}

.stock-value {
    color: #fbbf24;
    font-weight: 600;
}