/* Compact, sticky site-level PWA install notice.
   It remains in normal flow, reserving space while sticky at the viewport top. */
.kyl-app-install-banner {
    position: sticky;
    top: env(safe-area-inset-top, 0px);
    z-index: 10000;
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 4px clamp(12px, 3vw, 28px);
    background: #eef3ff;
    border-bottom: 1px solid #dce5fb;
    color: #202536;
}
.kyl-app-install-banner[hidden] { display: none !important; }
.kyl-app-install-banner-inner {
    width: min(100%, 1240px);
    min-height: 36px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 10px;
}
.kyl-app-install-banner-icon {
    width: 30px;
    height: 30px;
    flex: 0 0 30px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: #fff;
    border: 1px solid #e2e9fb;
}
.kyl-app-install-banner-icon img { width: 23px; height: 23px; object-fit: contain; }
.kyl-app-install-banner-copy {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 3px 8px;
}
.kyl-app-install-banner-title { margin: 0; font-size: 12px; font-weight: 700; line-height: 1.3; white-space: nowrap; }
.kyl-app-install-banner-description { margin: 0; font-size: 11px; line-height: 1.35; color: #596276; }
.kyl-app-install-banner-help { margin: 3px 0 0; font-size: 11px; line-height: 1.4; color: #46516b; flex-basis: 100%; }
.kyl-app-install-banner-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex: 0 0 auto;
    min-height: 30px;
    padding: 0 11px;
    border: 0;
    border-radius: 8px;
    background: #5273d2;
    color: #fff;
    font: inherit;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
}
.kyl-app-install-banner-action:hover:not(:disabled) { background: #405fbd; }
.kyl-app-install-banner-action:disabled { opacity: .68; cursor: wait; }
.kyl-app-install-banner-action:focus-visible,
.kyl-app-install-banner-dismiss:focus-visible { outline: 3px solid #8aa8ff; outline-offset: 2px; }
.kyl-app-install-banner-dismiss {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    flex: 0 0 28px;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: #68738a;
    cursor: pointer;
}
.kyl-app-install-banner-dismiss:hover { background: #e0e8fb; color: #26324a; }

@media (max-width: 600px) {
    .kyl-app-install-banner { padding: 4px 8px; }
    .kyl-app-install-banner-inner { gap: 6px; min-height: 32px; }
    .kyl-app-install-banner-icon { width: 26px; height: 26px; flex-basis: 26px; }
    .kyl-app-install-banner-icon img { width: 20px; height: 20px; }
    .kyl-app-install-banner-copy { display: block; }
    .kyl-app-install-banner-title { font-size: 11px; }
    .kyl-app-install-banner-description { display: none; }
    .kyl-app-install-banner-action { min-height: 28px; padding: 0 8px; font-size: 10px; }
    .kyl-app-install-banner-dismiss { width: 26px; height: 26px; flex-basis: 26px; }
    .kyl-app-install-banner-help { font-size: 10px; }
}

/* Shared measured height consumed by fixed public navigation and full-screen map. */
:root { --kyl-install-banner-height: 0px; }


/* Platform-specific installation guidance dialog. */
.kyl-install-dialog {
    width: min(460px, calc(100% - 32px));
    max-width: 460px;
    max-height: min(88dvh, 720px);
    margin: auto;
    padding: 0;
    overflow: auto;
    border: 1px solid #e2e8f2;
    border-radius: 22px;
    background: #fff;
    color: #202b40;
    box-shadow: 0 24px 80px rgba(18, 31, 58, .24);
}
.kyl-install-dialog::backdrop {
    background: rgba(15, 23, 42, .56);
    backdrop-filter: blur(3px);
}
.kyl-install-dialog[open] {
    animation: kyl-install-dialog-in 180ms ease-out;
}
.kyl-install-dialog-card {
    position: relative;
    padding: 28px;
}
.kyl-install-dialog-close {
    position: absolute;
    top: 14px;
    right: 14px;
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    border: 1px solid #e5eaf2;
    border-radius: 11px;
    background: #fff;
    color: #64748b;
    cursor: pointer;
}
.kyl-install-dialog-icon {
    display: grid;
    width: 54px;
    height: 54px;
    margin-bottom: 19px;
    place-items: center;
    border-radius: 16px;
    background: #edf2ff;
}
.kyl-install-dialog-icon img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}
.kyl-install-dialog-eyebrow {
    margin: 0 0 8px;
    color: #5573c8;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .13em;
}
.kyl-install-dialog-card h2 {
    margin: 0;
    padding-right: 18px;
    color: #1e293b;
    font-size: clamp(21px, 5vw, 26px);
    line-height: 1.2;
    letter-spacing: -.035em;
}
.kyl-install-dialog-description {
    margin: 12px 0 18px;
    color: #64748b;
    font-size: 14px;
    line-height: 1.6;
}
.kyl-install-dialog-steps {
    display: grid;
    gap: 11px;
    margin: 0;
    padding-left: 23px;
    color: #344258;
    font-size: 13px;
    line-height: 1.55;
}
.kyl-install-dialog-steps li {
    padding-left: 3px;
}
.kyl-install-dialog-steps li::marker {
    color: #5573c8;
    font-weight: 800;
}
.kyl-install-dialog-note {
    margin: 19px 0 0;
    padding: 12px 13px;
    border: 1px solid #e5ebf8;
    border-radius: 12px;
    background: #f5f7fd;
    color: #64748b;
    font-size: 11px;
    line-height: 1.55;
}
.kyl-install-dialog-primary {
    display: inline-flex;
    width: 100%;
    min-height: 46px;
    margin-top: 20px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 12px;
    background: #5273d2;
    color: #fff;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}
.kyl-install-dialog-primary:hover {
    background: #405fbd;
}
.kyl-install-dialog button:focus-visible {
    outline: 3px solid #91aaff;
    outline-offset: 3px;
}
@keyframes kyl-install-dialog-in {
    from { opacity: 0; transform: translateY(8px) scale(.985); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
@media (max-width: 480px) {
    .kyl-install-dialog-card { padding: 23px 20px 20px; }
}
@media (prefers-reduced-motion: reduce) {
    .kyl-install-dialog[open] { animation: none; }
}
