/*
 * innsight2026 - Cream / sticker skin.
 * Mobile-first. Pixel-targets the screenshots in design_handoff_innsight_map/screenshots.
 * Tokens come straight from the README "Design Tokens" section; do not mutate
 * without updating the design doc.
 */

/* ── Tokens ──────────────────────────────────────────────────────────────── */
:root {
    --in-bg:      #F2EDE3;
    --in-ink:     #0F0F0F;
    --in-accent:  #C9F73F;

    --in-surface: #FFFFFF;
    --in-sheet:   #FAF7EE;

    --in-mute:    rgba(15, 15, 15, 0.55);
    --in-mute2:   rgba(15, 15, 15, 0.40);
    --in-mute3:   rgba(15, 15, 15, 0.65);
    --in-divider: rgba(15, 15, 15, 0.15);
    --in-divider-dashed: rgba(15, 15, 15, 0.18);

    --in-open:    #1A8A4A;
    --in-closed:  #B43B3B;

    --in-cat-eats:   #FF6B3D;
    --in-cat-drinks: #C9F73F;
    --in-cat-sights: #6BB7FF;
    --in-cat-shops:  #FF4D8F;
    --in-cat-events: #B07AFF;

    --in-font-display: 'Instrument Serif', Georgia, serif;
    --in-font-ui:      'Bricolage Grotesque', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ── Reset / app frame ───────────────────────────────────────────────────── */
/* .in-app fills 100% of the shortcode container (.innsight-map-target,
 * which gets its height from the shortcode's `height` attribute - 70vh
 * default). We deliberately do NOT set min-height: 100dvh here - that
 * forces the app taller than its container on pages with sidebars /
 * shorter shortcode heights, which causes the tab bar to escape and
 * the layout to overflow into surrounding theme content. Authors who
 * want a full-viewport map should pass height="100dvh" in the shortcode. */
.in-app {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 360px;
    background: var(--in-bg);
    overflow: hidden;
    font-family: var(--in-font-ui);
    color: var(--in-ink);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
.in-app *, .in-app *::before, .in-app *::after { box-sizing: border-box; }
.in-app button { font-family: inherit; color: inherit; }
.in-app input { font-family: inherit; color: inherit; }
.in-spacer { flex: 1; }

/* Hide scrollbars but keep scroll. */
.in-app ::-webkit-scrollbar { display: none; }
.in-app * { scrollbar-width: none; }

/* ── Map stage ───────────────────────────────────────────────────────────── */
.in-map-stage {
    position: absolute; inset: 0;
}
.in-map {
    position: absolute; inset: 0;
}
.in-paper-grain {
    position: absolute; inset: 0;
    pointer-events: none;
    background-image:
        radial-gradient(circle at 1px 1px, rgba(0, 0, 0, 0.02) 0.5px, transparent 1px),
        radial-gradient(circle at 2px 2px, rgba(0, 0, 0, 0.02) 0.5px, transparent 1px);
    background-size: 3px 3px, 5px 5px;
    mix-blend-mode: multiply;
    opacity: 0.55;
    z-index: 2;
}

/* ── "spots nearby" badge ────────────────────────────────────────────────── */
.in-nearby {
    position: absolute;
    top: 222px;
    left: 16px;
    z-index: 40;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: var(--in-bg);
    border: 1.5px solid var(--in-ink);
    border-radius: 14px;
    box-shadow: 2px 2px 0 var(--in-ink);
    font-size: 12px; font-weight: 600;
    color: var(--in-ink);
    white-space: nowrap;
}
.in-nearby__dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--in-accent);
    animation: in-pulse 1.6s ease-in-out infinite;
}
.in-nearby__count { font-variant-numeric: tabular-nums; }

/* ── Map controls (right side) ───────────────────────────────────────────── */
.in-mapctl {
    position: absolute;
    top: 232px; right: 14px;
    z-index: 45;
    display: flex; flex-direction: column;
    /* Stack with breathing room between buttons. Each tile gets its own
     * drop-shadow filter so they read as separate cards rather than a
     * single segmented control. */
    gap: 8px;
    transition: top 220ms ease;
}
.in-mapctl__btn {
    width: 44px; height: 44px;
    background: var(--in-surface);
    color: var(--in-ink);
    border: 1.5px solid var(--in-ink);
    border-radius: 14px;
    box-shadow: 2px 2px 0 var(--in-ink);
    display: inline-flex; align-items: center; justify-content: center;
    cursor: pointer;
    padding: 0;
}
.in-mapctl__btn--first { border-top-left-radius: 14px; border-top-right-radius: 14px; }
.in-mapctl__btn--last  { border-bottom-left-radius: 14px; border-bottom-right-radius: 14px; }

/* Fullscreen wordmark pill (only visible in fullscreen) */
.in-wordmark-pill {
    position: absolute;
    top: 78px; left: 16px;
    z-index: 50;
    padding: 8px 14px;
    background: var(--in-bg);
    border: 1.5px solid var(--in-ink);
    border-radius: 999px;
    box-shadow: 2px 2px 0 var(--in-ink);
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 18px; color: var(--in-ink);
    display: none;
}

/* Browser-native fullscreen on the .in-app element. The browser hides the
 * host page (WP header, footer, chrome) behind the element; we make sure
 * the in-app fills the device viewport with no spacing. The user keeps
 * full access to chrome, chips, sheet, and tab bar inside the fullscreen
 * view. */
.in-app:fullscreen,
.in-app:-webkit-full-screen {
    width: 100vw;
    height: 100vh;
    max-width: none;
    max-height: none;
    background: var(--in-bg);
}

/* The .is-fullscreen class is now just a state marker (set in JS so other
 * code can react). No chrome is hidden - the user wants to keep search /
 * chips / tab bar accessible while at viewport size. */

/* ── Top chrome ──────────────────────────────────────────────────────────── */
.in-chrome {
    position: absolute;
    top: 0; left: 0; right: 0;
    z-index: 50;
    padding-top: 54px;
    background: linear-gradient(180deg, var(--in-bg) 0%, var(--in-bg) 60%, transparent 100%);
    pointer-events: none;
}
.in-chrome > * { pointer-events: auto; }
.in-chrome__row {
    display: flex; align-items: center; gap: 10px;
    padding: 0 16px;
}
.in-wordmark {
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 28px; color: var(--in-ink);
    letter-spacing: -0.02em;
    line-height: 1;
}
.in-accent-dot {
    color: var(--in-accent);
    font-family: var(--in-font-ui);
    font-style: normal;
    font-weight: 700;
}
/* Client-name wordmark variant. When the admin sets a "Wordmark prefix"
 * (e.g. "Balmers"), the skin rewrites .in-wordmark to:
 *   "Balmers <span class="innsight-mode-header">→ Innsight</span><span class="in-accent-dot">.</span>"
 * The mode-header pill renders the "→ Innsight" tag at half size with
 * a yellow-green chip background; the accent dot tucks under the chip
 * so the trailing period reads as part of the chip footprint. */
