    .fixed-header h1 {
        font-size: 1.5em;
        margin: 0;
        font-weight: 600;
        /* ONE LINE, ALWAYS. On narrow phones (Poco, Redmi, most Transsion)
           "Catholic Community" wrapped to two lines, which made the header
           TALLER than the 60px the sticky quick-nav offsets against — so on
           exactly those phones the nav tucked under the header when
           scrolling. The monogram swap below guarantees the height. */
        white-space: nowrap;
    }
    /* Full wordmark on screens with room; the CC monogram where there isn't.
       Same brand, never two lines, and the username beside it never gets
       squeezed out. */
    .fixed-header .brand-cc {
        display: none;
        width: 38px;
        height: 38px;
        border: 2px solid rgba(255, 255, 255, 0.9);
        border-radius: 50%;
        align-items: center;
        justify-content: center;
        font-size: 0.82em;
        font-weight: 700;
        letter-spacing: 0.5px;
    }
    /* 2026-11-09: the monogram is now the CC logo on a white disc ("CC" in text if the image fails) */
    .fixed-header .brand-cc { background: #fff; border-color: rgba(255, 255, 255, 0.95); color: #1f4e8c; overflow: hidden;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18); }
    .fixed-header .brand-cc img { width: 100%; height: 100%; object-fit: contain; display: block; padding: 3px; box-sizing: border-box; }
    @media (max-width: 430px) {
        .fixed-header .brand-full { display: none; }
        .fixed-header .brand-cc { display: inline-flex; }
    }
    /* header "me" chip (2026-11-11) */
    .fixed-header .hdr-left { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1 1 auto; }
    .fixed-header h1.hdr-h1-me .brand-full { display: none; }
    .fixed-header h1.hdr-h1-me .brand-cc { display: inline-flex; width: 32px; height: 32px; }   /* 36px with its border: the header stays 60px, the height the sticky nav expects */
    .fixed-header h1.hdr-h1-me { line-height: 0; }
    .fixed-header .hdr-me { display: flex; align-items: center; gap: 8px; min-width: 0; max-width: 100%; padding: 3px 12px 3px 3px;
        border-radius: 24px; background: rgba(255,255,255,0.16); color: #fff; text-decoration: none; }
    .fixed-header .hdr-me:active { background: rgba(255,255,255,0.28); }
    .fixed-header .hdr-me img.profile-pic, .fixed-header .hdr-me .placeholder-pic { width: 30px; height: 30px; flex: none; object-fit: cover; box-sizing: border-box; }
    .fixed-header .hdr-me-t { display: flex; flex-direction: column; min-width: 0; line-height: 1.15; }
    .fixed-header .hdr-me-t b { font-size: 0.95em; font-weight: 700; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
    .fixed-header .hdr-me-t small { font-size: 0.72em; opacity: 0.92; white-space: nowrap; }
    .fixed-header .user-info { flex: none; }    .bottom-nav {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        display: flex;
        justify-content: space-around;
        /* 10px was ~64px total height — taller than the platform norm.
           The labels and icons now match the top nav; every link keeps a
           48px minimum height so budget-phone taps stay accurate. */
        padding: 0; /* the links carry the padding, so the whole bar stays tappable */
        z-index: 1000;
    }
    .bottom-nav a {
        color: #3498db;
        text-decoration: none;
        font-size: 0.7em; /* same as .top-nav .nav-item */
        line-height: 1.25;
        padding: 8px 2px;
        min-height: 48px;
        box-sizing: border-box;
        text-align: center;
        flex: 1;
        transition: transform 0.2s;
        position: relative;
    }    .bottom-nav i {
        font-size: 1.3em;
        margin-bottom: 2px;
    }
    .bottom-nav .badge {
        position: absolute;
        
        background-color: #e74c3c;
        color: white;
        
    }
    .bottom-nav .update-indicator {
        position: absolute;
        
        
        background-color: #e74c3c;
        border-radius: 50%;
    }
    .bottom-nav .badge {
        top: 3px;
        right: auto;
        left: 50%;
        margin-left: 4px;
        box-sizing: border-box;
        min-width: 15px;
        height: 15px;
        line-height: 15px;
        padding: 0 4px;
        border-radius: 9px;
        font-size: 9px;
        font-weight: 700;
        text-align: center;
        white-space: nowrap;
    }
    .bottom-nav .update-indicator {
        top: 4px;
        right: auto;
        left: 50%;
        margin-left: 5px;
        width: 8px;
        height: 8px;
        padding: 0;
    }    h2 {
        color: #34495e;
        text-align: center;
    }        .top-nav .nav-items {
            display: flex;
            /* ONE ROW ON EVERY PHONE. This used to wrap — better than the old
               scroller that HID items, but it meant a Poco showed a different
               layout from a Galaxy, and members compare screens. Items now
               share the row equally and the LABELS shrink on narrow screens
               instead of the fourth item dropping to a second line. */
            flex-wrap: nowrap;
            justify-content: center;
            gap: 2px;
        }
        /* The badge hangs off the icon, not the label. `top:-5px` on an
           inline-block whose parent is display:block put it over the word
           "Chat" — the icon is 1.3em tall and the wrap was collapsing to the
           text baseline. Give the wrap the icon's own line box and pin the
           badge to its corner. */
        .nav-ico-wrap {
            position: relative;
            width: 100%;
        }
        .nav-ico-wrap i {
            display: inline-block !important;
            margin-bottom: 0 !important;
        }
        .nav-dot {
            position: absolute;
            top: 0;
            left: 50%;
            margin-left: 6px;
            width: 9px;
            height: 9px;
            border-radius: 50%;
            background: #e0332b;
            box-shadow: 0 0 0 2px #fff;
        }        .top-nav .nav-item {
            /* This must RESET, not merely add. An older `.nav-item` rule below
               paints a blue gradient pill; overriding only `color` left blue
               text on a blue pill — invisible. Every property that rule sets
               is undone here. */
            display: block;
            /* flex-basis 0 (not auto): every item gets an EQUAL share of the
               row regardless of label length, and min-width 0 lets flexbox
               actually shrink them — a min-width in pixels is why the row
               used to overflow and wrap on narrow phones. */
            
            max-width: 132px;
            text-align: center;
            padding: 7px 4px;
            background: none;
            background-image: none;
            box-shadow: none;
            border-radius: 10px;
            color: #3498db;
            text-decoration: none;
            font-size: 0.7em;
            font-weight: 600;
            transition: background 0.15s;
        }
        .top-nav .nav-item span {
            white-space: nowrap;
        }
        /* 2026-11-10: on a Poco (larger system text) "Prayer Wall" ran into
           "Devotions". Equal-width cells cannot hold a long label once the
           phone enlarges text, and nowrap let it spill into its neighbour.
           Now each item takes the room its label needs, and a two-word label
           ("Prayer Wall", "Video Feed", "Mur de prière") may go onto two
           short lines. A label can never cross into the next item. */
        .top-nav .nav-items { align-items: flex-start; }
        .top-nav .nav-item { flex: 1 1 auto; min-width: auto; }
        .top-nav .nav-item > span:not(.nav-ico-wrap) {
            display: block;
            white-space: normal;
            line-height: 1.15;
            overflow-wrap: normal;
            /* very large phone text: the label stops growing at about 3% of
               the screen width, so all six items still fit on one row */
            font-size: min(1em, 3vw);
        }
        /* Every icon sits in the SAME box, whether it carries a badge (Chat,
           News) or not, so all six labels start on the same line. */
        .top-nav .nav-item > i,
        .top-nav .nav-ico-wrap {
            display: block;
            font-size: min(1.3em, 5vw) !important;   /* beats the older .top-nav .nav-item i rule below */
            height: 1.5em;
            line-height: 1.5em;
            margin: 0 0 3px;
        }
        .top-nav .nav-ico-wrap i { font-size: 1em !important; line-height: 1.5em !important; }
        /* Narrow phones and large system fonts: smaller labels, tighter
           padding — four items still read fine, and "Video Feed" stays on
           the same row as everything else. French labels ("Mur de prière")
           are the longest; sized against those, not the English. */
        @media (max-width: 430px) {
            .top-nav .nav-item { font-size: 0.62em; padding: 7px 1px; }
            .bottom-nav a { font-size: 0.62em; }
        }
        .top-nav .nav-item i {
            display: block;
            font-size: 1.3em;
            margin-bottom: 3px;
        }
        .top-nav .nav-item:hover,
        .top-nav .nav-item:focus {
            background: #eef6fc;
            background-image: none;
            transform: none;
            box-shadow: none;
            color: #2b83c2;
        }
        .top-nav .nav-item.active {
            background: #eef6fc;
            color: #2c3e50;
            font-weight: 700;
        }        /* guide 2026-07-25 */
        .hdr-guide-btn {
            position: relative; display: inline-flex; align-items: center; gap: 6px;
            background: rgba(255,255,255,0.16); color: #fff; text-decoration: none;
            font-size: 0.78em; font-weight: 600; padding: 5px 11px; border-radius: 999px;
            white-space: nowrap; flex-shrink: 0;
        }
        .hdr-guide-btn:active { background: rgba(255,255,255,0.28); }
        .hdr-guide-btn .guide-dot {
            position: absolute; top: -2px; right: -2px; width: 8px; height: 8px;
            border-radius: 50%; background: #f39c12; display: none;
        }
        .hdr-guide-btn .guide-dot.on { display: block; }        @keyframes avpulse {
            0%   { transform: scale(0.9); opacity: 0; }
            40%  { opacity: 1; }
            100% { transform: scale(1.35); opacity: 0; }
        }    .nav-items {
        padding: 0 12px;
    }
    .nav-item {
        align-items: center;
        gap: 8px;
    }
    .nav-item:hover {
        background: linear-gradient(135deg, #2c3e50, #34495e);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    }
    .nav-item:active {
        transform: scale(0.95);
    }
    .nav-item.active {
        background: linear-gradient(135deg, #2c3e50, #34495e);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    }    /* feed-follow 2026-08-10.
       Deliberately NOT a solid blue button. Twenty cards would mean twenty
       blue buttons competing with the prayers themselves, and blue is the
       primary-action colour everywhere else on the site. A quiet outline
       that sits in the header's empty right-hand corner reads as an offer,
       not an instruction. It disappears the moment it is used. */
    .feed-follow-btn {
        margin-left: auto;
        flex-shrink: 0;
        align-self: center;
        border: 1px solid #bcd2e2;
        font-weight: 600;
        line-height: 1;
        padding: 8px 12px;
        border-radius: 999px;
        cursor: pointer;
        white-space: nowrap;
        transition: background 0.15s, color 0.15s, opacity 0.25s;
        -webkit-tap-highlight-color: transparent;
    }
    .feed-follow-btn:active { background: #eaf4fb; }
    .feed-follow-btn[disabled] { opacity: 0.55; }
    .feed-follow-btn.is-done {
        border-color: #cfe3d2;
        color: #4c8a5b;
        opacity: 0;
        pointer-events: none;
    }    /* feed-follow 2026-08-11 - HEADER OVERFLOW FIX.
       Adding the Follow button took ~110px out of a header that had never had
       to share. The name column is an unclassed <div> holding two inline
       spans, so with a long username the timestamp simply wrapped and
       "38min ago" broke across two lines.
       The column is now a flex row that is allowed to SHRINK (min-width:0 -
       without it a flex item refuses to go below its content width, which is
       the whole reason the wrap happened). The username takes the squeeze and
       ellipsises; the timestamp never wraps. */
    .post-header > div {
        flex: 1 1 auto;
        min-width: 0;
        display: flex;
        /* 2026-08-11: the column GROWS to fill the header, so once a username
           is long enough to ellipsise, the timestamp lands hard against the
           Follow button. The gap belongs here rather than on the button,
           because margin-left:auto on the button cannot also carry a gap, and
           this way the spacing is identical whether or not a button is drawn. */
    }
    .post-header > div > .username {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    .post-header > div > .timestamp {
        flex: 0 0 auto;
        white-space: nowrap;
        margin-left: 0;   /* the gap above replaces it */
    }    @keyframes fadeInParagraph {
        from {
            opacity: 0.8;
        }
        to {
            opacity: 1;
        }
    }  /* Image Carousel Styles */
.image-carousel {
    position: relative;
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    margin: 12px 0;
}

.carousel-container {
    position: relative;
    width: 100%;
    /* ig-carousel 2026-08-01: fallback shape only. The real frame is set
       by JS from the FIRST slide's true proportions, clamped between
       1.91:1 and 4:5 like Instagram, so square prayer cards get a square
       frame and display whole. */
    aspect-ratio: 1 / 1;
    overflow: hidden;
}
.carousel-slide {
    min-width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #ffffff;
}

.carousel-slide img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    cursor: pointer;
    position: relative;
    z-index: 1;
}

/* ig-carousel 2026-08-01: each slide is measured against the frame. A
   near-match (within 10%) fills it edge to edge; anything further off is
   shown WHOLE on a blurred copy of itself - no white bars and no content
   ever cropped away. !important so no shared stylesheet can reintroduce
   the old crop. */
.image-carousel .carousel-slide.fit-cover img {
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: cover !important;
}
.image-carousel .carousel-slide.fit-blur img {
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
}
.carousel-slide .slide-blur {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: blur(24px);
    transform: scale(1.18);
}

/* ig-carousel 2026-08-01: on touch screens the swipe IS the navigation,
   so the arrows are gone entirely and never sit on the prayer text; with
   a mouse, small translucent chevrons appear on hover, the way
   Instagram's website does it. */
.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.35);
    color: #fff;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    opacity: 0;
    transition: opacity 0.2s ease, background 0.2s ease;
}

.carousel-container:hover .carousel-nav {
    opacity: 1;
}

.carousel-nav:hover {
    background: rgba(0, 0, 0, 0.6);
}

@media (hover: none), (pointer: coarse) {
    .carousel-nav { display: none !important; }
}/* ig-carousel 2026-08-01: the dots moved OFF the media onto the card
   below it, Instagram-style - uniform size, blue when active, and past
   seven slides the strip compresses with shrunken edge dots. */
.carousel-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    padding: 8px 0 2px;
}

.carousel-dots .cdot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #c9ced6;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}

.carousel-dots .cdot.active {
    background: #3498db;
}

.carousel-dots .cdot.cdot-sm {
    transform: scale(0.55);
}

/* ig-carousel 2026-08-01: "3/9" appears top-right when the member
   changes slide, then fades away after two seconds. */
.image-counter {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.8em;
    z-index: 2;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.image-counter.show {
    opacity: 1;
}

/* Single Image Styles */
.single-image-container {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
}    .play-button-wrapper {
        position: relative;
        width: 90px;
        height: 90px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .play-button-ring {
        position: absolute;
        width: 100%;
        height: 100%;
        border: 3px solid rgba(255, 255, 255, 0.3);
        border-radius: 50%;
        animation: ringPulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    }
    .play-button-ring::before {
        content: '';
        position: absolute;
        inset: -10px;
        border: 2px solid rgba(255, 255, 255, 0.1);
        border-radius: 50%;
        animation: ringExpand 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    }
    @keyframes ringPulse {
        0%, 100% { 
            transform: scale(1); 
            opacity: 1;
        }
        50% { 
            transform: scale(1.05); 
            opacity: 0.8;
        }
    }
    @keyframes ringExpand {
        0%, 100% { 
            transform: scale(1); 
            opacity: 0;
        }
        50% { 
            transform: scale(1.2); 
            opacity: 1;
        }
    }
    
    /* Infinite Scroll Specific Styles */
    .infinite-scroll-loader {
        display: none;
        text-align: center;
        padding: 30px 20px;
        margin: 20px 0;
    }
    
    .infinite-scroll-loader.active {
        display: block;
    }
    
    .scroll-spinner {
        display: inline-block;
        width: 40px;
        height: 40px;
        border: 4px solid #f3f3f3;
        border-top: 4px solid #3498db;
        border-radius: 50%;
        animation: spin 1s linear infinite;
    }
    
    @keyframes spin {
        0% { transform: rotate(0deg); }
        100% { transform: rotate(360deg); }
    }
    
    .infinite-scroll-end {
        display: none;
        text-align: center;
        padding: 30px 20px;
        margin: 20px 0;
        color: #7f8c8d;
        font-size: 0.95em;
    }
    
    .infinite-scroll-end.active {
        display: block;
    }
    
    .infinite-scroll-error {
        display: none;
        text-align: center;
        padding: 20px;
        margin: 20px;
        background: #fff3cd;
        border: 1px solid #ffc107;
        border-radius: 8px;
        color: #856404;
    }
    
    .infinite-scroll-error.active {
        display: block;
    }
    
    .retry-button {
        background: #3498db;
        color: white;
        border: none;
        padding: 10px 20px;
        border-radius: 20px;
        cursor: pointer;
        margin-top: 10px;
        font-size: 0.9em;
        transition: background 0.2s;
    }
    
    .retry-button:hover {
        background: #2980b9;
    }
    
    .scroll-to-top {
        position: fixed;
        bottom: 100px;
        right: 20px;
        background: linear-gradient(135deg, #3498db, #2980b9);
        color: white;
        width: 50px;
        height: 50px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
        z-index: 900;
    }
    
    .scroll-to-top.visible {
        opacity: 1;
        visibility: visible;
    }
    
    .scroll-to-top:hover {
        transform: scale(1.1);
        box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
    }
    
    .new-posts-indicator {
        position: fixed;
        top: 70px;
        left: 50%;
        transform: translateX(-50%);
        background: linear-gradient(135deg, #27ae60, #2ecc71);
        color: white;
        padding: 12px 24px;
        border-radius: 25px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
        cursor: pointer;
        z-index: 1000;
        display: none;
        animation: slideDown 0.5s ease;
    }
    
    @keyframes slideDown {
        from {
            transform: translateX(-50%) translateY(-100px);
            opacity: 0;
        }
        to {
            transform: translateX(-50%) translateY(0);
            opacity: 1;
        }
    }
    
    .new-posts-indicator:hover {
        transform: translateX(-50%) scale(1.05);
    }    @keyframes glowPulse {
        0%, 100% { 
            transform: scale(1);
            opacity: 0.5;
        }
        50% { 
            transform: scale(1.1);
            opacity: 0.8;
        }
    }    .video-container.loading .play-button-wrapper {
        opacity: 0.3;
        pointer-events: none;
    }    .video-error {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        color: #e74c3c;
        text-align: center;
        padding: 20px;
        display: none;
    }
    .video-container.error .video-error {
        display: block;
    }
    .video-container.error .video-placeholder,
    .video-container.error .lazy-video {
        display: none;
    }    @keyframes heartBeat {
        0% { transform: scale(1); }
        25% { transform: scale(1.3); }
        50% { transform: scale(1.1); }
        75% { transform: scale(1.2); }
        100% { transform: scale(1); }
    }    .action-btn.edit-btn {
        color: #27ae60;
    }    .action-btn.delete-btn {
        color: #e74c3c;
    }    @keyframes shake {
        0%, 100% { transform: translateX(0); }
        25% { transform: translateX(-3px); }
        75% { transform: translateX(3px); }
    }        @keyframes slideIn {
        from {
            opacity: 0;
            transform: translateY(10px) rotate(180deg);
        }
        to {
            opacity: 1;
            transform: translateY(0) rotate(0);
        }
    }    @keyframes fadeIn {
        from { opacity: 0; transform: translateY(10px); }
        to { opacity: 1; transform: translateY(0); }
    }    .text-fade-overlay {
        position: absolute;
        bottom: 40px;
        left: 0;
        right: 0;
        height: 60px;
        pointer-events: none;
        transition: opacity 0.3s ease;
        background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.95));
    }
    .prayer-content.truncated {
        max-height: 130px;
        position: relative;
        overflow: hidden;
    }    @keyframes expandText {
        from {
            opacity: 0.8;
        }
        to {
            opacity: 1;
        }
    }
    .prayer-content-wrapper.expanded .text-fade-overlay {
        opacity: 0;
        visibility: hidden;
    }
    .view-toggle-btn {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        margin-top: 8px;
        padding: 8px 16px;
        background: linear-gradient(135deg, #f8f9fa, #e9ecef);
        border: 1px solid #dee2e6;
        border-radius: 20px;
        color: #3498db;
        font-size: 0.9em;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.3s ease;
        outline: none;
        position: relative;
        overflow: hidden;
    }    @keyframes fadeInModal {
        from { opacity: 0; }
        to { opacity: 1; }
    }    @keyframes slideUp {
        to { transform: translateY(0); }
    }

    /* Enhanced Comments Modal Styling */
    .comments-modal-content {
        max-height: 80vh;
        overflow: hidden;
        padding: 0;
        position: relative;
        display: flex;
        flex-direction: column;
        background: #ffffff;
    }
    .comments-modal-content h3 {
        background: linear-gradient(135deg, #667eea 0%, #4682b4 100%);
        color: white;
        padding: 20px 24px;
        margin: 0;
        font-size: 1.3em;
        font-weight: 600;
        text-align: center;
        position: sticky;
        top: 0;
        z-index: 100;
        box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
        border-radius: 16px 16px 0 0;
        backdrop-filter: blur(10px);
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
    }
    .comments-modal-content h3::before {
        content: '💬';
        font-size: 1.2em;
        animation: pulse 2s infinite;
    }
    @keyframes pulse {
        0%, 100% { transform: scale(1); opacity: 1; }
        50% { transform: scale(1.1); opacity: 0.8; }
    }

    /* Comments Container with Blue Scrollbar */
    #comments-modal-list {
        flex: 1;
        overflow-y: auto;
        padding: 20px;
        background: linear-gradient(180deg, #f8f9fc 0%, #ffffff 100%);
        position: relative;
        min-height: 200px;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        scrollbar-color: #3498db #e8f4fd;
    }
    #comments-modal-list::-webkit-scrollbar {
        width: 8px;
    }
    #comments-modal-list::-webkit-scrollbar-track {
        background: #e8f4fd;
        border-radius: 10px;
        margin: 10px 0;
    }
    #comments-modal-list::-webkit-scrollbar-thumb {
        background: linear-gradient(180deg, #3498db, #2980b9);
        border-radius: 10px;
        transition: all 0.3s;
    }
    #comments-modal-list::-webkit-scrollbar-thumb:hover {
        background: linear-gradient(180deg, #2980b9, #2c3e50);
        box-shadow: 0 0 10px rgba(52, 152, 219, 0.3);
    }

    /* Enhanced Comment Cards */
    .modal-comment {
        display: flex;
        align-items: flex-start;
        margin: 0 0 16px;
        padding: 16px;
        background: #ffffff;
        border-radius: 16px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
        opacity: 0;
        animation: slideInComment 0.4s ease forwards;
        position: relative;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border: 1px solid rgba(102, 126, 234, 0.1);
    }
    .modal-comment:nth-child(odd) {
        animation-delay: 0.1s;
    }
    .modal-comment:nth-child(even) {
        animation-delay: 0.2s;
        background: linear-gradient(135deg, #ffffff 0%, #f8f9fc 100%);
    }
    @keyframes slideInComment {
        from { 
            opacity: 0; 
            transform: translateY(20px) scale(0.95);
        }
        to { 
            opacity: 1; 
            transform: translateY(0) scale(1);
        }
    }
    .modal-comment:hover {
        transform: translateX(4px);
        box-shadow: 0 4px 16px rgba(102, 126, 234, 0.15);
        border-color: rgba(102, 126, 234, 0.3);
    }
    .modal-comment img.profile-pic {
        width: 44px;
        height: 44px;
        border-radius: 50%;
        border: 2px solid transparent;
        background: linear-gradient(white, white) padding-box,
                    linear-gradient(135deg, #667eea, #4682b4) border-box;
        margin-right: 14px;
        object-fit: cover;
        flex-shrink: 0;
        transition: all 0.3s;
    }
    .modal-comment:hover img.profile-pic {
        transform: scale(1.05);
        box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    }
    .modal-comment .placeholder-pic {
        width: 44px;
        height: 44px;
        border-radius: 50%;
        background: linear-gradient(135deg, #667eea, #4682b4);
        margin-right: 14px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #ffffff;
        font-size: 1em;
        font-weight: 700;
        flex-shrink: 0;
        text-transform: uppercase;
        box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2);
        transition: all 0.3s;
    }
    .modal-comment:hover .placeholder-pic {
        transform: scale(1.05) rotate(5deg);
    }
    .modal-comment p {
        color: #2c3e50;
        font-size: 0.95em;
        margin: 0;
        flex-grow: 1;
        line-height: 1.6;
        word-wrap: break-word;
        padding-right: 8px;
    }
    .modal-comment p strong a {
        background: linear-gradient(135deg, #667eea, #4682b4);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        font-weight: 600;
        font-size: 0.95em;
        text-decoration: none;
        transition: all 0.3s;
        position: relative;
    }
    .modal-comment p strong a::after {
        content: '';
        position: absolute;
        bottom: -2px;
        left: 0;
        width: 0;
        height: 2px;
        background: linear-gradient(135deg, #667eea, #4682b4);
        transition: width 0.3s;
    }
    .modal-comment p strong a:hover::after {
        width: 100%;
    }
    .modal-comment .delete-comment {
        color: #e74c3c;
        font-size: 1.2em;
        cursor: pointer;
        padding: 8px;
        border-radius: 50%;
        transition: all 0.3s;
        flex-shrink: 0;
        margin-left: auto;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        background: rgba(231, 76, 60, 0.1);
    }
    .modal-comment .delete-comment:hover {
        background: rgba(231, 76, 60, 0.2);
        transform: rotate(90deg) scale(1.1);
        box-shadow: 0 2px 8px rgba(231, 76, 60, 0.3);
    }
    .modal-comment .delete-comment:active {
        transform: rotate(90deg) scale(0.95);
    }

    /* Enhanced Comment Input Form */
    .modal-comment-form {
        display: flex;
        align-items: center;
        gap: 12px;
        position: sticky;
        bottom: 0;
        background: linear-gradient(180deg, rgba(255,255,255,0.95) 0%, #ffffff 100%);
        padding: 16px 20px;
        margin: 0;
        margin-bottom: 0;
        border-top: 1px solid rgba(102, 126, 234, 0.2);
        backdrop-filter: blur(10px);
        box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.08);
        z-index: 50;
    }
    .modal-comment-form input[type="text"] {
        flex: 1;
        padding: 12px 18px;
        border: 2px solid transparent;
        background: linear-gradient(white, white) padding-box,
                    linear-gradient(135deg, #667eea, #764ba2) border-box;
        border-radius: 25px;
        font-size: 0.95em;
        outline: none;
        min-height: 45px;
        background-color: #f8f9fc;
        transition: all 0.3s;
        font-family: inherit;
    }
    .modal-comment-form input[type="text"]:focus {
        background-color: #ffffff;
        box-shadow: 0 4px 16px rgba(102, 126, 234, 0.2);
        transform: translateY(-2px);
    }
    .modal-comment-form input[type="text"]::placeholder {
        color: #95a5a6;
        transition: all 0.3s;
    }
    .modal-comment-form input[type="text"]:focus::placeholder {
        color: #bdc3c7;
        transform: translateX(5px);
    }
    .modal-comment-form input[type="submit"] {
        background: linear-gradient(135deg, #3498db, #2980b9);
        color: white;
        padding: 8px 16px;
        border: none;
        border-radius: 20px;
        cursor: pointer;
        font-size: 0.9em;
        min-height: 25px;
        min-width: 40px;
        max-width: 80px;
        transition: transform 0.2s, background 0.2s;
        box-sizing: border-box;
    }    .modal-comment-form .loading {
        display: none;
        font-size: 0.9em;
        color: #667eea;
        margin-left: 8px;
        flex-shrink: 0;
        animation: fadeInOut 1.5s infinite;
    }
    @keyframes fadeInOut {
        0%, 100% { opacity: 0.3; }
        50% { opacity: 1; }
    }

    /* Exit Button with Proper Separation */
    .comments-modal-content .exit {
        background: linear-gradient(135deg, #ff6b6b, #ee5a24);
        color: white;
        border: none;
        border-radius: 0 0 16px 16px;
        padding: 16px;
        font-size: 1em;
        font-weight: 600;
        cursor: pointer;
        width: 100%;
        margin: 0;
        margin-top: 0;
        transition: all 0.3s;
        box-shadow: 0 -2px 10px rgba(238, 90, 36, 0.2);
        position: relative;
        overflow: hidden;
        text-transform: uppercase;
        letter-spacing: 1px;
        border-top: 2px solid rgba(238, 90, 36, 0.3);
        flex-shrink: 0;
    }
    .comments-modal-content .exit::before {
        content: '×';
        position: absolute;
        right: 20px;
        top: 50%;
        transform: translateY(-50%);
        font-size: 1.5em;
        opacity: 0.7;
        transition: all 0.3s;
    }
    .comments-modal-content .exit:hover {
        background: linear-gradient(135deg, #ff5252, #ff6348);
        box-shadow: 0 -4px 16px rgba(238, 90, 36, 0.3);
        letter-spacing: 2px;
    }
    .comments-modal-content .exit:hover::before {
        opacity: 1;
        transform: translateY(-50%) rotate(90deg);
    }
    .comments-modal-content .exit:active {
        transform: scale(0.98);
    }    @keyframes fadeInAlert {
        from { opacity: 0; }
        to { opacity: 1; }
    }    @keyframes slideUpAlert {
        to { transform: translateY(0); }
    }/* Hidden from the eye, kept for screen readers. */
.feed-container > h2 { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }#posts-container .post-header > div { flex-direction: column; align-items: flex-start; gap: 1px; margin-right: 10px; }
#posts-container .post-header > div > .username { max-width: 100%; font-size: 15.5px; font-weight: 700; }
#posts-container .post-header > div > .timestamp { font-size: 12.5px; color: #5d7485; }/* A preview ends in three dots on its last line, with no fade (Nick's choice). */
#posts-container .text-fade-overlay { background: none !important; }    /* App Install Modal */
    .app-install-modal {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(6px);
        z-index: 10000;
        display: none;
        align-items: center;
        justify-content: center;
        padding: 20px;
        box-sizing: border-box;
        animation: fadeInModal 0.3s ease-out;
    }
    .app-install-modal.show {
        display: flex;
    }
    .app-install-modal-content {
        background: white;
        border-radius: 16px;
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
        width: 100%;
        max-width: 400px;
        text-align: center;
        transform: scale(0.9) translateY(30px);
        animation: slideUpScale 0.3s ease-out forwards;
        overflow: hidden;
    }
    @keyframes slideUpScale {
        to {
            transform: scale(1) translateY(0);
        }
    }
    .app-install-header {
        background: linear-gradient(135deg, #833ab4, #fd1d1d, #fcb045);
        color: white;
        padding: 24px 20px 20px;
        position: relative;
    }
    .app-install-header .close-btn {
        position: absolute;
        top: 12px;
        right: 12px;
        background: rgba(255, 255, 255, 0.2);
        border: none;
        color: white;
        font-size: 1.2em;
        cursor: pointer;
        padding: 8px;
        border-radius: 50%;
        width: 32px;
        height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
        opacity: 0.9;
        transition: all 0.2s;
    }
    .app-install-header .close-btn:hover {
        opacity: 1;
        background: rgba(255, 255, 255, 0.3);
    }
    .app-install-header .app-icon {
        width: 80px;
        height: 80px;
        border-radius: 16px;
        background: white;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 2.5em;
        color: #833ab4;
        font-weight: bold;
        margin: 0 auto 16px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    }
    .app-install-header h3 {
        margin: 0 0 8px;
        font-size: 1.4em;
        font-weight: 600;
        color: white;
    }
    .app-install-header p {
        margin: 0;
        font-size: 1em;
        opacity: 0.9;
        line-height: 1.4;
    }
    .app-install-body {
        padding: 24px 20px;
    }
    .app-install-features {
        text-align: left;
        margin: 16px 0 24px;
    }
    .app-install-features ul {
        list-style: none;
        padding: 0;
        margin: 0;
    }
    .app-install-features li {
        display: flex;
        align-items: center;
        margin: 12px 0;
        font-size: 0.95em;
        color: #262626;
    }
    .app-install-features li::before {
        content: "✓";
        color: #27ae60;
        font-weight: bold;
        font-size: 1.1em;
        margin-right: 12px;
        flex-shrink: 0;
    }
    .app-install-actions {
        display: flex;
        flex-direction: column;
        gap: 12px;
        margin-top: 20px;
    }
    .app-install-btn {
        background: linear-gradient(135deg, #833ab4, #fd1d1d);
        color: white;
        border: none;
        padding: 16px 24px;
        border-radius: 12px;
        font-size: 1em;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.2s;
        box-shadow: 0 4px 12px rgba(131, 58, 180, 0.3);
    }
    .app-install-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 20px rgba(131, 58, 180, 0.4);
    }
    .app-install-btn:active {
        transform: translateY(0);
    }
    .app-install-later {
        background: none;
        border: 1px solid #dbdbdb;
        color: #737373;
        padding: 12px 24px;
        border-radius: 8px;
        font-size: 0.95em;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s;
    }
    .app-install-later:hover {
        background: #f8f9fa;
        color: #262626;
    }

    /* Community Engagement Modal */
    .community-engagement-modal {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.65);
        backdrop-filter: blur(8px);
        z-index: 15000;
        display: none;
        align-items: center;
        justify-content: center;
        padding: 20px;
        box-sizing: border-box;
        animation: fadeInEngagement 0.4s ease-out;
    }
    @keyframes fadeInEngagement {
        from { opacity: 0; }
        to { opacity: 1; }
    }
    .community-engagement-modal.show {
        display: flex;
    }
    .community-engagement-modal-content {
        background: white;
        border-radius: 20px;
        box-shadow: 0 25px 50px rgba(0, 0, 0, 0.35);
        width: 100%;
        max-width: 420px;
        text-align: center;
        transform: scale(0.9) translateY(30px);
        animation: slideUpEngagement 0.4s ease-out forwards;
        overflow: hidden;
        border: 2px solid #e8e8e8;
    }
    @keyframes slideUpEngagement {
        to {
            transform: scale(1) translateY(0);
        }
    }
    .community-engagement-header {
        background: linear-gradient(135deg, #3498db 0%, #2c3e50 100%);
        color: white;
        padding: 28px 24px 24px;
        position: relative;
    }
    .community-engagement-header .close-btn {
        position: absolute;
        top: 16px;
        right: 16px;
        background: rgba(255, 255, 255, 0.25);
        border: none;
        color: white;
        font-size: 1.4em;
        cursor: pointer;
        padding: 8px;
        border-radius: 50%;
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        opacity: 0.9;
        transition: all 0.3s ease;
        backdrop-filter: blur(10px);
    }
    .community-engagement-header .close-btn:hover {
        opacity: 1;
        background: rgba(255, 255, 255, 0.35);
        transform: scale(1.1);
    }
    .community-engagement-header .community-icon {
        width: 85px;
        height: 85px;
        border-radius: 20px;
        background: rgba(255, 255, 255, 0.2);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 2.8em;
        color: white;
        margin: 0 auto 20px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
        backdrop-filter: blur(15px);
        border: 2px solid rgba(255, 255, 255, 0.3);
    }
    .community-engagement-header h3 {
        margin: 0 0 10px;
        font-size: 1.5em;
        font-weight: 700;
        color: white;
        text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    }
    .community-engagement-header p {
        margin: 0;
        font-size: 1.05em;
        opacity: 0.95;
        line-height: 1.5;
        font-weight: 400;
    }
    .community-engagement-body {
        padding: 28px 24px;
    }
    .engagement-stats {
        display: flex;
        flex-direction: column;
        gap: 16px;
        margin-bottom: 24px;
        text-align: left;
    }
    .stat-item {
        display: flex;
        align-items: center;
        font-size: 0.95em;
        color: #2c3e50;
        padding: 12px 16px;
        background: #f4f7fa;
        border-radius: 12px;
        border-left: 4px solid #3498db;
        transition: all 0.3s ease;
    }
    .stat-item:hover {
        background: #e8f4fd;
        transform: translateX(4px);
    }
    .stat-item i {
        color: #3498db;
        font-size: 1.2em;
        margin-right: 14px;
        flex-shrink: 0;
        width: 20px;
        text-align: center;
    }
    .engagement-message {
        background: linear-gradient(135deg, #f4f7fa, #e8f4fd);
        border-radius: 15px;
        padding: 20px;
        margin: 20px 0 28px;
        border: 1px solid #bdc3c7;
    }
    .engagement-message p {
        margin: 0;
        color: #2c3e50;
        font-size: 0.95em;
        line-height: 1.6;
    }
    .engagement-message strong {
        color: #3498db;
        font-weight: 600;
    }
    .engagement-actions {
        display: flex;
        flex-direction: column;
        gap: 14px;
        margin-bottom: 24px;
    }
    .engagement-btn {
        background: linear-gradient(135deg, #3498db, #2c3e50);
        color: white;
        border: none;
        padding: 16px 24px;
        border-radius: 14px;
        font-size: 1em;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.3s ease;
        box-shadow: 0 6px 20px rgba(52, 152, 219, 0.25);
        text-decoration: none;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 10px;
        position: relative;
        overflow: hidden;
    }
    .engagement-btn::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
        transition: left 0.5s;
    }
    .engagement-btn:hover::before {
        left: 100%;
    }
    .engagement-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 25px rgba(52, 152, 219, 0.35);
        background: linear-gradient(135deg, #2980b9, #34495e);
    }
    .engagement-btn:active {
        transform: translateY(0);
    }
    .engagement-btn.secondary {
        background: linear-gradient(135deg, #27ae60, #2c5b2d);
        box-shadow: 0 6px 20px rgba(39, 174, 96, 0.25);
    }
    .engagement-btn.secondary:hover {
        box-shadow: 0 10px 25px rgba(39, 174, 96, 0.35);
        background: linear-gradient(135deg, #229954, #34495e);
    }
    .engagement-btn i {
        font-size: 1.1em;
    }
    .engagement-footer {
        padding-top: 16px;
        border-top: 1px solid #bdc3c7;
    }
    .engagement-later {
        background: none;
        border: none;
        color: #7f8c8d;
        padding: 14px 28px;
        border-radius: 10px;
        font-size: 0.9em;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.3s ease;
        width: 100%;
    }
    .engagement-later:hover {
        background: #f4f7fa;
        color: #34495e;
    }

    /* Mobile Responsive Styles */
    @media (max-width: 600px) {        .text-fade-overlay {
            height: 50px;
            bottom: 35px;
        }        /* Modal adjustments continue... */
    }

/* ---- index.php, block from line 4706 ---- */
              .pc-card { display: block; margin-bottom: 16px; padding: 14px 16px; border-radius: 16px; text-decoration: none; color: #2c3e50;
                         background: linear-gradient(168deg, #ffffff 0%, #f5f9fd 100%);
                         box-shadow: inset 0 1px 0 #ffffff, 0 1px 1px rgba(23,43,77,.09), 0 3px 9px rgba(23,43,77,.11); }
              .pc-card b { display: flex; align-items: center; gap: 8px; font-size: 0.98em; }
              .pc-card b i { color: #e67e22; }
              .pc-card p { margin: 6px 0 8px; color: #5d7485; font-size: 0.86em; }
              .pc-card .pc-list { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
              .pc-card .pc-list span { padding: 4px 10px; border-radius: 12px; background: #fdf0e3; color: #8a4b0f; font-size: 0.82em; font-weight: 600; }
              .pc-card .pc-go { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 16px; border-radius: 21px; background: #2c7cb8; color: #fff; font-size: 0.9em; font-weight: 600; }
            

/* ---- index.php, block from line 4717 ---- */
              .pc-card .pc-sec { display: block; margin: -14px -16px 12px; padding: 14px 16px; border-radius: 16px 16px 0 0; background: #fdecea; text-decoration: none; color: #2c3e50; }
              .pc-card .pc-sec:only-child { margin-bottom: -14px; border-radius: 16px; }
              .pc-card .pc-sec b i { color: #c0392b; }
              .pc-card .pc-sec p { color: #a93226; }
              .pc-card .pc-sec .pc-list span { background: #f9d0cb; color: #922b21; }
              .pc-card .pc-sec .pc-go { background: #c0392b; }
              .pc-card a.pc-rest { display: block; text-decoration: none; color: inherit; }
              .pc-card .pc-app { margin: 0 -16px 12px; padding: 0 16px 12px; border-bottom: 1px solid #f3d6d2; background: #fdecea; }
              .pc-card .pc-sec + .pc-app { margin-top: -12px; }
              .pc-card .pc-app p { margin: 0 0 8px; color: #a93226; font-size: 0.84em; font-weight: 600; }
              .pc-card .pc-app a { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px; border-radius: 20px; background: #fff; color: #c0392b;
                                   border: 1px solid #f1b9b2; text-decoration: none; font-size: 0.86em; font-weight: 700; }
              .pc-card .pc-app:last-child { margin-bottom: -14px; border-radius: 0 0 16px 16px; border-bottom: 0; }
            

/* ---- index.php, block from line 4821 ---- */
              @keyframes lmPulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }
              .lm-dot { width: 10px; height: 10px; border-radius: 50%; background: #e74c3c;
                        flex-shrink: 0; animation: lmPulse 1.6s ease-in-out infinite; }
              /* feed-ceramic 2026-11-05: the same finish as this card on messages.php. */
              .lm-card { display: flex; align-items: center; gap: 12px; min-height: 56px; box-sizing: border-box;
                         background: linear-gradient(168deg, #ffffff 0%, #fdf8f7 100%); border-radius: 16px;
                         box-shadow: inset 0 1px 0 #ffffff, 0 1px 1px rgba(23,43,77,.09), 0 3px 9px rgba(23,43,77,.11);
                         margin-bottom: 16px; padding: 10px 14px; text-decoration: none;
                         color: #2c3e50; cursor: pointer; }
              .lm-card:active { background: #faecea; }
              .lm-card .lm-t { flex: 1; min-width: 0; }
              .lm-card .lm-t b { display: block; font-size: 0.95em; overflow: hidden;
                                 white-space: nowrap; text-overflow: ellipsis; }
              .lm-card .lm-t small { color: #5d7485; font-size: 0.82em; }
              .lm-card .lm-join { color: #2c6f9f; font-weight: 600; font-size: 0.9em; flex-shrink: 0; }
              .lm-rows a { display: flex; align-items: center; gap: 12px; padding: 12px 16px;
                           border-top: 1px solid #efe6e4; text-decoration: none; color: #2c3e50; }.post-content img,
.single-image-container img {
    width: auto !important;
    max-width: 100% !important;
    margin-left: auto;
    margin-right: auto;
    display: block;
    object-fit: contain;
}
/* header on narrow phones (2026-11-17, seen on Nick's Poco): the "me" chip ran under the search button and the
   name kept only four letters. A little space between the two sides, and the buttons a touch tighter below 400px. */
.fixed-header .hdr-left { margin-right: 8px; }
.fixed-header .hdr-me-t small { overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 400px) {
    .fixed-header .hdr-left { gap: 8px; }
    .fixed-header .hdr-me { gap: 6px; padding-right: 10px; }
    .fixed-header .user-info .hdr-search-btn { width: 34px !important; height: 34px !important; margin-right: 5px !important; font-size: 15px !important; }
    .fixed-header .hdr-guide-btn { padding: 5px 9px; gap: 5px; }
    .fixed-header .hdr-menu-btn { padding: 6px 2px 6px 6px; }
}
