/* 订阅表格基础样式 */
.bbw-subscription-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.bbw-subscription-table th,
.bbw-subscription-table td {
    padding: 10px;
    border: 1px solid #eee;
    text-align: left;
}

.bbw-subscription-table th {
    background: #f7f7f7;
}

/* 订阅按钮基础样式 */
.bbw-subscribe-button-guest,
.bbw-subscribe-button {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    line-height: 1;
    transition: background 0.3s, color 0.3s;
}

.bbw-subscribe-button-guest{
    background-color: var(--e-global-color-accent);
}

.bbw-subscribe-button-guest:hover a{
    color: #fff !important;
}

/* 取消订阅按钮样式 */
.bbw-unsubscribe-button {
    color: #777;
    text-decoration: none;
    padding: 4px 8px;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.bbw-unsubscribe-button:hover {
    color: #999;
    background: #f5f5f5;
}

/* 加载状态样式 */
.bbw-subscribe-button.loading,
.bbw-unsubscribe-button.loading {
    position: relative;
    color: transparent !important;
    pointer-events: none;
    opacity: 0.7;
}

.bbw-subscribe-button.loading:after,
.bbw-unsubscribe-button.loading:after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1em;
    height: 1em;
    margin-top: -0.5em;
    margin-left: -0.5em;
    border: 2px solid rgba(255,255,255,0.25);
    border-top-color: #777;
    border-radius: 50%;
    animation: button-spin 1s linear infinite;
}

/* 复选框加载状态 */
.subscription-checkbox {
    position: relative;
    cursor: pointer;
}

.subscription-checkbox.loading {
    pointer-events: none;
    opacity: 0.7;
}

.subscription-checkbox.loading:after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    height: 12px;
    margin-top: -6px;
    margin-left: -6px;
    border: 2px solid rgba(0,0,0,0.1);
    border-top-color: #333;
    border-radius: 50%;
    animation: button-spin 1s linear infinite;
}

/* 动画效果 */
@keyframes button-spin {
    to {
        transform: rotate(360deg);
    }
}

/* 响应式适配 */
@media screen and (max-width: 768px) {
    .bbw-subscription-table {
        display: block;
        overflow-x: auto;
    }

    .bbw-subscription-table th,
    .bbw-subscription-table td {
        white-space: nowrap;
    }
}

.notification-bar {
    position: fixed;
    top: -60px;
    left: 0;
    right: 0;
    padding: 12px 16px;
    text-align: center;
    color: white;
    z-index: 1000;
    transition: top 0.3s ease-in-out;
    font-size: 16px;
    font-weight: 500;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.notification-bar.show {
    top: 0;
}

/* 成功状态样式 */
.notification-bar.success {
    background-color: #4CAF50;
}

/* 警告状态样式 */
.notification-bar.warning {
    background-color: #FF9800;
}

/* 错误状态样式 */
.notification-bar.error {
    background-color: #F44336;
}

.notification-prompt {
    position: fixed;
    top: 20px;
    left: 20px;
    max-width: 400px;
    width: calc(100% - 40px);
    z-index: 1000;
}

.notification-content {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 16px;
    border: 1px solid #e5e7eb;
}

.notification-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.notification-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}

.notification-description {
    color: #4b5563;
    margin-bottom: 16px;
    font-size: 14px;
}

.notification-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.bell-icon, .bell-off-icon {
    stroke: currentColor;
}

button {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}

.close-button {
    padding: 4px;
    color: #9ca3af;
    background: transparent;
    border-radius: 50%;
}

.close-button:hover {
    background: #f3f4f6;
    color: #4b5563;
}

.deny-button {
    color: #4b5563;
    background: #f3f4f6;
}

.deny-button:hover {
    background: #999;
}

.allow-button {
    color: white;
    background: #3b82f6;
}

.allow-button:hover {
    background: #2563eb;
}

.allow-button {
    position: relative;
    /* 保持你现有的按钮样式 */
    background-color: #4CAF50;
    color: white;
    padding: 10px 20px;
}

.button-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    animation: button-spin 1s linear infinite;
    margin-left: 8px;
    vertical-align: middle;
}

@keyframes button-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 按钮加载状态 */
.allow-button.loading {
    cursor: not-allowed;
    opacity: 0.8;
}

.allow-button.loading .button-text {
    opacity: 0.8;
}

@media (max-width: 480px) {
    .notification-prompt {
        bottom: 12px;
        right: 12px;
        width: calc(100% - 24px);
    }

    .notification-actions {
        flex-direction: column;
    }

    button {
        width: 100%;
        justify-content: center;
    }
}