/* ============================================================
   Upstore Coming Soon Popup — Frontend Styles v2
   No scroll indicators. Smooth border radius. Clean mobile.
   ============================================================ */

/* ── CSS custom props (set inline by PHP) ─────────────────── */
#upstore-overlay {
    --ua:   #FF661F;        /* accent */
    --ual:  rgba(255,102,31,0.1);
    --ubf:  #1A1A1A;        /* bg from */
    --ubt:  #2D2D2D;        /* bg to */
    --ucb:  #ffffff;        /* card bg */
    --utc:  #1A1A1A;        /* title color */
    --utxt: #6B7280;        /* text / label */
    --ubc:  #FF661F;        /* button bg */
    --ubtc: #ffffff;        /* button text */
    --ur:   12px;           /* radius */
}



/* ── Absolute top-layer protection ─────────────────────────
   This popup is intentionally modal/no-close. While enabled,
   every other site element is hidden behind it, including sticky
   headers from other plugins/themes. */
html.upstore-popup-open,
body.upstore-popup-open {
    overflow: hidden !important;
    height: 100% !important;
    max-height: 100% !important;
    touch-action: none;
}
body.upstore-popup-open > *:not(#upstore-overlay):not(#ust-toast) {
    visibility: hidden !important;
    pointer-events: none !important;
}
body.upstore-popup-open #upstore-overlay,
body.upstore-popup-open #ust-toast {
    visibility: visible !important;
}
#upstore-overlay {
    z-index: 2147483647 !important;
    isolation: isolate !important;
    transform: translateZ(0);
}
#ust-toast {
    z-index: 2147483647 !important;
}

