/* =========================================================================
   PWA UI Styles: Install Button, Online/Offline Toast, iOS Instructions
   ========================================================================= */

.pwa-install-item {
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    margin-top: 4px;
    padding-top: 4px;
}

.pwa-install-btn {
    all: unset;
    cursor: pointer;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 11px 12px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: inherit;
    color: #071B2D;
    background: rgba(7, 27, 45, 0.04);
    transition: background 0.2s, color 0.2s, transform 0.15s;
}

.pwa-install-btn:hover {
    background: #071B2D;
    color: #ffffff;
}

.pwa-install-btn svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

/* Online / Offline Toast */
.pwa-toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    background: #071B2D;
    color: #ffffff;
    padding: 12px 18px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.9rem;
    font-family: Arial, sans-serif;
    transform: translateY(100px);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    pointer-events: none;
    max-width: min(90vw, 360px);
}

.pwa-toast.visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.pwa-toast-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.pwa-toast-dot.offline {
    background: #b96d54;
}

.pwa-toast-dot.online {
    background: #00B8A9;
}

/* iOS Installation Modal */
.pwa-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(7, 27, 45, 0.6);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.pwa-modal-backdrop.open {
    opacity: 1;
    pointer-events: auto;
}

.pwa-modal {
    background: #ffffff;
    color: #193548;
    max-width: 420px;
    width: 100%;
    border-radius: 18px;
    padding: 26px 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    font-family: Arial, sans-serif;
    position: relative;
    transform: scale(0.95);
    transition: transform 0.25s ease;
}

.pwa-modal-backdrop.open .pwa-modal {
    transform: scale(1);
}

.pwa-modal h3 {
    margin: 0 0 10px;
    font-family: Georgia, serif;
    font-size: 1.3rem;
    color: #071B2D;
}

.pwa-modal p {
    font-size: 0.92rem;
    line-height: 1.5;
    color: #4a5568;
    margin: 0 0 16px;
}

.pwa-modal ol {
    margin: 0 0 20px;
    padding-left: 20px;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #263044;
}

.pwa-modal ol li {
    margin-bottom: 8px;
}

.pwa-modal-close {
    background: #071B2D;
    color: #ffffff;
    border: none;
    border-radius: 10px;
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: background 0.2s;
}

.pwa-modal-close:hover {
    background: #123B52;
}
