/* Shared, deliberately isolated from each app's CSS/reset. */
:root {
  --tw-pwa-navy: #14283f;
  --tw-pwa-orange: #c9330d;
  --tw-pwa-paper: #fffaf4;
  --tw-pwa-muted: #536174;
  --tw-pwa-line: #dedfdc;
}
.tw-pwa, .tw-pwa *, .tw-pwa *::before, .tw-pwa *::after { box-sizing: border-box; }
.tw-pwa { font-family: Manrope, system-ui, sans-serif; font-size: 14px; line-height: 1.6; color: var(--tw-pwa-navy); text-align: left; letter-spacing: normal; }
.tw-pwa [hidden] { display: none !important; }
.tw-pwa button, .tw-pwa a { -webkit-tap-highlight-color: transparent; }
.tw-pwa button { font: inherit; cursor: pointer; text-transform: none; letter-spacing: normal; }
.tw-pwa button:focus-visible, .tw-pwa a:focus-visible, .tw-pwa input:focus-visible { outline: 3px solid var(--tw-pwa-orange); outline-offset: 4px; }
.tw-pwa button:disabled { opacity: .5; cursor: not-allowed; }
.tw-pwa-trigger { position: fixed; z-index: 1050; right: max(16px, env(safe-area-inset-right)); bottom: calc(112px + env(safe-area-inset-bottom)); display: flex; gap: 8px; align-items: center; border: 1px solid #d9dfdf; border-radius: 30px; padding: 10px 15px; background: var(--tw-pwa-paper); color: var(--tw-pwa-navy); box-shadow: 0 3px 15px #14283f18; font-size: 12px !important; font-weight: 800 !important; }
.tw-pwa svg { width: 18px; height: 18px; flex: none; }
.tw-pwa-invite { position: fixed; z-index: 1051; right: 16px; bottom: calc(170px + env(safe-area-inset-bottom)); width: min(334px, calc(100vw - 32px)); padding: 22px; background: var(--tw-pwa-paper); border: 1px solid var(--tw-pwa-line); border-top: 3px solid var(--tw-pwa-orange); border-radius: 14px; box-shadow: 0 12px 45px #14283f24; animation: tw-pwa-enter .25s ease both; }
.tw-pwa-invite h2 { font-size: 18px; margin: 6px 20px 8px 0; font-weight: 800; color: var(--tw-pwa-navy); line-height: 1.3; }
.tw-pwa p { margin: 0 0 14px; }
.tw-pwa-kicker { display: block; color: var(--tw-pwa-orange); font-size: 10px; letter-spacing: .14em; font-weight: 800; text-transform: uppercase; }
.tw-pwa-close { border: 0; background: transparent; color: var(--tw-pwa-navy); padding: 8px; display: flex; align-items: center; justify-content: center; border-radius: 8px; }
.tw-pwa-invite > .tw-pwa-close { position: absolute; right: 9px; top: 9px; }
.tw-pwa-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 16px; }
.tw-pwa-primary, .tw-pwa-secondary { display: inline-flex; justify-content: center; align-items: center; gap: 8px; padding: 11px 16px; border-radius: 8px; font-weight: 800 !important; text-decoration: none !important; font-size: 13px !important; line-height: 1.4; }
.tw-pwa-primary { background: var(--tw-pwa-orange); color: #fffaf4 !important; border: 1px solid var(--tw-pwa-orange); }
.tw-pwa-secondary { background: transparent; color: var(--tw-pwa-navy) !important; border: 1px solid #bbc5cc; }
.tw-pwa-dialog { padding: 0; border: 1px solid var(--tw-pwa-line); border-radius: 18px; background: var(--tw-pwa-paper); width: min(560px, calc(100vw - 28px)); max-width: 560px; max-height: calc(100dvh - 40px); margin: auto; box-shadow: 0 25px 90px #14283f38; overflow: auto; }
.tw-pwa-dialog::backdrop { background: #0e2038a6; }
.tw-pwa-head { padding: 25px 26px 20px; background: #edf0ef; border-bottom: 1px solid var(--tw-pwa-line); display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.tw-pwa-head h2 { font-size: 25px; line-height: 1.2; font-weight: 800; margin: 9px 0 5px; color: var(--tw-pwa-navy); letter-spacing: -.04em; }
.tw-pwa-head p { color: var(--tw-pwa-muted); font-size: 12px; margin: 0; }
.tw-pwa-body { padding: 24px 26px; }
.tw-pwa-section + .tw-pwa-section { margin-top: 26px; padding-top: 24px; border-top: 1px solid var(--tw-pwa-line); }
.tw-pwa h3 { margin: 0 0 10px; font-size: 17px; font-weight: 800; color: var(--tw-pwa-navy); }
.tw-pwa-note { color: var(--tw-pwa-muted); font-size: 12px; }
.tw-pwa-steps { padding-left: 24px; margin: 14px 0; }
.tw-pwa-steps li { padding: 3px 0 7px 4px; }
.tw-pwa-steps li::marker { color: var(--tw-pwa-orange); font-weight: 800; }
.tw-pwa-notice { border-left: 3px solid var(--tw-pwa-orange); background: #f4ede3; padding: 12px 14px; margin: 12px 0; font-size: 13px; }
.tw-pwa-topics { border: 1px solid var(--tw-pwa-line); border-radius: 10px; overflow: hidden; margin: 16px 0; }
.tw-pwa-topic { padding: 12px 14px; display: flex; align-items: center; gap: 12px; background: #fcf8f1; cursor: pointer; }
.tw-pwa-topic + .tw-pwa-topic { border-top: 1px solid var(--tw-pwa-line); }
.tw-pwa-topic input { width: 18px; height: 18px; accent-color: var(--tw-pwa-orange); flex: none; margin: 0; }
.tw-pwa-topic span { font-size: 13px; font-weight: 700; }
.tw-pwa-topic small { display: block; font-weight: 400; color: var(--tw-pwa-muted); font-size: 11px; }
.tw-pwa-device { padding: 13px 0; border-top: 1px solid var(--tw-pwa-line); display: flex; gap: 12px; align-items: center; justify-content: space-between; }
.tw-pwa-device strong { display: block; font-size: 12px; overflow-wrap: anywhere; }
.tw-pwa-device small { display: block; color: var(--tw-pwa-muted); }
.tw-pwa-status { margin-top: 14px !important; font-size: 13px; overflow-wrap: anywhere; }
.tw-pwa-loading { height: 70px; border-radius: 8px; background: #e8eceb; }
.tw-pwa-help { color: var(--tw-pwa-muted); font-size: 12px; display: inline-block; margin-top: 16px; text-decoration: underline; }
@keyframes tw-pwa-enter { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 600px) { .tw-pwa-body { padding: 20px; } .tw-pwa-head { padding: 22px 20px; } .tw-pwa-trigger { padding: 9px 12px; } .tw-pwa-dialog { max-height: calc(100dvh - 28px); } .tw-pwa-invite { top: max(90px, env(safe-area-inset-top)); bottom: auto; } }
@media (prefers-reduced-motion: reduce) { .tw-pwa-invite { animation: none; } }
@media print { .tw-pwa { display: none !important; } }
