/* Asphalt Calculator - Main Stylesheet */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', 'Helvetica', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 768px;
    margin: 0 auto;
    padding: 0 30px;
}

/* Navigation Bar Styles */
nav {
    background-color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border-bottom: 1px solid #e0e0e0;
}

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

.nav-left, .nav-right {
    flex: 1;
    display: flex;
}

.nav-center {
    flex: 2;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

.nav-right {
    justify-content: flex-end;
}

.menu-btn {
    background: none;
    border: none;
    color: #333;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.3s;
}

.menu-btn:hover {
    color: #666;
}

.logo {
    width: 32px;
    height: 32px;
    border-radius: 50%;
}

.nav-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin: 0;
}

/* Main Content Area */
main {
    padding: 0;
}

/* Hero Section */
.hero-section {
    background: #000000;
    color: white;
    padding: 4rem 0;
    text-align: center;
    margin-bottom: 24px;
}

.hero-section h1 {
    font-size: 32px;
    font-weight: 400;
    margin: 0;
    letter-spacing: 1px;
    line-height: 1.2;
}

.hero-section p {
    font-size: 16px;
    margin-top: 1.5rem;
    opacity: 0.9;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Calculator Section */
.calculator-section {
    background: white;
    border-radius: 10px;
    padding: 20px;
    margin: 24px auto;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.input-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-bottom: 24px;
}

.input-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-width: 0;
}

.input-field label {
    font-weight: bold;
    color: #2c3e50;
}

.input-row {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.input-row input {
    flex: 2;
    min-width: 0;
    padding: 0.7rem;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
}

.input-row select {
    flex: 1;
    min-width: 100px;
    padding: 0.7rem;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    background-color: white;
}

.input-row input:focus,
.input-row select:focus {
    outline: none;
    border-color: #3498db;
}

/* Results Display Area */
.results-section {
    background: #ecf0f1;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 24px;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 24px;
}

.result-item {
    background: white;
    padding: 1rem;
    border-radius: 5px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.result-item h3 {
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.result-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: #e74c3c;
}

/* Additional Parameters Area */
.additional-params {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-bottom: 24px;
}

/* Article Content Styles */
.article-section {
    background: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 24px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.article-section h2 {
    color: #2c3e50;
    font-size: 28px;
    margin-bottom: 24px;
    text-align: center;
    border-bottom: 3px solid #3498db;
    padding-bottom: 0.5rem;
    line-height: 1.3;
}

.article-section h3 {
    color: #2c3e50;
    font-size: 24px;
    margin-top: 24px;
    margin-bottom: 16px;
    border-left: 4px solid #e74c3c;
    padding-left: 1rem;
    line-height: 1.4;
}

.article-section h4 {
    color: #34495e;
    font-size: 1.2rem;
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
}

.article-section p {
    margin-bottom: 16px;
    text-align: justify;
    line-height: 1.75;
}

.article-section ul, .article-section ol {
    margin-bottom: 16px;
    padding-left: 2rem;
}

.article-section li {
    margin-bottom: 8px;
    line-height: 1.6;
}

/* Sidebar Styles */
.sidebar {
    position: fixed;
    top: 0;
    left: -300px;
    width: 300px;
    height: 100vh;
    background: #f8f9fa;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    transition: left 0.3s ease;
    z-index: 1000;
    padding: 20px;
    overflow-y: auto;
}

.sidebar.active {
    left: 0;
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #dee2e6;
}

.sidebar-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #000;
    margin: 0;
}

.sidebar-nav {
    list-style: none;
    padding: 4px 0;
    margin: 0;
}

.sidebar-nav li {
    margin-bottom: 0px;
}

.sidebar-nav a {
    display: block;
    color: #000;
    text-decoration: none;
    padding: 8px 0;
    border-radius: 0;
    transition: background-color 0.3s;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.2;
    text-align: left;
}

.sidebar-nav a:hover {
    background-color: #f0f0f0;
}

.sidebar-section {
    margin-top: 30px;
}

.sidebar-section-title {
    font-size: 21px;
    font-weight: 400;
    color: #999;
    margin-bottom: 15px;
    text-transform: none;
    letter-spacing: 0;
    text-align: left;
}

/* Overlay */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.5);
    display: none;
    z-index: 999;
}

.sidebar-overlay.active {
    display: block;
}

/* Footer Styles */
.footer-link {
    color: #333;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #007bff;
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 900px) {
    .input-group {
        grid-template-columns: 1fr;
    }

    .additional-params {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    nav {
        background-color: white;
    }

    .nav-container {
        padding: 0 20px;
    }

    .container {
        padding: 0 20px;
    }

    .nav-title {
        font-size: 1rem;
    }

    .logo {
        width: 28px;
        height: 28px;
    }

    .menu-btn {
        font-size: 0.8rem;
        padding: 0.3rem;
    }

    .hero-section {
        padding: 2rem 0;
    }

    .hero-section h1 {
        font-size: 2.5rem;
        letter-spacing: 1px;
    }

    .hero-section p {
        font-size: 1rem;
        padding: 0 1rem;
    }

    .results-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .breadcrumb {
        padding: 0.5rem 0;
    }
    
    .breadcrumb-nav {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .nav-title {
        font-size: 0.9rem;
    }

    .logo {
        width: 24px;
        height: 24px;
    }

    .hero-section h1 {
        font-size: 2rem;
    }

    .results-grid {
        grid-template-columns: 1fr;
    }

    .footer-links {
        flex-direction: column;
        gap: 1rem;
    }
}