.in-wordmark span.innsight-mode-header {
    font-size: .5em;
    color: #333;
    background: var(--in-accent);
    padding: 2px 15px 2px 3px;
}
.in-wordmark span.innsight-mode-header + .in-accent-dot {
    margin-left: -13px;
    color: #a3c540;
}
.in-profile {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--in-ink);
    color: var(--in-bg);
    border: 0;
    cursor: pointer;
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 18px;
    display: inline-flex; align-items: center; justify-content: center;
    padding: 0;
}

.in-chrome__search { padding: 10px 16px 0; }
.in-search {
    height: 44px;
    border-radius: 999px;
    background: var(--in-surface);
    border: 1.5px solid var(--in-ink);
    box-shadow: 2px 2px 0 var(--in-ink);
    display: flex; align-items: center;
    padding: 0 14px;
    gap: 10px;
}
.in-search__icon { color: var(--in-ink); flex-shrink: 0; }
.in-search__input {
    flex: 1;
    border: 0; outline: none; background: transparent;
    font-size: 14px; color: var(--in-ink);
    min-width: 0;
}
.in-search__input::placeholder { color: var(--in-mute); }
.in-search__badge {
    width: 28px; height: 28px;
    border-radius: 50%;
    background: var(--in-accent);
    border: 1.5px solid var(--in-ink);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 700; color: var(--in-ink);
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
}

/* Chips */
.in-chips {
    display: flex; gap: 8px;
    padding: 12px 16px 14px;
    overflow-x: auto;
}
.in-chip {
    flex-shrink: 0;
    height: 34px;
    padding: 0 14px;
    border-radius: 999px;
    background: var(--in-surface);
    color: var(--in-ink);
    border: 1.5px solid var(--in-ink);
    box-shadow: 2px 2px 0 var(--in-ink);
    font-family: var(--in-font-ui);
    font-weight: 600; font-size: 13px;
    cursor: pointer;
    display: inline-flex; align-items: center; gap: 6px;
    transition: transform 120ms, box-shadow 120ms, background 120ms, color 120ms;
}
.in-chip[aria-pressed="true"] {
    background: var(--in-ink);
    color: var(--in-bg);
    box-shadow: none;
    transform: translate(2px, 2px);
}
.in-chip__dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    border: 1px solid var(--in-ink);
    flex-shrink: 0;
}
.in-chip[aria-pressed="true"] .in-chip__dot { border-color: var(--in-bg); }
.in-chips--small .in-chip {
    height: 32px;
    padding: 0 12px;
    font-size: 12.5px;
}
.in-chips--small .in-chip__dot { width: 7px; height: 7px; }

/* ── Tab bar ─────────────────────────────────────────────────────────────── */
/* position: absolute keeps the tab bar at the bottom edge of .in-app.
 * On pages where .in-app fills the viewport, that's the bottom of the
 * screen; on pages where the shortcode is shorter than the viewport, the
 * tab bar lives at the bottom of the visible shortcode footprint and
 * scrolls with it - this is the correct "embedded UI" behaviour. Authors
 * who want an always-on tab bar should pass height="100dvh" in the
 * shortcode so the .in-app covers the full viewport. */
.in-tabs {
    position: absolute;
    left: 12px; right: 12px;
    bottom: 22px;
    /* z-index needs to beat aggressive theme floats like sticky "BOOK
     * NOW" buttons (Balmers theme uses z-index 9999 on its CTA). The
     * tab bar is inside .in-app so we don't pollute the page stack -
     * just tall enough to win inside our own root. */
    z-index: 9999;
    height: 58px;
    border-radius: 999px;
    background: var(--in-bg) !important;
    border: 1.5px solid var(--in-ink);
    box-shadow: 3px 3px 0 var(--in-ink);
    display: flex; align-items: center;
    padding: 4px;
    /* Force this layer to claim pointer events even if a theme overlay
     * tries to swallow them with pointer-events:auto on a higher node. */
    pointer-events: auto;
}
.in-tab {
    flex: 1;
    height: 50px;
    border-radius: 999px;
    position: relative;
    background: transparent;
    color: var(--in-mute);
    border: 0;
    cursor: pointer;
    font-weight: 600; font-size: 14px;
    transition: background 160ms, color 160ms;
    display: inline-flex; align-items: center; justify-content: center;
}
.in-tab[aria-selected="true"] {
    background: var(--in-ink) !important;
    color: #ffffff !important;
}
.in-tab__underline {
    position: absolute;
    left: 50%; bottom: 8px;
    transform: translateX(-50%);
    width: 0; height: 3px;
    border-radius: 99px;
    background: var(--in-accent);
    transition: width 160ms;
}
.in-tab[aria-selected="true"] .in-tab__underline { width: 18px; }

/* ── Pin (per-POI) ───────────────────────────────────────────────────────── */
/* Mapbox GL marker host. The engine's MapboxGLProvider sets className to
 * .innsight-pin-host for skins that supply a per-pin template. */
.innsight-pin-host {
    cursor: pointer;
    background: transparent;
    will-change: transform;
}
.in-pin {
    width: 44px; height: 44px;
    animation: in-pin-pop 0.55s cubic-bezier(.5, 1.6, .4, 1) both;
    transform-origin: 50% 100%;
}
.in-pin__base {
    width: 44px; height: 44px;
    border-radius: 8px;
    border: 3px solid #fff;
    box-shadow: 2px 3px 0 rgba(0, 0, 0, 0.85);
    transform: rotate(-4deg);
    overflow: hidden;
    position: relative;
    background: var(--c, #FFB85C);
}
.in-pin__img {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    filter: saturate(0.15) contrast(1.15) brightness(1.05);
    mix-blend-mode: hard-light;
    opacity: 0.95;
}
.in-pin__wash {
    position: absolute; inset: 0;
    background: var(--c, #FFB85C);
    mix-blend-mode: multiply;
    opacity: 0.55;
}
.in-pin__initial {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 26px;
    color: #fff;
    line-height: 1;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45), 0 0 1px rgba(0, 0, 0, 0.3);
}

/* ── Bottom sheet ────────────────────────────────────────────────────────── */
.in-sheet-backdrop {
    position: absolute; inset: 0;
    background: rgba(15, 15, 15, 0.45);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    /* Modal layers must beat the tab bar (z-index 9999, raised to
     * defeat theme floats). Sheet stack starts at 10000 so the tab
     * bar can't poke through over the sheet content / actions. */
    z-index: 10000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 220ms ease;
}
.in-app.is-sheet-open .in-sheet-backdrop {
    opacity: 1;
    pointer-events: auto;
}
.in-sheet {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    z-index: 10001;
    transform: translateY(110%);
    transition: transform 280ms cubic-bezier(.32, .72, .2, 1);
    will-change: transform;
}
.in-app.is-sheet-open .in-sheet { transform: translateY(0); }
.in-sheet__inner {
    background: var(--in-sheet);
    border-top-left-radius: 28px;
    border-top-right-radius: 28px;
    padding: 10px 16px 36px;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.18);
    max-height: 78vh;
    overflow-y: auto;
    /* Contain prevents iOS overscroll bounce from reaching the page; pan-y
     * lets the sheet content scroll natively while our JS handles the
     * top-zone drag-to-close gesture. */
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
    transform: translateX(0);
    transition: transform 280ms cubic-bezier(.32, .72, .2, 1), opacity 220ms;
}
.in-sheet__inner.is-hint {
    animation: in-sheet-hint 1.6s cubic-bezier(.4, 0, .2, 1) both;
}
.in-grabber {
    width: 44px; height: 5px;
    border-radius: 99px;
    background: var(--in-ink);
    opacity: 0.18;
    margin: 4px auto 14px;
    cursor: pointer;
    /* Claim the pointer gesture entirely so iOS / Chrome Android don't
     * try to interpret a downward drag as pull-to-refresh. */
    touch-action: none;
}