/* ── Overlay ─────────────────────────────────────────────── */
.upstore-overlay {
    position: fixed !important;
    inset: 0 !important;
    z-index: 2147483647 !important;
    background: linear-gradient(135deg, var(--ubf) 0%, var(--ubt) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    overflow: hidden; /* no scrollbar on backdrop */
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ── Popup card ──────────────────────────────────────────── */
.upstore-popup {
    width: 100%;
    max-width: 1060px;
    background: var(--ucb);
    border-radius: calc(var(--ur) * 2);
    box-shadow: 0 20px 60px rgba(0,0,0,0.22);
    border: 1px solid rgba(255,255,255,0.08);
    animation: ust-in 0.4s cubic-bezier(0.16,1,0.3,1) forwards;
    max-height: calc(100vh - 32px);
}

@keyframes ust-in {
    from { opacity: 0; transform: translateY(20px) scale(0.98); }
    to   { opacity: 1; transform: translateY(0)    scale(1); }
}

/* ── Inner scroll container — hidden scrollbar ───────────── */
.upstore-inner {
    padding: 36px 32px 28px;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
    overflow-x: hidden;
    /* hide scroll indicators everywhere */
    scrollbar-width: none;     /* Firefox */
    -ms-overflow-style: none;  /* IE/Edge */
}
.upstore-inner::-webkit-scrollbar { display: none; } /* Chrome/Safari */

/* ── Header ──────────────────────────────────────────────── */
.upstore-header { text-align: center; margin-bottom: 24px; }

.upstore-logo-img {
    max-height: 80px;
    max-width: 220px;
    object-fit: contain;
    margin: 0 auto 16px;
    display: block;
}

.upstore-icon-wrap {
    width: 72px; height: 72px;
    background: linear-gradient(135deg, var(--ua) 0%, color-mix(in srgb, var(--ua) 70%, #fff) 100%);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px;
    box-shadow: 0 8px 24px rgba(255,102,31,0.28);
    animation: ust-pulse 2.2s ease-in-out infinite;
}
@keyframes ust-pulse {
    0%,100% { box-shadow: 0 8px 24px rgba(255,102,31,0.28); }
    50%      { box-shadow: 0 8px 32px rgba(255,102,31,0.48); }
}
.upstore-icon-wrap i { font-size: 32px; color: #fff; }

.upstore-title {
    font-size: 30px;
    font-weight: 800;
    color: var(--utc);
    margin: 0 0 6px;
    line-height: 1.2;
    letter-spacing: -0.5px;
}
.upstore-tagline { font-size: 13px; color: var(--utxt); margin: 0 0 14px; }

.upstore-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--ual);
    color: var(--ua);
    padding: 5px 16px;
    border-radius: var(--ur);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.2px;
}

/* ── Countdown ───────────────────────────────────────────── */
.upstore-countdown {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 0 0 28px;
    flex-wrap: wrap;
}
.upstore-cd-item { text-align: center; }
.upstore-cd-num {
    display: block;
    font-size: 30px;
    font-weight: 800;
    color: var(--utc);
    background: var(--ual);
    padding: 10px 14px;
    border-radius: var(--ur);
    min-width: 66px;
    margin-bottom: 5px;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}
.upstore-cd-lbl {
    font-size: 10px;
    font-weight: 600;
    color: var(--utxt);
    text-transform: uppercase;
    letter-spacing: 0.6px;
}
.upstore-cd-sep {
    font-size: 26px;
    font-weight: 800;
    color: var(--ua);
    line-height: 1;
    margin-bottom: 22px;
    opacity: 0.6;
}

/* ── Section wrapper ─────────────────────────────────────── */
.upstore-section { margin-bottom: 24px; }

.upstore-section-hd {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 700;
    color: var(--utc);
    margin-bottom: 14px;
}
.upstore-section-hd i { color: var(--ua); font-size: 15px; }
.upstore-badge-sm {
    margin-left: auto;
    background: var(--ual);
    color: var(--ua);
    padding: 2px 10px;
    border-radius: var(--ur);
    font-size: 10px;
    font-weight: 700;
}

/* ── Product Carousel ─────────────────────────────────────── */
.upstore-carousel-track {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    padding: 4px 2px 14px;
    cursor: grab;
    /* hide scrollbar */
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.upstore-carousel-track:active { cursor: grabbing; }
.upstore-carousel-track::-webkit-scrollbar { display: none; }

.upstore-card {
    min-width: 175px;
    background: #fff;
    border-radius: var(--ur);
    overflow: hidden;
    border: 1.5px solid #f0f0f0;
    flex-shrink: 0;
    transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.upstore-card:hover {
    transform: translateY(-6px);
    border-color: var(--ua);
    box-shadow: 0 10px 24px rgba(0,0,0,0.1);
}
.upstore-card-img {
    width: 100%;
    height: 150px;
    background: #f7f7f7;
    overflow: hidden;
}
.upstore-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}
.upstore-card:hover .upstore-card-img img { transform: scale(1.06); }
.upstore-card-info { padding: 12px; text-align: center; }
.upstore-card-name {
    font-size: 12px;
    font-weight: 700;
    color: var(--ua);
    text-transform: uppercase;
    letter-spacing: 0.4px;
    margin-bottom: 3px;
}
.upstore-card-price { font-size: 11px; color: var(--utxt); }

/* ── Vendor / Store grid ─────────────────────────────────── */
.upstore-store-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 10px;
    max-height: 260px;
    overflow-y: auto;
    /* hide scrollbar */
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.upstore-store-grid::-webkit-scrollbar { display: none; }

.upstore-store-item {
    background: rgba(0,0,0,0.02);
    border-radius: var(--ur);
    padding: 10px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1.5px solid transparent;
    transition: border-color 0.2s, background 0.2s, transform 0.2s;
}
.upstore-store-item:hover {
    border-color: var(--ua);
    background: var(--ual);
    transform: translateX(4px);
}
.upstore-store-icon {
    width: 38px; height: 38px;
    background: var(--ual);
    border-radius: var(--ur);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.upstore-store-icon i { font-size: 16px; color: var(--ua); }
.upstore-store-info { flex: 1; min-width: 0; }
.upstore-store-name     { font-size: 12px; font-weight: 700; color: var(--utc); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: 1px; }
.upstore-store-cat      { font-size: 10px; color: var(--utxt); }
.upstore-store-loc      { font-size: 9px; color: var(--ua); font-weight: 600; margin-top: 1px; }

/* ── Email Form ──────────────────────────────────────────── */
.upstore-form { margin: 20px 0 4px; }
.upstore-form-inner {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.upstore-input {
    flex: 1;
    min-width: 180px;
    padding: 13px 18px;
    border: 1.5px solid #e5e7eb;
    border-radius: var(--ur);
    font-size: 14px;
    font-family: inherit;
    color: var(--utc);
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.upstore-input:focus {
    outline: none;
    border-color: var(--ua);
    box-shadow: 0 0 0 3px rgba(255,102,31,0.1);
}
.upstore-btn {
    background: var(--ubc);
    color: var(--ubtc);
    border: none;
    padding: 13px 26px;
    border-radius: var(--ur);
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    font-family: inherit;
    transition: filter 0.2s, transform 0.15s;
    white-space: nowrap;
    letter-spacing: 0.2px;
}
.upstore-btn:hover  { filter: brightness(0.9); transform: translateY(-1px); }
.upstore-btn:active { transform: translateY(0); }
.upstore-btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.upstore-form-msg {
    font-size: 12px;
    font-weight: 500;
    min-height: 18px;
    margin: 8px 0 0;
    color: #10B981;
}
.upstore-form-msg.err { color: #ef4444; }

/* ── Social links ────────────────────────────────────────── */
.upstore-social {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 18px;
    flex-wrap: wrap;
}
.upstore-social a {
    width: 40px; height: 40px;
    background: rgba(0,0,0,0.04);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: var(--utc);
    font-size: 17px;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}
.upstore-social a:hover {
    background: var(--ua);
    color: #fff;
    transform: translateY(-3px);
}

/* ── Toast ───────────────────────────────────────────────── */
.upstore-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(80px);
    opacity: 0;
    background: #111827;
    color: #fff;
    padding: 12px 24px;
    border-radius: var(--ur);
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.2);
    z-index: 2147483647 !important;
    transition: transform 0.35s cubic-bezier(0.16,1,0.3,1), opacity 0.35s;
    border-left: 3px solid var(--ua);
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    max-width: calc(100vw - 32px);
    pointer-events: none;
}
.upstore-toast.show { transform: translateX(-50%) translateY(0); opacity: 1; }
.upstore-toast i { font-size: 18px; color: #10B981; flex-shrink: 0; }

/* ── Responsive — Tablet ─────────────────────────────────── */
@media (max-width: 800px) {
    .upstore-inner      { padding: 26px 20px 22px; }
    .upstore-title      { font-size: 24px; }
    .upstore-cd-num     { font-size: 24px; min-width: 54px; padding: 8px 10px; }
    .upstore-cd-sep     { font-size: 22px; margin-bottom: 20px; }
    .upstore-store-grid { grid-template-columns: 1fr 1fr; max-height: 220px; }
    .upstore-card       { min-width: 155px; }
    .upstore-card-img   { height: 130px; }
}

/* ── Responsive — Mobile ─────────────────────────────────── */
@media (max-width: 560px) {
    .upstore-overlay    { padding: 10px; align-items: flex-end; }
    .upstore-popup      { border-bottom-left-radius: 0; border-bottom-right-radius: 0; max-height: 92vh; }
    .upstore-inner      { padding: 20px 16px 18px; max-height: 92vh; }
    .upstore-title      { font-size: 20px; }
    .upstore-icon-wrap  { width: 58px; height: 58px; }
    .upstore-icon-wrap i{ font-size: 26px; }
    .upstore-countdown  { gap: 5px; }
    .upstore-cd-num     { font-size: 20px; min-width: 46px; padding: 7px 8px; }
    .upstore-cd-sep     { font-size: 18px; margin-bottom: 18px; }
    .upstore-store-grid { grid-template-columns: 1fr; max-height: 180px; }
    .upstore-card       { min-width: 140px; }
    .upstore-card-img   { height: 118px; }
    .upstore-form-inner { flex-direction: column; }
    .upstore-btn        { width: 100%; justify-content: center; padding: 14px; font-size: 14px; }
    .upstore-input      { min-width: unset; width: 100%; }
    .upstore-social a   { width: 38px; height: 38px; font-size: 16px; }
    .upstore-section-hd { font-size: 13px; }
}

/* ── Very small ──────────────────────────────────────────── */
@media (max-width: 360px) {
    .upstore-cd-num   { font-size: 17px; min-width: 40px; padding: 6px 7px; }
    .upstore-title    { font-size: 18px; }
    .upstore-tagline  { font-size: 12px; }
}

/* ── Reduce motion ───────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .upstore-popup, .upstore-icon-wrap { animation: none; }
    .upstore-card, .upstore-store-item,
    .upstore-social a, .upstore-btn    { transition: none; }
}

/* ============================================================
   Cross-browser + iPhone/Safari fixes
   ============================================================ */

.upstore-overlay,
.upstore-overlay * {
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

.upstore-overlay {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
}

.upstore-popup {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    overflow: hidden;
}

.upstore-inner {
    -webkit-overflow-scrolling: touch;
}

.upstore-carousel-track,
.upstore-store-grid {
    -webkit-overflow-scrolling: touch;
}

.upstore-card,
.upstore-store-item,
.upstore-btn,
.upstore-social a {
    -webkit-tap-highlight-color: transparent;
}

/* Safari fallback for color-mix */
.upstore-icon-wrap {
    background: linear-gradient(135deg, var(--ua) 0%, #ff9a5c 100%);
}

/* Mobile Safari safe area */
@media (max-width: 560px) {
    html,
    body {
        overflow-x: hidden;
    }

    .upstore-overlay {
        padding: 10px 10px calc(10px + env(safe-area-inset-bottom));
        align-items: flex-end;
    }

.upstore-popup {
    max-height: 92vh;
    max-height: calc(92vh - env(safe-area-inset-bottom));
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.upstore-inner {
    max-height: 92vh;
    max-height: calc(92vh - env(safe-area-inset-bottom));
    padding-bottom: 18px;
    padding-bottom: calc(18px + env(safe-area-inset-bottom));
}
    .upstore-form-inner {
        display: flex;
        flex-direction: column;
    }

    .upstore-input {
        width: 100%;
        min-width: 0;
        font-size: 16px; /* prevents iPhone zoom on input focus */
    }

    .upstore-btn {
        width: 100%;
    }
}

/* Touch devices: remove hover dependency */
@media (hover: none) and (pointer: coarse) {
    .upstore-card:hover,
    .upstore-store-item:hover,
    .upstore-social a:hover,
    .upstore-btn:hover {
        transform: none;
    }

    .upstore-card:hover .upstore-card-img img {
        transform: none;
    }
}

/* Reduce animation issues on Safari */
@supports (-webkit-touch-callout: none) {
    .upstore-overlay {
        height: -webkit-fill-available;
    }

    .upstore-popup {
        animation-duration: 0.25s;
    }

    .upstore-toast {
        bottom: calc(24px + env(safe-area-inset-bottom));
    }
}




/* ============================================================
   FINAL iPhone/Safari responsive hardening patch
   Keeps same design, fixes mobile viewport, safe area, flex overflow,
   input zoom, carousel overflow and Safari dynamic toolbar issues.
   ============================================================ */

html.upstore-popup-open,
body.upstore-popup-open {
    overflow: hidden !important;
    width: 100% !important;
    position: relative;
}

#upstore-overlay.upstore-overlay {
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: calc(var(--ust-vh, 1vh) * 100);
    min-height: -webkit-fill-available;
    max-width: 100vw;
    padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
    overflow: hidden !important;
    -webkit-text-size-adjust: 100%;
    touch-action: manipulation;
}

#upstore-overlay .upstore-popup {
    width: min(1060px, 100%);
    max-width: 100%;
    max-height: calc((var(--ust-vh, 1vh) * 100) - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    overflow: hidden;
    display: flex;
    flex-direction: column;
    -webkit-transform: translate3d(0,0,0);
    transform: translate3d(0,0,0);
}

#upstore-overlay .upstore-inner {
    width: 100%;
    max-width: 100%;
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}

#upstore-overlay .upstore-title,
#upstore-overlay .upstore-tagline,
#upstore-overlay .upstore-card-name,
#upstore-overlay .upstore-store-name {
    overflow-wrap: anywhere;
    word-break: normal;
}

#upstore-overlay .upstore-carousel-track {
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
}

#upstore-overlay .upstore-card {
    scroll-snap-align: start;
}

#upstore-overlay .upstore-input,
#upstore-overlay .upstore-btn {
    -webkit-appearance: none;
    appearance: none;
    line-height: 1.25;
}

@media (max-width: 800px) {
    #upstore-overlay.upstore-overlay {
        align-items: center;
        justify-content: center;
    }

    #upstore-overlay .upstore-store-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    #upstore-overlay.upstore-overlay {
        align-items: flex-end;
        padding: 8px 8px max(8px, env(safe-area-inset-bottom)) 8px;
    }

    #upstore-overlay .upstore-popup {
        width: 100%;
        border-radius: 18px 18px 0 0;
        max-height: calc((var(--ust-vh, 1vh) * 100) - 8px - env(safe-area-inset-bottom));
    }

    #upstore-overlay .upstore-inner {
        padding: 18px 14px calc(16px + env(safe-area-inset-bottom));
    }

    #upstore-overlay .upstore-header {
        margin-bottom: 16px;
    }

    #upstore-overlay .upstore-logo-img {
        max-width: 170px;
        max-height: 58px;
        margin-bottom: 10px;
    }

    #upstore-overlay .upstore-title {
        font-size: clamp(18px, 5.4vw, 22px);
        line-height: 1.15;
    }

    #upstore-overlay .upstore-tagline {
        font-size: 12px;
        line-height: 1.35;
        margin-bottom: 10px;
    }

    #upstore-overlay .upstore-countdown {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 6px;
        margin-bottom: 18px;
    }

    #upstore-overlay .upstore-cd-sep {
        display: none;
    }

    #upstore-overlay .upstore-cd-num {
        min-width: 0;
        width: 100%;
        font-size: clamp(16px, 5.2vw, 21px);
        padding: 8px 4px;
    }

    #upstore-overlay .upstore-cd-lbl {
        font-size: 9px;
    }

    #upstore-overlay .upstore-section {
        margin-bottom: 18px;
    }

    #upstore-overlay .upstore-carousel-track {
        gap: 10px;
        padding-bottom: 10px;
    }

    #upstore-overlay .upstore-card {
        min-width: 42vw;
        max-width: 42vw;
    }

    #upstore-overlay .upstore-card-img {
        height: 108px;
    }

    #upstore-overlay .upstore-store-grid {
        grid-template-columns: 1fr;
        max-height: 170px;
    }

    #upstore-overlay .upstore-form-inner {
        flex-direction: column;
        gap: 8px;
    }

    #upstore-overlay .upstore-input {
        width: 100%;
        min-width: 0;
        font-size: 16px !important;
        padding: 13px 14px;
    }

    #upstore-overlay .upstore-btn {
        width: 100%;
        white-space: normal;
        text-align: center;
        padding: 14px 12px;
    }
}

