/* css/buttons.css */
/* Button styles, loading states, and button variants */

/* Button Styles - Soft Whimsy */
button {
    width: 100%;
    padding: 15px;
    margin-bottom: 20px;
    border: none;
    border-radius: 30px;
    background-color: #e91e63;
    color: #fff;
    font-size: clamp(0.9rem, 1vw + 0.7rem, 1rem);
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    min-height: 44px;
    position: relative;
}

button:hover {
    background-color: #ad1457;
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(233, 30, 99, 0.3);
}

button:active {
    transform: scale(0.98);
    box-shadow: 0 2px 6px rgba(233, 30, 99, 0.2);
}

/* Add Wish Button - Crown Polish shine effect */
#add-gift-button {
    overflow: hidden;
}

#add-gift-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.35) 50%, 
        transparent 100%);
    animation: crownPolish 4s ease-in-out infinite;
    animation-delay: 2s;
    pointer-events: none;
}

/* Loading Button Styles */
button.button-loading {
    position: relative;
    pointer-events: none;
    color: transparent;
}

button.button-loading::before {
    content: '';
    position: absolute;
    inset: 0;
    margin: auto;
    width: 22px;
    height: 22px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

button.button-disabled {
    pointer-events: none;
    opacity: 0.6;
    cursor: not-allowed;
}

/* Secondary Button Style */
.secondary-button {
    background-color: #fff;
    color: #e91e63;
    border: 2px solid #e91e63;
}

.secondary-button:hover {
    background-color: #e91e63;
    color: #fff;
}

.secondary-button .lucide {
    width: 1em;
    height: 1em;
}

/* Small Button Style */
.small-button {
    width: auto;
    padding: 8px 16px;
    margin: 0 5px;
    font-size: 0.85em;
    min-height: auto;
}

/* Add Member Button - Primary action with shine effect */
#add-family-member-button {
    background: linear-gradient(135deg, #e91e63, #c2185b);
    color: #fff;
    border: none;
    font-weight: 600;
    box-shadow: 0 3px 10px rgba(233, 30, 99, 0.3);
    position: relative;
    overflow: hidden;
}

#add-family-member-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.35) 50%, 
        transparent 100%);
    animation: crownPolish 3.5s ease-in-out infinite;
    animation-delay: 0.5s;
    pointer-events: none;
}

#add-family-member-button:hover {
    background: linear-gradient(135deg, #c2185b, #ad1457);
    color: #fff;
    box-shadow: 0 4px 15px rgba(233, 30, 99, 0.4);
}

#add-family-member-button .lucide {
    stroke: #fff;
}

/* Manage Group Icon Button - Subtle tertiary style */
.manage-icon-button {
    width: 40px;
    height: 40px;
    min-height: 40px;
    padding: 0;
    margin: 0;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.9);
    border: 1.5px solid rgba(150, 150, 150, 0.4);
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-size: 1em;
}

