/* Byna "Add to home screen" install banner. Framework-agnostic so it works
   on both the React/Inertia shell and the legacy Blade pages. Theme tracks
   the .dark class that both shells set on <html>. */

.byna-pwa-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2147483000;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    padding-top: calc(12px + env(safe-area-inset-top, 0px));
    background: #ffffff;
    color: #0a0a0a;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    font-family: inherit;
    transform: translateY(-115%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.byna-pwa-banner.is-visible {
    transform: translateY(0);
}

html.dark .byna-pwa-banner {
    background: #161616;
    color: #fafafa;
    border-bottom-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.55);
}

.byna-pwa-banner__icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    flex: 0 0 auto;
    object-fit: cover;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.byna-pwa-banner__body {
    flex: 1 1 auto;
    min-width: 0;
}

.byna-pwa-banner__title {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.25;
}

.byna-pwa-banner__text {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 2px;
    font-size: 13px;
    line-height: 1.3;
    opacity: 0.7;
}

.byna-pwa-banner__text svg {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}

.byna-pwa-banner__actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
}

.byna-pwa-banner__install {
    appearance: none;
    border: 0;
    cursor: pointer;
    background: #0a0a0a;
    color: #ffffff;
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    padding: 9px 16px;
    border-radius: 10px;
    white-space: nowrap;
    transition: opacity 0.15s ease;
}

.byna-pwa-banner__install:hover {
    opacity: 0.85;
}

html.dark .byna-pwa-banner__install {
    background: #fafafa;
    color: #0a0a0a;
}

.byna-pwa-banner__close {
    appearance: none;
    border: 0;
    cursor: pointer;
    background: transparent;
    color: inherit;
    opacity: 0.5;
    padding: 6px;
    border-radius: 8px;
    line-height: 0;
    transition: opacity 0.15s ease;
}

.byna-pwa-banner__close:hover {
    opacity: 1;
}

.byna-pwa-banner__close svg {
    width: 18px;
    height: 18px;
}

@media (min-width: 640px) {
    .byna-pwa-banner {
        left: 50%;
        right: auto;
        width: min(460px, calc(100vw - 32px));
        margin-top: 14px;
        border: 1px solid rgba(0, 0, 0, 0.08);
        border-radius: 16px;
        transform: translateX(-50%) translateY(-160%);
    }

    .byna-pwa-banner.is-visible {
        transform: translateX(-50%) translateY(0);
    }

    html.dark .byna-pwa-banner {
        border-color: rgba(255, 255, 255, 0.08);
    }
}

@media (prefers-reduced-motion: reduce) {
    .byna-pwa-banner {
        transition: none;
    }
}
