body {

    background-color: #f8f9fa;

}







.chart-container {

    height: 400px;

}



#map {

    height: 400px;

    background: #ddd;

}



.temperature {

    font-size: 20px;

    font-weight: bold;

}



.forecast-container {

    display: flex; /* Wajib buat horizontal! */

    gap: 12px;

    overflow-x: auto; /* Scroll horizontal */

    white-space: nowrap; /* Biar item sejajar */

    padding: 12px;

    scroll-behavior: smooth; /* Biar scroll halus */

    scroll-snap-type: x mandatory; /* Optional buat snap efek */

}





.forecast-container::-webkit-scrollbar {

    height: 8px; /* Biar scrollbar horizontal kelihatan */

}



.forecast-container::-webkit-scrollbar-thumb {

    background-color: #ccc;

    border-radius: 4px;

}



.forecast-card {

    flex: 0 0 auto; /* Wajib, biar gak ngewrap */

    width: 110px;

    text-align: center;

    border-radius: 12px;

    padding: 12px;

    background: #ffffff;

    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);

    font-size: 0.9rem;

    color: #333;

    transition: all 0.3s ease;

    border: 1px solid #e0e0e0;

}



.forecast-card:hover {

    transform: translateY(-5px);

    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);

}



.forecast-card.active-hour {

    background: linear-gradient(135deg, #198754, #1bd67f);

    color: #ffffff;

    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);

    transform: scale(1.05);

}





.forecast-card.active-hour img {

    filter: brightness(0) invert(1);

}



.forecast-card strong {

    font-size: 1.1em;

    display: block;

    margin-bottom: 4px;

}



.forecast-card img {

    width: 40px;

    height: 40px;

    margin-bottom: 4px;

    transition: filter 0.3s ease;

}



.forecast-card small {

    display: block;

    margin-top: 4px;

    font-size: 0.8em;

    opacity: 0.8;

}



/* Responsive adjustment (optional) */

@media (max-width: 480px) {

    .forecast-card {

        width: 90px;

        padding: 8px;

    }



    .forecast-card img {

        width: 32px;

        height: 32px;

    }



    .forecast-card strong {

        font-size: 1em;

    }

}







.card-container {

    background: #fff;

    border-radius: 12px;

    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);

    text-align: center;

    padding: 10px;

    flex: 0 0 auto;

    width: 18rem;

    margin: 0.5rem; /* Tambahkan ini */

}







.gauge-label {

    font-weight: bold;

    margin-bottom: 10px;

    color: #333;

}



.gauge-wrapper {

    position: relative;

    width: 180px;

    height: 180px;

    margin: auto;

}



.gauge-text {

    position: absolute;

    top: 50%;

    left: 50%;

    transform: translate(-50%, -50%);

    font-size: 22px;

    font-weight: bold;

    color: #222;

    background: rgba(255, 255, 255, 0.8);

    padding: 5px 10px;

    border-radius: 8px;

}



.card-footer {

    background-color: transparent;

    border-top: none;

}



.last-update {

    color: #666;

    font-size: 12px;

    display: block;

}



.weather-icon {

    width: 50px;

    height: 50px;

    margin-right: 10px;

}



.weather-text {

    font-size: 18px;

    font-weight: bold;

}



.weather-temp {

    font-size: 16px;

    color: #555;

}



#device-container {

    overflow-x: auto;

    white-space: nowrap;

    padding: 10px;

}







#device-list {

    display: flex;

    gap: 8px;

    overflow-x: auto;

    padding: 8px;

    white-space: nowrap; /* Pastikan anak-anaknya gak pecah ke bawah */

}



.card-container1 {

    background: #fff;

    border: 1px solid #ddd;

    border-radius: 8px;

    box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.1);

    padding: 8px;

    text-align: center;

    flex-shrink: 0;

    width: 140px; /* Fix width biar gak liar */

    max-width: 140px; /* Biar safe */

}



.card-container1 strong {

    font-size: 14px;

    white-space: nowrap;

}



.card-container1 .device-icon {

    font-size: 36px;

}



/* Text di dalam card */

.card-container1 p {

    font-size: 12px;

    margin: 4px 0 0 0;

    white-space: normal;

}



.card-container1 small {

    font-size: 10px;

}





.scroll-container {

    display: flex;

    overflow: hidden;

    white-space: nowrap;

    width: 100%;

    position: relative;

    cursor: grab;

}



.scroll-wrapper {

    display: flex;

    gap: 20px;

    /* Jarak antar kartu */

    transition: transform 0.1s linear;

}







.chart-container {

    margin-bottom: 10px;

}



.hidden {

    display: none;

}





.gauge-container1 {

    position: relative;

    display: inline-block;

    width: 9rem;

    /* Sesuaikan dengan ukuran canvas */

    height: 9rem;

}



