/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

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

/* Header */
.navbar {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo {
    color: white;
    font-size: 1.8rem;
    font-weight: bold;
}

.language-selector select {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 5px;
    padding: 8px 12px;
    font-size: 14px;
}

.language-selector select option {
    background: #333;
    color: white;
}

/* Main Content */
.main-content {
    margin-top: 80px;
    padding: 2rem 0;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 4rem 0;
    color: white;
}

.hero h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: 300;
}

.hero p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Calculator Categories */
.calculator-categories {
    padding: 2rem 0;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.category-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: center;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.category-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #667eea;
}

.category-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #333;
}

.category-card p {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.calculator-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.calculator-link {
    display: block;
    padding: 10px 15px;
    background: #f8f9fa;
    color: #333;
    text-decoration: none;
    border-radius: 8px;
    transition: background-color 0.3s ease, color 0.3s ease;
    font-weight: 500;
}

.calculator-link:hover {
    background: #667eea;
    color: white;
}

/* Calculator Page Styles */
.calculator-container {
    max-width: 800px;
    margin: 2rem auto;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.calculator-header {
    text-align: center;
    margin-bottom: 2rem;
    color: #333;
}

.calculator-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.calculator-header p {
    color: #666;
    font-size: 1.1rem;
}

.calculator-form {
    display: grid;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #333;
}

.form-group input,
.form-group select {
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
}

.calculate-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-top: 1rem;
}

.calculate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.result-section {
    margin-top: 2rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 10px;
    border-left: 4px solid #667eea;
}

.result-section h3 {
    color: #333;
    margin-bottom: 1rem;
}

.result-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 0.5rem;
}

.result-details {
    color: #666;
    font-size: 0.95rem;
}

/* Back Navigation */
.back-nav {
    margin-bottom: 2rem;
}

.back-link {
    display: inline-flex;
    align-items: center;
    color: white;
    text-decoration: none;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 25px;
    transition: background-color 0.3s ease;
}

.back-link:hover {
    background: rgba(255, 255, 255, 0.3);
}

.back-link i {
    margin-right: 0.5rem;
}

/* Footer */
footer {
    background: rgba(0, 0, 0, 0.8);
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero h2 {
        font-size: 2rem;
    }
    
    .category-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .nav-container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .logo {
        font-size: 1.5rem;
    }
    
    .calculator-container {
        margin: 1rem;
        padding: 1.5rem;
    }
    
    .calculator-header h1 {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .category-card {
        padding: 1.5rem;
    }
    
    .hero {
        padding: 2rem 0;
    }
    
    .hero h2 {
        font-size: 1.8rem;
    }
    
    .calculator-container {
        padding: 1rem;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide-up {
    animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}