.install-trigger { min-height: 44px; max-width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 10px 13px; border: 1px solid #dfc4d8; border-radius: 9px; color: #853b74; background: #fff; font: inherit; font-size: 12px; font-weight: 600; line-height: 1.5; text-align: center; cursor: pointer; touch-action: manipulation; }
.install-trigger:hover { background: #fdf1f9; border-color: #c586b2; }
.install-trigger svg { width: 17px; height: 17px; flex-shrink: 0; }
.install-trigger-label { overflow-wrap: anywhere; }
.install-trigger:disabled { opacity: .7; cursor: progress; }
.install-settings-action { margin-top: 16px; }
.topbar .install-trigger { flex: 0 1 auto; min-width: 0; white-space: normal; }
.install-dialog { position: fixed; inset: 0; margin: auto; width: min(590px, calc(100vw - 32px)); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px - env(safe-area-inset-top) - env(safe-area-inset-bottom)); padding: 0; overflow: auto; border: 1px solid #ead7e4; border-radius: 18px; background: #fff; color: var(--ink, #35353c); box-shadow: 0 24px 85px #48233d30; z-index: 500; }
.install-dialog::backdrop { background: #382130a3; backdrop-filter: blur(3px); }
.install-dialog-header { position: sticky; top: 0; display: flex; justify-content: space-between; align-items: flex-start; gap: 15px; padding: 23px 25px 21px; background: linear-gradient(120deg, #fbecf7, #fff2eb); border-bottom: 1px solid #eedee8; z-index: 1; }
.install-dialog-header > div { min-width: 0; }
.install-dialog-header h2 { font-size: 21px; line-height: 1.4; letter-spacing: -.5px; color: #713266; overflow-wrap: anywhere; }
.install-eyebrow { margin: 0 0 7px; color: #956580; font-size: 10px; font-weight: 700; letter-spacing: 1.2px; text-transform: uppercase; }
.install-close { display: grid; place-items: center; width: 44px; height: 44px; flex: 0 0 44px; border: 1px solid #e2c9da; border-radius: 10px; color: #845275; background: #ffffffa8; font-size: 25px; line-height: 1; cursor: pointer; touch-action: manipulation; }
.install-close:hover { background: #fff; }
.install-dialog-content { padding: 23px 25px 25px; }
.install-intro { font-size: 13px; color: #766370; line-height: 1.8; margin: 0 0 20px; }
.install-platform { display: block; margin: 21px 0; }
.install-platform > span { display: block; font-size: 12px; font-weight: 600; color: #705367; line-height: 1.7; margin-bottom: 7px; }
.install-platform select { min-height: 46px; width: 100%; max-width: 100%; padding: 12px; border: 1px solid #dfccda; border-radius: 9px; color: #59424f; background: #fff; font: inherit; font-size: 14px; }
.install-platform select:focus-visible { outline: 3px solid #d68cbd38; border-color: #b55c9f; }
.install-guide h3 { font-size: 15px; line-height: 1.7; color: #6f3965; margin: 0 0 13px; }
.install-guide ol { margin: 0; padding-left: 23px; }
.install-guide li { font-size: 13px; line-height: 1.9; padding-left: 4px; margin: 0 0 11px; color: #5e4c58; }
.install-guide li::marker { color: #a0518b; font-weight: 700; }
.install-help { margin: 17px 0 0; font-size: 12px; line-height: 1.8; color: #7e6d77; }
.install-status, .install-browser-note { border: 1px solid #e9d5e2; background: #fff6fc; border-radius: 11px; padding: 16px; margin: 0 0 17px; }
.install-status strong { display: block; font-size: 14px; line-height: 1.6; color: #843b72; }
.install-status p, .install-browser-note p { font-size: 12px; line-height: 1.8; margin: 7px 0 0; color: #775e70; }
.install-browser-note p { margin: 0 0 11px; }
.install-browser-note .button { white-space: normal; min-height: 44px; }
.install-data-note { margin: 21px 0 0; padding-top: 18px; border-top: 1px solid #efE2e9; font-size: 11px; line-height: 1.9; color: #7e6c78; }
.install-dialog-actions { display: flex; justify-content: flex-end; margin-top: 21px; }
.install-dialog-actions .button { min-height: 44px; min-width: 115px; }
@media (max-width: 950px) {
  .topbar .top-right { gap: 9px; }
  .install-platform select { font-size: 16px; }
}
@media (max-width: 800px) {
  .topbar { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; }
  .topbar .mobile-logo { grid-column: 1; grid-row: 1; max-width: 100%; }
  .topbar .top-right { display: contents; }
  .topbar .local-status { grid-column: 1 / -1; grid-row: 2; max-width: none; width: 100%; }
  .topbar .install-trigger { grid-column: 2; grid-row: 1; max-width: 205px; }
  .topbar #retry-save { grid-column: 1 / -1; grid-row: 3; justify-self: start; }
}
@media (max-width: 560px) {
  .topbar .install-trigger { padding: 10px 11px; font-size: 11px; max-width: 175px; }
  .install-dialog { width: calc(100vw - 24px); border-radius: 15px; }
  .install-dialog-header { padding: 19px 17px; gap: 11px; }
  .install-dialog-header h2 { font-size: 19px; }
  .install-dialog-content { padding: 20px 18px 22px; }
  .install-dialog-actions .button { width: 100%; }
}
@media (max-width: 360px) {
  .topbar .install-trigger { max-width: 128px; padding: 9px; }
}
@media (display-mode: standalone) {
  .topbar { padding-top: max(16px, env(safe-area-inset-top)); padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
}
@media print { .install-dialog, .install-trigger { display: none !important; } }
