/* MaamVerse — UX / accessibility polish (V151). Public pages only. Loaded after style.css, before theme-light.css. */

/* ---------- 1. Keyboard focus ring (was missing) ---------- */
html a:focus-visible,
html button:focus-visible,
html [role="button"]:focus-visible,
html summary:focus-visible,
html input:focus-visible,
html select:focus-visible,
html textarea:focus-visible,
html [tabindex]:not([tabindex="-1"]):focus-visible {
    outline: 3px solid #c3b8ff;
    outline-offset: 3px;
    box-shadow: 0 0 0 6px rgba(140, 117, 255, .22);
}
html[data-theme="light"] a:focus-visible,
html[data-theme="light"] button:focus-visible,
html[data-theme="light"] [role="button"]:focus-visible,
html[data-theme="light"] summary:focus-visible,
html[data-theme="light"] input:focus-visible,
html[data-theme="light"] select:focus-visible,
html[data-theme="light"] textarea:focus-visible,
html[data-theme="light"] [tabindex]:not([tabindex="-1"]):focus-visible {
    outline-color: #4a35d4;
    box-shadow: 0 0 0 6px rgba(74, 53, 212, .18);
}
html .navbar nav a:focus-visible { outline-offset: 2px; border-radius: 10px; }

/* ---------- 2. Skip link ---------- */
.skip-link {
    position: absolute; left: 12px; top: -64px; z-index: 100001;
    padding: 12px 18px; min-height: 44px; box-sizing: border-box; border-radius: 12px;
    background: #ffffff; color: #1b2250; text-decoration: none;
    font: 600 14px/1.2 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    box-shadow: 0 8px 28px rgba(0, 0, 0, .35);
    transition: top .18s ease;
}
.skip-link:focus, .skip-link:focus-visible { top: 12px; }
.mv-main { display: contents; }

/* ---------- 3. Tap targets ---------- */
html .navbar nav a { display: inline-flex; align-items: center; justify-content: center; min-height: 32px; }
html body .nav-logo { min-height: 44px !important; }
html body .memory-info .read-more-btn { min-height: 44px; }
@media (max-width: 900px), (pointer: coarse) {
    html .navbar nav a { min-height: 44px; min-width: 44px; }
    html .mv-theme-btn { width: 44px; height: 44px; }
    html .mv-install-btn { min-height: 44px; }
    html .mv-install-foot { min-height: 44px; }
    html .mv-ios .mv-x { min-height: 48px; }
}

/* ---------- 4. Smallest text: nothing under 12px ---------- */
html body .navbar nav a { font-size: 12px !important; }
html body .premium-profile-label,
html body .premium-card-label,
html body .premium-contact-kicker,
html body .journey-point small,
html body .premium-facts small,
html body .special-day-box small,
html body .special-day-hint,
html body .memory-number,
html body .mvp-swipe,
html body .gateway-small-text,
html body .gateway-footer { font-size: 12px !important; }
html body .gateway-footer { letter-spacing: .14em; }

/* ---------- 5. Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto !important; }
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ---------- 6. V152: memory dots (Day) + install hint ---------- */
html[data-theme="light"] .mvp-dots button::before { background: rgba(74, 53, 212, .28); }
html[data-theme="light"] .mvp-dots button[aria-current="true"]::before { background: #4a35d4; }
.mv-hint { position: absolute; z-index: 61; max-width: 240px; padding: 12px 36px 12px 14px; border-radius: 14px;
    background: rgba(22, 18, 52, .94); color: #f3f0ff; border: 1px solid rgba(170, 150, 255, .5);
    box-shadow: 0 12px 34px rgba(0, 0, 0, .38); font: 500 13px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    opacity: 0; transform: translateY(-6px); transition: opacity .35s ease, transform .35s ease; }
.mv-hint.mv-in { opacity: 1; transform: none; }
.mv-hint::before { content: ""; position: absolute; top: -6px; right: var(--mv-arrow, 28px); width: 10px; height: 10px; background: inherit; border-left: 1px solid rgba(170, 150, 255, .5); border-top: 1px solid rgba(170, 150, 255, .5); transform: rotate(45deg); }
.mv-hint button { position: absolute; top: 2px; right: 2px; width: 36px; height: 36px; border: 0; background: none; color: #cfc6ff; font-size: 18px; line-height: 1; cursor: pointer; border-radius: 10px; }

/* V157: memory-card photo chip stays light on its dark glass in Day mode */
html[data-theme="light"] body .memory-card .has-cover span.mvp-art { color: #fff !important; background: rgba(8, 10, 28, .55) !important; border-color: rgba(255, 255, 255, .45) !important; }
