:root {
    --primary-color: #1a56db;
    --secondary-color: #2563eb;
    --text-color: #1f2937;
    --light-gray: #f3f4f6;
    --border-color: #e5e7eb;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #fff;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header Styles */
header {
    background-color: var(--primary-color);
    color: white;
    padding: 2rem 0;
    margin-bottom: 2rem;
}

.header-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
}

.logo {
    max-width: 300px;
    height: auto;
    margin-bottom: 0.5rem;
}

.subtitle {
    font-size: 1rem;
    opacity: 0.9;
    text-align: left;
}

/* Filter Section */
.filter-section {
    background-color: var(--light-gray);
    padding: 1.5rem;
    border-radius: 0.5rem;
    margin-bottom: 2rem;
}

.date-filters {
    display: flex;
    gap: 1rem;
    align-items: flex-end;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

label {
    font-weight: 500;
    font-size: 0.875rem;
}

input[type="date"] {
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    font-size: 1rem;
}

.update-btn {
    background-color: var(--primary-color);
    color: white;
    padding: 0.5rem 1.5rem;
    border: none;
    border-radius: 0.375rem;
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.2s;
}

.update-btn:hover {
    background-color: var(--secondary-color);
}

.year-select {
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    font-size: 1rem;
    background-color: white;
    min-width: 100px;
}

/* Chart Section */
.chart-section {
    margin-bottom: 3rem;
    position: relative;
}

.chart-container {
    background-color: white;
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 2rem;
    min-height: 400px;
    position: relative;
    height: 60vh;
    width: 100%;
    overflow: hidden;
}

#styringsrenteChart {
    width: 100% !important;
    height: 100% !important;
}

.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #6b7280;
    font-size: 1.25rem;
    font-weight: 500;
}

.error-message {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    padding: 2rem;
}

.error-message h3 {
    color: #dc2626;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.error-message p {
    color: #6b7280;
    font-size: 1rem;
    margin-bottom: 1.5rem;
    max-width: 400px;
    line-height: 1.5;
}

.retry-btn {
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0.375rem;
    cursor: pointer;
    font-weight: 500;
    font-size: 1rem;
    transition: background-color 0.2s;
}

.retry-btn:hover {
    background-color: var(--secondary-color);
}

.placeholder-chart {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #6b7280;
    font-size: 1.25rem;
}

/* Info Section */
.info-section {
    margin-bottom: 3rem;
}

.info-section h2 {
    font-size: 1.875rem;
    margin-bottom: 1.5rem;
}

.info-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.info-card {
    background-color: white;
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 1.5rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.info-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.info-card h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

/* Footer */
footer {
    background-color: var(--light-gray);
    padding: 1.5rem 0;
    margin-top: 3rem;
    text-align: center;
}

/* Responsive Design */
@media (max-width: 768px) {
    header h1 {
        font-size: 2rem;
    }
    
    .date-filters {
        flex-direction: column;
    }
    
    .filter-group {
        width: 100%;
    }
    
    .update-btn {
        width: 100%;
    }
}

.year-range-container {
    width: 100%;
    margin-bottom: 1rem;
}

.year-labels {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    color: var(--text-color);
    font-size: 0.875rem;
}

.slider-container {
    position: relative;
    height: 40px;
    width: 100%;
    display: flex;
    align-items: center;
}

.slider-track {
    position: absolute;
    height: 6px;
    width: 100%;
    background: var(--border-color);
    border-radius: 3px;
    z-index: 1;
}

.year-slider {
    position: absolute;
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    background: transparent;
    pointer-events: none;
    z-index: 2;
}

.year-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    pointer-events: auto;
    transition: background 0.2s;
}

.year-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    pointer-events: auto;
    transition: background 0.2s;
}

#start-year-slider {
    z-index: 3;
}

#end-year-slider {
    z-index: 2;
}

#start-year-slider::-webkit-slider-thumb:hover,
#end-year-slider::-webkit-slider-thumb:hover {
    background: var(--secondary-color);
}

#start-year-slider::-moz-range-thumb:hover,
#end-year-slider::-moz-range-thumb:hover {
    background: var(--secondary-color);
}

.selected-years {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
}

#selected-start-year,
#selected-end-year {
    color: var(--primary-color);
    font-weight: 600;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 0.5rem;
}

.language-selector {
    display: flex;
    gap: 0.5rem;
}

.lang-btn {
    padding: 0.5rem;
    border: 1px solid white;
    border-radius: 0.25rem;
    background: transparent;
    color: white;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
}

.lang-btn .fi {
    font-size: 1.5rem;
    line-height: 1;
}

.lang-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.1);
}

.lang-btn.active {
    background: white;
    color: var(--primary-color);
    transform: scale(1.1);
} 