/* body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
}

.converter-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.converter-header {
    text-align: center;
    margin-bottom: 30px;
}

.converter-header h2 {
    color: #1e3c72;
    font-size: 2em;
    margin-bottom: 10px;
}

.converter-header p {
    color: #666;
    font-size: 1.1em;
}

.converter-card {
    background: white;
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.input-group {
    margin-bottom: 5px;
    max-width: 200px;
    margin: 0 auto;
}

.input-group label {
    display: block;
    margin-bottom: 2px;
    color: #333;
    font-weight: 500;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper input, select {
    width: 100%;
    padding: 5px;
    padding-right: 40px;
    border: 2px solid #e0e0e0;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.input-wrapper input:focus, select:focus {
    outline: none;
    border-color: #1e3c72;
}

.input-wrapper .unit {
    position: absolute;
    right: 12px;
    color: #666;
    font-weight: 500;
}

button {
    margin-top: 20px;
    background: #1e3c72;
    color: white;
    width: 200px;
    margin: 20px auto;
    display: block;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

button:hover {
    background: #2a5298;
}

.result {
    margin-top: 20px;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.result hr {
    margin: 15px 0;
    border: none;
    border-top: 1px solid #e0e0e0;
}

.result p {
    margin: 8px 0;
    color: #333;
}

.formula-section {
    margin-top: 40px;
}

.formula-section h3 {
    color: #1e3c72;
    text-align: center;
    margin-bottom: 20px;
}

.formula-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.formula-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    text-align: center;
}

.formula-card h4 {
    color: #1e3c72;
    margin-bottom: 10px;
}

.formula-card p {
    color: #666;
    font-family: monospace;
    font-size: 1.1em;
}

.hidden {
    display: none;
}

@media (max-width: 768px) {
    .converter-container {
        padding: 15px;
    }

    .converter-header h2 {
        font-size: 1.8em;
    }

    .converter-card {
        padding: 20px;
    }

    .formula-cards {
        grid-template-columns: 1fr;
    }
}
 */

 :root {
    --primary-color: #1e3c72;
    --primary-hover: #2a5298;
    --text-primary: #333;
    --text-secondary: #666;
    --border-color: #e0e0e0;
    --shadow-sm: 0 2px 5px rgba(0,0,0,0.1);
    --shadow-md: 0 2px 10px rgba(0,0,0,0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background-color: #f5f5f5;
    min-height: 100vh;
}

.calculator-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.calculator-header {
    text-align: center;
    margin-bottom: 30px;
}

.calculator-header h2 {
    color: var(--primary-color);
    font-size: 2em;
    margin-bottom: 10px;
}

.calculator-header p {
    color: var(--text-secondary);
    font-size: 1.1em;
}

.calculator-card {
    background: white;
    border-radius: 8px;
    padding: 30px;
    box-shadow: var(--shadow-md);
    margin-bottom: 30px;
}

.input-row {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 0 auto;
    margin-bottom: 15px;
}

.input-field {
    width: 200px;
}

.input-field label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-weight: 500;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

select {
    width: 300px; /* Wider than regular inputs */
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s;
    background-color: white;
}

select:focus {
    outline: none;
    border-color: var(--primary-color);
}

input {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s;
}

input:focus {
    outline: none;
    border-color: var(--primary-color);
}

button {
    background: var(--primary-color);
    color: white;
    width: 200px;
    margin: 20px auto;
    display: block;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

button:hover {
    background: var(--primary-hover);
}

.error-message {
    margin: 20px auto;
    max-width: 200px;
    padding: 12px;
    background-color: #fff5f5;
    border: 1px solid #feb2b2;
    border-radius: 4px;
    color: #c53030;
    display: none;
    text-align: center;
}

.results {
    margin: 20px auto;
    max-width: 400px;
    padding: 20px;
    background-color: white;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    display: none;
}

.results h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    text-align: center;
}

.results p {
    margin-bottom: 8px;
    color: var(--text-secondary);
    text-align: center;
}

.results .highlight {
    color: var(--primary-color);
    font-weight: 500;
}

.formula-section {
    margin-top: 40px;
}

.formula-section h3 {
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 20px;
}

.formula-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.formula-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.formula-card h4 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.formula-card p {
    color: var(--text-secondary);
    font-family: monospace;
    font-size: 1.1em;
}

@media (max-width: 600px) {
    .input-row {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    
    .input-field {
        width: 200px;
    }

    select {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .calculator-container {
        padding: 15px;
    }

    .calculator-header h2 {
        font-size: 1.8em;
    }

    .calculator-card {
        padding: 20px;
    }

    .results {
        max-width: 100%;
    }

    .formula-cards {
        grid-template-columns: 1fr;
    }
}

