/* Gaya Umum */
body {
    background-color: #000000;
    color: #ffffff;
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
}

/* Header */
.main-header {
    background-color: #1a1a1a;
    border-bottom: 1px solid #333;
}

.top-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.header-left .logo img {
    height: 30px;
}

.main-nav {
    display: flex;
    gap: 20px;
}

.nav-link {
    color: #fff;
    text-decoration: none;
    font-size: 16px;
    font-weight: bold;
    display: flex;
    align-items: center;
}

.nav-link:hover {
    color: #ff9900;
}

.arrow-down {
    display: inline-block;
    width: 0;
    height: 0;
    margin-left: 5px;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 4px solid #fff;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #2a2a2a;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
}

.dropdown:hover .dropdown-content {
    display: block;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.icon-link {
    color: #fff;
    text-decoration: none;
    display: flex;
    align-items: center;
    position: relative;
}

.icon {
    font-size: 20px;
}

.user-count {
    position: absolute;
    top: -5px;
    right: -10px;
    background-color: red;
    color: white;
    font-size: 10px;
    padding: 2px 5px;
    border-radius: 50%;
}

.bottom-header {
    background-color: #000;
    padding: 15px 20px;
}

.bottom-header .header-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    max-width: 1200px;
    margin: 0 auto;
}

.titles .main-title-text {
    font-size: 24px;
    font-weight: bold;
    margin: 0;
}

.titles .sub-title {
    font-size: 16px;
    margin: 5px 0 0;
    color: #aaa;
}

.filter-options {
    display: flex;
    align-items: center;
    gap: 15px;
}

.filter-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 5px;
}

.filter-btn:hover {
    color: #ff9900;
}

/* Konten Utama */
.main-container {
    display: flex;
    gap: 20px;
    max-width: 1200px;
    margin: 20px auto;
}

.main-content {
    flex: 1;
}

.sidebar-container {
    width: 300px;
    flex-shrink: 0;
    background-color: #7b0000;
    padding: 20px;
    border-radius: 8px;
}

.header-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-title {
    font-size: 24px;
    margin: 0;
}

.view-all-link {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
}

.featured-card-container {
    max-width: 900px;
    width: 100%;
    margin: 0 auto 20px;
    box-sizing: border-box;
}

.featured-card-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.featured-card-content {
    padding: 15px 0;
    text-align: left;
}

.featured-card-title {
    font-size: 28px;
    font-weight: bold;
    margin: 0;
}

.featured-card-metadata {
    font-size: 16px;
    color: #b0b0b0;
    margin-top: 5px;
}

.card-grid-container {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
}

.card {
    background-color: #212121;
    border-radius: 8px;
    overflow: hidden;
    color: #ffffff;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    padding-bottom: 10px;
}

.card-image-container {
    position: relative;
}

.card-image {
    width: 100%;
    height: auto;
    display: block;
}

.up-badge {
    position: absolute;
    top: 5px;
    right: 5px;
    background-color: #ff0000;
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: bold;
}

.card-content {
    padding: 5px; /* Mengurangi padding lebih banyak */
}

.card-title {
    font-size: 11px; /* Mengurangi ukuran font */
    font-weight: bold;
    margin: 0;
}

.card-author {
    font-size: 9px; /* Mengurangi ukuran font */
    color: #b0b0b0;
    margin-top: 2px;
}

.card-metadata {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 8px; /* Mengurangi ukuran font */
    color: #b0b0b0;
    margin-top: 5px;
}

/* Gaya Daftar Peringkat */
.ranking-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ranking-item {
    display: flex;
    align-items: center;
    background-color: #9c0000;
    border-radius: 8px;
    padding: 10px;
    gap: 10px;
    text-decoration: none;
    color: inherit;
}

.ranking-number {
    font-size: 24px;
    font-weight: bold;
    color: #ffffff;
}

.ranking-image {
    width: 60px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
}

.ranking-details {
    display: flex;
    flex-direction: column;
}

.ranking-title {
    font-size: 14px;
    font-weight: bold;
    margin: 0;
}

.ranking-author {
    font-size: 12px;
    color: #ffffff;
    margin-top: 5px;
}

.ranking-metadata {
    font-size: 11px;
    color: #ffffff;
    margin-top: 5px;
}

/* Media Queries untuk Responsif */
@media (max-width: 992px) {
    .main-container {
        flex-direction: column;
    }

    .sidebar-container {
        width: 100%;
        order: -1;
    }

    .card-grid-container {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 576px) {
    .main-container {
        padding: 10px;
        gap: 10px;
    }

    .card-grid-container {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    
    .card-content {
        padding: 3px; /* Padding sangat kecil */
    }

    .card-title {
        font-size: 8px; /* Ukuran font lebih kecil lagi */
    }

    .card-author {
        font-size: 7px;
    }

    .card-metadata {
        font-size: 6px;
        flex-direction: column; /* Metadata dipecah menjadi kolom agar tidak terlalu panjang */
        align-items: center;
    }

    .chapter-number, .view-count {
        margin: 2px 0;
    }
    
    .section-title {
        font-size: 18px;
    }

    .ranking-number {
        font-size: 16px;
    }

    .ranking-image {
        width: 40px;
        height: 60px;
    }

    .ranking-title {
        font-size: 11px;
    }

    .ranking-author {
        font-size: 9px;
    }
}