body {
    font-family: 'Inter', sans-serif;
    background-color: #f0f2f7;
}

/* --- Sticky Header --- */
.sticky-header {
    position: sticky;
    top: 0;
    z-index: 1020;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, .075);
    padding: 0.75rem 0;
}

.stat-label {
    font-size: 0.7rem;
    font-weight: 700;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-value {
    font-size: 1.25rem;
    font-weight: 900;
}

.stat-breakdown {
    font-size: 0.7rem;
    font-weight: 600;
}

#market-news-ticker {
    font-size: 0.8rem;
    font-weight: 600;
    background-color: #212529;
    color: #fff;
    padding: 0.25rem 0;
    text-align: center;
}

/* --- Item Cards --- */
.product-card {
    background-color: #ffffff;
    border-radius: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out, border-color 0.3s ease;
    display: flex;
    flex-direction: column;
    text-align: center;
    border: 3px solid transparent;
    /* for glowing effect */
}

.product-card.booming {
    border-color: #198754;
    box-shadow: 0 0 15px rgba(25, 135, 84, 0.5);
}

.product-card.busting {
    border-color: #dc3545;
    box-shadow: 0 0 15px rgba(220, 53, 69, 0.5);
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.product-icon {
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
}

.product-icon img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.product-name {
    font-weight: 700;
    color: #333;
    flex-grow: 1;
    /* Ensures cards in a row have same height buttons */
}

.product-price {
    font-weight: 700;
    color: #0d6efd;
}

.product-info-line {
    font-weight: 600;
    font-size: 0.85rem;
}

.quantity-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.quantity-input {
    width: 70px;
    text-align: center;
    font-weight: 700;
    font-size: 1.25rem;
}

.quantity-input::-webkit-outer-spin-button,
.quantity-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.quantity-input {
    -moz-appearance: textfield;
}

.control-button {
    width: 60px;
    height: 45px;
    font-size: 1.1rem;
    font-weight: 700;
}

/* --- Side Panel Sections --- */
.side-panel-section {
    background-color: #ffffff;
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    /* Removed position: sticky to prevent overlap */
    /* Removed top: 140px; */
}

#owned-items-list {
    max-height: 400px;
    overflow-y: auto;
}

#opportunities-list {
    max-height: 400px;
    overflow-y: auto;
}

.owned-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
}

.owned-item:last-child {
    border-bottom: none;
}

.owned-item-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.owned-item-icon {
    width: 50px;
    height: 50px;
}

.owned-item-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.sell-from-assets-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

/* --- Level 2 Opportunities --- */
.opportunity-card {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.75rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

.opportunity-card:last-child {
    margin-bottom: 0;
}

/* --- Game Over Overlay --- */
#gameOverOverlay .modal-content {
    border-radius: 1rem;
}

.legal-text {
    color: #000000;
}