/* Sheet nav row (prev / counter / next) */
.in-sheet__nav {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 10px;
    font-size: 11px;
    color: var(--in-mute);
}
.in-sheet__navbtn {
    background: transparent; border: 0; padding: 0;
    color: inherit; cursor: pointer;
    display: inline-flex; align-items: center; gap: 6px;
    font: inherit;
    max-width: 40%;
}
.in-sheet__navname {
    max-width: 110px;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.in-sheet__chev { font-size: 14px; }
.in-sheet__counter {
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--in-mute2);
    white-space: nowrap;
}
.in-sheet__inner.is-hint .in-sheet__navbtn {
    animation: in-hint-chev 1.4s ease-in-out 2;
}

/* Hero */
.in-hero {
    height: 168px;
    border-radius: 22px;
    overflow: hidden;
    position: relative;
    background: var(--c, #FFB85C);
}
.in-hero__img {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    filter: saturate(0.9) contrast(1.05);
}
.in-hero__wash {
    position: absolute; inset: 0;
    background: var(--c, #FFB85C);
    opacity: 0.55;
    mix-blend-mode: multiply;
}
.in-hero__shine {
    position: absolute; inset: 0;
    background: radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.25), transparent 60%);
}
.in-hero__initial {
    position: absolute;
    left: 18px; bottom: 16px;
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 78px; line-height: 0.85;
    /* Always white over the photo + multiply wash. Dark layered shadow gives
     * legibility on any underlying hue. */
    color: #fff;
    letter-spacing: -0.02em;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.45), 0 0 1px rgba(0, 0, 0, 0.35);
}
.in-hero__tagpill {
    position: absolute;
    top: 14px; right: 14px;
    background: var(--in-ink);
    color: #fff;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 11px; font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* Sheet meta + body */
.in-sheet__meta {
    display: flex; align-items: center; gap: 8px;
    margin-top: 16px;
    font-size: 12px;
    color: var(--in-mute3);
    flex-wrap: wrap;
}
.in-sheet__catdot {
    width: 10px; height: 10px;
    border-radius: 50%;
    border: 1.5px solid var(--in-ink);
    flex-shrink: 0;
}
.in-sheet__catlabel {
    font-size: 12px; font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--in-ink);
}
.in-sheet__sep { color: var(--in-mute2); }
.in-sheet__open[data-open="true"]  { color: var(--in-open);   font-weight: 600; }
.in-sheet__open[data-open="false"] { color: var(--in-closed); font-weight: 600; }
.in-sheet__title {
    font-family: var(--in-font-display);
    font-weight: 400;
    font-size: 38px; line-height: 1.05;
    margin: 8px 0 6px;
    letter-spacing: -0.01em;
    color: var(--in-ink);
}
.in-sheet__hours {
    font-size: 14px; color: var(--in-mute3);
    margin-bottom: 14px;
}
.in-sheet__blurb {
    font-size: 15px; line-height: 1.5;
    margin: 0 0 18px;
    color: var(--in-ink);
}
.in-sheet__vibelabel {
    font-size: 10px; font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--in-mute);
    margin-bottom: 8px;
}
.in-sheet__vibewrap {
    display: flex; gap: 6px; flex-wrap: wrap;
    margin-bottom: 22px;
}
.in-sheet__tag {
    display: inline-block;
    padding: 6px 11px;
    border-radius: 999px;
    background: var(--in-bg);
    color: var(--in-ink);
    border: 1px solid var(--in-ink);
    font-size: 12px; font-weight: 500;
}

/* Personal-note preview above the sheet actions. Accent background +
 * dark text + 3-line clamp; entire block is a button that opens the
 * full notes editor on tap. */
.in-sheet__note-preview {
    display: block;
    width: 100%;
    background: var(--in-accent);
    color: var(--in-ink);
    border: 1.5px solid var(--in-ink);
    box-shadow: 2px 2px 0 var(--in-ink);
    border-radius: 14px;
    padding: 10px 14px;
    margin-bottom: 14px;
    text-align: left;
    font: inherit;
    cursor: pointer;
    transition: transform 120ms, box-shadow 120ms;
}
.in-sheet__note-preview:hover { transform: translate(1px, 1px); box-shadow: 1px 1px 0 var(--in-ink); }
.in-sheet__note-label {
    display: block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--in-ink);
    opacity: 0.7;
    margin-bottom: 4px;
}
.in-sheet__note-text {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 14px;
    line-height: 1.45;
    font-style: italic;
    word-break: break-word;
}

/* "Featured in" popover - the scrollable list of posts that reference
 * this POI, revealed by tapping More info. Sits ABOVE the actions row
 * with a max-height = ~3 items so longer lists scroll inside. Bg is
 * surface white over the sheet's cream so it reads as a distinct
 * floating panel. */
.in-sheet__refs {
    background: #ffffff;
    border: 1.5px solid var(--in-ink);
    border-radius: 14px;
    box-shadow: 2px 2px 0 var(--in-ink);
    padding: 10px 14px;
    margin-bottom: 12px;
    animation: in-refs-pop 220ms cubic-bezier(.32, .72, .2, 1) backwards;
}
.in-sheet__refs[hidden] { display: none; }
.in-sheet__refs-head {
    font-size: 10px; font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--in-mute);
    margin-bottom: 6px;
}
.in-sheet__refs-list {
    list-style: none;
    margin: 0; padding: 0;
    /* ~3 rows visible (38px each) before scroll kicks in. */
    max-height: 132px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}
