/*
Theme Name: Kanal Indonesia
Author: RonieMedia
Description: A fast WordPress theme using Bootstrap 5 with modern styling.
Version: 1.1
*/

/* ===== Global Styles ===== */
body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.8;
    color: #222;
    margin: 0;
    padding: 0;
    font-size: clamp(0.9rem, 1vw, 1rem);
    background-color: #f8f9fa;
}

a {
    text-decoration: none;
    color: #e74c3c;
    transition: color 0.3s ease-in-out;
}

a:hover {
    color: #c0392b;
}

h1 { font-size: clamp(2rem, 5vw, 2.5rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2rem); }
h3 { font-size: clamp(1.4rem, 3vw, 1.5rem); }
h4 { font-size: clamp(1.1rem, 2.5vw, 1.25rem); }
h5 { font-size: clamp(1rem, 2vw, 1.1rem); }

h1, h2, h3, h4, h5 {
    font-weight: 600;
    color: #333;
}

/* ===== Navbar ===== */
.custom-navbar {
    background: linear-gradient(90deg, #8B0000 0%, #FF4500 100%);
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.15);
    padding: 6px 0;
}

.navbar-logo {
    width: auto;
    height: auto;
    max-width: 250px;
    margin-right: 10px;
}

.custom-menu .menu-item a {
    color: #ffffff;
    font-weight: 600;
    padding: 6px 12px;
    transition: all 0.3s ease-in-out;
    border-radius: 5px;
    font-size: clamp(0.85rem, 1.5vw, 1rem);
}

.custom-menu .menu-item a:hover {
    color: #FFD700;
}

/* ===== Search Form ===== */
.search-form {
    display: flex;
    align-items: center;
}

.search-input {
    border-radius: 20px;
    padding: 6px 12px;
    border: none;
    font-size: clamp(0.85rem, 1.5vw, 1rem);
}

.search-btn {
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease-in-out;
}

.search-btn:hover {
    background-color: #FFD700;
    color: #8B0000;
}

/* ===== News Carousel ===== */
#newsCarousel {
    margin-bottom: 20px;
}

.carousel-item img {
    border-radius: 10px;
}

.carousel-caption {
    background: rgba(0, 0, 0, 0.6);
    padding: 10px 15px;
    border-radius: 8px;
}

.carousel-caption h5 {
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
}

.carousel-caption h5 a {
    color: #FFD700;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease-in-out;
}

.carousel-caption h5 a:hover {
    color: #FFA500;
}

.carousel-caption p {
    font-size: clamp(0.8rem, 1.5vw, 1rem);
    color: #f0f0f0;
}

/* Responsive untuk perangkat mobile */
@media (max-width: 576px) {
    .carousel-caption h5 {
        font-size: 14px;
    }
    .carousel-caption p {
        font-size: 12px;
    }
}

/* ===== News Section ===== */
.bg-danger {
    background: linear-gradient(90deg, #8B0000 0%, #FF4500 100%) !important;
    color: white;
    font-size: clamp(1rem, 2vw, 1.1rem);
}

.sub-news h6 a {
    color: #333;
    font-weight: 600;
    transition: color 0.3s ease-in-out;
    text-decoration: none;
}

.sub-news h6 a:hover {
    color: #B22222 !important;
}

.sub-news p {
    font-size: clamp(0.85rem, 1.5vw, 1rem);
    color: #777;
}

.sub-news img {
    width: 100%;
    max-width: 269px;
    object-fit: cover;
    border-radius: 5px;
    transition: all 0.3s ease-in-out;
    overflow: hidden;
}

/* Untuk perangkat mobile */
@media (max-width: 767px) {
    .sub-news img {
        max-width: 128px;
        height: 72px;
    }
}

/* Untuk perangkat tablet ke atas */
@media (min-width: 768px) {
    .sub-news img {
        max-width: 269px;
        height: 151px;
    }
}

/* ===== News Items ===== */
.news-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}

.news-item img {
    width: 100%;
    max-width: 250px;
    height: auto;
    object-fit: cover;
    border-radius: 5px;
    transition: all 0.3s ease-in-out;
}

@media (max-width: 767px) {
    .news-item img {
        width: 128px;
        height: 90px;
    }
}

@media (min-width: 768px) {
    .news-item img {
        width: 229px; 
        height: 128px;
    }
}

.news-item .category {
    font-size: clamp(12px, 1.5vw, 14px);
    font-weight: bold;
    color: #940600;
    display: block;
    margin-bottom: 2px;
}

.news-item h6 {
    font-size: clamp(14px, 2vw, 18px);
    font-weight: 600;
    margin: 5px 0;
}

.news-item h6 a {
    color: #212529;
    text-decoration: none;
}

.news-item h6 a:hover {
    color: #dc3545;
}