.manage-icon-button:hover {
    background-color: #f5f5f5;
    border-color: #999;
    color: #333;
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.manage-icon-button:active {
    transform: scale(0.95);
}

.manage-icon-button .lucide {
    width: 20px;
    height: 20px;
    stroke: #666;
}

.manage-icon-button:hover .lucide {
    stroke: #333;
}

/* Danger Button Style */
.danger-button {
    background: linear-gradient(135deg, #f44336, #d32f2f);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 25px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Open Sans', sans-serif;
}

.danger-button:hover:not(:disabled) {
    background: linear-gradient(135deg, #d32f2f, #b71c1c);
    box-shadow: 0 4px 15px rgba(244, 67, 54, 0.4);
    transform: translateY(-2px);
}

.danger-button:disabled {
    background: #ccc;
    cursor: not-allowed;
    opacity: 0.6;
}

.danger-button.button-loading {
    pointer-events: none;
    opacity: 0.7;
}

/* Delete Button Styles */
.delete-button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2em;
    margin-left: 10px;
    color: #ff4d4d;
    padding: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s, transform 0.2s;
    width: auto;
    margin-bottom: 0;
    min-width: 44px;
    min-height: 44px;
}

.delete-button:hover {
    color: #ff1a1a;
    animation: candleFlicker 0.8s ease-in-out infinite;
}

.delete-button:active {
    color: #e60000;
    transform: scale(0.95);
}

.delete-button:focus {
    outline: none;
    color: #e60000;
}

.delete-button .lucide {
    stroke: #ff4d4d;
}

.delete-button:hover .lucide {
    stroke: #ff1a1a;
}

/* Icon Button */
.icon-button {
    width: 48px;
    height: 48px;
    min-height: 48px;
    padding: 0;
    margin: 0;
    border-radius: 50%;
    background-color: #fff;
    border: 2px solid #e91e63;
    color: #e91e63;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-size: 1.2em;
}

.icon-button:hover {
    background-color: #e91e63;
    color: #fff;
    transform: scale(1.08);
    box-shadow: 0 4px 12px rgba(233, 30, 99, 0.3);
}

.icon-button:active {
    transform: scale(0.95);
}

.icon-button .lucide {
    stroke: #e91e63 !important;
}

.icon-button:hover .lucide {
    stroke: #fff !important;
}

.copy-icon, .share-icon {
    pointer-events: none;
}

/* Back Arrow Button */
.back-arrow {
    position: absolute;
    top: 20px;
    left: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    outline: none;
    width: auto;
    height: auto;
    padding: 10px;
    font-size: 2rem;
    line-height: 1;
    z-index: 10000;
    color: #e91e63;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    transition: transform 0.2s, color 0.3s;
    animation: sleighGlide 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.back-arrow:hover {
    transform: translateX(-3px);
}

.back-arrow:active {
    transform: scale(0.9);
    color: #ad1457;
}

.back-arrow .lucide {
    width: 1.5em;
    height: 1.5em;
    color: #e91e63;
}

/* Logout Button Styles */
.logout-button {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    width: auto;
    padding: 10px 20px;
    margin: 0;
    background-color: rgba(255, 255, 255, 0.95);
    color: #e91e63;
    border: 2px solid #e91e63;
    border-radius: 25px;
    font-size: 0.9em;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(233, 30, 99, 0.2);
    animation: slideInFromRight 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.logout-button:hover {
    background-color: #e91e63;
    color: #fff;
    transform: scale(1.05);
    box-shadow: 0 4px 16px rgba(233, 30, 99, 0.4);
}

.logout-button:active {
    transform: scale(0.98);
}

.logout-icon {
    font-size: 1.1em;
    transition: transform 0.3s ease;
}

.logout-button:hover .logout-icon {
    transform: translateX(2px);
}

@media (max-width: 480px) {
    .logout-button {
        padding: 10px 14px;
        top: 15px;
        right: 15px;
    }
    
    .logout-text {
        display: none;
    }
    
    .logout-icon {
        font-size: 1.3em;
    }
}

/* Support Button Styles */
.support-button {
    position: fixed;
    top: 20px;
    right: 145px;
    z-index: 1000;
    width: auto;
    padding: 10px 20px;
    margin: 0;
    text-decoration: none;
    height: auto;
    min-height: 44px;
    box-sizing: border-box;
    background: linear-gradient(135deg, #ff6b6b, #ee5a5a);
    color: #fff;
    border: 2px solid transparent;
    border-radius: 25px;
    font-size: 0.9em;
    font-weight: 600;
    font-family: 'Open Sans', sans-serif;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 3px 12px rgba(238, 90, 90, 0.35);
    animation: slideInFromRight 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
}

/* Crown Polish shine effect for Support button */
.support-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.4) 50%, 
        transparent 100%);
    animation: crownPolish 3s ease-in-out infinite;
    animation-delay: 0.5s;
    pointer-events: none;
}

.support-button:hover {
    background: linear-gradient(135deg, #ff5252, #e64545);
    color: #fff;
    transform: scale(1.05) translateY(-1px);
    box-shadow: 0 5px 20px rgba(238, 90, 90, 0.5);
}

.support-button:active {
    transform: scale(0.98);
}

.support-icon {
    font-size: 1em;
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
}

.support-button:hover .support-icon {
    animation: heartbeat 0.6s ease-in-out;
}

@media (max-width: 600px) {
    .support-button {
        right: 75px;
        padding: 10px 14px;
        top: 15px;
    }
    
    .support-text {
        display: none;
    }
    
    .support-icon {
        font-size: 1.3em;
    }
}

@media (max-width: 480px) {
    .support-button {
        right: 65px;
    }
    
    .icon-button {
        width: 52px;
        height: 52px;
    }
}

.support-button.login-visible {
    right: 20px;
}

@media (max-width: 600px) {
    .support-button.login-visible {
        right: 15px;
    }
}

/* Share Group Button */
.share-group-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: auto;
    padding: 10px 18px;
    margin: 0;
    background-color: #fff;
    color: #e91e63;
    border: 2px solid #e91e63;
    border-radius: 25px;
    font-size: 0.9em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

/* Crown Polish shine effect for Share Group button */
.share-group-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(233, 30, 99, 0.2) 50%, 
        transparent 100%);
    animation: crownPolish 3.5s ease-in-out infinite;
    animation-delay: 1.5s;
    pointer-events: none;
}

.share-group-btn:hover {
    background-color: #e91e63;
    color: #fff;
    transform: scale(1.02);
}

.share-group-btn:active {
    transform: scale(0.98);
}

.share-group-btn .lucide {
    width: 1.1em;
    height: 1.1em;
}

/* Group Delete Button */
.group-delete-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    min-width: 24px;
    min-height: 24px;
    max-width: 24px;
    max-height: 24px;
    border-radius: 50%;
    border: 2px solid rgba(244, 67, 54, 0.4);
    background: rgba(244, 67, 54, 0.1);
    color: #f44336;
    font-size: 1.1em;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    line-height: 1;
    padding: 0;
    z-index: 5;
    flex-shrink: 0;
    box-sizing: border-box;
}

