:root {
    --primary-color: #D2BDA1;
    --hover-color: #D71718;
    --text-color: #333;
    --white: #fff;
    --max-width: 1200px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Arial', sans-serif;
}

body {
    padding-top: 100px;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    width: 100%;
    padding: 0 20px;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    max-width: var(--max-width);
    margin: 0 auto;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 100px;
}

.nav-container {
    display: flex;
    align-items: center;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    margin-right: 20px;
    color: var(--text-color);
}

.nav-menu {
    display: flex;
    list-style: none;
}

.nav-item {
    position: relative;
    margin: 0 15px;
}

.nav-link {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    padding: 10px 0;
    display: flex;
    align-items: center;
    transition: color 0.3s;
    position: relative;
}

.nav-link:hover {
    color: var(--hover-color);
}

.nav-link i {
    margin-left: 5px;
    font-size: 12px;
    transition: transform 0.3s ease;
}

.nav-text {
    flex: 1;
}

.sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--primary-color);
    list-style: none;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 100;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
}

.sub-sub-menu {
    position: absolute;
    top: 0;
    left: 100%;
    background-color: var(--primary-color);
    list-style: none;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.nav-item:hover>.sub-menu {
    opacity: 1;
    visibility: visible;
}

.sub-menu-item:hover>.sub-sub-menu {
    opacity: 1;
    visibility: visible;
}

.sub-menu-item {
    position: relative;
}

.sub-link {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.3s;
    position: relative;
}

.sub-link:hover {
    background-color: var(--hover-color);
    color: var(--white);
}

.sub-link i {
    margin-left: auto;
    font-size: 12px;
    transition: transform 0.3s ease;
}

.quick-quote-btn {
    background-color: var(--hover-color);
    color: var(--white);
    border: none;
    padding: 15px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    font-size: 16px;
    transition: background-color 0.3s;
    margin-left: 20px;
}

.quick-quote-btn:hover {
    background-color: #c51617;
}

.search-toggle {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    margin-right: 15px;
    color: var(--text-color);
    transition: color 0.3s;
}

.search-toggle:hover {
    color: var(--hover-color);
}

/* Search Modal */
.search-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 2001;
    justify-content: center;
    align-items: center;
}

.search-modal-content {
    background-color: var(--white);
    padding: 30px;
    border-radius: 10px;
    width: 90%;
    max-width: 600px;
    position: relative;
}

.search-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-color);
}

.search-input-container {
    display: flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
}

#searchInput {
    flex: 1;
    padding: 12px 15px;
    border: none;
    outline: none;
    font-size: 16px;
}

.search-submit-btn {
    background-color: var(--hover-color);
    color: white;
    border: none;
    padding: 12px 20px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.search-submit-btn:hover {
    background-color: #c51617;
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 30px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    position: relative;
    overflow: hidden;
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-color);
}

.modal-title {
    margin-bottom: 20px;
    text-align: center;
    font-size: 1.8rem;
    color: var(--hover-color);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.form-group textarea {
    height: 100px;
    resize: vertical;
}

.file-upload {
    display: flex;
    align-items: center;
}

.file-upload-btn {
    background-color: #f0f0f0;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    margin-right: 10px;
    border: 1px solid #ddd;
}

.file-name {
    color: #777;
}

.submit-btn {
    background-color: var(--hover-color);
    color: var(--white);
    border: none;
    padding: 12px 25px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    width: 100%;
    transition: background-color 0.3s;
}

.submit-btn:hover {
    background-color: #c51617;
}

/* For the main navigation */
.nav-item:hover > .nav-link {
    color: var(--hover-color);
}

/* For sub-menu items */
.sub-menu-item:hover > .sub-link {
    color: var(--white) !important;
    background-color: var(--hover-color);
}

/* For sub-sub-menu items */
.sub-sub-menu li:hover > .sub-sub-link {
    color: var(--white) !important;
    background-color: var(--hover-color);
}

/* Keep the active state for current page */
.nav-link.active,
.sub-link.active,
.sub-sub-link.active {
    color: var(--hover-color) !important;
    font-weight: 600;
}

/* Mobile styles */
@media (max-width: 992px) {
    .nav-toggle {
        display: inline;
    }

    .nav-menu {
        position: fixed;
        top: 100px;
        left: 0;
        width: 100%;
        background-color: var(--white);
        flex-direction: column;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    }

    .nav-menu.active {
        max-height: 550px;
        overflow: overlay;
    }
    .nav-link i,.sub-link i{
        font-size: 16px;
    }

    .nav-item {
        margin: 0;
        border-bottom: 1px solid #eee;
    }

    .nav-link {
        padding: 15px 20px;
        justify-content: space-between;
    }

    .nav-icon {
        margin-left: 10px;
        transition: transform 0.3s ease;
    }

    .nav-icon.rotated {
        transform: rotate(90deg);
    }

    .sub-menu {
        position: static;
        background-color: #f9f9f9;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        display: none;
    }

    .sub-menu.active {
        max-height: 1000px;
        display: block;
    }

    .sub-sub-menu {
        position: static;
        background-color: #f0f0f0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s;
        display: none;
        opacity: 1;
        visibility: visible;
    }

    .sub-sub-menu.active {
        max-height: 550px;
        display: block;
    }

    .sub-link {
        padding: 12px 20px 12px 30px;
        justify-content: space-between;
    }

    .sub-sub-link {
        padding: 12px 20px 12px 60px;
    }

    .quick-quote-btn {
        margin-left: 0;
    }

    .nav-link.active,
    .sub-link.active,
    .sub-sub-link.active {
        background-color: transparent;
        color: var(--hover-color) !important;
    }
}

@media (max-width: 576px) {
    .modal-content {
        top: 0;
        transform: none;
        margin: 30% auto;
        max-height: 500px;
        overflow-y: auto;
    }
    .quick-quote-btn{
        padding: 15px 10px;
    }
}