/**
 * HifzIQ PWA Install Banner Styles
 * Warm, on-brand green with smooth animations
 */

#hifziq-install-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 999999;

    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;

    background: #ffffff;
    border-top: 3px solid #1a5c38;
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.12);

    /* Slide up animation */
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);

    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

#hifziq-install-banner.hifziq-banner-visible {
    transform: translateY(0);
}

/* Icon */
.hifziq-banner-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    overflow: hidden;
    background: #f0f7f3;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hifziq-banner-icon img {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 12px;
}

/* Text */
.hifziq-banner-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.hifziq-banner-text strong {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
}

.hifziq-banner-text span {
    font-size: 12px;
    color: #666;
    line-height: 1.4;
    display: flex;
    align-items: center;
    gap: 4px;
}

.hifziq-banner-text span svg {
    color: #1a5c38;
    flex-shrink: 0;
}

/* Install button */
.hifziq-banner-install {
    flex-shrink: 0;
    background: #1a5c38;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 9px 18px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
    white-space: nowrap;
}

.hifziq-banner-install:hover {
    background: #154a2d;
}

.hifziq-banner-install:active {
    transform: scale(0.97);
}

/* Close button */
.hifziq-banner-close {
    flex-shrink: 0;
    background: none;
    border: none;
    color: #999;
    font-size: 16px;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
    line-height: 1;
}

.hifziq-banner-close:hover {
    background: #f5f5f5;
    color: #333;
}

/* Desktop — show as a corner card instead of full-width bar */
@media (min-width: 768px) {
    #hifziq-install-banner {
        bottom: 24px;
        left: auto;
        right: 24px;
        width: 340px;
        border-radius: 16px;
        border-top: none;
        border-left: 4px solid #1a5c38;
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
        transform: translateX(120%);
    }

    #hifziq-install-banner.hifziq-banner-visible {
        transform: translateX(0);
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    #hifziq-install-banner {
        background: #1e2a23;
        border-color: #2e8b57;
    }

    .hifziq-banner-text strong {
        color: #f0f0f0;
    }

    .hifziq-banner-text span {
        color: #aaa;
    }

    .hifziq-banner-close:hover {
        background: #2a3d2f;
        color: #ddd;
    }

    .hifziq-banner-icon {
        background: #2a3d2f;
    }
}