@media (max-width: 380px) {
    #upstore-overlay .upstore-card {
        min-width: 46vw;
        max-width: 46vw;
    }

    #upstore-overlay .upstore-inner {
        padding-left: 12px;
        padding-right: 12px;
    }
}

@supports (-webkit-touch-callout: none) {
    #upstore-overlay.upstore-overlay {
        height: calc(var(--ust-vh, 1vh) * 100) !important;
        min-height: 0 !important;
    }
}

/* ============================================================
   Mobile-first horizontal scrolling rows for products + stores
   Works across iOS Safari, Android Chrome, Firefox and desktop.
   ============================================================ */
#upstore-overlay .upstore-carousel-track,
#upstore-overlay .upstore-store-grid,
#upstore-overlay .upstore-carousel-row {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: stretch;
    gap: 12px;
    width: 100%;
    max-width: 100%;
    max-height: none !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    padding: 4px 2px 12px;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x pan-y;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
#upstore-overlay .upstore-carousel-track::-webkit-scrollbar,
#upstore-overlay .upstore-store-grid::-webkit-scrollbar,
#upstore-overlay .upstore-carousel-row::-webkit-scrollbar {
    display: none;
}

#upstore-overlay .upstore-card,
#upstore-overlay .upstore-store-item {
    flex: 0 0 175px !important;
    width: 175px !important;
    min-width: 175px !important;
    max-width: 175px !important;
    scroll-snap-align: start;
}

