/* Install Popup Styles - Retained for compatibility */
.install-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    animation: installFadeIn 0.5s ease-out;
}

.install-popup-content {
    background: var(--bg-card);
    border-radius: 1.5rem;
    padding: 2.5rem;
    text-align: center;
    max-width: 90%;
    width: 400px;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-color);
    transform: translateY(0);
    transition: transform 0.3s ease;
    position: relative; /* Add this for close button positioning */
}

/* Add close button styles */
.install-popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-secondary);
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.install-popup-close:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.install-popup-content:hover {
    transform: translateY(-5px);
}

.app-icon-container {
    width: 100px;
    height: 100px;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 1.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.app-icon {
    width: 70px;
    height: 70px;
    border-radius: 50%;
}

.app-name {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.rating-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.stars {
    color: #f59e0b;
    font-size: 1rem;
}

.rating-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.install-instruction {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.install-button {
    background: var(--gradient-primary);
    color: white;
    border: none;
    border-radius: 0.75rem;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    margin-bottom: 1rem;
}

.install-button:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.install-button:active {
    transform: translateY(-1px);
}

.ios-instruction {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-top: 1rem;
}

.ios-instruction i {
    color: var(--primary-color);
}

.fallback-instruction {
    font-size: 0.85rem;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.fallback-link {
    font-size: 0.75rem;
    color: var(--text-secondary);
    background: var(--bg-secondary);
    padding: 0.5rem;
    border-radius: 0.5rem;
    word-break: break-all;
    margin-bottom: 1rem;
}

@keyframes installFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Floating Action Button (FAB) Styles */
.fab-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
}

.fab-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 24px;
    transition: all 0.3s ease;
    animation: pulse 2s infinite;
    position: relative;
}

.fab-button:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.fab-button:active {
    transform: scale(1.05);
}

/* Tooltip for FAB - Only the top one */
.fab-button::before {
    content: "Install App";
    position: absolute;
    bottom: 70px;
    right: 50%;
    transform: translateX(50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    z-index: 10000;
}

.fab-button:hover::before {
    opacity: 1;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.7);
    }
    70% {
        box-shadow: 0 0 0 12px rgba(99, 102, 241, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(99, 102, 241, 0);
    }
}

/* Responsive styles */
@media (max-width: 768px) {
    .install-popup-content {
        padding: 2rem 1.5rem;
        width: 90%;
    }
    
    .app-icon-container {
        width: 80px;
        height: 80px;
        margin-bottom: 1.25rem;
    }
    
    .app-icon {
        width: 55px;
        height: 55px;
    }
    
    .app-name {
        font-size: 1.5rem;
        margin-bottom: 0.75rem;
    }
    
    .install-instruction {
        margin-bottom: 1.5rem;
    }
    
    .install-button {
        padding: 0.875rem 1.5rem;
        font-size: 0.95rem;
    }
    
    .rating-container {
        margin-bottom: 1.25rem;
    }
    
    .stars {
        font-size: 0.9rem;
    }
    
    .rating-text {
        font-size: 0.8rem;
    }
    
    /* FAB responsive styles */
    .fab-container {
        bottom: 20px;
        right: 20px;
    }
    
    .fab-button {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
    
    /* Adjust tooltip for mobile */
    .fab-button::before {
        font-size: 12px;
        padding: 4px 8px;
        bottom: 60px;
    }
}

@media (max-width: 480px) {
    .install-popup-content {
        padding: 1.5rem 1rem;
    }
    
    .app-icon-container {
        width: 70px;
        height: 70px;
        margin-bottom: 1rem;
    }
    
    .app-icon {
        width: 50px;
        height: 50px;
    }
    
    .app-name {
        font-size: 1.35rem;
    }
    
    .install-instruction {
        font-size: 0.9rem;
        margin-bottom: 1.25rem;
    }
    
    .install-button {
        padding: 0.75rem 1.25rem;
        font-size: 0.9rem;
    }
    
    .ios-instruction {
        font-size: 0.8rem;
    }
    
    .fallback-instruction {
        font-size: 0.75rem;
    }
    
    .fallback-link {
        font-size: 0.65rem;
    }
    
    .rating-container {
        margin-bottom: 1rem;
    }
    
    .stars {
        font-size: 0.8rem;
    }
    
    .rating-text {
        font-size: 0.7rem;
    }
    
    /* FAB responsive styles */
    .fab-container {
        bottom: 15px;
        right: 15px;
    }
    
    .fab-button {
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
    
    /* Adjust tooltip for small mobile */
    .fab-button::before {
        bottom: 55px;
    }
}