.in-sheet__refs-list li {
    border-bottom: 1px dashed var(--in-divider-dashed);
}
.in-sheet__refs-list li:last-child { border-bottom: 0; }
.in-sheet__refs-list a {
    display: block;
    padding: 9px 4px;
    color: var(--in-ink) !important;
    text-decoration: none !important;
    font-size: 14px;
    line-height: 1.3;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.in-sheet__refs-list a:hover { color: var(--in-ink) !important; background: var(--in-bg); border-radius: 6px; }
.in-sheet__refs-empty {
    padding: 9px 4px;
    color: var(--in-mute);
    font-style: italic;
    font-size: 13px;
}
@keyframes in-refs-pop {
    from { transform: translateY(8px); opacity: 0; }
    to   { transform: translateY(0);   opacity: 1; }
}

/* Sheet actions */
.in-sheet__actions {
    display: flex; gap: 10px;
}
.in-sheet__act {
    flex: 1;
    /* min-width:0 lets the flex item shrink past its content size, which
     * is what enables text-overflow:ellipsis to actually clip a long
     * button label instead of forcing the row taller / wider. */
    min-width: 0;
    height: 48px;
    line-height: 48px;
    border-radius: 14px;
    background: transparent;
    color: var(--in-ink);
    border: 1.5px solid var(--in-ink);
    font-weight: 600; font-size: 15px;
    cursor: pointer;
    /* Single-line, centered, ellipsis when the custom button text is
     * too long (e.g. "The most beautiful lakes around Interlaken"). */
    display: block;
    text-align: center;
    padding: 0 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    box-sizing: border-box;
}
.in-sheet__act--primary,
.in-sheet__act--primary:visited,
.in-sheet__act--primary:active {
    /* Pure white text - cream (--in-bg) on ink reads too dim. Both
     * the <button> and <a> form get the same color. `!important`
     * everywhere because host themes routinely override `a, button`
     * colors and we end up with invisible text on a black pill. */
    background: var(--in-ink) !important;
    color: #ffffff !important;
    border-color: var(--in-ink) !important;
    text-decoration: none !important;
}
.in-sheet__act--primary:hover,
.in-sheet__act--primary:focus {
    /* On hover, swap to accent bg + ink text so the action is OBVIOUSLY
     * interactable and the text never disappears (some themes set
     * a:hover { background: #fff } which would white-out the white
     * label). Accent + ink is unambiguous on every host theme. */
    background: var(--in-accent) !important;
    color: var(--in-ink) !important;
    border-color: var(--in-ink) !important;
    text-decoration: none !important;
}
.in-sheet__act--primary span { color: inherit !important; }
.in-sheet__act,
.in-sheet__act:visited,
.in-sheet__act:hover,
.in-sheet__act:focus {
    color: var(--in-ink) !important;
}
.in-sheet__act--primary { color: #ffffff !important; }

/* ── List view ───────────────────────────────────────────────────────────── */
.in-list {
    position: absolute;
    inset: 0;
    background: var(--in-bg);
    z-index: 60;
    /* The list scrolls internally - never lets the page scroll past the
     * shortcode container on mobile. overscroll-behavior: contain stops
     * iOS Safari from chaining the bounce-scroll back to the document.
     * max-height: 100dvh caps it at the dynamic viewport (accounts for
     * iOS URL bar shrinkage) so the tab bar always stays reachable. */
    max-height: 100dvh;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    padding-top: 54px;
    /* Leave room for the tab bar (58px tall + 22px bottom + 16px breathing). */
    padding-bottom: 110px;
    transform: translateX(100%);
    transition: transform 320ms cubic-bezier(.32, .72, .2, 1);
    pointer-events: none;
}
.in-app.is-route-list .in-list {
    transform: translateX(0);
    pointer-events: auto;
}
.in-list__row {
    display: flex; align-items: center; gap: 10px;
    padding: 0 16px;
}
.in-list__title { padding: 14px 16px 4px; }
.in-list__pretitle {
    font-size: 11px; font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--in-mute);
}
.in-list__h1 {
    font-family: var(--in-font-display);
    font-weight: 400;
    font-size: 40px; line-height: 1;
    margin: 6px 0 0;
    letter-spacing: -0.02em;
}
.in-list__h1 em {
    color: var(--in-ink);
    background: var(--in-accent);
    padding: 0 8px;
    border-radius: 6px;
    font-style: italic;
}
.in-list__search { padding: 14px 16px 0; }
.in-list__sort {
    display: flex; align-items: center; gap: 6px;
    padding: 10px 16px 0;
    font-size: 11.5px;
    color: var(--in-mute3);
}
.in-list__sortvalue {
    font-weight: 700; color: var(--in-ink);
    text-decoration: underline var(--in-accent) 3px;
    text-underline-offset: 3px;
}
.in-list__rows { padding: 4px 16px 130px; }
.in-list__empty {
    padding: 60px 12px; text-align: center;
    color: var(--in-mute);
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 22px;
}
.in-row {
    display: flex; align-items: center; gap: 14px;
    padding: 14px 4px;
    background: transparent; border: 0;
    border-bottom: 1px dashed var(--in-divider-dashed);
    cursor: pointer;
    text-align: left;
    width: 100%;
    animation: in-list-in 0.45s cubic-bezier(.5, 1.4, .4, 1) both;
    animation-delay: calc(var(--i, 0) * 50ms);
}
.in-row__sticker {
    width: 56px; height: 56px;
    flex-shrink: 0;
    border-radius: 10px;
    border: 2.5px solid var(--in-ink);
    box-shadow: 3px 3px 0 var(--in-ink);
    transform: rotate(-3deg);
    overflow: hidden;
    position: relative;
    background: var(--c, #FFB85C);
}
.in-row__img {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    filter: saturate(0.85);
}
.in-row__wash {
    position: absolute; inset: 0;
    background: var(--c, #FFB85C);
    opacity: 0.65;
    mix-blend-mode: multiply;
}
.in-row__initial {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 33px; color: #fff; line-height: 1;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}
.in-row__body {
    flex: 1;
    min-width: 0;
}
.in-row__head {
    display: flex; align-items: baseline; gap: 8px;
}
.in-row__name {
    font-family: var(--in-font-display);
    font-size: 22px; line-height: 1.05;
    color: var(--in-ink);
    letter-spacing: -0.01em;
}
.in-row__dist {
    font-size: 11px; color: var(--in-mute);
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
}
.in-row__tag {
    font-size: 12px; color: var(--in-mute);
    margin-top: 2px;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.in-row__meta {
    display: flex; align-items: center; gap: 6px;
    margin-top: 6px;
}
.in-row__catdot {
    width: 7px; height: 7px;
    border-radius: 50%;
    border: 1px solid var(--in-ink);
}
.in-row__catlabel {
    font-size: 10.5px; font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--in-mute3);
}
.in-row__sep { color: var(--in-mute2); font-size: 10px; }
.in-row__open[data-open="true"]  { color: var(--in-open);   font-size: 11px; font-weight: 600; }
.in-row__open[data-open="false"] { color: var(--in-closed); font-size: 11px; font-weight: 600; }
.in-row__rating {
    font-size: 11px; font-weight: 600;
    background: var(--in-accent);
    color: var(--in-ink);
    border: 1px solid var(--in-ink);
    padding: 2px 7px;
    border-radius: 999px;
}

/* Personal note row block. Mobile: stacks below the meta row, aligned
 * with the body content (78px = 56px sticker + 14px gap + 8px breathing).
 * Desktop: floats to the right with a fixed-width column so the row
 * keeps a clean single line. Truncates to 2 lines mobile / 3 lines
 * desktop with an ellipsis. */
.in-row__note {
    flex-basis: 100%;
    margin: 8px 0 0 70px;
    background: var(--in-accent);
    color: var(--in-ink);
    border: 1.5px solid var(--in-ink);
    border-radius: 10px;
    padding: 6px 10px;
    font-size: 12.5px;
    line-height: 1.4;
    font-style: italic;
    /* 2-line clamp with ellipsis. */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    word-break: break-word;
}
@media (min-width: 768px) {
    .in-row__note {
        flex-basis: auto;
        flex: 0 0 240px;
        margin: 0 0 0 auto;
        align-self: center;
        -webkit-line-clamp: 3;
    }
    .in-row { flex-wrap: nowrap; }
}
@media (max-width: 767px) {
    .in-row { flex-wrap: wrap; }
}

/* ── Empty state (Saved / You) ───────────────────────────────────────────── */
.in-screen-empty {
    position: absolute;
    inset: 0;
    background: var(--in-bg);
    z-index: 60;
    display: none;
    flex-direction: column; align-items: center;
    text-align: center;
    padding: 110px 32px 130px;
}
.in-app.is-route-me   .in-screen-empty { display: flex; }
.in-empty__tile {
    width: 84px; height: 84px;
    border-radius: 16px;
    margin-bottom: 18px;
    background: var(--in-accent);
    border: 2.5px solid var(--in-ink);
    box-shadow: 4px 4px 0 var(--in-ink);
    transform: rotate(-4deg);
    display: inline-flex; align-items: center; justify-content: center;
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 48px; color: var(--in-ink);
}
.in-empty__title {
    font-family: var(--in-font-display);
    font-weight: 400;
    font-size: 40px;
    margin: 6px 0 8px;
    color: var(--in-ink);
    line-height: 1;
}
.in-empty__body {
    font-size: 14px;
    color: rgba(15, 15, 15, 0.6);
    margin: 0;
    max-width: 240px;
}

/* ── Mapbox attribution restyle ──────────────────────────────────────────── */
.in-app .mapboxgl-ctrl-attrib {
    background: rgba(250, 247, 238, 0.7);
    font: 10px/1 var(--in-font-ui);
    color: rgba(15, 15, 15, 0.5);
    border-radius: 999px;
    padding: 3px 8px;
    margin: 0 0 92px 12px;
}
.in-app .mapboxgl-ctrl-attrib a { color: rgba(15, 15, 15, 0.55); }

/* Hide the Mapbox logo - the design has no logo on the map. */
.in-app .mapboxgl-ctrl-logo { display: none !important; }

/* Mapbox marker reset (the engine wraps each pin in a div with our class) */
.in-app .mapboxgl-marker { will-change: transform; }
.in-app .mapboxgl-marker.innsight-pin-host { background: transparent; border: 0; padding: 0; }

/* ── Animations ──────────────────────────────────────────────────────────── */
@keyframes in-pin-pop {
    0%   { transform: scale(0);    opacity: 0; }
    60%  { transform: scale(1.18); opacity: 1; }
    100% { transform: scale(1);    opacity: 1; }
}
@keyframes in-pin-drop {
    0%   { transform: translateY(-180%) scale(0.6); opacity: 0; }
    70%  { transform: translateY(0)     scale(1.05); opacity: 1; }
    100% { transform: translateY(0)     scale(1);    opacity: 1; }
}
@keyframes in-pin-ripple {
    0%   { transform: scale(0.2);  opacity: 0; filter: blur(3px); }
    50%  { transform: scale(1.05); opacity: 1; filter: blur(0); }
    100% { transform: scale(1);    opacity: 1; filter: blur(0); }
}
@keyframes in-pin-fade {
    0%   { transform: scale(0.92); opacity: 0; }
    100% { transform: scale(1);    opacity: 1; }
}
@keyframes in-pulse {
    0%, 100% { transform: scale(1);   opacity: 0.55; }
    50%      { transform: scale(1.6); opacity: 0;    }
}
@keyframes in-list-in {
    0%   { transform: translateX(-12px); opacity: 0; }
    100% { transform: translateX(0);     opacity: 1; }
}
@keyframes in-sheet-hint {
    0%   { transform: translateX(0); }
    25%  { transform: translateX(-34px); }
    50%  { transform: translateX(0); }
    75%  { transform: translateX(18px); }
    100% { transform: translateX(0); }
}
@keyframes in-hint-chev {
    0%, 100% { transform: translateX(0);    opacity: 0.55; }
    50%      { transform: translateX(-4px); opacity: 1;    }
}

/* ── Pin entry style swap ───────────────────────────────────────────────── */
.in-app[data-entry="drop"]   .in-pin { animation-name: in-pin-drop; }
.in-app[data-entry="ripple"] .in-pin { animation-name: in-pin-ripple; }
.in-app[data-entry="fade"]   .in-pin { animation-name: in-pin-fade; }

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
    .in-pin, .in-row, .in-sheet, .in-sheet__inner.is-hint { animation: none !important; transition: none !important; }
    .in-nearby__dot { animation: none !important; }
}

/* ── v0.4.5 overrides ────────────────────────────────────────────────────── */

/* Search box: themes sometimes inject grey input/form backgrounds; force
 * pure white on both the wrapper and the input itself. */
.in-app .in-search,
.in-app .in-list__search .in-search { background: #ffffff; }
.in-app .in-search__input { background: transparent; color: var(--in-ink); }
.in-app .in-search__input:focus { outline: none; }

/* Hide the "You" tab and the profile circle in v0.4.x. They are reserved
 * for a future user-account feature; keeping them visible but inert misled
 * testers. Re-enable by overriding `display` in a child theme. */
.in-app .in-tabs .in-tab[data-route="me"] { display: none; }
.in-app .in-profile { display: none; }

/* Toast notification (used by Save / Remove). Anchored above the tab bar
 * so it never collides with sheet content. */
.in-toast {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--in-ink) !important;
    color: #ffffff !important;
    padding: 10px 18px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    opacity: 0;
    pointer-events: none;
    z-index: 200;
    box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.4);
    transition: opacity 220ms ease, transform 220ms cubic-bezier(.32, .72, .2, 1);
    white-space: nowrap;
}
.in-toast.is-visible { opacity: 1; transform: translateX(-50%) translateY(0); }

/* Save button toggled "saved" state - accent fill + ink text + check icon. */
.in-sheet__act.is-saved {
    background: var(--in-accent);
    color: var(--in-ink);
    border-color: var(--in-ink);
}

/* Lock the host page while the bottom sheet is open. This prevents iOS
 * Safari and Chrome Android from interpreting a downward drag inside the
 * sheet as a pull-to-refresh gesture on the WordPress page below. */
body.innsight-sheet-locked {
    overflow: hidden;
    overscroll-behavior-y: contain;
    touch-action: pan-x pan-y;
}

/* Also nuke pull-to-refresh on the sheet nav row - the row is in the top
 * gesture zone and dragging from there should close the sheet, never
 * scroll the page. */
.in-sheet__nav { touch-action: none; }

/* Sort dropdown trigger + menu (list view header). */
.in-list__sort { position: relative; }
.in-list__sortvalue {
    background: transparent;
    border: 0;
    padding: 0;
    color: inherit;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
    color: var(--in-ink);
    text-decoration: underline var(--in-accent) 3px;
    text-underline-offset: 3px;
}
.in-list__sortmenu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 6px;
    background: #fff;
    border: 1.5px solid var(--in-ink);
    border-radius: 14px;
    box-shadow: 3px 3px 0 var(--in-ink);
    padding: 6px;
    display: flex;
    flex-direction: column;
    min-width: 160px;
    z-index: 80;
}
.in-list__sortmenu[hidden] { display: none; }
.in-list__sortmenu button {
    background: transparent;
    border: 0;
    padding: 8px 10px;
    border-radius: 8px;
    cursor: pointer;
    text-align: left;
    font: inherit;
    color: var(--in-ink);
    font-size: 13px;
}
.in-list__sortmenu button:hover { background: var(--in-bg); }

/* "X km from base" meta on list rows. */
.in-row__hostel {
    font-size: 10.5px;
    color: var(--in-mute);
    font-variant-numeric: tabular-nums;
}

/* ── Saved tab ───────────────────────────────────────────────────────────── */
.in-saved {
    position: absolute;
    inset: 0;
    background: var(--in-bg);
    z-index: 60;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    padding-top: 54px;
    padding-bottom: 110px;
    transform: translateX(100%);
    transition: transform 320ms cubic-bezier(.32, .72, .2, 1);
    pointer-events: none;
}
.in-app.is-route-save .in-saved {
    transform: translateX(0);
    pointer-events: auto;
}
.in-saved__head { padding: 0 0 4px; }
.in-saved__rows { padding: 4px 16px 130px; }
.in-saved__rows .in-list__empty { padding: 60px 12px; text-align: center; color: var(--in-mute);
    font-family: var(--in-font-display); font-style: italic; font-size: 22px; }

/* Inline "Remove from saved" X affordance on each saved row. Span (not
 * button) to avoid nested-button HTML; positioned absolutely on the
 * right edge of the row. */
.in-saved .in-row { position: relative; padding-right: 44px; }
.in-row__remove {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 0;
    color: var(--in-mute2);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    border-radius: 50%;
    transition: color 160ms, background 160ms, transform 160ms;
    user-select: none;
}
.in-row__remove:hover {
    color: var(--in-closed);
    background: rgba(180, 59, 59, 0.10);
    transform: translateY(-50%) scale(1.08);
}
.in-row__remove:active { transform: translateY(-50%) scale(0.92); }

/* Google Maps "View on" link below the sheet actions. Subtle, not a button. */
.in-sheet__gmaps {
    display: block;
    margin-top: 14px;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    color: var(--in-mute);
    text-decoration: none;
    letter-spacing: 0.02em;
}
.in-sheet__gmaps:hover { color: var(--in-ink); }

.in-sheet__tag--rating { background: var(--in-accent); }

/* ── Live location pulse marker ──────────────────────────────────────────── */
.in-livedot {
    position: relative;
    width: 44px; height: 44px;
    pointer-events: none;
    display: flex; align-items: center; justify-content: center;
    z-index: 35;
}
.in-livedot__pulse {
    position: absolute; inset: 0;
    border-radius: 50%;
    background: var(--in-accent);
    opacity: 0.35;
    animation: in-livedot-pulse 2s ease-in-out infinite;
}
.in-livedot__core {
    position: relative;
    width: 26px; height: 26px;
    border-radius: 50%;
    background: var(--in-accent);
    border: 2px solid var(--in-ink);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    display: flex; align-items: center; justify-content: center;
    font-size: 16px; line-height: 1;
    /* Emoji-safe centering: emoji fonts have inconsistent metrics. */
    font-family: 'Apple Color Emoji', 'Segoe UI Emoji', system-ui;
}
@keyframes in-livedot-pulse {
    0%, 100% { transform: scale(1);   opacity: 0.35; }
    50%      { transform: scale(1.7); opacity: 0;    }
}
@media (prefers-reduced-motion: reduce) {
    .in-livedot__pulse { animation: none !important; opacity: 0.2; }
}

/* ── v0.5.0 - Google Places loading state ────────────────────────────────── */
.in-sheet__enriching {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--in-mute2);
    font-size: 11px;
    font-style: italic;
}
.in-sheet__enriching-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--in-accent);
    animation: in-pulse 1.6s ease-in-out infinite;
}
.in-sheet__hours--placeholder {
    height: 18px; width: 60%;
    border-radius: 6px;
    background: linear-gradient(90deg, rgba(15,15,15,0.06) 25%, rgba(15,15,15,0.12) 50%, rgba(15,15,15,0.06) 75%);
    background-size: 200% 100%;
    animation: in-shimmer 1.4s linear infinite;
    margin-bottom: 14px;
}
.in-sheet__tag--placeholder {
    background: rgba(15,15,15,0.06);
    color: var(--in-mute2);
    border-color: var(--in-divider);
    font-style: italic;
    animation: in-shimmer-soft 1.6s ease-in-out infinite;
}
@keyframes in-shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
@keyframes in-shimmer-soft {
    0%, 100% { opacity: 0.55; }
    50%      { opacity: 1;    }
}

