
/*------------------ Dark Theme Styles -------------- */

.dark-theme {
    --bs-body-bg: #121212;
    --bs-body-color: #f8f9fa;
}

/* Navbar */
.dark-theme .navbar {
    background-color: #343a40 !important;
    /* Dark gray */
    color: #f8f9fa !important;
}

.dark-theme .navbar .nav-link {
    color: #f8f9fa !important;
}

.dark-theme .navbar .nav-link:hover {
    color: #adb5bd;
    /* Lighter gray */
}

/* Footer */
.dark-theme footer {
    background-color: #343a40 !important;
    color: #f8f9fa !important;
}

.dark-theme footer a {
    color: #fafafa !important;
    font-size: xx-large;
}

.dark-theme footer a:hover {
    color: #c0c0c0 !important;
}

/* Buttons */
.dark-theme .btn-primary {
    background-color: #375a7f;
    border-color: #375a7f;
}

.dark-theme .btn-secondary {
    background-color: #6c757d;
    border-color: #6c757d;
}


/* Dark theme form adjustments */
.dark-theme form {
    color: #ffffff !important; /* Ensure form text is white */
}

.dark-theme form .form-control {
    background-color: #495057; /* Darker input field background */
    color: #ffffff !important; /* White text inside input fields */
    border: 1px solid #adb5bd; /* Light gray border */
}

.dark-theme form .form-control::placeholder {
    color: #ced4da; /* Light gray placeholder text for better contrast */
}

.dark-theme form .form-control:focus {
    border-color: #ffffff; /* White border on focus */
    box-shadow: 0 0 0 0.2rem rgba(255, 255, 255, 0.25); /* Subtle white glow */
}

.dark-theme form label {
    color: #ffffff; /* Ensure labels are white */
}

.dark-theme form .form-text {
    color: #ced4da; /* Helper text below inputs, styled in light gray */
}


/* Alert Messages */
.alert-danger {
    background-color: #f8d7da;
    /* Light red background */
    color: #721c24;
    /* Dark red text */
}

.alert-warning {
    background-color: #fff3cd;
    /* Light yellow background */
    color: #856404;
    /* Dark yellow text */
}

.alert-success {
    background-color: #d4edda;
    /* Light green background */
    color: #155724;
    /* Dark green text */
}

/*------------------------ Footer ------------------- */
footer a {
    color: #353535 !important;
    font-size: xx-large;
}

footer a:hover {
    color: #000000 !important;
}

/*----------------------- Homepage ------------------ */
.profile-img {
    max-width: 100%;
}

/*----------------------- Settings ------------------ */
#settings-illustration {
    max-width: 75%; 
    height: auto;
}

/*----------------------- Dashboard ------------------ */
.calendar-month {
    text-align: center;
}

.calendar-container {
    text-align: center;
}

.calendar-div {
    margin: 0 auto;
    display: inline-block;
    min-height: 200px;
}

svg {
    margin: 0 auto;
    display: block;
}

.calendar-div {
    display: flex;
    justify-content: center;
    /* Center the SVG horizontally */
    align-items: center;
}

.calendar-div svg {
    max-width: 100%;
    /* Make SVG responsive to parent */
    height: auto;
    /* Maintain aspect ratio */
}

/* Default horizontal legend */
.legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: 1rem;
    align-items: center;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem; /* Add spacing between the square and text */
}

.legend-item div {
    width: 20px;
    height: 20px;
    border-radius: 4px; /* Optional: Rounded corners for the squares */
}

/* General rule for legend items */
/* .legend-item {
    width: 20px;
    height: 20px;
    display: inline-block;
    margin-left: 15px;
    border-radius: 4px;
} */

/* Specific rules for each mood */
.happy {
    background-color: #FFD700;
    /* Gold */
}

.sad {
    background-color: #FF4500;
    /* OrangeRed */
}

.anxious {
    background-color: #9370DB;
    /* MediumPurple */
}

.angry {
    background-color: #FF6347;
    /* Tomato */
}

.calm {
    background-color: #87CEFA;
    /* LightSkyBlue */
}

.excited {
    background-color: #32CD32;
    /* LimeGreen */
}

.tired {
    background-color: #A9A9A9;
    /* DarkGray */
}

/*----------------------- Mood History ------------------ */

#history-illustration {
    max-width: 75%; 
    height: auto;
}

.history-date{
    min-width: 100px;
}

.badge {
    min-width: 60px;
}
.badge.happy {
    background-color: #FFD700;
    color: #121212;
}

.badge.sad {
    background-color: #FF4500;
    color: #121212;
}

.badge.anxious {
    background-color: #9370DB;
    color: #121212;
}

.badge.angry {
    background-color: #FF6347;
    color: #121212;
}

.badge.calm {
    background-color: #87CEEB;
    color: #121212;
}

.badge.excited {
    background-color: #32CD32;
    color: #121212;
}

.badge.tired {
    background-color: #A9A9A9;
    color: #121212;
}

/* Accordion */
.dark-theme .accordion-button {
    background-color: #2c2c2c;
    color: #f8f9fa;
}

.dark-theme .accordion-button::after {
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ffffff'><path fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/></svg>") !important;
}

/* Vertical legend for small screens */
@media (max-width: 768px) {
    .legend {
        align-items: center;
    }
}