/* Mandi Bhav Widget – mandi-bhav.css */

.mandi-bhav-widget {
    font-family: 'Noto Sans', 'Noto Sans Devanagari', sans-serif;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 14px;
    overflow: hidden;
    max-width: 360px;
}

/* ── HEADER ── */
.mbw-header {
    background: linear-gradient(135deg, #0f6e56 0%, #1d9e75 100%);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.mbw-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ffffff;
}
.mbw-title {
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
}
.mbw-live-badge {
    background: rgba(255,255,255,0.25);
    color: #ffffff;
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 20px;
    letter-spacing: 0.8px;
}
.mbw-msp-badge {
    background: rgba(255,255,255,0.2);
    color: #ffffff;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 20px;
}

/* ── CROP LIST ── */
.mbw-list {
    margin: 0;
    padding: 6px 0;
    list-style: none;
}
.mbw-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    border-bottom: 1px solid #f3f3f3;
    transition: background 0.12s;
}
.mbw-row:last-child { border-bottom: none; }
.mbw-row:hover { background: #f9fafb; }

.mbw-icon {
    font-size: 22px;
    width: 34px;
    flex-shrink: 0;
    text-align: center;
}
.mbw-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.mbw-name {
    font-size: 14px;
    font-weight: 500;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.mbw-market {
    font-size: 11px;
    color: #888;
}

/* ── PRICE COLUMN ── */
.mbw-price-col {
    text-align: right;
    flex-shrink: 0;
}
.mbw-price {
    font-size: 15px;
    font-weight: 600;
    display: block;
    font-variant-numeric: tabular-nums;
}
.mbw-price small {
    font-size: 10px;
    font-weight: 400;
    color: #999;
}
.mbw-up   { color: #0f6e56; }
.mbw-down { color: #a32d2d; }
.mbw-flat { color: #ba7517; }

.mbw-tag {
    display: inline-block;
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 10px;
    margin-top: 3px;
}
.mbw-tag-up   { background: #e1f5ee; color: #0f5e47; }
.mbw-tag-down { background: #fcebeb; color: #8a2424; }
.mbw-tag-flat { background: #faeeda; color: #9a5f0a; }

/* ── FOOTER ── */
.mbw-footer {
    padding: 9px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid #f0f0f0;
    background: #fafafa;
}
.mbw-updated {
    font-size: 11px;
    color: #999;
}
.mbw-source-link {
    font-size: 11px;
    color: #0f6e56;
    text-decoration: none;
    font-weight: 500;
}
.mbw-source-link:hover { text-decoration: underline; }

/* ── DARK MODE (if theme supports it) ── */
@media (prefers-color-scheme: dark) {
    .mandi-bhav-widget {
        background: #1a1a1a;
        border-color: #333;
    }
    .mbw-name    { color: #e8e8e8; }
    .mbw-market  { color: #777; }
    .mbw-row:hover { background: #222; }
    .mbw-row     { border-bottom-color: #2a2a2a; }
    .mbw-footer  { background: #141414; border-top-color: #2a2a2a; }
    .mbw-updated { color: #666; }
    .mbw-up      { color: #3dcba8; }
    .mbw-down    { color: #e87070; }
    .mbw-tag-up  { background: #0d3d2e; color: #3dcba8; }
    .mbw-tag-down{ background: #3d0d0d; color: #e87070; }
}
