/* =============================================================
   Install-prompt bottom banner
   ─────────────────────────────────────────────────────────────
   Slides up from the bottom edge on mobile when the page-load
   gate in `install-prompt.js` decides to surface it. Hidden by
   default via the `hidden` attribute; JS unsets it and adds
   `.is-open` to trigger the slide-in. Standalone-mode + desktop
   viewports never see this — JS won't show it AND the CSS
   below short-circuits the display for belt-and-suspenders.
   ============================================================= */

.install-prompt {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 80;
  padding: 0 14px;
  /* Stay clear of the iOS home indicator in standalone mode. */
  padding-bottom: max(14px, env(safe-area-inset-bottom));
  pointer-events: none;
}
.install-prompt[hidden] { display: none; }

.install-prompt-card {
  pointer-events: auto;
  background: var(--paper);
  border: 1px solid var(--hair);
  border-radius: var(--r-lg);
  padding: 14px 16px;
  display: grid;
  grid-template-columns: 48px 1fr;
  grid-template-areas:
    "icon body"
    "icon actions";
  column-gap: 14px;
  row-gap: 10px;
  box-shadow:
    0 1px 0 var(--hair) inset,
    0 24px 50px -16px rgba(13, 13, 13, 0.28);
  transform: translateY(120%);
  opacity: 0;
  transition: transform .28s cubic-bezier(.2,.8,.2,1), opacity .2s ease;
}
.install-prompt.is-open .install-prompt-card {
  transform: translateY(0);
  opacity: 1;
}

.install-prompt-icon {
  grid-area: icon;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  align-self: start;
  box-shadow: 0 1px 0 var(--hair);
}
.install-prompt-body { grid-area: body; min-width: 0; }
.install-prompt-title {
  margin: 0 0 2px;
  font-family: var(--display);
  font-size: 14px;
  font-weight: 800;
  font-variation-settings: 'wdth' 90;
  letter-spacing: -0.2px;
  color: var(--ink);
}
.install-prompt-text {
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  color: var(--ink-2);
}
.install-prompt-text-chrome,
.install-prompt-text-ios { display: none; }
.install-prompt[data-platform="chrome"] .install-prompt-text-chrome { display: block; }
.install-prompt[data-platform="ios"]    .install-prompt-text-ios    { display: block; }
.install-prompt-text .ios-share {
  display: inline-block;
  vertical-align: -2px;
  font-weight: 700;
  color: var(--ink);
}

.install-prompt-actions {
  grid-area: actions;
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  align-items: center;
}
.install-prompt-dismiss,
.install-prompt-cta {
  font-family: var(--body);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.2px;
  padding: 9px 14px;
  border-radius: var(--r-pill);
  cursor: pointer;
  transition: all .15s;
  min-height: 36px;
  border: 1px solid transparent;
}
.install-prompt-dismiss {
  background: transparent;
  color: var(--ink-3);
  border-color: var(--hair-2);
}
.install-prompt-dismiss:hover {
  color: var(--ink);
  border-color: var(--ink-3);
}
.install-prompt-cta {
  background: var(--pink);
  color: #fff;
  border-color: var(--pink);
  box-shadow: 0 1px 0 rgba(214, 25, 104, 0.3);
}
.install-prompt-cta:hover { background: var(--pink-2); border-color: var(--pink-2); }

/* Desktop kill-switch — JS already gates on viewport but reinforce
   here so a manually-shown card never escapes onto a wide screen. */
@media (min-width: 721px) {
  .install-prompt { display: none !important; }
}

/* Belt-and-suspenders: when actually running standalone, never show
   the install prompt. (`install-prompt.js` checks this too.) */
@media (display-mode: standalone) {
  .install-prompt { display: none !important; }
}
