/* Custom styles for SPAR Upjau Rewards UI - High Specificity */

/* Container */
body #spar-redeem-compact-totals {
    background-color: #FFF098 !important;
    border: 1px solid var(--g5-color-border, #e2e2e2) !important;
    border-radius: 4px !important;
    padding: 15px 20px !important;
    /* Increased padding slightly */
    margin-bottom: 20px !important;
    margin-top: 10px !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

/* Row Layout */
body #spar-redeem-compact-totals .spar-compact-row {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    width: 100% !important;
    flex-wrap: nowrap !important;
}

/* "You have points" Text */
body #spar-redeem-compact-totals .spar-compact-left {
    font-family: var(--g5-body-font) !important;
    font-size: 16px !important;
    /* Reduced from 18px */
    /* Enforce larger text */
    font-weight: 700 !important;
    color: var(--g5-color-text-main, #333) !important;
    line-height: 1.4 !important;
}

/* Toggle Button (Redeem Points) */
body #spar-redeem-compact-totals button.spar-compact-toggle-btn {
    background-color: var(--g5-color-primary, #004d25) !important;
    color: #fff !important;
    border: none !important;
    padding: 0 16px !important;
    /* Increased padding */
    /* Force small padding */
    font-size: 13px !important;
    /* Increased from 12px */
    /* Force small font */
    font-weight: 700 !important;
    border-radius: 4px !important;
    cursor: pointer !important;
    text-transform: uppercase !important;
    line-height: 1 !important;
    height: 38px !important;
    /* Increased from 30px */
    /* Fixed small height */
    min-height: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    width: auto !important;
}

body #spar-redeem-compact-totals button.spar-compact-toggle-btn:hover {
    background-color: var(--g5-color-primary-brightness, #007337) !important;
}

/* Panel Container */
body #spar-redeem-compact-totals .spar-redeem-panel {
    margin-top: 15px !important;
    padding-top: 15px !important;
    border-top: 1px solid var(--g5-color-border, #e2e2e2) !important;
}

/* Slider Row */
body #spar-redeem-compact-totals .spar-panel-row {
    display: flex !important;
    align-items: center !important;
    gap: 15px !important;
    margin-bottom: 15px !important;
}

/* Slider Input */
body #spar-redeem-compact-totals input[type=range].spar-redeem-slider {
    flex-grow: 1 !important;
    accent-color: var(--g5-color-primary, #004d25) !important;
    height: 6px !important;
    background: #e2e2e2 !important;
    border-radius: 3px !important;
    outline: none !important;
    margin: 0 !important;
}

/* Number Input */
body #spar-redeem-compact-totals input.spar-redeem-input {
    width: 70px !important;
    padding: 0 10px !important;
    border: 1px solid var(--g5-color-border, #ccc) !important;
    border-radius: 4px !important;
    text-align: center !important;
    font-weight: 600 !important;
    color: var(--g5-color-text-main) !important;
    font-size: 14px !important;
    height: 38px !important;
    /* Match button height */
    min-height: 0 !important;
    line-height: 38px !important;
}

/* Actions Row */
body #spar-redeem-compact-totals .spar-redeem-actions {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 15px !important;
}

/* Discount Value Box */
body #spar-redeem-compact-totals .spar-discount-box {
    font-size: 14px !important;
    font-weight: 600 !important;
    color: var(--g5-color-text-main) !important;
    background: #e8f5e9 !important;
    padding: 0 15px !important;
    border-radius: 4px !important;
    border: 1px solid #c8e6c9 !important;
    display: flex !important;
    align-items: center !important;
    height: 38px !important;
    /* Match button height */
    box-sizing: border-box !important;
}

body #spar-redeem-compact-totals .spar-redeem-value {
    color: var(--g5-color-primary, #004d25) !important;
    font-weight: 700 !important;
    margin-left: 5px !important;
}

/* Apply Button */
body #spar-redeem-compact-totals button.spar-redeem-apply-btn {
    background-color: var(--g5-color-accent, #16892f) !important;
    color: #fff !important;
    border: none !important;
    padding: 0 20px !important;
    font-size: 13px !important;
    /* Increased from 12px */
    font-weight: 700 !important;
    border-radius: 4px !important;
    text-transform: uppercase !important;
    height: 38px !important;
    /* Match other elements */
    min-height: 0 !important;
    line-height: 38px !important;
    margin: 0 !important;
    display: inline-block !important;
}

body #spar-redeem-compact-totals button.spar-redeem-apply-btn:hover {
    background-color: var(--g5-color-accent-brightness, #1baa3a) !important;
}

body #spar-redeem-compact-totals button.spar-redeem-apply-btn:disabled {
    background-color: #ccc !important;
    cursor: not-allowed !important;
}

/* Guest Login Prompt Styles */
.upjau-rewards-login-wrapper {
    margin-bottom: 20px;
    padding: 15px;
    background-color: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    margin-top: 10px;
}

@media (max-width: 768px) {
    .upjau-rewards-login-wrapper {
        padding: 12px;
        margin-bottom: 15px;
    }
}

@media (max-width: 480px) {
    .upjau-rewards-login-wrapper {
        padding: 10px;
        margin-bottom: 12px;
    }
}

.upjau-rewards-login-button {
    width: 100%;
    padding: 12px 20px;
    background-color: #FFF098;
    color: #333;
    border: 1px solid #ffb300;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-align: center;
}

.upjau-rewards-login-button:hover {
    background-color: #ffe066;
}

/* Mobile responsive styles */
@media (max-width: 768px) {
    .upjau-rewards-login-button {
        padding: 10px 15px;
        font-size: 14px;
        gap: 8px;
    }
    
    .upjau-rewards-icon {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .upjau-rewards-login-button {
        padding: 8px 12px;
        font-size: 13px;
        gap: 6px;
    }
    
    .upjau-rewards-icon {
        font-size: 14px;
    }
}

.upjau-rewards-icon {
    font-size: 18px;
}