/* Bandeau et UI PWA */
.pwa-install-banner {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10050;
    width: min(560px, calc(100vw - 2rem));
    animation: pwa-slide-up 0.35s ease;
}

.pwa-install-banner[hidden],
.pwa-ios-hint[hidden],
.pwa-update-toast[hidden] {
    display: none !important;
}

.pwa-install-banner__inner,
.pwa-ios-hint__inner {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.pwa-install-banner__icon img {
    border-radius: 10px;
    display: block;
}

.pwa-install-banner__text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    font-size: 0.875rem;
    color: #495057;
}

.pwa-install-banner__text strong {
    color: #212529;
    font-size: 0.95rem;
}

.pwa-install-banner__actions {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    flex-shrink: 0;
}

.pwa-ios-hint {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10049;
    width: min(480px, calc(100vw - 2rem));
}

.pwa-ios-hint__inner {
    font-size: 0.875rem;
    color: #495057;
    justify-content: space-between;
}

.pwa-update-toast {
    position: fixed;
    top: calc(var(--navbar-height, 70px) + 0.75rem);
    right: 1rem;
    z-index: 10051;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 0.85rem;
    background: #212529;
    color: #fff;
    border-radius: 10px;
    font-size: 0.875rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.pwa-btn {
    font-family: inherit;
    cursor: pointer;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    transition: opacity 0.2s;
}

.pwa-btn:hover {
    opacity: 0.9;
}

.pwa-btn-sm {
    padding: 0.4rem 0.75rem;
    font-size: 0.8rem;
}

.pwa-btn-primary {
    background: #26a69a;
    color: #fff;
}

.pwa-btn-ghost {
    background: transparent;
    color: #6c757d;
}

.pwa-btn-link {
    display: inline-block;
    margin-top: 0.75rem;
    color: #26a69a;
    text-decoration: none;
    font-size: 0.9rem;
}

/* Page hors ligne */
.pwa-offline-page {
    margin: 0;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f6f9;
    font-family: "Heebo", "Inter", system-ui, sans-serif;
    padding: 1.5rem;
}

.pwa-offline-card {
    text-align: center;
    max-width: 420px;
    background: #fff;
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}

.pwa-offline-icon {
    font-size: 3rem;
    color: #26a69a;
    margin-bottom: 1rem;
}

.pwa-offline-card h1 {
    font-size: 1.35rem;
    margin: 0 0 0.75rem;
    color: #212529;
}

.pwa-offline-card p {
    color: #6c757d;
    line-height: 1.5;
    margin: 0 0 1.25rem;
}

@keyframes pwa-slide-up {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@media (max-width: 576px) {
    .pwa-install-banner__inner {
        flex-wrap: wrap;
    }

    .pwa-install-banner__actions {
        flex-direction: row;
        width: 100%;
        justify-content: flex-end;
    }
}
