/* =========================================================
   AlAdwaa Bundles Grade Widget
   ========================================================= */

:root {
    --bgw-study-accent: #6226C9;
    --bgw-study-bg: #F3EEFF;
    --bgw-revision-accent: #00A3E0;
    --bgw-revision-bg: #E6F8FF;
    --bgw-tab-active: #FCE391;
    --bgw-tab-inactive-bg: #F5F5F5;
    --bgw-tab-inactive-color: #00A3E0;
    --bgw-text-primary: #1A1A1A;
    --bgw-text-muted: #888;
    --bgw-font-family: 'Almarai', 'Inter', sans-serif;
    --bgw-radius: 24px;
}

.bgw-container {
    width: 100%;
    /* max-width: 880px; */
    margin: 0 auto;
    padding: 16px;
    font-family: var(--bgw-font-family);
}

/* ---------- Tabs ---------- */
.bgw-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    justify-content: center;
}

.bgw-tab {
    min-width: 170px;
    padding: 12px 20px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 400;
    font-family: var(--bgw-font-family);
    cursor: pointer;
    transition: background 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
    background: var(--bgw-tab-inactive-bg);
    color: #106F97;
}

.bgw-tab:hover {
    color: var(--bgw-text-primary);
}

.bgw-tab.active {
    background: var(--bgw-tab-active);
    color: var(--bgw-text-primary);
    box-shadow: 0 2px 8px rgba(252, 227, 145, 0.4);
}


html[lang="ar"] .bgw-tab.active[data-classification="1"] {
    border-radius: 8px 50px 50px 8px;
}
.bgw-tab.active[data-classification="1"] {
    border-radius: 50px 8px 8px 50px;
}

html[lang="ar"] .bgw-tab.active[data-classification="3"] {
    border-radius: 50px 8px 8px 50px;
}
.bgw-tab.active[data-classification="3"] {
    border-radius: 8px 50px 50px 8px;

}
/* ---------- Panels ---------- */
.bgw-panels {
    position: relative;
}

.bgw-panel {
    display: none;
}

.bgw-panel.active {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}
@media (max-width: 768px) {
    .bgw-panel.active {
        flex-direction: column;
    }
}
.bgw-panel--solo {
    display: block;
}

/* ---------- Bundle Card ---------- */
.bgw-bundle-card {
    width: 32.33%;
    border-radius: var(--bgw-radius);
    padding: 24px 20px;
    margin-bottom: 16px;
    border: 1px solid transparent;
}
@media (max-width: 768px) {
    .bgw-bundle-card {
        width: 100%;
    }
}
.bgw-bundle-card:last-child {
    margin-bottom: 0;
}

.bgw-study .bgw-bundle-card {
    background: var(--bgw-study-bg);
    border-color: rgba(98, 38, 201, 0.12);
}

.bgw-revision .bgw-bundle-card {
    background: var(--bgw-revision-bg);
    border-color: rgba(0, 163, 224, 0.12);
}

.bgw-bundle-card__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 20px;
}

.bgw-bundle-card__title {
    margin: 0;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
}

.bgw-study .bgw-bundle-card__title {
    color: var(--bgw-study-accent);
}

.bgw-revision .bgw-bundle-card__title {
    color: #0A3D6B;
}

.bgw-bundle-card__price {
    text-align: right;
    white-space: nowrap;
    flex-shrink: 0;
}

.bgw-price-value {
    font-size: 22px;
    font-weight: 800;
    line-height: 1;
}

.bgw-study .bgw-price-value {
    color: var(--bgw-study-accent);
}

.bgw-revision .bgw-price-value {
    color: var(--bgw-revision-accent);
}

.bgw-price-currency {
    font-size: 14px;
    font-weight: 600;
}

.bgw-price-original {
    display: block;
    font-size: 14px;
    font-weight: 500;
    text-decoration: line-through;
    color: var(--bgw-text-muted);
    margin-bottom: 2px;
}

/* ---------- Advantages List ---------- */
.bgw-advantages {
    list-style: none;
    margin: 0 0 24px;
    padding: 0;
}

.bgw-advantages li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    font-size: 15px;
    color: var(--bgw-text-primary);
    line-height: 1.4;
}

.bgw-advantages li:last-child {
    margin-bottom: 0;
}

.bgw-advantage-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    min-width: 28px;
    border-radius: 50%;
    flex-shrink: 0;
}

.bgw-study .bgw-advantage-icon {
    background: rgba(98, 38, 201, 0.15);
    color: var(--bgw-study-accent);
}

.bgw-revision .bgw-advantage-icon {
    background: rgba(0, 163, 224, 0.15);
    color: var(--bgw-revision-accent);
}

.bgw-advantage-icon svg {
    width: 14px;
    height: 14px;
}

/* ---------- Buy Button ---------- */
.bgw-buy-btn {
    display: block;
    width: 100%;
    padding: 14px 24px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 700;
    font-family: var(--bgw-font-family);
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    text-align: center;
    color: #fff;
}

.bgw-buy-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    color: #fff;
}

.bgw-study .bgw-buy-btn {
    background: var(--bgw-study-accent);
}

.bgw-revision .bgw-buy-btn {
    background: var(--bgw-revision-accent);
}

.bgw-buy-btn.bgw-subscribed {
    background: #2E7D32;
    cursor: default;
    opacity: 0.9;
}

.bgw-buy-btn.bgw-subscribed:hover {
    transform: none;
    box-shadow: none;
}

.bgw-buy-btn.bgw-in-cart {
    background: #106F97 !important;
}

/* ---------- Footer Link ---------- */
.bgw-footer-link {
    display: block;
    margin-top: 28px;
    text-align: center;
    font-size: 14px;
    color: var(--bgw-text-primary);
    text-decoration: none;
    line-height: 1.5;
}

.bgw-footer-link span {
    color: var(--bgw-revision-accent);
    font-weight: 700;
}

.bgw-footer-link:hover {
    text-decoration: underline;
}

/* ---------- Empty State ---------- */
.bgw-container--empty {
    max-width: 100%;
}

.bgw-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 20px 32px;
    text-align: center;
}

.bgw-empty-state img {
    width: 200px;
    max-width: 70%;
    height: auto;
    margin-bottom: 24px;
}

.bgw-empty-state p {
    margin: 0;
    font-size: 15px;
    line-height: 1.6;
    color: var(--bgw-text-muted);
    max-width: 280px;
}
