/*
 * SnapZyte — Global Responsive CSS
 * File: assets/css/app.css
 *
 * Architecture:
 *   - Mobile First (< 1024px): Bottom nav, full-width feed, no sidebars
 *   - Tablet (768px-1023px): Left icon-only sidebar (72px)
 *   - Desktop (>= 1024px): 3-column layout (240px left | 600px center | 280px right)
 */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

/* ============================================================
   1. CSS VARIABLES & BASE RESET
   ============================================================ */
:root {
    --sidebar-left-width: 240px;
    --sidebar-right-width: 280px;
    --sidebar-icon-width: 72px;
    --feed-max-width: 600px;
    --bottom-nav-height: 60px;
    --header-height: 56px;
    --color-primary: #2563eb;
    --color-primary-hover: #1d4ed8;
    --color-accent: #ec4899;
    --color-bg: #f8fafc;
    --color-card: #ffffff;
    --color-border: #e2e8f0;
    --color-text: #0f172a;
    --color-text-muted: #64748b;
    --transition-speed: 0.2s;
}

.dark {
    --color-bg: #0f172a;
    --color-card: #1e293b;
    --color-border: #334155;
    --color-text: #f1f5f9;
    --color-text-muted: #94a3b8;
}

*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    transition: background-color var(--transition-speed), color var(--transition-speed);
    /* Bottom padding for mobile bottom nav */
    padding-bottom: var(--bottom-nav-height);
}

/* ============================================================
   2. TOP HEADER (Mobile & Tablet only)
   ============================================================ */
.sz-top-header {
    position: sticky;
    top: 0;
    z-index: 40;
    height: var(--header-height);
    background: var(--color-card);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    transition: background var(--transition-speed), border-color var(--transition-speed);
}

.sz-top-header .sz-logo {
    font-size: 1.4rem;
    font-weight: 900;
    color: var(--color-primary);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.sz-top-header .sz-header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.sz-top-header .sz-header-icon {
    position: relative;
    color: var(--color-text);
    font-size: 1.15rem;
    text-decoration: none;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color var(--transition-speed);
}

.sz-top-header .sz-header-icon:hover {
    color: var(--color-primary);
}

.sz-header-badge {
    position: absolute;
    top: -3px;
    right: -5px;
    background: #ef4444;
    color: #ffffff;
    font-size: 0.6rem;
    font-weight: 800;
    min-width: 17px;
    height: 17px;
    border-radius: 9999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid var(--color-bg, #ffffff);
    box-shadow: 0 1px 3px rgba(239, 68, 68, 0.45);
    z-index: 10;
    line-height: 1;
    pointer-events: none;
}

.sz-header-badge.hidden,
.sz-nav-badge.hidden {
    display: none !important;
}

/* ============================================================
   3. LEFT SIDEBAR (Tablet: icon-only | Desktop: full)
   ============================================================ */
.sz-left-sidebar {
    display: none; /* hidden on mobile */
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 50;
    background: var(--color-card);
    border-right: 1px solid var(--color-border);
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
    transition: width var(--transition-speed), background var(--transition-speed);
}

.sz-sidebar-logo {
    padding: 20px 16px 16px;
    font-size: 1.4rem;
    font-weight: 900;
    color: var(--color-primary);
    text-decoration: none;
    letter-spacing: -0.5px;
    white-space: nowrap;
    overflow: hidden;
    border-bottom: 1px solid var(--color-border);
    display: block;
}

.sz-sidebar-logo .sz-logo-icon {
    display: none; /* shown only in icon-only mode */
}

.sz-nav-list {
    list-style: none;
    padding: 12px 0;
    margin: 0;
    flex: 1;
}

.sz-nav-item {
    width: 100%;
}

.sz-nav-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    color: var(--color-text);
    text-decoration: none;
    font-size: 0.9375rem;
    font-weight: 500;
    border-radius: 10px;
    margin: 2px 8px;
    transition: background var(--transition-speed), color var(--transition-speed);
    white-space: nowrap;
    overflow: hidden;
    position: relative;
}

.sz-nav-link:hover {
    background: rgba(37, 99, 235, 0.08);
    color: var(--color-primary);
}

.sz-nav-link.active {
    background: rgba(37, 99, 235, 0.1);
    color: var(--color-primary);
    font-weight: 700;
}

.sz-nav-link i {
    font-size: 1.1rem;
    width: 22px;
    text-align: center;
    flex-shrink: 0;
}

.sz-nav-link .sz-nav-label {
    flex: 1;
}

.sz-nav-create-btn {
    margin: 8px 16px 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 11px 16px;
    background: var(--color-primary);
    color: #fff;
    font-size: 0.9rem;
    font-weight: 700;
    border-radius: 12px;
    text-decoration: none;
    transition: background var(--transition-speed), transform 0.1s;
    white-space: nowrap;
    overflow: hidden;
}

.sz-nav-create-btn:hover {
    background: var(--color-primary-hover);
}

.sz-nav-create-btn:active {
    transform: scale(0.97);
}

/* Sidebar profile section */
.sz-sidebar-profile {
    padding: 12px 16px;
    border-top: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--color-text);
    transition: background var(--transition-speed);
    border-radius: 10px;
    margin: 4px 8px;
    overflow: hidden;
}