/* ── v0.5.0 - Personal note pull-up ──────────────────────────────────────── */

/* Peek strip at the bottom of the sheet. Shows the downward arrow + label
 * + a thin top edge of the textarea, hinting "drag me up to write a note".
 *
 * Hidden by default; revealed only when the POI is saved (the JS toggles
 * `.is-poi-saved` on `.in-app` after every openSheet / save / unsave).
 * This keeps the sheet visually quiet for unsaved POIs - notes are a
 * "keeper's feature", not noise for casual browsing. */
.in-sheet__notes-peek {
    display: none;
    margin-top: 22px;
    padding: 14px 16px 0;
    background: var(--in-bg);
    border: 1.5px dashed var(--in-divider);
    border-radius: 18px 18px 0 0;
    border-bottom: 0;
    cursor: pointer;
    user-select: none;
    text-align: center;
    color: var(--in-mute);
    transition: background 160ms, color 160ms;
    /* Pointer gestures: own them entirely so we don't conflict with the
     * sheet's vertical-scroll. */
    touch-action: none;
}
.in-app.is-poi-saved .in-sheet__notes-peek { display: block; }
.in-sheet__notes-peek:hover { background: #fff; color: var(--in-ink); }
.in-sheet__notes-peek-arrow {
    display: block;
    color: var(--in-ink);
    margin: 0 auto 4px;
    animation: in-notes-bob 2.2s ease-in-out infinite;
}
.in-sheet__notes-peek-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 10px;
}
/* The peek-edge mimics the top of a textarea peeking through. */
.in-sheet__notes-peek-edge {
    display: block;
    height: 14px;
    margin: 0 -16px;
    border-top: 1.5px solid var(--in-ink);
    background: #FFFDF6;
    border-radius: 16px 16px 0 0;
    box-shadow: 2px -2px 0 var(--in-ink);
}

