/* ===== FENIKS CAR DETAILING - STORIES ENGINE ===== */

.live-stories-section {
    padding: 26px 0 22px;
    background: #0d1017;
    border-top: 1px solid rgba(35, 146, 255, 0.15);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    position: relative;
    overflow: hidden;
}

.stories-bar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 12px;
}

.stories-tag-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(35, 146, 255, 0.12);
    border: 1px solid rgba(35, 146, 255, 0.3);
    color: #38bdf8;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    padding: 5px 12px;
    border-radius: 20px;
}

.stories-tag-icon {
    display: inline-flex;
    color: #38bdf8;
}

.stories-header-text {
    display: flex;
    align-items: baseline;
    gap: 10px;
    flex-wrap: wrap;
}

.stories-header-title {
    font-family: var(--font-heading, 'Outfit', sans-serif);
    font-size: 1.15rem;
    color: #ffffff;
    font-weight: 700;
    margin: 0;
}

.stories-header-sub {
    font-size: 0.85rem;
    color: #94a3b8;
    margin: 0;
}

.stories-ig-direct-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
    color: #cbd5e1;
    text-decoration: none;
    padding: 6px 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    transition: all 0.2s ease;
}

.stories-ig-direct-link:hover {
    background: rgba(225, 48, 108, 0.15);
    border-color: #e1306c;
    color: #ffffff;
}

/* Stories Carousel Container */
.stories-carousel {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding: 6px 4px 10px;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
}

.stories-carousel::-webkit-scrollbar {
    display: none;
}

/* Single Story Bubble */
.story-circle-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    flex-shrink: 0;
    width: 82px;
    text-align: center;
    background: none;
    border: none;
    padding: 0;
    color: inherit;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    user-select: none;
}

.story-circle-item:hover,
.story-circle-item:focus {
    transform: translateY(-3px);
    outline: none;
}

.story-avatar-wrap {
    position: relative;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    padding: 3px;
    background: linear-gradient(45deg, #00d2ff 0%, #3a7bd5 40%, #e1306c 70%, #f59e0b 100%);
    box-shadow: 0 4px 15px rgba(0, 210, 255, 0.25);
    transition: box-shadow 0.25s ease;
}

.story-circle-item:hover .story-avatar-wrap {
    box-shadow: 0 6px 20px rgba(0, 210, 255, 0.5);
}

.story-avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    background: #000;
    border: 2px solid #0d1017;
    display: block;
}

.story-title {
    font-size: 0.78rem;
    color: #e2e8f0;
    font-weight: 600;
    line-height: 1.25;
    max-width: 82px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ==============================================================================
   FULL-SCREEN INSTAGRAM STORIES MODAL PLAYER
   ============================================================================== */

.story-modal {
    position: fixed;
    inset: 0;
    z-index: 2000000;
    background: rgba(0, 0, 0, 0.94);
    backdrop-filter: blur(14px);
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.story-modal.active {
    display: flex;
    opacity: 1;
}

.story-player-frame {
    position: relative;
    width: 100%;
    max-width: 420px;
    height: 92vh;
    max-height: 820px;
    background: #000000;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9), 0 0 40px rgba(35, 146, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    flex-direction: column;
}

/* Progress Bars */
.story-progress-container {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    gap: 4px;
    z-index: 20;
}

.story-progress-bar {
    flex: 1;
    height: 3px;
    background: rgba(255, 255, 255, 0.35);
    border-radius: 3px;
    overflow: hidden;
}

.story-progress-fill {
    width: 0%;
    height: 100%;
    background: #ffffff;
    border-radius: 3px;
    transition: width 0.05s linear;
}

/* Story Header */
.story-player-header {
    position: absolute;
    top: 24px;
    left: 14px;
    right: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 20;
    background: linear-gradient(180deg, rgba(0,0,0,0.7) 0%, transparent 100%);
    padding-bottom: 10px;
}

.story-header-user {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.story-header-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid #2392ff;
    object-fit: cover;
}

.story-header-info {
    display: flex;
    flex-direction: column;
}

.story-header-name {
    color: #ffffff;
    font-size: 0.88rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
    line-height: 1.2;
}

.story-verified-badge {
    color: #38bdf8;
    display: inline-flex;
}

.story-header-time {
    color: #cbd5e1;
    font-size: 0.72rem;
    line-height: 1.2;
}

.story-header-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.story-icon-btn {
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: background 0.2s, transform 0.2s;
}

.story-icon-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.1);
}