#upstore-overlay .upstore-store-item {
    background: #fff;
    border-radius: var(--ur);
    overflow: hidden;
    border: 1.5px solid #f0f0f0;
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    gap: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}
#upstore-overlay .upstore-store-item:hover {
    transform: translateY(-6px);
    border-color: var(--ua);
    background: #fff;
    box-shadow: 0 10px 24px rgba(0,0,0,0.1);
}
#upstore-overlay .upstore-store-logo,
#upstore-overlay .upstore-store-icon {
    width: 82px;
    height: 82px;
    border-radius: 18px;
    background: var(--ual);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex: 0 0 auto;
}
#upstore-overlay .upstore-store-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    padding: 8px;
    background: #fff;
}
#upstore-overlay .upstore-store-icon i {
    font-size: 30px;
    color: var(--ua);
}
#upstore-overlay .upstore-store-info {
    width: 100%;
    min-width: 0;
}
#upstore-overlay .upstore-store-name {
    font-size: 12px;
    font-weight: 800;
    color: var(--ua);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1.25;
    white-space: normal;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 30px;
}
#upstore-overlay .upstore-store-cat {
    font-size: 11px;
    color: var(--utxt);
    margin-top: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
#upstore-overlay .upstore-store-loc {
    font-size: 10px;
    color: var(--ua);
    font-weight: 700;
    margin-top: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 560px) {
    #upstore-overlay .upstore-carousel-track,
    #upstore-overlay .upstore-store-grid,
    #upstore-overlay .upstore-carousel-row {
        gap: 10px;
        padding-bottom: 10px;
    }
    #upstore-overlay .upstore-card,
    #upstore-overlay .upstore-store-item {
        flex-basis: 42vw !important;
        width: 42vw !important;
        min-width: 42vw !important;
        max-width: 42vw !important;
    }
    #upstore-overlay .upstore-store-logo,
    #upstore-overlay .upstore-store-icon {
        width: 70px;
        height: 70px;
        border-radius: 16px;
    }
}

