html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    font-family: var(--font-stack);
    /* overflow: hidden; Removed to allow scrolling if needed */
    background-color: #f4f4f4;
}

/* General body styling */
body {
    /* font-family: sans-serif; Use Montserrat from html, body */
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    padding: 20px;
    box-sizing: border-box;
    min-height: 100vh;
}

h1 {
    text-align: center;
    color: #6d6d6d;
    width: 100%;
    margin-bottom: 20px;
}

/* Main container for layout */
.main-container {
    display: flex;
    flex-direction: column; /* Stack controls above chart */
    align-items: center; /* Center items horizontally */
    width: 90%;
    max-width: 600px;
    height: 1200px;
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    /* flex-grow: 1; Not needed if body handles min-height */
    margin-bottom: 20px; /* Add some space at the bottom */
}

/* Removed styles for .container, .main-layout, .side-panel, .text-container, .controls-container as they are no longer in the HTML */

/* Controls styling */
#controls {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    gap: 15px;
    width: 100%; /* Make controls take full width of container */
    max-width: 700px; /* Limit max width of controls area */
}

#controls label {
    white-space: nowrap; /* Prevent label text wrapping */
}

#playButton {
    padding: 8px 15px;
    font-size: 1em;
    cursor: pointer;
    border: none;
    background-color: #4E9076; /* Blue color */
    color: white;
    border-radius: 4px;
    transition: background-color 0.3s ease;
    min-width: 70px; /* Ensure minimum width */
    text-align: center;
}

#playButton:hover {
    background-color: #4E9076;
}

#yearSlider {
    flex-grow: 1;
    max-width: 500px; /* Adjust max width as needed */
    cursor: pointer;
    height: 8px;
    background: #ddd;
    border-radius: 4px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

/* Style the slider thumb */
#yearSlider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: #4E9076;
    border-radius: 50%;
    cursor: pointer;
}

#yearSlider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    background: #4E9076;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* Chart container styling */
#chart-container {
    width: 100%; /* Take full width of the main-container */
    /* height is determined by content or JS, add min-height */
    display: flex; /* Center the SVG */
    justify-content: center;
    align-items: center;
    overflow: hidden; /* Prevent SVG overflow */
    padding: 10px; /* Add some padding inside */
    box-sizing: border-box;
    opacity: 0; /* Start with opacity 0 for fade-in effect */
}

/* Animation for chart fade-in */
@keyframes fadeIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

.fade-in {
    animation: fadeIn 3s ease-in-out forwards;
    animation-delay: 0.5s; /* 0.5 second delay before starting animation */
}

#barChart {
    width: 100%;
    height: 100%;
    display: block;
}

/* --- Styles for D3 Chart Elements --- */

.x-axis path,
.x-axis line,
.y-axis path,
.y-axis line {
    stroke: #ccc;
    shape-rendering: crispEdges;
    fill: none;
}

.x-axis .tick text,
.y-axis .tick text {
    fill: #555;
    font-size: 16px; /* Adjust as needed */
    /* font-family: 'Gochi Hand', cursive; Applied in JS */
}

.y-axis .tick text {
    text-anchor: end;
}

.bar {
    transition: fill 0.3s ease, opacity 0.2s ease;
    stroke: #333;
    stroke-width: 0px;
    /* Removed neumorphic style for simplicity, can be added back if desired */
}

.bar:hover {
    opacity: 0.8;
}

.label {
    font-size: 20px; /* Adjust as needed */
    pointer-events: none;
    /* fill and text-anchor managed by JS */
}

.score-label {
    font-size: 20px; /* Match label size */
    text-anchor: end;
    pointer-events: none;
    /* fill and font-weight managed by JS */
}

.year-ticker {
    font-size: clamp(40px, 10vw, 150px); /* Responsive size */
    font-weight: bold;
    fill: rgba(128, 128, 128, 0.6); /* Lighter gray, less opaque */
    text-anchor: middle;
    dominant-baseline: middle; /* Better vertical centering */
    pointer-events: none;
    /* Position managed by JS */
}

/* Removed styles for .year-display, .slider-wrapper classes not in the simplified HTML */
/* Removed specific thumb styles based on playing/paused/snapping classes */
/* Removed .sr-only style as it's now inline in HTML */
/* Removed Font Awesome import, assuming it's correctly linked in HTML */

/* Botão de navegação para home */
.nav-button {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1000;
}

.home-button {
    display: inline-block;
    padding: 10px 15px;
    background-color: #4E9076;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.home-button:hover {
    background-color: #3d7060;
}