/* ===== Interactive Volume Control Widget ===== */
.story-volume-widget {
    display: inline-flex;
    align-items: center;
    position: relative;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 22px;
    padding: 2px;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.story-volume-widget:hover,
.story-volume-widget.active {
    background: rgba(11, 15, 25, 0.92);
    border-color: rgba(56, 189, 248, 0.5);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.6);
}

.story-volume-widget .story-icon-btn {
    border: none;
    background: transparent;
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    transform: none !important;
}

.story-volume-slider-box {
    display: flex;
    align-items: center;
    gap: 8px;
    max-width: 0;
    opacity: 0;
    overflow: hidden;
    padding-right: 0;
    transition: max-width 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease, padding 0.25s ease;
    pointer-events: none;
}

/* Expanded state on hover or mobile tap */
.story-volume-widget:hover .story-volume-slider-box,
.story-volume-widget.active .story-volume-slider-box {
    max-width: 135px;
    opacity: 1;
    padding-right: 10px;
    pointer-events: auto;
}

/* Range input slider styling */
.story-volume-range {
    -webkit-appearance: none;
    appearance: none;
    width: 72px;
    height: 5px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 5px;
    outline: none;
    cursor: pointer;
    transition: background 0.2s;
    touch-action: manipulation;
}

.story-volume-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 15px;
    height: 15px;
    background: #38bdf8;
    border: 2px solid #ffffff;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 8px rgba(56, 189, 248, 0.85);
    transition: transform 0.15s;
}

.story-volume-range::-webkit-slider-thumb:hover,
.story-volume-range::-webkit-slider-thumb:active {
    transform: scale(1.2);
}

.story-volume-range::-moz-range-thumb {
    width: 15px;
    height: 15px;
    background: #38bdf8;
    border: 2px solid #ffffff;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 8px rgba(56, 189, 248, 0.85);
}

.story-volume-pill-label {
    font-size: 0.72rem;
    font-weight: 700;
    color: #38bdf8;
    min-width: 28px;
    text-align: right;
    font-variant-numeric: tabular-nums;
    user-select: none;
}

/* Floating HUD Notification */
.story-volume-hud {
    position: absolute;
    top: 64px;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    background: rgba(10, 14, 22, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(56, 189, 248, 0.4);
    color: #ffffff;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
    z-index: 40;
    pointer-events: none;
}

.story-volume-hud.visible {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Media Viewport (Image and Video) */
.story-media-viewport {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    user-select: none;
}

.story-media-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.story-media-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

/* Tap Navigation Touch Zones */
.story-tap-zone {
    position: absolute;
    top: 0;
    bottom: 0;
    z-index: 5;
    cursor: pointer;
}

.story-tap-prev {
    left: 0;
    width: 35%;
}

.story-tap-next {
    right: 0;
    width: 65%;
}

/* Left & Right Physical Arrow Buttons */
.story-arrow-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 30;
    transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
    backdrop-filter: blur(8px);
}

.story-arrow-nav:hover {
    background: rgba(35, 146, 255, 0.75);
    border-color: #2392ff;
    transform: translateY(-50%) scale(1.1);
}

.story-arrow-prev {
    left: 12px;
}

.story-arrow-next {
    right: 12px;
}

/* Story Bottom CTA Only (No bulk captions) */
.story-footer-scrim {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 35px 18px 20px;
    background: linear-gradient(0deg, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.5) 70%, transparent 100%);
    z-index: 20;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.story-cta-wa-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #25D366;
    color: #ffffff !important;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 13px 20px;
    border-radius: 50px;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.45);
    transition: transform 0.2s ease, background 0.2s ease;
}

.story-cta-wa-btn:hover {
    background: #20bd5a;
    transform: translateY(-2px);
}

@media (max-width: 480px) {
    .story-player-frame {
        max-width: 100%;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
        border: none;
    }
}