.news-item small {
    font-size: clamp(12px, 1.5vw, 13px);
    color: #6c757d;
}

/* ===== Ukuran Gambar Carousel ===== */
.carousel-item img {
    width: 100%;
    height: 450px;
    object-fit: cover;
}

@media (max-width: 768px) {
    .carousel-item img {
        height: 250px;
    }
}

/* ===== Carousel Navigation ===== */
.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 50%;
    padding: 10px;
    transition: background-color 0.3s ease-in-out;
}

.carousel-control-prev-icon:hover,
.carousel-control-next-icon:hover {
    background-color: rgba(255, 69, 0, 0.8);
}

.carousel-control-prev,
.carousel-control-next {
    height: 100%;
    top: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== Headline Section ===== */
h3.fw-bold {
    position: relative;
    display: inline-block;
    padding-bottom: 5px;
}

h3.fw-bold span {
    display: block;
    height: 3px;
    background-color: red;
    width: 50px;
    margin-top: 5px;
}

/* ===== Button Styles ===== */
.bg-dark-red {
    background: linear-gradient(90deg, #8B0000 0%, #FF4500 100%) !important;
    color: white !important;
    border: none;
    transition: all 0.3s ease-in-out;
}

.bg-dark-red:hover {
    background: linear-gradient(90deg, #FF4500 0%, #8B0000 100%) !important;
    color: #fff !important;
}

.post-thumbnail-full img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* ===== Share Buttons ===== */
.share-buttons {
    margin-top: 20px;
    text-align: center;
}

.share-buttons h5 {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.share-buttons .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    font-size: 20px;
    border-radius: 50%;
    transition: all 0.3s ease-in-out;
}

.btn-facebook { background: #1877F2; color: white; }
.btn-facebook:hover { background: #145dbf; color: white; }

.btn-twitter { background: #1DA1F2; color: white; }
.btn-twitter:hover { background: #0d8ddb; color: white; }

.btn-whatsapp { background: #25D366; color: white; }
.btn-whatsapp:hover { background: #1ebe5d; color: white; }

.btn-telegram { background: #0088CC; color: white; }
.btn-telegram:hover { background: #007bb5; color: white; }

.btn-pinterest { background: #E60023; color: white; }
.btn-pinterest:hover { background: #b8001c; color: white; }

.btn-email { background: #DD4B39; color: white; }
.btn-email:hover { background: #c23321; color: white; }

.btn-print { background: #6C757D; color: white; }
.btn-print:hover { background: #5a6268; color: white; }

.share-buttons .btn:hover {
    opacity: 0.8;
    transform: scale(1.1);
}

/* ===== Related Articles ===== */
.related-articles {
    background-color: #efefef;
    border-left: 4px solid #dc3545;
    padding: 12px;
    margin: 16px 0;
    border-radius: 5px;
}

.related-articles strong {
    color: #333;
    font-size: 16px;
}

.related-articles a {
    font-weight: bold;
    text-decoration: underline;
}

/* ===== Footer Navigation ===== */
.footer-nav {
    text-align: center;
    padding: 10px 0;
    list-style: none;
}

.footer-nav li {
    display: inline;
}

.footer-nav li a {
    color: #ffffff;
    text-decoration: none;
    padding: 0 5px;
}

.footer-nav li::after {
    content: " / ";
    color: #ffffff;
}

.footer-nav li:last-child::after {
    content: "";
}

/* ===== Pagination ===== */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
    margin-bottom: 20px;
}

.pagination .page-numbers {
    background-color: #b24a48;
    border: 1px solid #b24a48;
    color: white;
    padding: 8px 16px;
    margin: 0 5px;
    text-decoration: none;
    border-radius: 3px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.pagination .page-numbers:hover,
.pagination .page-numbers.current {
    background-color: #8d0100;
    color: white;
    border-color: #8d0100;
}

.pagination .prev, .pagination .next {
    background-color: #b24a48;
    color: white;
    padding: 8px 16px;
    margin: 0 5px;
    text-decoration: none;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.pagination .prev:hover,
.pagination .next:hover {
    background-color: #8d0100;
    color: white;
    border-color: #8d0100;
}

/* ===== Video News ===== */
.video-news img {
    width: 100%;
    height: 180px;
    border-radius: 8px;
    object-fit: cover;
}

.video-news {
    text-align: center;
    padding: 10px;
}

.video-news h6 {
    font-size: 14px;
    font-weight: bold;
    margin-top: 8px;
}

.video-news h6 a {
    text-decoration: none;
    color: #000;
    transition: color 0.3s ease;
}

.video-news h6 a:hover {
    color: #dc3545;
}

/* Menyesuaikan ukuran tombol navigasi carousel */
.carousel-control-prev,
.carousel-control-next {
    width: 5%;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    padding: 10px;
}
