/* Montserrat (Variable Font for all weights) */
@font-face {
    font-family: 'Montserrat';
    src: url('fonts/Montserrat-VariableFont_wght.woff2') format('woff2-variations');
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

/* Lato (Regular weight) */
@font-face {
    font-family: 'Lato';
    src: url('fonts/Lato-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2c5530;
    --secondary-color: #4a7856;
    --accent-color: #8fbc8f;
    --text-color: #333;
    --light-bg: #f5f5f5;
    --white: #ffffff;
}

body {
    font-family: 'Lato', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
}

/* Headings */
h1, h2, h3, h4 {
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 700;
}

/* Adjust specific elements */
.navbar .logo h1,
.cta-button,
.cookie-btn,
.filter-btn,
.project-btn,
.footer-section h3,
.keyfact span {
    font-family: 'Montserrat', sans-serif !important;
}

/* Ensure icons use their correct font */
i {
    font-family: initial;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    background-color: var(--white);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    z-index: 1000;
}

.logo {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 40px;
    width: auto;
    transition: transform 0.3s ease;
}

.logo-img:hover {
    transform: scale(1.05);
}

.logo h1 {
    color: var(--primary-color);
    font-size: 1.8rem;
}

.nav-links {
    display: flex;
    align-items: center;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    margin-left: 2rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--primary-color);
}

/* Hero Section */
.hero {
    height: 100vh;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)),
                url('img/hero.jpg') no-repeat center center/cover;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    padding: 0 1rem;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.cta-button {
    display: inline-block;
    padding: 1rem 2rem;
    background-color: var(--primary-color);
    color: var(--white);
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.cta-button:hover {
    background-color: var(--secondary-color);
}

/* Services Section */
.services {
    padding: 5rem 10%;
    background-color: var(--light-bg);
}

.services h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

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

.service-card {
    background-color: var(--white);
    padding: 2.5rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

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

.service-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.service-card h3 {
    color: var(--primary-color);
    font-size: 1.8rem;
    margin: 0;
}

.service-card h4 {
    color: var(--secondary-color);
    font-size: 1.2rem;
    margin: 0;
    font-weight: 500;
}

.service-card p {
    color: var(--text-color);
    line-height: 1.6;
    margin: 0;
}

.service-features {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}

.service-features li {
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: var(--text-color);
}

.service-features i {
    font-size: 1rem;
    color: var(--primary-color);
    margin: 0;
}

.learn-more-btn {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-top: auto;
}

.learn-more-btn:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* Service Details Modal */
.service-details-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.service-details-modal.active {
    display: flex;
}

.service-details-content {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 10px;
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.close-modal {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 1.5rem;
    color: var(--text-color);
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.5rem;
    transition: color 0.3s ease;
}

.close-modal:hover {
    color: var(--primary-color);
}

.service-details {
    display: none;
}

.service-details.active {
    display: block;
}

.service-details h3 {
    color: var(--primary-color);
    font-size: 2rem;
    margin-bottom: 1rem;
}

.service-details p {
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

@media screen and (max-width: 768px) {
    .service-card {
        padding: 1.5rem;
    }

    .service-card h3 {
        font-size: 1.5rem;
    }

    .service-card h4 {
        font-size: 1.1rem;
    }

    .service-details-content {
        padding: 1.5rem;
    }
}

/* Projects Section */
.projects {
    padding: 5rem 10%;
}

.projects h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.project-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.5rem 1.5rem;
    background-color: var(--light-bg);
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    color: var(--text-color);
}

.filter-btn:hover,
.filter-btn.active {
    background-color: var(--primary-color);
    color: var(--white);
}

.project-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.project-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

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

.project-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.project-item:hover img {
    transform: scale(1.05);
}

.project-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.5rem;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: var(--white);
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.project-item:hover .project-info {
    transform: translateY(0);
}

.project-info h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.project-location {
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.project-btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: var(--primary-color);
    color: var(--white);
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.project-btn:hover {
    background-color: var(--secondary-color);
}

/* Project Details Modal */
.project-details-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.project-details-modal.active {
    display: flex;
}

.project-details-content {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 10px;
    max-width: 1000px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.project-details-modal.active .project-details-content {
    animation: modalFadeIn 0.3s ease;
}

.project-details {
    display: none;
}

.project-details.active {
    display: block;
}

.project-gallery-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.project-image {
    position: relative;
    border-radius: 5px;
    overflow: hidden;
}

.project-image h4 {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 0.5rem;
    background: rgba(0,0,0,0.7);
    color: var(--white);
    font-size: 0.9rem;
}

.project-gallery-details img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.project-gallery-details img:hover {
    transform: scale(1.05);
}

.close-modal {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 1.5rem;
    color: var(--text-color);
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.5rem;
    transition: color 0.3s ease;
}

.close-modal:hover {
    color: var(--primary-color);
}

.project-description {
    margin-top: 2rem;
}

.project-description h4 {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.project-description ul {
    list-style: none;
    padding: 0;
}

.project-description li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

.project-description li:before {
    content: "•";
    color: var(--primary-color);
    position: absolute;
    left: 0;
}

@media screen and (max-width: 768px) {
    .project-filters {
        flex-direction: column;
        align-items: center;
    }

    .filter-btn {
        width: 100%;
        max-width: 300px;
    }

    .project-gallery {
        grid-template-columns: 1fr;
    }

    .project-details-content {
        padding: 1.5rem;
    }

    .project-gallery-details {
        grid-template-columns: 1fr;
    }
}

/* About Section */
.about {
    padding: 5rem 10%;
    background-color: var(--light-bg);
}

.about-flex {
    display: flex;
    gap: 4rem;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
}

.about-keyfacts {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    flex: 1;
}

.about-textblock {
    flex: 1;
    padding: 2rem;
    background-color: var(--white);
    border-radius: 10px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
}

.about-textblock p {
    margin-bottom: 1rem;
}

.keyfact {
    background-color: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.keyfact i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.keyfact span {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
}

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

.about-image {
    flex: 1;
    max-width: 500px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
}

@media screen and (max-width: 900px) {
    .about-flex {
        flex-direction: column;
        gap: 2rem;
    }

    .about-keyfacts {
        order: 2;
    }

    .keyfact {
        padding: 1rem;
    }

    .keyfact i {
        font-size: 1.5rem;
    }

    .keyfact span {
        font-size: 1rem;
    }

    .about-textblock {
        order: 1;
    }
}

@media screen and (max-width: 600px) {
    .about-flex {
        gap: 1.5rem;
    }

    .about-textblock {
        padding: 1.5rem;
    }

    .about-keyfacts {
        grid-template-columns: 1fr;
    }
}

.about-simple-text {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
    background-color: var(--white);
    border-radius: 10px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
}

.about-simple-text p {
    margin-bottom: 1rem;
}

@media screen and (max-width: 600px) {
    .about-simple-text {
        padding: 1.5rem;
    }
}

/* Contact Section */
.contact {
    padding: 5rem 10%;
}

.contact h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-form input,
.contact-form textarea {
    padding: 1rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: 'Lato', sans-serif;
}

.contact-form textarea {
    min-height: 150px;
    resize: vertical;
}

.submit-button {
    padding: 1rem 2rem;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.submit-button:hover {
    background-color: var(--secondary-color);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.info-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

/* Footer */
footer {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 4rem 5% 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

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

.footer-section h3 {
    color: var(--white);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.footer-section h3 + p {
    margin-bottom: 1rem;
}

.footer-section .info-item:first-of-type {
    margin-bottom: 1rem;
}

.footer-section .info-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.footer-section a {
    color: var(--white);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: var(--accent-color);
}

.footer-bottom {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
}

.footer-logo-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--white);
    text-decoration: none;
}

.footer-caption {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.navbar .nav-links {
    display: flex;
    align-items: center;
}

.burger {
    display: none;
}

.burger div {
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    margin: 5px;
    transition: all 0.3s ease;
}

@keyframes navLinkFade {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--white);
    padding: 1rem 5%;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    z-index: 1000;
    display: none;
}

.cookie-banner.active {
    display: block;
}

.cookie-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.cookie-text {
    flex: 1;
}

.cookie-buttons {
    display: flex;
    gap: 1rem;
}

.cookie-btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.accept-btn {
    background-color: var(--primary-color);
    color: var(--white);
}

.accept-btn:hover {
    background-color: var(--secondary-color);
}

.settings-btn {
    background-color: var(--light-bg);
    color: var(--text-color);
}

.settings-btn:hover {
    background-color: #e0e0e0;
}

.cookie-settings {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.cookie-settings.active {
    display: flex;
}

.cookie-settings-content {
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.cookie-settings-content h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.cookie-option {
    margin: 1.5rem 0;
    padding: 1rem;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.cookie-option-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.cookie-option-header h4 {
    color: var(--primary-color);
    margin: 0;
}

.cookie-option-header p {
    color: var(--text-color);
    margin: 0;
    font-size: 0.9rem;
}

.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
}

input:checked + .slider {
    background-color: var(--primary-color);
}

input:disabled + .slider {
    background-color: #e0e0e0;
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}

.cookie-settings-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 2rem;
}

.about h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.map-placeholder {
    width: 100%;
    min-height: 180px;
    background: #f5f5f5;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    color: #444;
    font-size: 1rem;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

#mapPlaceholder .cookie-btn {
    margin-top: 0.5rem;
}

@media screen and (max-width: 600px) {
    .map-placeholder {
        min-height: 120px;
        font-size: 0.95rem;
    }
}

.legal-page .container {
    max-width: 800px;
    margin: 120px auto 50px;
    padding: 2rem;
    background: var(--white);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.legal-page .container h1 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    text-align: center;
}

.legal-page .container h2 {
    color: var(--primary-color);
    margin: 2rem 0 1rem;
}

.legal-page .container h3 {
     color: var(--secondary-color);
     margin: 1.5rem 0 1rem;
}

.legal-page .container p {
    margin-bottom: 1rem;
    line-height: 1.6;
}

.legal-page .container ul {
    margin-bottom: 1rem;
    padding-left: 20px;
}

.legal-page .container li {
    margin-bottom: 0.5rem;
}

.legal-page .back-link {
    display: inline-block;
    margin-top: 2rem;
    color: var(--primary-color);
    text-decoration: none;
}

.legal-page .back-link:hover {
    color: var(--secondary-color);
}

#backToTopBtn {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 99;
    border: none;
    outline: none;
    background-color: var(--primary-color);
    color: var(--white);
    cursor: pointer;
    padding: 15px;
    border-radius: 10px;
    font-size: 18px;
    transition: opacity 0.3s ease-in-out;
    opacity: 0;
    text-decoration: none;
    line-height: 0;
}

#backToTopBtn:hover {
    background-color: var(--secondary-color);
}

#backToTopBtn.show {
    opacity: 1;
}

@media (max-width: 600px) {
    #backToTopBtn {
        bottom: 20px;
        right: 20px;
        padding: 12px;
        font-size: 16px;
    }
}

@media screen and (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background-color: var(--white);
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2rem;
        transition: right 0.3s ease-in-out;
        z-index: 999;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        margin: 0;
        font-size: 1.5rem;
        color: var(--text-color);
        text-decoration: none;
        transition: color 0.3s ease;
    }

    .nav-links a:hover {
        color: var(--primary-color);
    }

    .mobile-menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 21px;
        cursor: pointer;
        z-index: 1000;
        position: relative;
    }

    .mobile-menu-toggle span {
        display: block;
        width: 100%;
        height: 3px;
        background-color: var(--text-color);
        border-radius: 3px;
        transition: all 0.3s ease;
    }

    .mobile-menu-toggle.active span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }

    .mobile-menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-toggle.active span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }

    .navbar {
        padding: 1rem 5%;
    }

    .hero {
        padding-top: 60px;
        height: calc(100vh - 60px);
    }

    .services-grid,
    .project-gallery,
    .contact-container {
        grid-template-columns: 1fr;
    }

    .logo-img {
        height: 35px;
    }

    .cookie-content {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-buttons {
        width: 100%;
        justify-content: center;
    }

    .cookie-settings-content {
        width: 95%;
        padding: 1rem;
    }

    .cookie-option-header {
        flex-direction: column;
        align-items: flex-start;
    }
}