/* --- General Styles --- */
:root {
    --primary-color: #1a237e;
    /* Dark Blue */
    --secondary-color: #4caf50;
    /* Green */
    --background-light: #f9fafb;
    --text-color: #333;
    --card-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

body {
    font-family: 'Roboto', 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--background-light);
}

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

h1,
h2,
h3 {
    color: var(--primary-color);
}

h2 {
    text-align: center;
    font-size: 2.5em;
    margin-bottom: 50px;
    position: relative;
    padding-bottom: 15px;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--secondary-color);
}

section {
    padding: 80px 0;
}

/* --- Header --- */
header {
    background-color: #ffffff;
    padding: 15px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5em;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
}

nav a {
    margin: 0 15px;
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.3s;
}

nav a:hover {
    color: var(--secondary-color);
}

/* --- Hero Section --- */
#hero {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('https://images.unsplash.com/photo-1619566636858-57a2a24b1301?q=80&w=2070&auto=format&fit=crop') no-repeat center center/cover;
    color: white;
    text-align: center;
    padding: 120px 0;
    /* Default for desktop */
}

@media (max-width: 768px) {
    #hero {
        padding: 60px 0;
        /* Specific for mobile */
    }
}

#hero h1 {
    font-size: 3em;
    margin-bottom: 20px;
    color: #fff;
}

#hero p {
    font-size: 1.2em;
    max-width: 700px;
    margin: 0 auto 30px;
}

.cta-button {
    display: inline-block;
    background-color: var(--secondary-color);
    color: white;
    padding: 15px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1em;
    transition: background-color 0.3s, transform 0.3s;
}

.cta-button:hover {
    background-color: #45a049;
    transform: translateY(-2px);
}

/* --- Advantages Section --- */
#advantages {
    background-color: #fff;
}

.advantages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    text-align: center;
}

.advantage-item {
    padding: 30px;
    border-radius: 8px;
    background-color: var(--background-light);
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.advantage-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.advantage-item i {
    font-size: 3em;
    color: var(--secondary-color);
    margin-bottom: 20px;
}

.advantage-item h3 {
    font-size: 1.5em;
    margin-bottom: 10px;
}

/* --- New Inspection Reports Section Styles --- */
#inspection-reports {
    background-color: #fff;
}

.inspection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.inspection-item {
    text-align: center;
    padding: 30px;
    border-radius: 8px;
    background-color: var(--background-light);
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.inspection-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.inspection-item i {
    font-size: 3em;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.inspection-item h3 {
    font-size: 1.4em;
    margin-bottom: 15px;
}

.download-link {
    display: inline-block;
    background-color: var(--secondary-color);
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s, transform 0.3s;
}

.download-link:hover {
    background-color: #45a049;
    transform: translateY(-2px);
}

/* --- Products Section --- */
#products {
    background-color: #fff;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.product-item {
    text-align: center;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease;
}

.product-item:hover {
    transform: translateY(-5px);
}

.product-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.product-item h3 {
    padding: 20px;
    margin: 0;
}

/* --- Contact Section --- */
#contact .cta-phrase {
    font-size: 1.8em;
    font-weight: 700;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 15px;
    font-style: italic;
}

#contact p {
    text-align: center;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.contact-info {
    max-width: 600px;
    margin: 40px auto;
    text-align: center;
    font-size: 1.1em;
}

.contact-info p {
    margin: 15px 0;
}

.contact-info a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
}

.contact-info a:hover {
    text-decoration: underline;
}

.whatsapp-button {
    display: inline-block;
    background-color: #25D366;
    color: white;
    padding: 12px 25px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    margin-top: 20px;
    transition: background-color 0.3s ease;
}

.whatsapp-button:hover {
    background-color: #25D366;
}

.telegram-button {
    display: inline-block;
    background-color: #0088CC;
    color: white;
    padding: 12px 25px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    margin-top: 20px;
    transition: background-color 0.3s ease;
}

.telegram-button:hover {
    background-color: #0088CC;
}