@keyframes in-notes-bob {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(3px); }
}

/* Notes panel - covers the full .in-app footprint when open.
 *
 * Hidden states use BOTH `display:none` (via the [hidden] HTML attribute
 * the JS sets) AND `display:none` in CSS as a backstop, because past
 * versions of the panel rendered visible due to transform-only hides
 * being defeated by ancestor positioning. The `.is-notes-open` class on
 * `.in-app` flips display to flex AND triggers a slide-up animation.
 *
 * --in-notes-h is updated by the JS from visualViewport.height so the
 * keyboard never hides the textarea on iOS / Android. Default 100% =
 * fill the .in-app container.
 */
.in-notes {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    height: var(--in-notes-h, 100%);
    /* Above the sheet (10001) so the notes editor fully covers the
     * sheet's content + actions when open. Tab bar (9999) stays
     * underneath - the notes editor is modal. */
    z-index: 10005;
    background: var(--in-sheet);
    border-top-left-radius: 28px;
    border-top-right-radius: 28px;
    box-shadow: 0 -16px 50px rgba(0,0,0,0.22);
    flex-direction: column;
    display: none;           /* hidden by default, no exceptions */
}
.in-notes[hidden] { display: none !important; }   /* belt-and-braces */
.in-app.is-notes-open .in-notes {
    display: flex;
    animation: in-notes-slide-up 320ms cubic-bezier(.32,.72,.2,1) backwards;
}
@keyframes in-notes-slide-up {
    from { transform: translateY(100%); opacity: 0.6; }
    to   { transform: translateY(0);    opacity: 1; }
}
.in-notes__inner {
    flex: 1;
    display: flex; flex-direction: column;
    padding: 8px 16px 18px;
    min-height: 0;
}
.in-notes__head {
    display: flex; align-items: center; gap: 10px;
    padding: 4px 4px 12px;
    border-bottom: 1px dashed var(--in-divider-dashed);
    margin-bottom: 10px;
    cursor: grab;
    touch-action: none;
}
.in-notes__grabber {
    width: 44px; height: 5px;
    border-radius: 99px;
    background: var(--in-ink);
    opacity: 0.18;
    margin-right: 4px;
}
.in-notes__title {
    font-family: var(--in-font-display);
    font-style: italic;
    font-size: 22px;
    color: var(--in-ink);
    flex: 1;
    line-height: 1;
}
.in-notes__close,
.in-notes__close:visited,
.in-notes__close:hover,
.in-notes__close:focus {
    height: 36px;
    padding: 0 16px;
    border-radius: 999px;
    background: var(--in-ink) !important;
    color: #ffffff !important;
    border: 0;
    font: inherit; font-weight: 600;
    cursor: pointer;
}
.in-notes__sub {
    font-size: 11px;
    color: var(--in-mute);
    text-align: right;
    margin: 0 4px 6px;
    transition: color 200ms;
}
.in-notes__sub.is-saved { color: var(--in-open); font-weight: 600; }
.in-notes__area {
    flex: 1;
    width: 100%;
    border: 1.5px solid var(--in-ink);
    border-radius: 18px;
    box-shadow: 2px 2px 0 var(--in-ink);
    background: #FFFDF6;
    padding: 14px 16px;
    font-family: var(--in-font-ui);
    font-size: 15px;
    line-height: 1.5;
    color: var(--in-ink);
    resize: none;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    min-height: 120px;
}
.in-notes__area::placeholder { color: var(--in-mute2); font-style: italic; }
.in-notes__area:focus { box-shadow: 2px 2px 0 var(--in-accent), 2px 2px 0 1.5px var(--in-ink); }

