/* Importing Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Dancing+Script:wght@400;500;600;700&family=Great+Vibes&family=Merriweather:wght@400;700&family=Libre+Baskerville:wght@400;700&display=swap');


/* global CSS */

:root {
    --primary-color: #314f3a; /* Muted green from the leaves */
    --secondary-color: #B5C5AC; /* Light, natural green from the lighter leaves */
    --alternative-color:#1516; /* Mixed, natural green from the two leaves */
    --accent-color: #E2DED3; /* Soft, warm beige from the background */
    --text-color: #3B3B3B; /* Dark, natural brown from the main text */
    --background-color: #F2EAD3; /* Light, warm cream */
    --backdrop-color: #7e694938; /* Deep, warm cream to compliment the bg*/
    --light-gray: #EDECE6; /* Soft, natural light gray */
    --medium-gray: #888; /* Soft, natural medium gray */    
    --script-font: 'Libre Baskerville', cursive;
    --serif-font: 'Merriweather', serif;
}


/* Global Styles */
body {
    font-family: var(--serif-font);
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    margin: 0;
    padding: 0;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--script-font);
    color: var(--primary-color);
}

a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

/* js dependant */

/* For fade-in elements */

.fade-in {
    opacity: 0;
    transition: opacity 1s ease-in;
}

.fade-in.visible {
    opacity: 1;
}


/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    overflow: hidden;
}

/* Navigation */
.logopeda-nav {
    background-color: var(--primary-color);
    padding: 1rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

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

.logopeda-nav .logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: white;
}

.logopeda-nav .logo img {
    height: 80px; 
    margin-right: 10px; 
    background-color: #cbccc2;
    border-radius: 5px;
    padding:5px;
}

.logopeda-nav ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.logopeda-nav ul li {
    margin-left: 1.5rem;
}

.logopeda-nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: 800;
    transition: color 0.3s ease;
    font-size: 1.5rem;
}

.logopeda-nav ul li a:hover {
    color: var(--accent-color);
}

.burger-menu {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.burger-menu span {
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 2px 0;
    transition: 0.4s;
}

/* Breadcrumbs */
.breadcrumbs {
    background-color: var(--light-gray);
    padding: 0.5rem 1rem;
    margin-bottom: 1rem;
    border-radius: 5px;
    font-size: 0.9rem;
}

.breadcrumbs a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

/* Hero Section */
.hero {
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    padding: 8rem 2rem;
    position: relative;
}

.hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
}

.hero-content {
    position: relative;
    z-index: 1;
}

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

/* Sections */
section {
    padding: 4rem 12rem;
}

/* Buttons */
.cta-button, .read-more {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

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

.cta-button-light-bg, .read-more-light-bg {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.cta-button-light-bg:hover, .read-more-light-bg:hover {
    background-color: var(--alternative-color);
}

/* Blog Layout */
.blog-layout {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-top: 40px;
}

#blog-posts {
    flex: 1;
    max-width: 100%;
}

#blog-sidebar {
    flex: 0 0 25%;
    margin-left: 5%;
}

/* Blog Post Styles */
.blog-post {
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--light-gray);
    padding-bottom: 2rem;
    overflow: hidden;
}

.blog-post-thumbnail {
    width: 250px;
    height: 250px;
    object-fit: cover;
    float: left;
    margin: 0 20px 20px 0;
}

.blog-post h2 {
    margin-top: 0;
}

.post-meta {
    color: #777;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.post-excerpt {
    margin-bottom: 1rem;
}

/* Individual blog post image */
.blog-post-image {
    max-width: 500px;
    max-height: 500px;
    width: auto;
    height: auto;
    object-fit: contain;
    float: left;
    margin: 0 40px 20px 0;
}

/* Forms */
form input[type="text"],
form input[type="email"],
form input[type="tel"],
form textarea {
    width: 100%;
    padding: 0.75rem;
    margin-bottom: 1rem;
    border: 1px solid var(--light-gray);
    border-radius: 5px;
}

form input[type="submit"] {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

form input[type="submit"]:hover {
    background-color: var(--secondary-color);
}

/* Footer */
.logopeda-footer {
    background-color: var(--primary-color);
    color: white;
    padding: 2rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}

.footer-section {
    flex: 1;
    margin-right: 2rem;
    margin-bottom: 1rem;
}

.footer-section h3 {
    color: white;
}

.social-icons a {
    color: white;
    margin-right: 1rem;
}

/* Call Back and Meeting Buttons and Modal */

/* Base styles for the buttons */
.call-back-button, .meeting-button {
    background-color: var(--primary-color);
    color: white;
    padding: 15px;
    border-radius: 5px;
    text-align: center;
    font-size: 16px;
    position: fixed;
    bottom: 20px;
    z-index: 1000;
    box-sizing: border-box; 
}

.call-back-button:hover, .meeting-button:hover {
    background-color: var(--secondary-color);
}

/* Positioning the buttons side by side at the bottom right on desktop */
.call-back-button {
    right: 160px;
}

.meeting-button {
    right: 20px;
}

/* Mobile adjustments */
@media (max-width: 480px) {
    .call-back-button, .meeting-button {
        position: fixed;
        bottom: 0;
        width: 50%;
        height: auto;
        border-radius: 0;
        padding: 10px;
        font-size: 14px;
    }

    .call-back-button {
        left: 0;
        border-right: 1px solid white;
    }

    .meeting-button {
        right: 0;
    }
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.4); 
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 5px;
    box-sizing: border-box; 
}

