/* Merriweather Black Font Styles */
.merriweather-black {
    font-family: "Merriweather", system-ui;
    font-weight: 900;
    font-style: normal;
}

.merriweather-black-italic {
    font-family: "Merriweather", system-ui;
    font-weight: 700;
    font-style: italic;
}

/* General Body Styling */
body {
    font-family: 'Merriweather', serif;
    margin: 20px;
    background: linear-gradient(135deg, #f5f7fa, #c3cfe2); /* Soft background gradient */
    transition: background 0.5s ease-in-out;
}

h1, h2 {
    font-family: "Merriweather", system-ui; /* Apply Merriweather font */
    font-weight: 900;
}

h1 {
    font-size: 35px;
    color: #0d7dd4;
    margin-bottom: 20px;
    letter-spacing: normal; /* Removed letter spacing for heading */
    text-align: center;
    animation: fadeInDown 1s ease-out;
}

h2 {
    font-size: 25px; /* Increased font size for the result heading */
    color: #0d7dd4;
    margin-bottom: 20px;
    text-align: center;
    animation: fadeInUp 1s ease-out;
}

/* Animations for fade-in effects */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

input, button {
    display: block;
    margin-bottom: 10px;
    width: 100%;
    max-width: 300px;
    padding: 10px;
    font-size: 16px;
    border-radius: 10px;
    transition: all 0.3s ease-in-out;
}

input {
    border: 1px solid #0d7dd4;
    background-color: #fff;
}

input:focus {
    border-color: #0b6fbb;
    box-shadow: 0 0 8px rgba(13, 125, 212, 0.2);
    outline: none;
}

button {
    cursor: pointer;
    background-color: #0d7dd4;
    color: white;
    padding: 10px;
    font-size: 16px;
    border-radius: 10px;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

button:hover {
    background-color: #0b6fbb;
    transform: scale(1.05);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15);
}

#results {
    margin-top: 20px;
    padding: 20px;
    border-radius: 15px;
    background-color: #f0fdf9;
    border: 2px solid #0d7dd4;
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.5s ease-in-out, transform 0.5s ease-in-out;
    animation: resultFadeIn 1.2s ease-in-out forwards;
}

#results.show {
    opacity: 1;
    transform: scale(1);
}

@keyframes resultFadeIn {
    0% {
        opacity: 0;
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Adding letter spacing to the result display for clarity */
#detailedResult, #totalDays, #totalHours, #totalMinutes, #totalSeconds {
    letter-spacing: 2px; /* Increased letter spacing in the result */
    font-size: 18px; /* Slightly larger font size for emphasis */
    color: #0d7dd4;
    animation: fadeInUp 1s ease-in-out;
}

/* Adding letter spacing and line height to calculation breakdown for readability */
#breakdown {
    letter-spacing: 1.5px; /* Letter spacing for better readability */
    line-height: 1.6; /* Increased line height for better line spacing */
    font-size: 16px; /* Slightly larger font size */
    margin-top: 15px; /* Spacing above breakdown */
    color: #333; /* Slightly darker color for readability */
    animation: fadeIn 1.2s ease-in-out;
}

/* Input group styling with slight animation */
.input-group {
    margin-bottom: 20px;
    opacity: 0;
    transform: translateX(-20px);
    animation: slideIn 0.8s ease-in-out forwards;
}

@keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateX(-20px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}
