/**
 * PWA Install Banner Styles - Kormi Design
 */

/* Install Banner */
.pwa-install-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #FFFFFF;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
    padding: 16px 20px;
    z-index: 9998;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-top: 3px solid;
    border-image: linear-gradient(90deg, #2196F3, #E53935, #FFD600, #E8734A) 1;
}

.pwa-install-banner.show {
    transform: translateY(0);
}

.pwa-install-content {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.pwa-install-icon {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.pwa-install-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pwa-install-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.pwa-install-text strong {
    font-family: 'Playfair Display', serif;
    font-size: 1rem;
    font-weight: 600;
    color: #2D3436;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pwa-install-text span {
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    color: #636E72;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pwa-install-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.pwa-install-dismiss {
    padding: 8px 16px;
    background: linear-gradient(135deg, #29B6F6 0%, #0288D1 100%);
    border: none;
    border-radius: 999px;
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 500;
    color: #FFFFFF;
    cursor: pointer;
    transition: all 0.2s;
}

.pwa-install-dismiss:hover {
    background: linear-gradient(135deg, #0288D1 0%, #01579B 100%);
    transform: translateY(-1px);
}

.pwa-install-button {
    padding: 10px 20px;
    background: linear-gradient(135deg, #E53935 0%, #E8734A 100%);
    border: none;
    border-radius: 999px;
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    color: #FFFFFF;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(229, 57, 53, 0.2);
}

.pwa-install-button:hover {
    background: linear-gradient(135deg, #C62828 0%, #D4623C 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(229, 57, 53, 0.3);
}

/* Mobile adjustments */
@media (max-width: 576px) {
    .pwa-install-banner {
        flex-direction: row;
        align-items: center;
        padding: 12px 16px;
        gap: 10px;
    }

    .pwa-install-content {
        gap: 10px;
        flex: 1;
        min-width: 0;
    }

    .pwa-install-icon {
        width: 36px;
        height: 36px;
        border-radius: 8px;
    }

    .pwa-install-text strong {
        font-size: 0.85rem;
    }

    .pwa-install-text span {
        display: none;
    }

    .pwa-install-actions {
        gap: 6px;
    }

    .pwa-install-dismiss {
        padding: 6px 10px;
        font-size: 0.8rem;
    }

    .pwa-install-button {
        padding: 8px 14px;
        font-size: 0.8rem;
    }
}

/* iOS Modal */
.pwa-ios-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.pwa-ios-modal.show {
    opacity: 1;
    visibility: visible;
}

.pwa-ios-modal-content {
    background: #FFFFFF;
    border-radius: 24px;
    padding: 32px 24px;
    max-width: 340px;
    width: 100%;
    text-align: center;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.pwa-ios-modal.show .pwa-ios-modal-content {
    transform: scale(1);
}

.pwa-ios-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #F5F5F5;
    border: none;
    border-radius: 50%;
    color: #636E72;
    cursor: pointer;
    transition: all 0.2s;
}

.pwa-ios-close:hover {
    background: #EEEEEE;
    color: #2D3436;
}

.pwa-ios-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 16px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.pwa-ios-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pwa-ios-modal h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: #2D3436;
    margin-bottom: 8px;
}

.pwa-ios-modal p {
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    color: #636E72;
    margin-bottom: 20px;
}

.pwa-ios-steps {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
    text-align: left;
}

.pwa-ios-steps li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #F0F0F0;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    color: #2D3436;
}

.pwa-ios-steps li:last-child {
    border-bottom: none;
}

.pwa-ios-steps li:nth-child(1) .step-icon { background: #2196F3; }
.pwa-ios-steps li:nth-child(2) .step-icon { background: #E53935; }
.pwa-ios-steps li:nth-child(3) .step-icon { background: #FFD600; }

.pwa-ios-steps .step-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    border-radius: 8px;
    flex-shrink: 0;
}

.pwa-ios-steps .step-icon i {
    font-size: 1rem;
}

.pwa-ios-ok {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #E53935 0%, #E8734A 100%);
    border: none;
    border-radius: 999px;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    color: #FFFFFF;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(229, 57, 53, 0.2);
}

.pwa-ios-ok:hover {
    background: linear-gradient(135deg, #C62828 0%, #D4623C 100%);
    box-shadow: 0 6px 16px rgba(229, 57, 53, 0.3);
}

/* Already installed - hide banner */
.pwa-installed .pwa-install-banner {
    display: none !important;
}