.gauge-wrapper1 {

    display: block;

    margin: auto;

}



.gauge-text1 {

    position: absolute;

    top: 50%;

    left: 50%;

    transform: translate(-50%, -50%);

    font-size: 15px;

    font-weight: bold;

    color: #222;

    background: rgba(255, 255, 255, 0.8);

    padding: 5px 10px;

    border-radius: 8px;

    white-space: nowrap;

}



.filter-toggle {

    position: fixed;

    top: 60%;

    right: 0;

    background: #007bff;

    color: white;

    padding: 10px;

    font-size: 16px;

    border-radius: 0px 10px 10px 0px;

    cursor: pointer;

    transform: translateY(-50%) rotate(180deg);

    z-index: 9998;

    writing-mode: vertical-lr;

    text-orientation: mixed;

    display: flex;

    align-items: center;

    justify-content: center;

    height: 100px;

}



.filter-form {

    position: fixed;

    top: 60%;

    right: -300px;

    width: 280px;

    background: white;

    padding: 15px;

    border-radius: 5px 0 0 5px;

    box-shadow: -2px 2px 10px rgba(0, 0, 0, 0.2);

    transition: right 0.3s ease-in-out;

    transform: translateY(-50%);

}



/* Hover effect untuk menampilkan form */

.filter-wrapper:hover .filter-form {

    right: 0;

    z-index: 9998;

    /* Pastikan lebih tinggi dari elemen lain */

}





.navbar {

    padding: 10px;

    background-color: #ffffff; /* Warna latar belakang navbar */

}

.navbar-brand img {

    height: 40px;

}

.nav-link {

    color: rgb(0, 0, 0);

    font-weight: bold;

}

.nav-link:hover {

    color: #000000;

}



 /* Ikon status */

 .device-icon {

    font-size: 30px;

}





/* Styling untuk tab */

.custom-tabs {

    border-bottom: none;

    display: flex;

    color: #333;

    flex-wrap: nowrap; /* Paksa selalu 1 baris */

    overflow-x: auto; /* Tambah scroll horizontal kalau kepanjangan */

    overflow-y: hidden;

    white-space: nowrap; /* Biar teks gak pecah */

    -webkit-overflow-scrolling: touch; /* Smooth scrolling untuk iOS */

    scrollbar-width: thin; /* Untuk Firefox */

}



/* Style scrollbar biar rapi (opsional) */

.custom-tabs::-webkit-scrollbar {

    height: 5px;

}

.custom-tabs::-webkit-scrollbar-thumb {

    background: #ccc;

    border-radius: 10px;

}



/* Style tab item */

.custom-tabs .nav-link {

    flex: 1; /* Semua tab ukurannya rata */

    min-width: 150px; /* Minimal lebar tiap tab */

    border-radius: 20px 20px 0 0;

    background-color: #fff;

    padding: 12px 24px;

    font-weight: bold;

    font-size: 10.1pt;

    color: black;

    text-align: center; /* Teks di tengah */

    transition: all 0.3s ease;

    box-shadow: 0px -2px 5px rgba(0, 0, 0, 0.1);

}



/* Tab aktif */

.custom-tabs .nav-link.active {

    background-color: #333;

    color: white;

    box-shadow: 0px -3px 8px rgba(0, 0, 0, 0.3);

}



/* Styling untuk konten */

.tab-content {

    background: white;

    padding: 20px;

    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);

}









/* HP (â‰¤ 600px) */

@media (max-width: 600px) {

    .device-wrapper {

        gap: 5px;

        padding-bottom: 5px;

    }



    #device-list {

        gap: 4px;

    }

    .card-container1 {

        width: 110px;

        max-width: 110px;

        padding: 4px;

    }

    .card-container1 strong {

        font-size: 12px;

    }

    .card-container1 .device-icon {

        font-size: 28px;

    }

    .card-container1 p {

        font-size: 10px;

    }

    .card-container1 small {

        font-size: 8px;

    }



    .device-icon {

        font-size: 35px;

    }



    .arrow {

        font-size: 16px;

        padding: 3px 7px;

    }

}



/* Tablet (600px - 900px) */

@media (min-width: 601px) and (max-width: 900px) {

    .device-wrapper {

        gap: 8px;

    }



    .card-container1 {

        width: 130px;

        height: 9rem;

    }



    .device-icon {

        font-size: 40px;

    }



    .arrow {

        font-size: 18px;

        padding: 4px 8px;

    }

}



/* Laptop/Desktop (> 900px) */

@media (min-width: 901px) {

    .device-wrapper {

        gap: 10px;

    }



    .card-container1 {

        width: 150px;

        height: 10.2rem;

    }

}

