/* General Body Styles - Assuming a dark background for the page */
.strombay-calculator-body {
    font-family: 'Poppins', sans-serif; /* Use a font similar to the image */
    background-color: #0b0c10; /* Dark background matching the image */
    color: #e0e0e0; /* Light text for contrast */
    margin: 0;
    padding: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    box-sizing: border-box;
}

.strombay-calculator-wrapper {
    width: 100%;
    max-width: 600px; /* Adjust max-width as needed */
    background: radial-gradient(circle at top left, #2a2a47 0%, #1a1a2e 100%); /* Gradient background */
    border-radius: 15px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden; /* For any background patterns */
}

/* Background Patterns - Optional, to match the subtle lines */
.strombay-calculator-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('path/to/your/subtle-pattern.png'); /* Replace with your actual pattern image */
    opacity: 0.1;
    pointer-events: none;
    z-index: 0;
}

.strombay-calculator-card {
    position: relative;
    z-index: 1; /* Ensure content is above background pattern */
}

.strombay-calculator-card h1 {
    font-size: 2.2em;
    color: #ffffff;
    text-align: center;
    margin-bottom: 10px;
    letter-spacing: 0.5px;
}

.strombay-calculator-card .subtitle {
    font-size: 0.9em;
    color: #a0a0a0;
    text-align: center;
    margin-bottom: 30px;
}

.section-title {
    font-size: 1.1em;
    color: #ffffff;
    margin-top: 30px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    letter-spacing: 0.8px;
}

.info-icon {
    font-family: sans-serif; /* Ensure it renders correctly */
    font-size: 0.8em;
    color: #a0a0a0;
    border: 1px solid #a0a0a0;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-left: 8px;
    cursor: help;
}

/* Radio Button Styling */
.radio-group {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
}

.radio-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 1em;
    color: #e0e0e0;
}

.radio-label input[type="radio"] {
    /* Hide default radio button */
    display: none;
}

.radio-custom {
    width: 18px;
    height: 18px;
    border: 2px solid #5a5a5a;
    border-radius: 50%;
    margin-right: 10px;
    position: relative;
    transition: all 0.2s ease-in-out;
}

.radio-label input[type="radio"]:checked + .radio-custom {
    border-color: #FF5733; /* Orange accent color */
    background-color: #2e2e42; /* Slightly different background when selected */
}

.radio-label input[type="radio"]:checked + .radio-custom::after {
    content: '';
    width: 10px;
    height: 10px;
    background-color: #FF5733; /* Orange dot */
    border-radius: 50%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Input Row for KM and Daily/Weekly */
.input-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
}

.input-label {
    font-size: 1em;
    color: #e0e0e0;
}

.input-label.on-a {
    margin-left: 10px;
}

.text-input {
    background-color: #2e2e42; /* Darker input background */
    border: 1px solid #4a4a60;
    border-radius: 8px;
    padding: 10px 15px;
    color: #ffffff;
    font-size: 1em;
    flex-grow: 1; /* Allow KM input to take available space */
    width: 80px; /* Default width for KM input */
}

.text-input:focus {
    outline: none;
    border-color: #FF5733;
    box-shadow: 0 0 0 2px rgba(255, 87, 51, 0.3);
}

.km-input {
    max-width: 100px; /* Limit width of KM input */
}

.unit-label {
    color: #a0a0a0;
    font-size: 0.9em;
}

.unit-label.basis-label, .unit-label.years-label {
    min-width: 40px; /* Ensure labels don't get too cramped */
}


.dropdown-input {
    background-color: #2e2e42;
    border: 1px solid #4a4a60;
    border-radius: 8px;
    padding: 10px 15px;
    color: #ffffff;
    font-size: 1em;
    appearance: none; /* Remove default dropdown arrow */
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23a0a0a0'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E"); /* Custom arrow */
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px; /* Make space for custom arrow */
}

.dropdown-input:focus {
    outline: none;
    border-color: #FF5733;
    box-shadow: 0 0 0 2px rgba(255, 87, 51, 0.3);
}

/* Slider Group */
.slider-group {
    margin-bottom: 25px;
}

.slider-input {
    width: 100%;
    -webkit-appearance: none; /* Override default CSS for range input */
    background: transparent; /* Make track transparent */
    margin: 10px 0;
}

.slider-input:focus {
    outline: none;
}

/* Track styles */
.slider-input::-webkit-slider-runnable-track {
    width: 100%;
    height: 8px;
    cursor: pointer;
    background: linear-gradient(to right, #FF5733 0%, #FF5733 var(--slider-fill, 50%), #4a4a60 var(--slider-fill, 50%), #4a4a60 100%); /* Dynamic fill */
    border-radius: 5px;
    border: 0.2px solid #3a3a4a;
}

.slider-input::-moz-range-track {
    width: 100%;
    height: 8px;
    cursor: pointer;
    background: linear-gradient(to right, #FF5733 0%, #FF5733 var(--slider-fill, 50%), #4a4a60 var(--slider-fill, 50%), #4a4a60 100%);
    border-radius: 5px;
    border: 0.2px solid #3a3a4a;
}

/* Thumb styles */
.slider-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    border: 3px solid #FF5733;
    height: 20px;
    width: 20px;
    border-radius: 50%;
    background: #ffffff;
    cursor: pointer;
    margin-top: -6px; /* Adjust to center thumb on track */
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
}

.slider-input::-moz-range-thumb {
    border: 3px solid #FF5733;
    height: 20px;
    width: 20px;
    border-radius: 50%;
    background: #ffffff;
    cursor: pointer;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
}


.slider-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.85em;
    color: #a0a0a0;
    margin-top: 5px;
    position: relative;
}