/* ── v0.5.0 - Share button (Saved tab header) ────────────────────────────── */
.in-saved__share,
.in-saved__share:visited,
.in-saved__share:hover,
.in-saved__share:focus,
.in-saved__share:active {
    display: inline-flex; align-items: center; gap: 6px;
    height: 38px;
    padding: 0 14px;
    border-radius: 999px;
    background: var(--in-ink) !important;
    color: #ffffff !important;
    border: 1.5px solid var(--in-ink) !important;
    box-shadow: 2px 2px 0 var(--in-accent);
    font: inherit;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: transform 120ms, box-shadow 120ms;
}
.in-saved__share span { color: inherit !important; }
.in-saved__share svg  { color: inherit !important; }
.in-saved__share:hover,
.in-saved__share:focus {
    background: var(--in-accent) !important;
    color: var(--in-ink) !important;
    transform: translate(1px, 1px);
    box-shadow: 1px 1px 0 var(--in-ink);
}
.in-saved__share[hidden] { display: none; }

/* ── v0.5.0 - Share menu (bottom sheet with channel tiles) ──────────────── */
.in-share-backdrop {
    position: absolute; inset: 0;
    background: rgba(15,15,15,0.45);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    /* Share is launched from the Saved tab so it must sit above the
     * tab bar (9999) and above any open sheet/notes (10001/10005). */
    z-index: 10010;
    opacity: 0;
    pointer-events: none;
    transition: opacity 220ms ease;
}
.in-app.is-share-open .in-share-backdrop { opacity: 1; pointer-events: auto; }
.in-share-menu {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    z-index: 10011;
    transform: translateY(110%);
    transition: transform 280ms cubic-bezier(.32,.72,.2,1);
    will-change: transform;
}
.in-app.is-share-open .in-share-menu { transform: translateY(0); }
.in-share-menu__inner {
    background: var(--in-sheet);
    border-top-left-radius: 28px;
    border-top-right-radius: 28px;
    padding: 10px 16px 28px;
    box-shadow: 0 -10px 40px rgba(0,0,0,0.18);
}
.in-share-menu__head {
    display: flex; align-items: center; gap: 10px;
    padding: 6px 4px 14px;
}
.in-share-menu__pretitle {
    font-size: 11px; font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--in-mute);
}
.in-share-menu__title {
    font-family: var(--in-font-display);
    font-size: 26px; line-height: 1;
    color: var(--in-ink);
    margin-top: 4px;
}
.in-share-menu__close {
    margin-left: auto;
    width: 38px; height: 38px;
    border-radius: 50%;
    background: transparent;
    color: var(--in-ink);
    border: 1.5px solid var(--in-ink);
    font-size: 20px;
    cursor: pointer;
    line-height: 1;
}
.in-share-menu__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
    gap: 10px;
}
.in-share-tile {
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    padding: 14px 10px;
    border-radius: 16px;
    background: var(--in-surface);
    border: 1.5px solid var(--in-ink);
    box-shadow: 2px 2px 0 var(--in-ink);
    color: var(--in-ink);
    font-weight: 600;
    font-size: 12px;
    cursor: pointer;
    transition: transform 120ms, box-shadow 120ms;
}
.in-share-tile:hover { transform: translate(1px, 1px); box-shadow: 1px 1px 0 var(--in-ink); }
.in-share-tile__icon {
    width: 42px; height: 42px;
    border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--in-bg);
    color: var(--in-ink);
    border: 1.5px solid var(--in-ink);
}
/* Brand-tinted icon backgrounds. */
.in-share-tile__icon[data-channel="whatsapp"] { background: #25D366; color: #fff; }
.in-share-tile__icon[data-channel="facebook"] { background: #1877F2; color: #fff; }
.in-share-tile__icon[data-channel="email"]    { background: var(--in-accent); }

/* ── v0.5.0 - Receive popup (recipient lands via share URL) ─────────────── */
.in-receive {
    position: absolute; inset: 0;
    /* Top-most modal: appears on landing from a share URL, must
     * cover everything else (sheet, notes, share menu). */
    z-index: 10020;
    display: flex; align-items: center; justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    background: rgba(15,15,15,0.55);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    transition: opacity 240ms ease;
}
.in-app.is-receive-open .in-receive { opacity: 1; pointer-events: auto; }
.in-receive__card {
    width: min(100%, 380px);
    background: var(--in-sheet);
    border: 2px solid var(--in-ink);
    box-shadow: 6px 6px 0 var(--in-ink);
    border-radius: 24px;
    padding: 28px 24px 24px;
    text-align: center;
    transform: translateY(20px) scale(0.96);
    transition: transform 320ms cubic-bezier(.4,1.6,.4,1);
}
.in-app.is-receive-open .in-receive__card { transform: translateY(0) scale(1); }
.in-receive__sticker {
    width: 68px; height: 68px;
    margin: 0 auto 14px;
    border-radius: 16px;
    background: var(--in-accent);
    border: 2px solid var(--in-ink);
    box-shadow: 3px 3px 0 var(--in-ink);
    transform: rotate(-6deg);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 38px;
    color: var(--in-ink);
    line-height: 1;
    /* Heart character benefits from a tiny optical correction. */
    padding-bottom: 4px;
}
.in-receive__pretitle {
    font-size: 11px; font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--in-mute);
}
.in-receive__title {
    font-family: var(--in-font-display);
    font-size: 30px;
    line-height: 1.1;
    color: var(--in-ink);
    margin: 8px 0 10px;
}
.in-receive__body {
    font-size: 14px;
    color: var(--in-mute3);
    margin: 0 4px 14px;
    line-height: 1.5;
}
.in-receive__count {
    display: inline-block;
    background: var(--in-bg);
    border: 1.5px solid var(--in-ink);
    border-radius: 999px;
    padding: 5px 14px;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 22px;
}
.in-receive__count span { font-variant-numeric: tabular-nums; }
.in-receive__actions {
    display: flex; gap: 10px;
}
.in-receive__btn {
    flex: 1;
    height: 46px;
    border-radius: 14px;
    background: transparent;
    color: var(--in-ink);
    border: 1.5px solid var(--in-ink);
    font: inherit;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: transform 120ms, box-shadow 120ms;
}
.in-receive__btn--primary,
.in-receive__btn--primary:visited,
.in-receive__btn--primary:active {
    background: var(--in-ink) !important;
    color: #ffffff !important;
    border-color: var(--in-ink) !important;
    box-shadow: 2px 2px 0 var(--in-accent);
}
.in-receive__btn--primary:hover,
.in-receive__btn--primary:focus {
    background: var(--in-accent) !important;
    color: var(--in-ink) !important;
    border-color: var(--in-ink) !important;
    transform: translate(1px, 1px);
    box-shadow: 1px 1px 0 var(--in-ink);
}
.in-receive__btn,
.in-receive__btn:visited {
    color: var(--in-ink) !important;
    border-color: var(--in-ink) !important;
}
.in-receive__btn--primary { color: #ffffff !important; }

/* ── v0.5.0 - Dancing 'Friend's picks' chip ─────────────────────────────── */
.in-chip--shared {
    background: var(--in-accent);
    color: var(--in-ink);
    border-color: var(--in-ink);
    padding-right: 6px;
}
.in-chip--shared .in-chip__heart {
    color: #B43B7C;
    margin-right: 2px;
    font-size: 14px;
    line-height: 1;
}
.in-chip--shared .in-chip__close {
    display: inline-flex; align-items: center; justify-content: center;
    width: 22px; height: 22px;
    border-radius: 50%;
    background: var(--in-ink);
    color: var(--in-bg);
    margin-left: 4px;
    font-size: 14px;
    line-height: 1;
}
.in-chip--dance { animation: in-dance 1.6s ease-in-out infinite; transform-origin: 50% 80%; }
@keyframes in-dance {
    0%, 100% { transform: rotate(-3deg) translateY(0); }
    25%      { transform: rotate( 3deg) translateY(-2px); }
    50%      { transform: rotate(-2deg) translateY(0); }
    75%      { transform: rotate( 4deg) translateY(-1px); }
}
@media (prefers-reduced-motion: reduce) {
    .in-chip--dance, .in-sheet__notes-peek-arrow { animation: none !important; }
}

/* ── v0.5.1 - Desktop sheet (≥ 900px) ────────────────────────────────────
 *
 * On wide screens the bottom sheet stretching edge-to-edge looks wrong
 * (a 1900px-wide hero photo dominates the screen). Constrain the inner
 * card to ~50% of the viewport, centred horizontally, with a modest
 * height bump on the hero so the image still reads as a poster. The
 * outer .in-sheet stays full-width so the slide-up transition / backdrop
 * keep working unchanged.
 */
@media (min-width: 900px) {
    .in-sheet__inner {
        width: 56%;
        max-width: 720px;
        min-width: 480px;
        margin: 0 auto;
        max-height: 80vh;
        border-radius: 28px 28px 0 0;
        padding: 14px 28px 40px;
    }
    .in-hero { height: 240px; border-radius: 26px; }
    .in-hero__initial { font-size: 92px; }
    .in-sheet__title { font-size: 44px; }
    .in-sheet__blurb { font-size: 16px; }
    /* Notes panel deliberately fills the FULL .in-app on desktop too so
     * it visibly takes over the sheet (no awkward floating-card look
     * that overlaps the sheet hero). The animation comes from
     * @keyframes in-notes-slide-up; no transform overrides here. */
    .in-share-menu__inner {
        width: 56%; max-width: 720px; min-width: 480px;
        margin: 0 auto;
        border-radius: 28px 28px 0 0;
    }
}

@media (min-width: 1280px) {
    .in-sheet__inner { width: 50%; max-width: 760px; }
    .in-share-menu__inner { width: 50%; max-width: 760px; }
}