.sz-sidebar-profile:hover {
    background: rgba(0,0,0,0.04);
}

.sz-sidebar-profile img,
.sz-sidebar-profile .sz-avatar-placeholder {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--color-border);
    flex-shrink: 0;
}

.sz-sidebar-profile .sz-profile-info {
    overflow: hidden;
}

.sz-sidebar-profile .sz-profile-name {
    font-size: 0.8125rem;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sz-sidebar-profile .sz-profile-username {
    font-size: 0.75rem;
    color: var(--color-text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Notification badge in sidebar */
.sz-nav-badge {
    background: #ef4444;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 800;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    margin-left: auto;
    flex-shrink: 0;
}

/* ============================================================
   4. MAIN LAYOUT WRAPPER
   ============================================================ */
.sz-layout {
    display: flex;
    min-height: 100vh;
    position: relative;
}

/* ============================================================
   5. CENTER FEED
   ============================================================ */
.sz-main-content {
    flex: 1;
    min-width: 0;
    /* On mobile, no left margin */
    margin-left: 0;
    margin-right: 0;
    padding-top: 0;
}

.sz-feed-container {
    max-width: var(--feed-max-width);
    margin: 0 auto;
    padding: 0 0 16px;
    width: 100%;
}

/* ============================================================
   6. RIGHT SIDEBAR (Desktop only)
   ============================================================ */
.sz-right-sidebar {
    display: none; /* hidden on mobile and tablet */
    width: var(--sidebar-right-width);
    flex-shrink: 0;
    position: sticky;
    top: 16px;
    align-self: flex-start;
    padding: 16px 0 16px 16px;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
}

.sz-right-sidebar::-webkit-scrollbar {
    width: 0;
}

/* Right sidebar mini profile card */
.sz-mini-profile {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.sz-mini-profile img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--color-border);
}

.sz-mini-profile .sz-mini-name {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--color-text);
}

.sz-mini-profile .sz-mini-username {
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

/* Suggestions section */
.sz-suggestions-card {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 16px;
}

.sz-suggestions-title {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.sz-suggestion-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid var(--color-border);
}

.sz-suggestion-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.sz-suggestion-item img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--color-border);
    flex-shrink: 0;
}

.sz-suggestion-item .sz-sug-info {
    flex: 1;
    min-width: 0;
}

.sz-suggestion-item .sz-sug-name {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sz-suggestion-item .sz-sug-username {
    font-size: 0.725rem;
    color: var(--color-text-muted);
}

.sz-suggestion-item .sz-sug-follow-btn {
    font-size: 0.8rem;
    font-weight: 700;
    color: #fff;
    background: var(--color-primary);
    text-decoration: none;
    flex-shrink: 0;
    padding: 5px 14px;
    border-radius: 8px;
    transition: background var(--transition-speed), transform 0.1s;
    display: inline-flex;
    align-items: center;
}

.sz-suggestion-item .sz-sug-follow-btn:hover {
    background: var(--color-primary-hover);
    transform: scale(1.03);
}

/* ============================================================
   7. BOTTOM NAVIGATION BAR (Mobile Native App System)
   ============================================================ */
.sz-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    height: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0px));
    padding-bottom: env(safe-area-inset-bottom, 0px);
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-top: 1px solid rgba(226, 232, 240, 0.85);
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding-left: 8px;
    padding-right: 8px;
    box-shadow: 0 -4px 20px -2px rgba(0, 0, 0, 0.04), 0 -1px 3px rgba(0, 0, 0, 0.02);
    transition: background var(--transition-speed), border-color var(--transition-speed);
    user-select: none;
    -webkit-user-select: none;
}

.dark .sz-bottom-nav {
    background: rgba(15, 23, 42, 0.90);
    border-top: 1px solid rgba(30, 41, 59, 0.85);
    box-shadow: 0 -4px 25px -2px rgba(0, 0, 0, 0.45);
}

