/* ===========================================
   Web Push 複習提醒：軟詢問卡片 / toast / profile 開關
   注意：components.css 有全域 button { color: white }，
   這裡所有按鈕都要明確指定顏色。
   =========================================== */

/* --- 軟詢問卡片 --- */
.push-soft-ask {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 9999;
    width: 300px;
    max-width: calc(100vw - 32px);
    background: #fffaf3;
    border: 2px solid #d7ccc8;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(62, 39, 35, 0.25);
    padding: 16px;
    text-align: center;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.push-soft-ask.show {
    opacity: 1;
    transform: translateY(0);
}

.push-soft-ask-img {
    width: 72px;
    height: 72px;
    object-fit: contain;
    margin-bottom: 8px;
}

.push-soft-ask-text {
    margin: 0 0 12px;
    font-size: 14px;
    line-height: 1.6;
    color: #3e2723;
}

.push-soft-ask-actions {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.push-btn {
    border: none;
    border-radius: 20px;
    padding: 8px 18px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.push-btn:hover {
    transform: translateY(-1px);
}

.push-btn:disabled {
    opacity: 0.6;
    cursor: wait;
}

.push-btn-accept {
    background: #d84315;
    color: #ffffff;
}

.push-btn-accept:hover {
    background: #bf360c;
}

.push-btn-decline {
    background: #efebe9;
    color: #6d4c41;
}

.push-btn-decline:hover {
    background: #d7ccc8;
    color: #4e342e;
}

/* --- toast --- */
.push-toast {
    position: fixed;
    left: 50%;
    bottom: 40px;
    transform: translate(-50%, 16px);
    z-index: 10000;
    background: rgba(62, 39, 35, 0.92);
    color: #ffffff;
    font-size: 14px;
    padding: 10px 20px;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
    max-width: calc(100vw - 40px);
}

.push-toast.show {
    opacity: 1;
    transform: translate(-50%, 0);
}

.push-toast-error {
    background: rgba(183, 28, 28, 0.95);
}

/* --- profile 頁開關按鈕 --- */
.push-toggle {
    border: 1px solid #d7ccc8;
    border-radius: 14px;
    padding: 3px 14px;
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    background: #efebe9;
    color: #8d6e63;
    transition: background 0.2s ease, color 0.2s ease;
}

.push-toggle.push-toggle-on {
    background: #2e7d32;
    border-color: #2e7d32;
    color: #ffffff;
}

.push-toggle:disabled {
    opacity: 0.6;
    cursor: wait;
}

/* --- 深色模式 --- */
[data-theme="dark"] .push-soft-ask {
    background: #2c2523;
    border-color: #4e423e;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .push-soft-ask-text {
    color: #efebe9;
}

[data-theme="dark"] .push-btn-accept {
    background: #ff7043;
    color: #1a1412;
}

[data-theme="dark"] .push-btn-accept:hover {
    background: #ff8a65;
}

[data-theme="dark"] .push-btn-decline {
    background: #3e3532;
    color: #d7ccc8;
}

[data-theme="dark"] .push-btn-decline:hover {
    background: #4e423e;
    color: #efebe9;
}

[data-theme="dark"] .push-toggle {
    background: #3e3532;
    border-color: #4e423e;
    color: #bcaaa4;
}

[data-theme="dark"] .push-toggle.push-toggle-on {
    background: #66bb6a;
    border-color: #66bb6a;
    color: #1a1412;
}
