/* General Body and Container Styles */
/* Removed @import url for Google Fonts */

html {
    scroll-behavior: smooth;
}

body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f7f6;
    color: #333;
}

.container {
    background-color: #ffffff;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    width: 960px;
    max-width: 98%;
    margin-top: 40px;
    text-align: left;
    border-top: 3px solid #e3eafc;
    margin-bottom: 40px; /* Add margin to bottom to separate from footer */
}

.container h1 {
    color: #0056b3;
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
    letter-spacing: 0.8px;
}

.container h2 {
    color: #1976d2;
    font-size: 1.8rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.container p {
    color: #495057;
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .container {
        padding: 25px;
        margin-top: 30px;
        width: 95%;
    }

    .container h1 {
        font-size: 2rem;
        margin-bottom: 1rem;
    }

    .container h2 {
        font-size: 1.5rem;
        margin-top: 1.5rem;
        margin-bottom: 0.8rem;
    }

    .container p {
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 20px;
        margin-top: 20px;
        border-radius: 15px;
    }

    .container h1 {
        font-size: 1.8rem;
        margin-bottom: 0.8rem;
    }

    .container h2 {
        font-size: 1.3rem;
        margin-top: 1rem;
        margin-bottom: 0.6rem;
    }

    .container p {
        font-size: 0.85rem;
    }
}

.calculator-container,
.about-section,
.formula-section,
.faq-section,
.site-footer {
    max-width: 900px;
    margin: 20px auto;
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.calculator-container:hover {
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    transform: translateY(-3px);
}

.top-menu {
    background-color: #0056b3;
    color: #fff;
    padding: 10px 0;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.top-menu nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.top-menu nav ul li a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    padding: 5px 10px;
    transition: background-color 0.3s ease;
}

.top-menu nav ul li a:hover {
    background-color: #004494;
    border-radius: 5px;
}

.language-selector {
    margin-top: 10px;
}

.language-selector select {
    padding: 8px;
    border-radius: 5px;
    border: 1px solid #ddd;
    background-color: #f9f9f9;
}

.calculator-container span {
    display: block;
    text-align: center;
    margin-bottom: 20px;
    color: #555;
}

.input-group {
    margin-bottom: 15px;
}

.input-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.input-with-unit {
    display: flex;
    gap: 10px;
}

.input-with-unit input[type="number"] {
    flex-grow: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
}

.input-with-unit select {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    background-color: #f9f9f9;
}

.norm-display {
    font-size: 0.9em;
    color: #666;
    margin-top: 5px;
    text-align: right;
}

button {
    display: block;
    width: 100%;
    padding: 12px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 18px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: #0056b3;
}

.result-group {
    margin-top: 20px;
    text-align: center;
}

.result-group h3 {
    color: #0056b3;
    margin-bottom: 10px;
}

.result-group p {
    font-size: 24px;
    font-weight: bold;
    color: #28a745;
}

/* About Section */
.about-section h2,
.formula-section h2,
.faq-section h2 {
    color: #0056b3;
    margin-top: 30px;
    margin-bottom: 15px;
    text-align: center;
}

.about-section p {
    line-height: 1.6;
    margin-bottom: 10px;
    text-align: justify;
}

/* Formula Section */
.formula-content {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.formula-box {
    background-color: #e9f7ef;
    border: 1px solid #28a745;
    border-left: 5px solid #28a745;
    padding: 15px;
    border-radius: 5px;
}

.formula-math {
    font-family: 'Courier New', Courier, monospace;
    font-size: 1.1em;
    color: #0056b3;
    display: block;
    margin-top: 5px;
}

.formula-note {
    font-size: 0.9em;
    color: #666;
    text-align: center;
    margin-top: 15px;
}

/* FAQ Section */
.faq-item {
    background-color: #f0f8ff;
    border: 1px solid #cce5ff;
    border-radius: 5px;
    margin-bottom: 10px;
    padding: 15px;
}

.faq-question {
    color: #0056b3;
    cursor: pointer;
    margin: 0;
    font-size: 1.1em;
}

.faq-answer {
    margin-top: 10px;
    padding-left: 15px;
    border-left: 3px solid #007bff;
    color: #555;
    display: none; /* Hidden by default */
}

.faq-item.active .faq-answer {
    display: block; /* Shown when active */
}

/* Footer */
.site-footer {
    text-align: center;
    padding: 20px;
    margin-top: 30px;
    color: #4a5a6a;
    font-size: 0.9em;
    border-top: 1px solid #eee;
}

.site-footer a {
    color: #0056b3;
    text-decoration: none;
}

.site-footer a:hover {
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 768px) {
    .top-menu nav ul {
        flex-direction: column;
        gap: 10px;
    }

    .top-menu nav ul li a {
        padding: 10px;
        display: block;
    }

    .language-selector {
        margin-top: 15px;
    }
}

@media (max-width: 480px) {
    .calculator-container,
    .about-section,
    .formula-section,
    .faq-section,
    .site-footer {
        margin: 10px auto;
        padding: 15px;
    }

    .input-with-unit {
        flex-direction: column;
        gap: 5px;
    }

    .input-with-unit select {
        width: 100%;
    }

    button {
        font-size: 16px;
    }

    .result-group p {
        font-size: 20px;
    }

    .formula-box {
        padding: 10px;
    }

    .faq-question {
        font-size: 1em;
    }

    .faq-answer {
        padding-left: 10px;
    }
}

.formula-section {
    background: #f7fbff;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    width: 960px;
    max-width: 98%;
    margin: 48px auto 32px auto;
    padding: 36px 32px 28px 32px;
    text-align: left;
    border-top: 3px solid #e3eafc;
}
.formula-title {
    color: #1a73e8;
    font-size: 1.7rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    letter-spacing: 0.5px;
    text-align: center;
}
.formula-content p {
    color: #4a5a6a;
    font-size: 1.08rem;
    margin-bottom: 1.2rem;
}
.formula-box {
    background: #e3eafc;
    border-radius: 10px;
    padding: 16px 18px;
    margin-bottom: 1.1rem;
    font-size: 1.08rem;
    box-shadow: 0 2px 8px rgba(26,115,232,0.04);
    border-left: 4px solid #1a73e8;
}
.formula-math {
    font-family: 'Consolas', 'Menlo', 'Monaco', monospace;
    color: #1976d2;
    font-size: 1.13rem;
    display: block;
    margin-top: 6px;
    margin-bottom: 2px;
    letter-spacing: 0.2px;
}
.formula-note {
    color: #888;
    font-size: 0.98rem;
    margin-top: 0.5rem;
    font-style: italic;
}
@media (max-width: 900px) {
    .formula-section {
        width: 98%;
        padding: 22px 8px 18px 8px;
    }
}

.seo-intro {
    background: #e3eafc;
    border-radius: 14px;
    box-shadow: 0 2px 8px rgba(26,115,232,0.04);
    margin: 32px auto 24px auto;
    padding: 18px 28px 14px 28px;
    width: 900px;
    max-width: 96%;
    color: #355;
    font-size: 1.08rem;
    line-height: 1.7;
    text-align: left;
    border-left: 4px solid #1a73e8;
}
.seo-intro strong {
    color: #1976d2;
    font-weight: 600;
}
@media (max-width: 1000px) {
    .seo-intro { width: 98%; padding: 12px 8px 10px 12px; }
}

.about-section {
    background-color: #f7fbff;
    padding: 40px 36px 32px 36px;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    width: 960px;
    max-width: 98%;
    margin-top: 40px;
    text-align: left;
    border-top: 3px solid #e3eafc;
    border-left: 4px solid #1a73e8;
}

.about-section h2 {
    color: #1a73e8;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    text-align: left;
    letter-spacing: 1px;
}

.about-section p {
    color: #6c757d;
    font-size: 1.08rem;
    line-height: 1.8;
    margin-bottom: 1.2rem;
}

.about-section p:last-child {
    margin-bottom: 0;
}

/* Media Queries for About Section */
@media (max-width: 768px) {
    .about-section {
        padding: 25px 20px 20px 20px;
        margin-top: 30px;
        width: 95%;
    }

    .about-section h2 {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .about-section p {
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .about-section {
        padding: 20px 15px 15px 15px;
        margin-top: 20px;
        border-radius: 15px;
    }

    .about-section h2 {
        font-size: 1.3rem;
        margin-bottom: 0.8rem;
    }

    .about-section p {
        font-size: 0.85rem;
    }
}

.literature-section {
    background-color: #f7fbff;
    padding: 40px 36px 32px 36px;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    width: 960px;
    max-width: 98%;
    margin-top: 40px;
    text-align: left;
    border-top: 3px solid #e3eafc;
    border-left: 4px solid #1a73e8;
}

.literature-section h2 {
    color: #1a73e8;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    text-align: center;
    letter-spacing: 1px;
}

.literature-section h3 {
    color: #1976d2;
    font-size: 1.25rem;
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
}

.literature-section p {
    color: #6c757d;
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 1rem;
}

.literature-section p:last-of-type {
    margin-bottom: 0;
}

/* Media Queries for Literature Section */
@media (max-width: 768px) {
    .literature-section {
        padding: 25px 20px 20px 20px;
        margin-top: 30px;
        width: 95%;
    }

    .literature-section h2 {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .literature-section h3 {
        font-size: 1.1rem;
        margin-top: 1rem;
        margin-bottom: 0.6rem;
    }

    .literature-section p {
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .literature-section {
        padding: 20px 15px 15px 15px;
        margin-top: 20px;
        border-radius: 15px;
    }

    .literature-section h2 {
        font-size: 1.3rem;
        margin-bottom: 0.8rem;
    }

    .literature-section h3 {
        font-size: 1rem;
        margin-top: 0.8rem;
        margin-bottom: 0.5rem;
    }

    .literature-section p {
        font-size: 0.85rem;
    }
} 