@media (max-width: 380px) {
    #upstore-overlay .upstore-card,
    #upstore-overlay .upstore-store-item {
        flex-basis: 46vw !important;
        width: 46vw !important;
        min-width: 46vw !important;
        max-width: 46vw !important;
    }
}

/* ============================================================
   FINAL FIX v1.0.2: guaranteed touch-scroll rows + vendor fallback logo cards
   ============================================================ */
#upstore-overlay .upstore-carousel-track,
#upstore-overlay .upstore-store-grid,
#upstore-overlay .upstore-carousel-row {
    position: relative !important;
    display: -webkit-box !important;
    display: -webkit-flex !important;
    display: flex !important;
    -webkit-box-orient: horizontal !important;
    -webkit-box-direction: normal !important;
    -webkit-flex-direction: row !important;
    flex-direction: row !important;
    -webkit-flex-wrap: nowrap !important;
    flex-wrap: nowrap !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    gap: 12px !important;
    overflow-x: scroll !important;
    overflow-y: hidden !important;
    -webkit-overflow-scrolling: touch !important;
    overscroll-behavior-x: contain !important;
    scroll-behavior: smooth;
    touch-action: auto !important;
    padding: 5px 2px 14px !important;
    margin: 0 !important;
    white-space: nowrap !important;
    cursor: grab;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
