/* Tabs */
.tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 0.5rem;
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.tab {
    flex: 1;
    padding: 1rem;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.tab:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.tab.active {
    background: var(--primary);
    color: white;
}

/* Tab Content */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}


/* Subscription Plans */
.plans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.plan-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    transition: all 0.3s;
    border: 3px solid transparent;
    position: relative;
}

.plan-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(0, 200, 83, 0.2);
}

.plan-card.selected {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(0, 200, 83, 0.05), rgba(0, 200, 83, 0.1));
}

.plan-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.plan-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.plan-badge.limit-badge {
    background: rgba(255, 160, 0, 0.25);
    color: #ffd28a;
}

.plan-badge.popular {
    background: linear-gradient(135deg, #ffd600, #ff8f00);
}

.checkbox-wrapper {
    position: relative;
}

.plan-checkbox {
    width: 24px;
    height: 24px;
    cursor: pointer;
    accent-color: var(--primary);
}

.plan-card h3 {
    font-size: 1.75rem;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}

.plan-description {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.plan-price {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary);
    margin-bottom: 0.25rem;
}

.plan-price span {
    font-size: 1rem;
    color: var(--text-light);
    font-weight: normal;
}

.plan-features {
    list-style: none;
    margin: 1.5rem 0;
}

.plan-features li {
    padding: 0.75rem 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text);
    border-bottom: 1px solid #e2e8f0;
}

.plan-features li:last-child {
    border-bottom: none;
}

.plan-features li::before {
    content: '✓';
    color: var(--primary);
    font-weight: bold;
    font-size: 1.2rem;
}


/* Checkout Section */
.checkout-section {
    color: var(--text);
    background: var(--card-bg);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    position: sticky;
    top: 100px;
}

.checkout-header {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--secondary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.selected-items {
    margin-bottom: 1.5rem;
}

.selected-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: rgba(0, 200, 83, 0.05);
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.selected-item-name {
    font-weight: 600;
    color: var(--text);
}

.selected-item-price {
    font-weight: bold;
    color: var(--primary);
}

.empty-cart {
    text-align: center;
    padding: 2rem;
    color: var(--text-light);
}

.empty-cart-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.divider {
    border: none;
    border-top: 2px solid #e2e8f0;
    margin: 1.5rem 0;
}

.total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.25rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
}

.total-amount {
    color: var(--primary);
    font-size: 1.75rem;
}

.checkout-btn {
    width: 100%;
    padding: 1rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.checkout-btn.waiting {
    background: #9ca3af; /* gray */
    cursor: not-allowed;
    opacity: 0.8;
}

.checkout-btn:hover:not(:disabled) {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 200, 83, 0.3);
}

.checkout-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}


/* Active Subscriptions */
.subscriptions-list {
    display: grid;
    gap: 1.5rem;
}

.subscription-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.subscription-info {
    flex: 1;
}

.subscription-name {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}

.subscription-status {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.subscription-status.active {
    background: rgba(0, 200, 83, 0.1);
    color: var(--primary);
}

.subscription-status.cancel-pending {
    background: rgba(255, 193, 7, 0.2);  /* soft amber */
    color: #B88600;                      /* dark amber text */
    border: 1px solid rgba(255, 193, 7, 0.5);
}

.subscription-status.cancelled {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.subscription-details {
    color: var(--text-light);
    font-size: 0.9rem;
}

.subscription-details div {
    margin-bottom: 0.25rem;
}

.subscription-actions {
    display: flex;
    gap: 1rem;
}

.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    text-decoration: none;
    display: inline-block;
}

.btn-manage {
    background: var(--primary);
    color: white;
}

.btn-manage:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-cancel {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    border: 2px solid var(--danger);
}

.btn-cancel:hover {
    background: var(--danger);
    color: white;
}

.no-subscriptions {
    text-align: center;
    padding: 4rem 2rem;
    color: rgba(255, 255, 255, 0.7);
}

.no-subscriptions-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.no-subscriptions h3 {
    color: white;
    margin-bottom: 0.5rem;
}

.layout-grid {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 2rem;
    align-items: start;
}






.btn-secondary {
    background: #e2e8f0;
    color: var(--text);
}

.btn-secondary:hover {
    background: #cbd5e0;
}


/* === PLAN COMPARISON TABLE === */

.league-info-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 0.75rem 1.25rem;
    margin: 2rem 0 1rem;

    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.league-info-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.league-info-icon {
    width: 28px;
    height: 28px;
    flex-shrink: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 1.1rem;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 50%;
}

.league-info-text {
    display: flex;
    gap: 0.4rem;
    align-items: center;
    flex-wrap: wrap;

    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.75);
}