/* Nav Item (Home, Search, Reels, Profile) */
.sz-bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    min-width: 52px;
    height: 48px;
    border-radius: 16px;
    color: #64748b;
    text-decoration: none;
    transition: color 0.18s ease, transform 0.15s ease;
    -webkit-tap-highlight-color: transparent;
}

.dark .sz-bottom-nav-item {
    color: #94a3b8;
}

.sz-bottom-nav-item i {
    font-size: 1.25rem;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), color 0.18s ease;
}

/* Flutter / Native App Spring Touch Feedback */
.sz-bottom-nav-item:active {
    transform: scale(0.86);
    opacity: 0.85;
}

.sz-bottom-nav-item:hover {
    color: #0f172a;
}
.dark .sz-bottom-nav-item:hover {
    color: #ffffff;
}

/* Active State with Native Micro-Dot Indicator */
.sz-bottom-nav-item.active {
    color: var(--color-primary);
}
.dark .sz-bottom-nav-item.active {
    color: #3b82f6;
}

.sz-bottom-nav-item.active i {
    transform: scale(1.08);
}

.sz-bottom-nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 3.5px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--color-primary);
    box-shadow: 0 0 6px rgba(37, 99, 235, 0.65);
    animation: szDotPop 0.22s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.dark .sz-bottom-nav-item.active::after {
    background: #3b82f6;
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.8);
}

/* Reels Item Specific Active Color */
.sz-bottom-nav-item[href="reel.php"].active {
    color: #ec4899;
}
.sz-bottom-nav-item[href="reel.php"].active::after {
    background: #ec4899;
    box-shadow: 0 0 7px rgba(236, 72, 153, 0.7);
}

@keyframes szDotPop {
    0% { transform: scale(0); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* ── Center Elevated Action Button (Create +) ────────────────────────── */
.sz-bottom-nav-create {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: linear-gradient(135deg, #2563eb 0%, #4f46e5 100%);
    color: #ffffff !important;
    text-decoration: none;
    box-shadow: 0 6px 16px -2px rgba(37, 99, 235, 0.45), 0 2px 6px rgba(37, 99, 235, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.25);
    transition: transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s ease;
    -webkit-tap-highlight-color: transparent;
    cursor: pointer;
}

.sz-bottom-nav-create i {
    font-size: 1.15rem;
    color: #ffffff;
    transition: transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sz-bottom-nav-create:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 9px 22px -2px rgba(37, 99, 235, 0.6), 0 3px 8px rgba(37, 99, 235, 0.35);
}

.sz-bottom-nav-create:active {
    transform: scale(0.88);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.35);
}

/* Top glass glare highlight */
.sz-bottom-nav-create::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 14px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.28) 0%, rgba(255, 255, 255, 0) 100%);
    pointer-events: none;
}

/* ── Profile Avatar in Bottom Nav ────────────────────────────────────── */
.sz-bottom-nav-avatar {
    width: 27px;
    height: 27px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid transparent;
    transition: border-color var(--transition-speed), transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sz-bottom-nav-item.active .sz-bottom-nav-avatar {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.25);
    transform: scale(1.06);
}
.dark .sz-bottom-nav-item.active .sz-bottom-nav-avatar {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.35);
}

/* Notification badge on bottom nav */
.sz-bottom-badge {
    position: absolute;
    top: 5px;
    right: 8px;
    background: #ef4444;
    color: #fff;
    font-size: 0.55rem;
    font-weight: 800;
    min-width: 15px;
    height: 15px;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    border: 1.5px solid var(--color-card);
    box-shadow: 0 1px 3px rgba(239, 68, 68, 0.35);
}

/* ============================================================
   8. POST CARD
   ============================================================ */
.sz-post-card {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: 0; /* Mobile: edge to edge */
    margin-bottom: 8px;
    overflow: hidden;
    transition: background var(--transition-speed), border-color var(--transition-speed);
}

/* ============================================================
   9. TABLET BREAKPOINT (>= 768px)
   ============================================================ */
