/*--------------------------------------------------------------
# Instagram Story Slider Styles v1.3.0
--------------------------------------------------------------*/

/* Container for the slider */
.iss-container {
    width: 100%;
    /* --- Updated Vertical Padding --- */
    padding: 3px 0; /* 3px top/bottom padding, 0px left/right padding */
    /* --- End Updated Vertical Padding --- */
    box-sizing: border-box;
    overflow: hidden; /* Hide scrollbar from the container itself */
    position: relative;
}

/* Add specific class for auto-displayed sliders if needed for targeting */
.iss-container.iss-auto-displayed {
    /* Add specific styles for auto-displayed sliders if necessary */
    /* Example: margin-bottom: 10px; */ /* Adjust margin if needed */
}

/* The actual slider element that scrolls horizontally */
.iss-slider {
    display: flex; /* Layout items in a row */
    overflow-x: auto; /* Enable horizontal scrolling */
    overflow-y: hidden; /* Hide vertical scrollbar */
    padding: 5px 10px; /* Internal padding for scroll area (keeps space for items) */
    gap: 15px; /* Space between each story item */
    scroll-snap-type: x mandatory; /* Enable snapping for smoother scrolling */
    -webkit-overflow-scrolling: touch; /* Improve scrolling feel on iOS */
    scrollbar-width: none; /* Hide scrollbar for Firefox */
}

/* Hide scrollbar for WebKit browsers (Chrome, Safari, Opera) */
.iss-slider::-webkit-scrollbar {
    display: none;
}

/* Individual story item wrapper */
.iss-story-item {
    flex: 0 0 auto; /* Prevent items from stretching or shrinking */
    text-align: center; /* Center the text below the thumbnail */
    scroll-snap-align: start; /* Align items to the start when snapping */
    width: 80px; /* Define the width of each story item */
}

/* The link element wrapping the thumbnail and text */
.iss-story-link {
    display: flex;
    flex-direction: column; /* Stack thumbnail and text vertically */
    align-items: center; /* Center content horizontally */
    text-decoration: none; /* Remove link underline */
    color: #333; /* Default text color */
    transition: transform 0.2s ease-in-out; /* Add subtle hover effect */
}

/* Slightly scale up the item on hover for visual feedback */
.iss-story-link:hover {
    transform: scale(1.05);
}

/* Circular thumbnail container */
.iss-story-thumbnail {
    width: 66px; /* Diameter of the circle */
    height: 66px;
    border-radius: 50%; /* Make it perfectly round */
    overflow: hidden; /* Clip the image inside */
    border: 2px solid transparent; /* Transparent border to reserve space */
    /* Instagram-style gradient border */
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    padding: 3px; /* Space between the gradient border and the image */
    box-sizing: border-box; /* Include padding and border in element's total width/height */
    display: flex; /* Use flexbox to center the image */
    justify-content: center;
    align-items: center;
}

/* The actual image element */
.iss-story-thumbnail img {
    display: block; /* Remove extra space below image */
    width: 100%;
    height: 100%;
    object-fit: cover; /* Scale image to cover the container, cropping if necessary */
    border-radius: 50%; /* Ensure the image itself is clipped to a circle */
    border: 1px solid #fff; /* Optional: Add a thin white border inside the gradient */
}

/* Text below the thumbnail (displays category) */
.iss-story-title {
    font-size: 12px; /* Adjust font size as needed */
    line-height: 1.3; /* Adjust line height for readability */
    margin-top: 6px; /* Space between thumbnail and text */
    color: #555; /* Text color */
    overflow: hidden; /* Prevent text from overflowing */
    text-overflow: ellipsis; /* Add '...' if text is too long */
    white-space: nowrap; /* Keep text on a single line */
    max-width: 100%; /* Ensure text doesn't exceed the item width */
}

/*--------------------------------------------------------------
# Responsive Adjustments
--------------------------------------------------------------*/
/* Styles for tablet-sized screens and below */
@media (max-width: 768px) {
    .iss-story-item {
        width: 70px; /* Slightly smaller items */
    }
    .iss-story-thumbnail {
        width: 56px;
        height: 56px;
        padding: 3px; /* Keep inner padding consistent */
    }
    .iss-story-title {
        font-size: 11px;
    }
    .iss-slider {
        gap: 12px; /* Slightly reduce gap */
    }
    /* Adjust container padding for smaller screens if needed */
    .iss-container {
         padding: 3px 0; /* Keep vertical padding consistent */
    }
}

/* Styles for mobile-sized screens and below */
@media (max-width: 480px) {
    .iss-story-item {
        width: 65px; /* Further reduce size */
    }
    .iss-story-thumbnail {
        width: 50px;
        height: 50px;
        padding: 3px; /* Keep inner padding consistent */
    }
     .iss-story-title {
        font-size: 10px;
    }
    .iss-slider {
        gap: 10px; /* Further reduce gap */
        padding: 5px; /* Adjust internal slider padding */
    }
     .iss-container {
        padding: 3px 0; /* Keep vertical padding consistent */
    }
}