.league-info-text strong {
    color: white;
    font-weight: 600;
}

/* Mobile */
@media (max-width: 768px) {
    .league-info-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}

.plans-grid-table {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin: 2rem 0;
}

.plan-table-row {
    display: grid;
    grid-template-columns: 60px 1fr 150px;
    align-items: center;
    padding: 1.2rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    transition: background 0.2s, border 0.2s;
}

.plan-table-row:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary);
}

.plan-table-checkbox {
    display: flex;
    justify-content: center;
}

.plan-table-checkbox input {
    transform: scale(1.4);
}

.plan-table-name {
    color: white;
    font-size: 1rem;
    display: flex;
    gap: 0.6rem;
    align-items: center;
}

.plan-table-price {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--primary);
    text-align: right;
}

.plan-table-price span {
    font-weight: 400;
    color: rgba(255,255,255,0.6);
    font-size: 0.85rem;
}

.plan-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    background: rgba(255, 255, 255, 0.15);
}

.plan-badge.popular {
    background: rgba(255, 200, 0, 0.25);
}

.disabled-row {
    opacity: 0.5;
    pointer-events: none;
}


@media (max-width: 768px) {

    .plan-table-row {
        grid-template-columns: 1fr; /* stack items vertically */
        text-align: left;
        gap: 0.75rem;
    }

    .plan-table-checkbox {
        justify-content: flex-start;
    }

    .plan-table-price {
        text-align: left;
        font-size: 1.2rem;
    }

    .subscription-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .subscription-actions {
        width: 100%;
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .layout-grid {
        grid-template-columns: 1fr;
    }

    .checkout-section {
        position: static;
    }
}



.telegram-info-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 0.75rem 1.25rem;
    margin-bottom: 1.5rem;

    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.telegram-info-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.telegram-info-icon {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

.telegram-info-text {
    display: flex;
    gap: 0.4rem;
    align-items: center;
    flex-wrap: wrap;

    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.75);
}

.telegram-info-text strong {
    color: white;
    font-weight: 600;
}

.telegram-info-text code {
    background: rgba(255, 255, 255, 0.12);
    padding: 2px 6px;
    border-radius: 5px;
    font-size: 0.8rem;
    color: white;
}

.telegram-info-cta {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

/* Mobile */
@media (max-width: 768px) {
    .telegram-info-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
}



   /* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 16px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.modal-header {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--secondary);
}

.modal-body {
    color: var(--text);
    margin-bottom: 1.5rem;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}


.btn.btn-confirm {
    color: white;
    background: var(--primary);
}







/* ==========================
   CONFIRM INFO BLOCK
   ========================== */

.confirm-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin: 1.25rem 0 1.75rem;
}

.confirm-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 0.6rem 0;
}

/* Labels */
.confirm-row .label {
    font-size: 0.95rem;
    color: #64748b; /* muted slate */
}

/* Values */
.confirm-row .value {
    font-size: 1.05rem;
    font-weight: 600;
    color: #0f172a;
    letter-spacing: 0.2px;
}

/* Primary monetary value */
.confirm-row .value-primary {
    font-size: 1.15rem;
    color: #16a34a; /* premium green */
}

/* Period text */
.confirm-row .period {
    font-size: 0.85rem;
    font-weight: 500;
    color: #64748b;
    margin-left: 0.25rem;
}

/* Muted value (date) */
.confirm-row .value-muted {
    font-weight: 500;
    color: #334155;
}

/* Optional subtle dividers */
.confirm-row:not(:last-child) {
    border-bottom: 1px dashed rgba(15, 23, 42, 0.08);
}