.group-delete-btn:hover {
    background: rgba(244, 67, 54, 0.2);
    border-color: #f44336;
    transform: translateY(-50%) scale(1.1);
}

.group-delete-btn:active {
    transform: translateY(-50%) scale(0.95);
}

/* Claim Link Button */
.claim-link-btn {
    width: auto;
    height: auto;
    min-width: auto;
    min-height: auto;
    max-width: none;
    max-height: none;
    padding: 4px 10px;
    margin: 0;
    border-radius: 12px;
    background: rgba(33, 150, 243, 0.1);
    border: 1px solid rgba(33, 150, 243, 0.4);
    color: #1976d2;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all 0.2s ease;
    font-size: 0.7em;
    font-weight: 600;
}

.claim-link-btn:hover {
    background: rgba(33, 150, 243, 0.2);
    border-color: #1976d2;
    transform: scale(1.05);
}

.claim-link-btn:active {
    transform: scale(0.95);
}

.claim-link-btn .lucide {
    width: 12px;
    height: 12px;
}

/* Action Buttons Container */
.action-buttons {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    gap: 4px;
}

/* Wish More Button (three-dot menu) */
.wish-more-button {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    padding: 0;
    margin: 0;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: #999;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.wish-more-button:hover:not(:disabled) {
    background: rgba(233, 30, 99, 0.1);
    color: #e91e63;
    transform: scale(1.1);
}

.wish-more-button:active:not(:disabled) {
    transform: scale(0.95);
}

.wish-more-button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.wish-more-button .lucide {
    width: 20px;
    height: 20px;
    stroke: currentColor;
}

/* Delete Wish Button (in modal) */
.delete-wish-button {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    margin: 0;
    background: linear-gradient(135deg, #f44336, #d32f2f);
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 0.95em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.delete-wish-button:hover:not(:disabled) {
    background: linear-gradient(135deg, #d32f2f, #b71c1c);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(244, 67, 54, 0.35);
}

.delete-wish-button:active:not(:disabled) {
    transform: translateY(0);
}

.delete-wish-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.delete-wish-button .lucide {
    width: 18px;
    height: 18px;
    stroke: white;
}

/* Button Animations */
@keyframes slideInFromRight {
    0% {
        opacity: 0;
        transform: translateX(30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.2); }
    50% { transform: scale(1); }
    75% { transform: scale(1.15); }
}