#upstore-overlay .upstore-carousel-track.ust-dragging,
#upstore-overlay .upstore-store-grid.ust-dragging,
#upstore-overlay .upstore-carousel-row.ust-dragging {
    cursor: grabbing;
    scroll-behavior: auto;
}
#upstore-overlay .upstore-carousel-track > *,
#upstore-overlay .upstore-store-grid > *,
#upstore-overlay .upstore-carousel-row > * {
    -webkit-box-flex: 0 !important;
    -webkit-flex: 0 0 175px !important;
    flex: 0 0 175px !important;
    width: 175px !important;
    min-width: 175px !important;
    max-width: 175px !important;
    white-space: normal !important;
}
#upstore-overlay .upstore-store-logo img {
    object-fit: contain !important;
    background: #fff !important;
}
@media (max-width: 560px) {
    #upstore-overlay .upstore-carousel-track,
    #upstore-overlay .upstore-store-grid,
    #upstore-overlay .upstore-carousel-row {
        gap: 10px !important;
        padding-bottom: 12px !important;
        -webkit-mask-image: linear-gradient(to right, #000 0%, #000 calc(100% - 22px), transparent 100%);
        mask-image: linear-gradient(to right, #000 0%, #000 calc(100% - 22px), transparent 100%);
    }
    #upstore-overlay .upstore-carousel-track > *,
    #upstore-overlay .upstore-store-grid > *,
    #upstore-overlay .upstore-carousel-row > * {
        -webkit-flex-basis: 44vw !important;
        flex-basis: 44vw !important;
        width: 44vw !important;
        min-width: 44vw !important;
        max-width: 44vw !important;
    }
}
@media (max-width: 380px) {
    #upstore-overlay .upstore-carousel-track > *,
    #upstore-overlay .upstore-store-grid > *,
    #upstore-overlay .upstore-carousel-row > * {
        -webkit-flex-basis: 48vw !important;
        flex-basis: 48vw !important;
        width: 48vw !important;
        min-width: 48vw !important;
        max-width: 48vw !important;
    }
}