@media (max-width: 480px) {
    .modal-content {
        width: 90%;
        margin: 10% auto; 
    }
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

/* Form elements within the modal */
.modal-content form {
    display: flex;
    flex-direction: column;
    gap: 15px; 
}

.modal-content label {
    font-weight: bold;
    margin-bottom: 5px;
}

.modal-content .consent-container {
    display: flex;
    align-items: center;
    gap: 5px;
}

.modal-content .consent-container input[type="checkbox"] {
    margin-right: 2px; 
}

.modal-content input[type="text"],
.modal-content input[type="email"],
.modal-content input[type="tel"],
.modal-content textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid var(--light-gray);
    border-radius: 5px;
    box-sizing: border-box;
    font-size: 14px;
}

.modal-content input[type="submit"]:hover {
    background-color: var(--secondary-color);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.2);
}

.modal-content input,
.modal-content textarea {
    max-width: 100%;
    box-sizing: border-box;
}


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

.service-card {
    background-color: var(--backdrop-color);
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    transition: transform 0.3s ease;
}

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

.service-card img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
    margin-bottom: 1rem;
}

/* Testimonial Slider  */
.tns-outer {
    position: relative;
}

.tns-nav {
    text-align: center;
    margin-top: 20px;
}

.tns-nav button {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--medium-gray);
    border: none;
    margin: 0 5px;
    padding: 0;
}

.tns-nav button.tns-nav-active {
    background: var(--primary-color);
}

.testimonial-slider {
    overflow: hidden;
}

.testimonial {
    background-color: var(--backdrop-color);
    border-radius: 10px;
    padding: 2rem;
    margin-bottom: 1rem;
}

.testimonial p {
    font-style: italic;
    margin-bottom: 1rem;
}

.client-name {
    font-weight: bold;
    text-align: right;
}

/* Why Choose Us */
#per-que-nosaltres ul {
    list-style-type: none;
    padding-left: 0;
}

#per-que-nosaltres li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

#per-que-nosaltres li::before {
    content: '✓';
    color: var(--primary-color);
    position: absolute;
    left: 0;
}

/* Contact Section */
#contacte {
    background-color: var(--secondary-color);
    color: white;
    text-align: center;
    padding: 4rem 2rem;
}

#contacte h2 {
    color: white;
}

/* Blog Sidebar Styles */
#blog-sidebar {
    background-color: var(--light-gray);
    padding: 1.5rem;
    border-radius: 5px;
    margin-left: 0px;
}

#blog-sidebar h3 {
    margin-top: 40px;
}

#blog-sidebar ul {
    list-style-type: none;
    padding-left: 0;
}

#blog-sidebar li {
    margin-bottom: 0.5rem;
}

/* Individual Blog Article Styles */
.blog-article {
    max-width: 80vw;
    margin: 0 auto;
    padding: 2rem 1rem;
    text-align: justify;

}

.blog-article header {
    text-align: center;
    margin-bottom: 5rem;
}

.blog-article .article-main-image {
    width: 100%;
    height: auto;
    border-radius: 5px;
    margin-bottom: 2rem;
}

.article-content {
    padding: 0 0 4rem 0;
}

.article-content h2 {
    margin-top: 2rem;
}

.article-content p {
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.blog-article footer {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--light-gray);
}

/* Social Share Buttons */
.social-share {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--light-gray);
}

.social-share h4 {
    margin-bottom: 1rem;
}

.share-button {
    display: inline-block;
    padding: 0.5rem 1rem;
    margin-right: 0.5rem;
    color: white;
    border-radius: 5px;
    text-decoration: none;
    font-size: 0.9rem;
}

.share-button.facebook {
    background-color: #3b5998;
}

.share-button.twitter {
    background-color: #1da1f2;
}

.share-button.linkedin {
    background-color: #0077b5;
}

.share-button:hover {
    opacity: 0.8;
}

/* Responsive Design */
@media (max-width: 768px) {
    .logopeda-nav ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--primary-color);
        padding: 1rem;
    }

    .logopeda-nav ul.show {
        display: flex;
    }

    .logopeda-nav ul li {
        margin: 0.5rem 0;
    }

    .burger-menu {
        display: flex;
    }

    .blog-layout {
        flex-direction: column;
    }

    #blog-posts, #blog-sidebar {
        flex: 0 0 100%;
        max-width: 100%;
    }

    #blog-sidebar {
        margin-left: 0;
        margin-top: 40px;
    }

    .blog-post-thumbnail,
    .blog-post-image {
        width: 100%;
        height: auto;
        float: none;
        margin: 0 0 20px 0;
    }

    .hero h1 {
        font-size: 2rem;
    }
    
    .footer-content {
        flex-direction: column;
    }
    
    .footer-section {
        margin-right: 0;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        width: 95%;
    }
}

@media (max-width: 480px) {
    section {
        padding: 2rem 1rem;
    }
    
    .hero {
        padding: 4rem 1rem;
    }
}