.slider-labels .current-value {
    color: #ffffff; /* Make current value stand out */
    font-weight: bold;
    position: absolute;
    transform: translateX(-50%); /* Center the value below the thumb */
    transition: left 0.1s ease-out; /* Smooth movement for value */
    /* JS will set 'left' property */
}


/* Readonly Input for Car Life */
input[readonly].text-input {
    background-color: #22223a; /* Slightly different background for readonly */
    opacity: 0.8;
    cursor: not-allowed;
    flex-grow: 0; /* Don't let it stretch */
    max-width: 100px; /* Specific width for car life */
    text-align: center;
}

.years-label {
    margin-left: -50px; /* Adjust to place "YEARS" correctly next to the input */
}


/* Calculate Button */
.calculate-button {
    background-color: #FF5733; /* Orange accent color */
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 15px 25px;
    font-size: 1.1em;
    font-weight: bold;
    width: 100%;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 35px;
    margin-bottom: 20px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.calculate-button:hover {
    background-color: #e04a2c; /* Slightly darker orange on hover */
}

/* Privacy Text */
.privacy-text {
    font-size: 0.75em;
    color: #7a7a7a;
    text-align: center;
    line-height: 1.5;
}

.privacy-text a {
    color: #FF5733;
    text-decoration: none;
}

.privacy-text a:hover {
    text-decoration: underline;
}

/* Results Section Styling (if you use it within the same card) */
.results-card {
    background-color: #1a1a2e; /* Slightly different background for results */
    border: 1px solid #4a4a60;
    border-radius: 10px;
    padding: 20px;
    margin-top: 30px;
    text-align: center;
}
.results-card h3 {
    color: #ffffff;
    margin-bottom: 15px;
    font-size: 1.2em;
}
.results-card p {
    font-size: 1.1em;
    color: #e0e0e0;
}
.results-card strong {
    color: #FF5733; /* Highlight savings amount */
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .strombay-calculator-wrapper {
        padding: 25px;
    }
    h1 {
        font-size: 1.8em;
    }
    .input-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .input-row .input-label.on-a {
        margin-left: 0;
    }
    .text-input, .dropdown-input, input[readonly].text-input {
        width: 100%;
        max-width: none;
    }
    .km-input, input[readonly].text-input {
        text-align: left;
        padding-right: 15px; /* Reset padding for text input */
    }
    .unit-label {
        align-self: flex-end; /* Align units to the right */
    }
    .years-label {
        margin-left: 0;
        align-self: flex-start;
        width: auto;
    }
}

/* --- Results Display Styling --- */
.strombay-results-display {
    margin-top: 30px;
    padding: 20px;
    background-color: #1a1a2e; /* Dark background matching the calculator card */
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
    text-align: center;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); /* Responsive grid for 3 items */
    gap: 20px;
    margin-bottom: 30px;
}

.result-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px;
    background-color: #2e2e42; /* Slightly lighter background for each item */
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.progress-circle {
    position: relative;
    width: 120px; /* Size of the circle */
    height: 120px;
    border-radius: 50%;
    background: #0d0e14; /* Dark background of the circle */
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    overflow: hidden; /* Important for the pseudo-elements to work */
}

.inner-circle {
    position: relative;
    width: 90px; /* Size of the inner circle containing the icon */
    height: 90px;
    background-color: #2e2e42; /* Background color of the inner circle */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2; /* Ensure inner content is above the progress arc */
}

.icon {
    width: 50px; /* Size of your icon image */
    height: 50px;
    object-fit: contain;
}

/* CSS for the animated progress arc */
.progress-circle::before,
.progress-circle::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    box-sizing: border-box;
    transform: rotate(-90deg); /* Start from the top */
}

.progress-circle::before { /* The grey background arc */
    border: 8px solid rgba(74, 74, 96, 0.5); /* #4a4a60 with transparency */
}

.progress-circle::after { /* The actual progress arc (orange) */
    border: 8px solid #FF5733; /* Orange color */
    border-right-color: transparent; /* Hide initial right part */
    border-bottom-color: transparent; /* Hide initial bottom part */
    transition: transform 1s ease-out; /* Smooth animation */
    /* This will be dynamically set by JS using a CSS variable */
    transform: rotate(calc(-90deg + var(--progress-deg, 0deg)));
}

/* For percentages > 50, the overlay helps with the full circle fill */
.circle-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-color: #FF5733; /* Orange fill */
    opacity: 0; /* Hidden by default */
    z-index: 1; /* Below inner-circle, above pseudo-elements */
    transition: opacity 0.5s ease-in-out;
}


.result-value {
    font-size: 1.8em;
    font-weight: bold;
    color: #FF5733; /* Orange for the main numbers */
    margin-bottom: 5px;
}

.result-text {
    font-size: 0.9em;
    color: #a0a0a0;
    line-height: 1.4;
}

.result-text strong {
    color: #ffffff; /* Make the actual numbers in the text stand out */
}

.calculate-again-button {
    background-color: #FF5733;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 12px 20px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 30px;
    width: auto; /* Allow button to size to content */
}

.calculate-again-button:hover {
    background-color: #e04a2c;
}

/* Responsive adjustments for results grid */
@media (max-width: 650px) {
    .results-grid {
        grid-template-columns: 1fr; /* Stack items vertically on smaller screens */
    }
}