@media (min-width: 768px) {
    body {
        padding-bottom: 0;
    }

    .sz-top-header {
        display: none; /* hidden on tablet — sidebar takes over */
    }

    .sz-bottom-nav {
        display: none; /* no bottom bar on tablet */
    }

    .sz-left-sidebar {
        display: flex;
        width: var(--sidebar-icon-width);
    }

    /* Icon-only mode: hide text labels */
    .sz-nav-link .sz-nav-label,
    .sz-sidebar-logo .sz-logo-text,
    .sz-sidebar-profile .sz-profile-info,
    .sz-nav-create-btn .sz-create-label {
        display: none;
    }

    .sz-sidebar-logo {
        text-align: center;
        padding: 20px 0 16px;
    }

    .sz-sidebar-logo .sz-logo-icon {
        display: inline;
        font-size: 1.4rem;
    }

    .sz-nav-link {
        position: relative;
        justify-content: center;
        padding: 14px 0;
        margin: 2px 8px;
    }

    .sz-nav-badge {
        position: absolute;
        top: 6px;
        right: calc(50% - 16px);
        margin-left: 0;
        font-size: 0.55rem;
        min-width: 16px;
        height: 16px;
        padding: 0 3px;
        border: 1.5px solid var(--color-bg, #ffffff);
    }

    .sz-nav-link i {
        width: auto;
    }

    .sz-nav-create-btn {
        margin: 8px auto 12px;
        width: 42px;
        height: 42px;
        padding: 0;
        border-radius: 50%;
        justify-content: center;
    }

    .sz-nav-create-btn i {
        font-size: 1.1rem;
    }

    .sz-sidebar-profile {
        justify-content: center;
        padding: 14px 0;
        margin: 4px 8px;
    }

    .sz-main-content {
        margin-left: var(--sidebar-icon-width);
    }

    .sz-post-card {
        border-radius: 12px;
        margin-bottom: 12px;
    }

    .sz-feed-container {
        padding: 12px 16px 16px;
    }
}

/* ============================================================
   10. DESKTOP BREAKPOINT (>= 1024px)
   ============================================================ */
@media (min-width: 1024px) {
    .sz-left-sidebar {
        width: var(--sidebar-left-width);
    }

    /* Show all labels again */
    .sz-nav-link .sz-nav-label,
    .sz-nav-badge,
    .sz-sidebar-logo .sz-logo-text,
    .sz-sidebar-profile .sz-profile-info,
    .sz-nav-create-btn .sz-create-label {
        display: flex;
    }

    .sz-nav-link .sz-nav-label {
        display: block;
    }

    .sz-sidebar-logo {
        text-align: left;
        padding: 20px 16px 16px;
    }

    .sz-sidebar-logo .sz-logo-icon {
        display: none;
    }

    .sz-nav-link {
        justify-content: flex-start;
        padding: 12px 16px;
    }

    .sz-nav-create-btn {
        width: auto;
        height: auto;
        padding: 11px 16px;
        border-radius: 12px;
        margin: 8px 16px 12px;
    }

    .sz-sidebar-profile {
        justify-content: flex-start;
        padding: 12px 16px;
        margin: 4px 8px;
    }

    .sz-main-content {
        margin-left: var(--sidebar-left-width);
        margin-right: var(--sidebar-right-width);
        display: flex;
        flex-direction: column;
    }

    .sz-right-sidebar {
        display: block;
        position: fixed;
        right: 0;
        top: 0;
        height: 100vh;
        padding: 24px 16px;
        overflow-y: auto;
        background: transparent;
        border-left: 1px solid var(--color-border);
        /* Custom scrollbar */
        scrollbar-width: thin;
        scrollbar-color: var(--color-border) transparent;
    }

    .sz-right-sidebar::-webkit-scrollbar {
        width: 4px;
    }

    .sz-right-sidebar::-webkit-scrollbar-thumb {
        background: var(--color-border);
        border-radius: 4px;
    }

    .sz-feed-container {
        padding: 16px 24px 24px;
        max-width: 680px;
    }

    .sz-post-card {
        border-radius: 14px;
        margin-bottom: 16px;
    }
}

/* ============================================================
   11. LARGE DESKTOP (>= 1280px)
   ============================================================ */
@media (min-width: 1280px) {
    .sz-feed-container {
        max-width: 680px;
    }
}

/* ============================================================
   12. SCROLLBAR (Global)
   ============================================================ */
body::-webkit-scrollbar {
    width: 6px;
}

body::-webkit-scrollbar-track {
    background: transparent;
}

body::-webkit-scrollbar-thumb {
    background: var(--color-border);
    border-radius: 3px;
}

/* ============================================================
   13. UTILITY CLASSES
   ============================================================ */
.sz-hide-desktop {
    display: block;
}

.sz-show-desktop {
    display: none;
}

@media (min-width: 1024px) {
    .sz-hide-desktop { display: none !important; }
    .sz-show-desktop { display: block !important; }
}

/* Fix: prevent body scroll when modal is open */
body.modal-open {
    overflow: hidden;
}

/* ============================================================
   14. PWA INSTALL BANNER
   ============================================================ */
.sz-pwa-banner {
    background: linear-gradient(135deg, #2563eb, #7c3aed);
    color: #fff;
    padding: 10px 16px;
    position: sticky;
    top: var(--header-height);
    z-index: 39;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.8125rem;
}

@media (min-width: 768px) {
    .sz-pwa-banner {
        top: 0;
    }
}

/* ============================================================
   15. FLUTTER / NATIVE ANDROID APP SYSTEM (PROFILE & GLOBAL UI)
   ============================================================ */
:root {
    --app-radius-xs: 8px;
    --app-radius-sm: 12px;
    --app-radius-md: 16px;
    --app-radius-lg: 24px;
    --app-radius-pill: 9999px;
    --app-tap-transition: transform 0.12s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.12s ease;
}

/* Eliminate Web Tap Highlight across all mobile taps */
* {
    -webkit-tap-highlight-color: transparent;
}

/* Native App Touch Feedback (Puckers on tap like Android/Flutter/iOS) */
.sz-touch-feedback {
    transition: var(--app-tap-transition);
    user-select: none;
    -webkit-user-select: none;
}
.sz-touch-feedback:active {
    transform: scale(0.96);
    opacity: 0.88;
}

/* Native Story Ring (Instagram / Android Gradient Glow) */
.sz-story-ring {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    padding: 2.5px;
    border-radius: 9999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(220, 39, 67, 0.25);
    flex-shrink: 0;
}

.sz-story-ring-blue {
    background: linear-gradient(135deg, #3b82f6 0%, #6366f1 50%, #8b5cf6 100%);
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.28);
}

/* Native Sheet Slide-Up Animation (Flutter ModalBottomSheet) */
@keyframes flutterSheetIn {
    from {
        transform: translateY(100%);
        opacity: 0.85;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}
.sz-sheet-animate {
    animation: flutterSheetIn 0.28s cubic-bezier(0.2, 0.9, 0.3, 1) forwards;
}

/* Native Grid Thumbnail Touch */
.sz-media-cell {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #e2e8f0;
    transition: transform 0.15s ease, opacity 0.15s ease;
    user-select: none;
    -webkit-user-select: none;
}
.dark .sz-media-cell {
    background: #1e293b;
}
.sz-media-cell:active {
    transform: scale(0.97);
}

/* Native Material / iOS Drag Handle */
.sz-drag-handle {
    width: 38px;
    height: 4.5px;
    background-color: #cbd5e1;
    border-radius: 9999px;
    margin: 8px auto 14px auto;
}
.dark .sz-drag-handle {
    background-color: #475569;
}

/* ============================================================
   14. NATIVE FEED, STORY RINGS & DOUBLE-TAP HEART ANIMATIONS
   ============================================================ */

/* Instagram-Style Double Tap Heart Burst */
@keyframes heartBurstPop {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    35% {
        transform: scale(1.3);
        opacity: 1;
    }
    60% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(0.9);
        opacity: 0;
    }
}

.sz-heart-burst {
    animation: heartBurstPop 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards !important;
}

/* Feed Action Icons Tactile Touch Physics */
.sz-feed-action-btn {
    transition: transform 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275), color 0.15s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.sz-feed-action-btn:active {
    transform: scale(0.75);
}

/* Scrollbar Hide Utility */
.scrollbar-none::-webkit-scrollbar {
    display: none;
}
.scrollbar-none {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* ============================================================
   Instagram-Style Asymmetric Explore Grid & Search Utilities
   ============================================================ */
.sz-explore-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-flow: dense;
    gap: 2px;
}
@media (min-width: 640px) {
    .sz-explore-grid {
        gap: 6px;
    }
}
@media (min-width: 768px) {
    .sz-explore-grid {
        gap: 8px;
    }
}

.sz-explore-card {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background-color: #f1f5f9;
    border-radius: 4px;
}
.dark .sz-explore-card {
    background-color: #1e293b;
}
@media (min-width: 640px) {
    .sz-explore-card {
        border-radius: 12px;
    }
}

.sz-explore-card.sz-tall {
    grid-row: span 2;
    aspect-ratio: auto;
    height: 100%;
}

.sz-explore-card img,
.sz-explore-card video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.sz-explore-card:hover img,
.sz-explore-card:hover video {
    transform: scale(1.04);
}

.sz-explore-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.38);
    backdrop-filter: blur(1.5px);
    -webkit-backdrop-filter: blur(1.5px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    color: #ffffff;
    font-weight: 700;
    font-size: 0.825rem;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
    z-index: 5;
}

.sz-explore-card:hover .sz-explore-overlay,
.sz-explore-card:focus-within .sz-explore-overlay {
    opacity: 1;
}


