:root {
    --primary: #4361ee;
    --primary-dark: #3a56d4;
    --text: #2b2d42;
    --light: #f8f9fa;
    --border: #e9ecef;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

body {
    background-color: #f5f7ff;
    color: var(--text);
    line-height: 1.6;
    padding: 2rem 1rem;
    display: flex;
    justify-content: center;
    min-height: 100vh;
}

.container {
    max-width: 600px;
    width: 100%;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-top: 50px;
    height: 100%;
}

header {
    background: var(--primary);
    color: white;
    padding: 1.5rem;
    text-align: center;
}

h1 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.subtitle {
    opacity: 0.9;
    font-size: 0.9rem;
    font-weight: 400;
}

.calculator {
    padding: 2rem;
}

.input-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    font-size: 0.95rem;
}

input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.2s;
}

input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.15);
}

button {
    width: 100%;
    padding: 0.75rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

button:hover {
    background: var(--primary-dark);
}

.result {
    margin-top: 2rem;
    padding: 1.5rem;
    background: var(--light);
    border-radius: 8px;
    text-align: center;
    display: none;
}

.result-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    margin: 0.5rem 0;
}

.result-label {
    font-size: 0.9rem;
    opacity: 0.8;
}

@media (max-width: 480px) {
    .calculator {
        padding: 1.5rem;
    }
    
    h1 {
        font-size: 1.3rem;
    }
}