/* css/custom-news-style.css */
.custom-news-marquee {
    width: 100%;
    overflow: hidden;
    position: relative;
    background-color: #f4f4f4;
    padding: 65px 0;
    box-shadow: 2px 4px 10px rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

/* Service Filter Section */
.service-filters-container {
    margin-bottom: 20px;
    padding: 0 20px;
}

.service-group {
    margin-bottom: 15px;
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.service-group-title {
    font-weight: bold;
    margin-bottom: 10px;
    color: #0c2961;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.service-group-title::after {
    content: '▼';
    font-size: 12px;
    transition: transform 0.3s ease;
}

.service-group-title.collapsed::after {
    transform: rotate(-90deg);
}

.sub-services {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.sub-service-checkbox {
    display: none;
}

.sub-service-label {
    padding: 8px 15px;
    background-color: #e9ecef;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.sub-service-checkbox:checked + .sub-service-label {
    background-color: #0c2961;
    color: white;
    border-color: #0c2961;
}

.sub-service-label:hover {
    background-color: #d0d7e0;
}

/* Scroll Speed Controls */
.marquee-controls {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 10px;
}

.scroll-speed-toggle {
    padding: 8px 12px;
    border: none;
    background-color: #0c2961;
    color: white;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
}

.scroll-speed-slider-container {
    display: none;
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    position: absolute;
    top: 40px;
    right: 0;
    min-width: 200px;
    z-index: 100;
}

.scroll-speed-slider-container.show {
    display: block;
}

.speed-slider {
    width: 100%;
    margin: 10px 0;
}

.speed-value {
    text-align: center;
    font-size: 14px;
    color: #333;
    margin-top: 5px;
}

.pagination-controls {
    padding: 0 30px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
    margin-top: 20px;
}

#article-range {
    font-size: 14px;
    color: #7c7c7c;
    margin-right: 10px;
    align-self: center;
}

#more-news, #prev-news {
    padding: 12px 20px;
    border: none;
    background-color: #0c2961;
    box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 2px, rgba(0, 0, 0, 0.09) 0px 4px 2px, rgba(0, 0, 0, 0.09) 0px 8px 4px, rgba(0, 0, 0, 0.09) 0px 16px 8px, rgba(0, 0, 0, 0.09) 0px 32px 16px;
    color: white;
    font-size: 14px;
    cursor: pointer;
    border-radius: 5px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
}

.scroll-speed-toggle:hover, #more-news:hover, #prev-news:hover {
    background-color: #2b4478;
}

.marquee-content {
    display: flex;
    gap: 30px;
    animation: marquee 60s linear infinite;
}

@keyframes marquee {
    0% { transform: translateX(50%); }
    50% { transform: translateX(-110%); }
    100% { transform: translateX(-365%); }
}

.news-article {
    width: 250px;
    padding: 15px;
    box-shadow: rgba(0, 0, 0, 0.09) 0px 2px 1px, rgba(0, 0, 0, 0.09) 0px 4px 2px, rgba(0, 0, 0, 0.09) 0px 8px 4px, rgba(0, 0, 0, 0.09) 0px 16px 8px, rgba(0, 0, 0, 0.09) 0px 32px 16px;
    border-radius: 10px;
    background-color: #f3f7ff;
    margin-bottom: 25px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.news-article img {
    width: 200px;
    height: 200px;
    object-fit: cover;
    border-radius: 5px;
    margin-bottom: 15px;
}

.news-article #news-article-h6 {
    font-size: 16px;
    margin: 10px 0;
    text-align: center;
    line-height: 1.4em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.news-article p {
    font-size: 14px;
    color: #646464;
    margin: 15px 0;
    text-align: center;
}

.news-article #article_a {
    padding: 8px 15px;
    background-color: #0c2961;
    box-shadow: 0 0 7px rgba(0, 0, 0, 0.8);
    color: #fff;
    text-align: center;
    text-decoration: none; 
    border-radius: 5px;
    width: 100%;
    margin-top: auto;
}

.news-article #article_a:hover {
    background-color: #3a5385;
}

.saved-articles-container {
    display: none;
    margin-left: 20px;
    margin-right: 20px;
    margin-top: 30px;
    padding: 20px;
    background-color: #d8d8d8;
    border: 1px solid #ccc;
    border-radius: 10px;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 2px 4px;
}

.saved-articles-container #saved-article-h2 {
    text-align: center;
    font-weight: 300;
    font-size: 18px;
}

.saved-articles-container p {
    display: none;
}

.saved-articles-content {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin: 10px;
}

.saved-articles-content .news-article {
    width: 240px;
}

.saved-articles-content img {
    height: 100px;
}

#save-articles-btn {
    margin-top: 10px;
    padding: 6px;
    font-size: 14px;
    background-color: #9daecefa; 
    border-radius: 3px;
    color: white;
    cursor: pointer;   
}

.saved-articles-content #save-articles-btn {
    display: none;
}  

.delete-article-btn {
    margin-top: 10px;
    padding: 6px;
    padding-top: 8px;
    padding-bottom: 8px;
    font-size: 12px;
    background-color: #ff4444;
    border-radius: 3px;
    color: white;
    cursor: pointer;
}

.delete-article-btn:hover {
    background-color: #cc0000;
}