/*
MMD Pupil Diary
PWA styles
Version: 1.1.1
*/

.mmd-pwa-install-button {
    position: fixed;
    right: 20px;
    bottom: 96px;
    z-index: 9999;
    background: #2563eb;
    color: #ffffff;
    border: none;
    padding: 12px 18px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
    transition: all 0.2s ease;
    max-width: calc(100vw - 32px);
}

.mmd-pwa-install-button:hover {
    background: #1e4fd1;
    transform: translateY(-1px);
}

.mmd-pwa-install-button:active {
    transform: translateY(0);
}

.mmd-pwa-ios-hint {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 96px;
    z-index: 9998;
}

.mmd-pwa-ios-hint__inner {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #ffffff;
    color: #0f172a;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 14px;
    padding: 14px 16px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.16);
}

.mmd-pwa-ios-hint__text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 14px;
    line-height: 1.4;
}

.mmd-pwa-ios-hint__text strong {
    font-size: 15px;
    line-height: 1.3;
}

.mmd-pwa-ios-hint__text span {
    color: #334155;
}

.mmd-pwa-ios-hint__text em {
    font-style: normal;
    font-weight: 600;
}

.mmd-pwa-ios-hint__close {
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    border: none;
    color: #64748b;
    font-size: 24px;
    line-height: 1;
    padding: 0;
    margin: -2px 0 0 auto;
    cursor: pointer;
}

.mmd-pwa-ios-hint__close:hover {
    color: #0f172a;
}

.mmd-pwa-push-box {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 170px;
    z-index: 9997;
    margin: 0;
}

.mmd-pwa-push-box__inner {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #ffffff;
    color: #0f172a;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 14px;
    padding: 14px 16px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.16);
}

.mmd-pwa-push-box__text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    font-size: 14px;
    line-height: 1.4;
}

.mmd-pwa-push-box__text strong {
    font-size: 15px;
    line-height: 1.3;
}

.mmd-pwa-push-box__text span {
    color: #334155;
}

.mmd-pwa-push-button {
    appearance: none;
    -webkit-appearance: none;
    border: none;
    border-radius: 10px;
    background: #0f172a;
    color: #ffffff;
    padding: 11px 14px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    white-space: nowrap;
}

.mmd-pwa-push-button.is-enabled {
    background: #15803d;
}

.mmd-pwa-push-button.is-disabled {
    background: #64748b;
}

@media (max-width: 767px) {
    .mmd-pwa-install-button {
        left: 16px;
        right: 16px;
        bottom: 110px;
        width: auto;
        text-align: center;
    }

    .mmd-pwa-ios-hint {
        left: 16px;
        right: 16px;
        bottom: 110px;
    }

    .mmd-pwa-push-box {
        left: 16px;
        right: 16px;
        bottom: 190px;
    }

    .mmd-pwa-push-box__inner {
        flex-direction: column;
    }

    .mmd-pwa-push-button {
        width: 100%;
        text-align: center;
    }
}

@media (min-width: 768px) {
    .mmd-pwa-ios-hint {
        left: auto;
        right: 20px;
        bottom: 20px;
        width: 360px;
    }

    .mmd-pwa-install-button {
        right: 20px;
        bottom: 20px;
    }

    .mmd-pwa-push-box {
        left: auto;
        right: 20px;
        bottom: 90px;
        width: 420px;
    }

    .mmd-pwa-push-box__inner {
        align-items: center;
    }
}