.apr-modal-open { overflow: hidden; }
.apr {
    --apr-pink: #ed37cf;
    --apr-muted: #bcb1c7;
    color-scheme: dark;
    position: fixed;
    inset: 0;
    width: min(950px, calc(100% - 40px));
    max-width: none;
    max-height: min(94vh, 1000px);
    max-height: min(94dvh, 1000px);
    margin: auto;
    padding: 0;
    overflow: auto;
    overscroll-behavior: contain;
    color: #f8f3fa;
    background: #0b060f;
    border: 1px solid #66315f;
    border-radius: 24px;
    box-shadow: 0 30px 120px #000c, 0 0 65px #d82bba18;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    text-align: left;
}
.apr:not([open]) { display: none; }
.apr::backdrop { background: #08040ddd; backdrop-filter: blur(9px); }
.apr *, .apr *::before, .apr *::after { box-sizing: border-box; }
.apr :is(h2, h3, p, ul) { margin: 0; padding: 0; color: inherit; }
.apr button { font: inherit; cursor: pointer; text-transform: none; letter-spacing: 0; margin: 0; }
.apr button:focus-visible { outline: 3px solid #fff; outline-offset: 4px; }
.apr__shell { background: radial-gradient(ellipse at 0 15%, #74126126, transparent 50%), radial-gradient(ellipse at 100% 80%, #641de81a, transparent 50%); }
.apr__topbar { display: flex; align-items: center; gap: 18px; padding: 16px 30px; border-bottom: 1px solid #ffffff0c; }
.apr__brand { color: var(--apr-pink); font-size: 28px; font-weight: 850; letter-spacing: 0; line-height: 1; white-space: nowrap; }
.apr__brand span { color: #f086e1; }
.apr__brand { min-width: 0; overflow-wrap: anywhere; white-space: normal; }
.apr__brand .custom-logo-link { display: block; }
.apr__brand .custom-logo { display: block; width: 260px; max-width: 100%; height: auto; }
.apr__top-label { color: #aea0b9; font-size: 11px; letter-spacing: 0; text-transform: uppercase; }
.apr .apr__close { display: grid; place-items: center; margin-left: auto; width: 36px; height: 36px; min-width: 36px; padding: 0; border: 1px solid #ffffff17; border-radius: 50%; color: #dbcede; background: #ffffff05; font-size: 25px; line-height: 1; }
.apr .apr__close:hover { background: #ffffff13; }
.apr__body { padding: 27px 38px 24px; }
.apr__intro { max-width: 610px; margin-bottom: 25px; }
.apr__eyebrow { display: block; margin-bottom: 10px; color: #d89dce; font-size: 10px; font-weight: 700; letter-spacing: 0; }
.apr #apr-title { font-size: 42px; font-weight: 780; line-height: 1.1; letter-spacing: 0; margin: 0 0 13px; }
.apr #apr-title span { color: var(--apr-pink); }
.apr #apr-description { max-width: 545px; color: var(--apr-muted); font-size: 14px; line-height: 1.65; }
.apr__dashboard { padding: 20px; border: 1px solid #aa40932d; border-radius: 17px; background: #0b0711d9; }
.apr__dashboard-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 17px; }
.apr__profile { display: flex; align-items: center; gap: 11px; min-width: 0; }
.apr__profile-icon { display: grid; place-items: center; width: 38px; height: 38px; flex-shrink: 0; border-radius: 12px; border: 1px solid #ef39cc59; color: var(--apr-pink); background: linear-gradient(140deg, #58174c, #26123e); font-size: 21px; }
.apr__profile strong { display: block; font-size: 15px; overflow-wrap: anywhere; }
.apr__profile div > span { display: block; margin-top: 1px; color: #a99bb7; font-size: 11px; }
.apr__metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 11px; }
.apr__metric { padding: 15px 17px; background: linear-gradient(140deg, #1a0d1c8c, #0e0a158c); border: 1px solid #a63d972a; border-radius: 11px; }
.apr__metric-label { display: flex; align-items: center; justify-content: space-between; gap: 5px; color: #cabdd3; font-size: 11px; }
.apr__metric-label > span { color: #bc66b5; font-size: 15px; }
.apr__metric > strong { display: block; padding: 6px 0 3px; color: #faeffa; font-size: 32px; letter-spacing: 0; font-weight: 720; line-height: 1.25; }
.apr__metric:first-child > strong { color: var(--apr-pink); }
.apr__metric-note { color: #a99ab5; font-size: 10px; }
.apr__choice-note { display: flex; gap: 12px; margin-top: 20px; }
.apr__choice-icon { color: var(--apr-pink); font-size: 25px; line-height: 1.1; }
.apr__choice-note strong { font-size: 12px; font-weight: 600; }
.apr .apr__choice-note p { margin-top: 4px; max-width: 640px; font-size: 11px; line-height: 1.6; color: var(--apr-muted); }
.apr__footer { position: sticky; bottom: 0; padding: 16px 38px 22px; background: #100a15f5; border-top: 1px solid #ffffff0d; backdrop-filter: blur(10px); }
.apr .apr__footer > p { font-size: 10px; color: #b9a9c3; margin-bottom: 12px; text-align: center; }
.apr__actions { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.apr .apr__button { display: flex; justify-content: center; align-items: center; gap: 15px; min-height: 47px; padding: 12px 20px; border-radius: 28px; border: 1px solid #ac448f; font-size: 13px; font-weight: 700; transition: background .15s, box-shadow .15s; }
.apr .apr__button--keep { background: linear-gradient(110deg, #ee37cc, #9719ec); color: #100519; border-color: #ee37cc; box-shadow: 0 3px 23px #dd2abd29; }
.apr .apr__button--keep:hover { box-shadow: 0 3px 28px #dd2abd59; }
.apr .apr__button--delete { color: #ebbbe3; background: #160c1d; }
.apr .apr__button--delete:hover { background: #31132f; }
.apr .apr__metric > .apr__fact-value { font-size: 24px; letter-spacing: 0; padding-top: 13px; padding-bottom: 8px; }
.apr__facts-label { color: #c99fc7; font-size: 11px; }
.apr .apr__data-note { margin-top: 17px; color: var(--apr-muted); font-size: 12px; }
@media (max-width: 650px) {
    .apr { width: calc(100% - 20px); max-height: 94vh; max-height: 94dvh; border-radius: 20px; }
    .apr__topbar { padding: 13px 18px; }
    .apr__top-label { display: none; }
    .apr__brand { font-size: 22px; }
    .apr__body { padding: 23px 18px 20px; }
    .apr__intro { margin-bottom: 20px; }
    .apr #apr-title { font-size: 34px; }
    .apr #apr-description { font-size: 13px; }
    .apr__dashboard { padding: 13px; }
    .apr__dashboard-heading { gap: 6px; }
    .apr__profile strong { font-size: 13px; }
    .apr__profile-icon { width: 30px; height: 30px; border-radius: 9px; }
    .apr__metrics { gap: 6px; }
    .apr__metric { padding: 11px 9px; }
    .apr__metric-label { font-size: 10px; }
    .apr__metric-label > span { display: none; }
    .apr__metric > strong { font-size: 25px; }
    .apr__metric-note { font-size: 9px; line-height: 1.4; display: block; }
    .apr__footer { padding: 13px 18px 17px; }
    .apr__actions { gap: 8px; }
    .apr .apr__button { padding: 11px 10px; gap: 6px; font-size: 11px; min-height: 46px; }
    .apr .apr__metric > .apr__fact-value { font-size: 16px; overflow-wrap: anywhere; }
}
@media (max-width: 360px) {
    .apr__top-label { display: none; }
    .apr__dashboard-heading { align-items: flex-start; flex-direction: column; }
    .apr__metrics { grid-template-columns: 1fr; }
    .apr__metric-note { display: inline; }
}
@media (prefers-reduced-motion: reduce) {
    .apr .apr__button { transition: none; }
}

/* Draw the close X with two centered strokes: the "×" glyph sits off-center in the circle because of font metrics. */
.apr .apr__close { position: relative; font-size: 0; }
.apr .apr__close::before,
.apr .apr__close::after { content: ''; position: absolute; top: 50%; left: 50%; width: 14px; height: 1.5px; border-radius: 1px; background: currentColor; transform: translate(-50%, -50%) rotate(45deg); }
.apr .apr__close::after { transform: translate(-50%, -50%) rotate(-45deg); }
