/* General Styles */
/* Import Noto Sans Thai font from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Thai:wght@300;400;500;700&display=swap');

/* If you want to apply it specifically to headings */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Noto Sans Thai', sans-serif;
}

/* You can apply the font to other specific elements as well */
p, a, span, div {
    font-family: 'Noto Sans Thai', sans-serif;
}

body {
    background-color: #d3e4ee;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #333;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Noto Sans Thai', sans-serif;
}

/* General Container Styles */
.container {
    max-width: 80%;      /* Limit the width to 60% of the available screen */
    width: 100%;         /* Make sure it takes full width up to the max-width */
    margin: 0 auto;      /* Center the container horizontally */
    padding: 20px;
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    border: 1px solid #dee2e6;
}


h1 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 30px;
    text-align: center;
    font-weight: 700;
    border-bottom: 2px solid #dee2e6; /* Added bottom border to header for emphasis */
    padding-bottom: 10px;
}

label {
    font-weight: bold;
    color: #333;
    font-size: 1.1rem;
}

/* Map Styles */
#map {
    height: 500px;
    margin-bottom: 20px;
    border-radius: 10px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    border: 1px solid #ced4da;
    background-color: #e9ecef; /* Added background color to ensure it's distinct */
}

/* Info Box Styles */
.info-box {
    padding: 20px;
    background-color: #f9f9f9;
    border: 1px solid #dee2e6; /* Added border to define the section */
    border-radius: 10px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    margin-top: 20px;
}

.info-box h3 {
    margin-bottom: 20px;
    font-size: 1.5rem;
    color: #333;
    font-weight: 600;
    border-bottom: 1px solid #dee2e6; /* Added border to separate title from content */
    padding-bottom: 10px;
}

.info-box p {
    margin: 5px 0;
    font-size: 1rem;
    color: #555;
}


/* Toggle Switch Styles */
.toggle-switch {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 10px;
    margin-bottom: 10px;
    padding: 10px 20px; /* Added padding for better spacing */
    background-color: #f9f9f9;
    border: 1px solid #dee2e6; /* Added border to define the section */
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.toggle-switch-label {
    margin-right: 10px;
    font-weight: bold;
    color: #333;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 25px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 25px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 17px;
    width: 17px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #2196F3;
}

input:checked + .slider:before {
    transform: translateX(24px);
}

/* Button Styles */
.btn {
    font-size: 1rem;
    font-weight: bold;
    padding: 10px 20px;
    border-radius: 5px;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.btn-primary {
    background-color: #007bff;
    color: white;
    border: none;
    box-shadow: 0 4px 6px rgba(0, 123, 255, 0.3);
}

.btn-primary:hover {
    background-color: #0056b3;
    box-shadow: 0 6px 8px rgba(0, 86, 179, 0.3);
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
    border: none;
    box-shadow: 0 4px 6px rgba(108, 117, 125, 0.3);
}

.btn-secondary:hover {
    background-color: #5a6268;
    box-shadow: 0 6px 8px rgba(90, 98, 104, 0.3);
}

/* Form Control Styles */
.form-control {
    font-size: 1rem;
    padding: 10px 12px; /* Adjusted padding for better height */
    border-radius: 5px;
    border: 1px solid #ced4da;
    margin-bottom: 15px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    height: auto; /* Ensure the height adjusts based on content */
    line-height: 1.5; /* Adjust line-height to ensure text isn't cut off */
}

.form-control:focus {
    border-color: #80bdff;
    outline: none;
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.5);
}

/* Tab Navigation Container - Ensure it's centered */
.nav-tabs {
    display: flex;
    justify-content: center; /* Centers the tabs horizontally */
    align-items: center;     /* Centers the tabs vertically if needed */
    border-bottom: 1px solid #ddd; /* Optional: to define a bottom border for the tabs */
    padding-bottom: 10px; /* Optional: add space between tabs and content below */
}

/* Tab Navigation Styles */
.nav-tabs .nav-link {
    font-size: 1rem;
    color: #467a58;
    margin-bottom: -1px;
    background-color: #f1f1f1;
    border: 1px solid transparent;
    border-radius: 5px 5px 0 0;
    text-align: center; /* Ensures the text inside each tab is centered */
}

/* Active Tab Style */
.nav-tabs .nav-link.active {
    color: #fff;
    background-color: #467a58;
    border-color: #467a58 #467a58 #f0f2f5;
}


.tab-content {
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 20px;
}

/* Responsive Styles */
@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
    }

    .container {
        padding: 10px;
    }

    .info-box {
        margin-top: 15px;
        padding: 15px;
    }

    .btn {
        font-size: 0.9rem;
        padding: 8px 15px;
    }

    .toggle-switch {
        flex-direction: column;
        align-items: flex-start;
    }

    #map {
        height: 400px;  /* Reduce map height on smaller screens */
    }

    .tab-content canvas {
        height: 200px !important;  /* Reduce chart height on smaller screens */
    }

    .form-control {
        font-size: 0.9rem;
        padding: 8px 10px;
    }
}

/* Chart Container Styles */
#chart-container {
    background-color: #ffffff;
    border: 1px solid #ced4da;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    margin-top: 20px;
}

#chart-container h3 {
    margin-bottom: 20px;
    font-size: 1.5rem;
    color: #333;
    text-align: center;
    font-weight: 600;
    border-bottom: 1px solid #dee2e6; /* Added border to separate title from content */
    padding-bottom: 10px;
}

.tab-content canvas {
    width: 100%;      /* Ensure it spans the full width of the container */
    height: 250px;    /* Set a smaller height for the charts */
    max-height: 250px; /* Added max-height to prevent overflow */
}

/* In your style.css */

/* Change the background color of the navbar */
.navbar {
    background-color: #467a58 !important; /* Replace with your desired color */
}

/* Optional: Change the color of the navbar links */
.navbar .nav-link {
    font-weight: bold;
    color: #ffffff; /* White text */
}

/* Optional: Change the color of the brand/logo text */
.navbar .navbar-brand {
    font-weight: bold;
    color: #ffffff; /* White text */
}

/* Optional: Change the color of the navbar links on hover */
.navbar .nav-link:hover {
    font-weight: bold;
    color: #f1c40f; /* Replace with your desired hover color */
}

/* Optional: Change the color of the active nav item */
.navbar .nav-item.active .nav-link {
    font-weight: bold;
    color: #ffde59; /* Replace with your desired active item color */
}

/* Styling for inactive navbar links */
.navbar .nav-item:not(.active) .nav-link {
    font-weight: bold;
    color: #cccccc !important; /* Color for inactive tabs */
}