/* New Contact Form Styles */
.contact-form-container {
    max-width: 600px;
    margin: 60px auto 0;
    padding: 40px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: var(--card-shadow);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.contact-form-container h3 {
    font-size: 1.8em;
    margin-bottom: 10px;
}

.contact-form-container p {
    margin-bottom: 30px;
    color: #666;
}

#contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
}

#contact-form input,
#contact-form textarea {
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1em;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

#contact-form input:focus,
#contact-form textarea:focus {
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.2);
    outline: none;
}

#contact-form textarea {
    min-height: 120px;
    resize: vertical;
}

#contact-form button {
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

#contact-form button:hover {
    transform: translateY(-2px);
}

/* CAPTCHA Styles */
.captcha-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.captcha-container label {
    font-size: 1.2em;
    color: var(--primary-color);
    font-weight: bold;
}

.captcha-container input {
    max-width: 150px;
    margin: 0 auto;
    font-size: 1.2em;
}

/* Error Message Styles */
.error-message {
    color: #f44336;
    font-size: 0.9em;
    margin-top: -15px;
    display: none;
    text-align: left;
}

/* --- Footer --- */
footer {
    background-color: var(--primary-color);
    color: white;
    text-align: center;
    padding: 20px 0;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    h2 {
        font-size: 2em;
    }

    #hero h1 {
        font-size: 2.2em;
    }

    header .container {
        flex-direction: column;
    }

    nav {
        margin-top: 15px;
    }

    nav a {
        margin: 0 10px;
    }

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

@media (max-width: 600px) {
    .contact-form-container {
        padding: 20px;
    }

    #contact-form input,
    #contact-form textarea {
        font-size: 0.9em;
        padding: 12px;
    }

    .cta-button {
        padding: 12px 25px;
        font-size: 1em;
    }

    .captcha-container label {
        font-size: 1em;
    }

    .captcha-container input {
        font-size: 1em;
        max-width: 120px;
    }

    .error-message {
        font-size: 0.8em;
        margin-top: -10px;
    }
}

#about .image-container {
    display: flex;
    justify-content: center;
    margin-top: 40px;
    margin-bottom: 40px;
}

#about .image-container img {
    max-width: 80%;
    /* برای 반응‌گرا بودن */
    height: auto;
    border-radius: 8px;
    /* اختیاری: برای گرد کردن گوشه‌ها */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    /* اختیاری: برای دادن سایه */
}

@media (max-width: 768px) {
    #about .image-container img {
        max-width: 95%;
    }
}

#form-message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

#form-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* --- Progress Bars for Partial Orders (New) --- */
.progress-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.progress-item {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: var(--card-shadow);
    text-align: left;
    transition: transform 0.3s ease;
    border: 1px solid #e0e0e0;
    /* Container-like border */
}

.progress-item:hover {
    transform: translateY(-3px);
}

.progress-item label {
    display: block;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--primary-color);
    font-size: 1.2em;
}

.progress-bar {
    height: 20px;
    background-color: #e0e0e0;
    /* Neutral background like container */
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    background: linear-gradient(to right, #f5f5f5, #e0e0e0);
    /* Subtle container texture */
}

.progress-fill {
    height: 100%;
    background: linear-gradient(to right, #673ab7, #2196f3);
    /* Gradient like attached image: purple to blue */
    transition: width 0.5s ease-in-out;
    /* Smooth animation */
}

.progress-label {
    display: block;
    text-align: right;
    margin-top: 5px;
    font-weight: bold;
    color: var(--text-color);
    position: relative;
}

.progress-label::after {
    content: '';
    position: absolute;
    top: -35px;
    /* Bubble position like image */
    right: 0;
    background-color: #333;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.9em;
    display: none;
    /* Optional: can show on hover if needed */
}

@media (max-width: 768px) {
    .progress-container {
        grid-template-columns: 1fr;
        /* Single column for mobile */
    }

    .progress-item {
        padding: 15px;
        /* Optimized for smaller screens */
    }
}

/* Responsive for New Inspection Section */
@media (max-width: 768px) {
    .inspection-grid {
        grid-template-columns: 1fr;
    }

    .inspection-item {
        padding: 20px;
    }

    .inspection-item h3 {
        font-size: 1.2em;
    }
}