/* --- Global Styles & Variables --- */
:root {
    --primary-color: #283593; /* Indigo (professional, pairs with gold) */
    --secondary-color: #546e7a; /* Blue Grey (modern, professional) */
    --accent-color: #ffc107; /* Gold accent remains */
    --light-bg-1: #f5f7fa; /* Light cool gray */
    --light-bg-2: #fdf6e3; /* Light cream, complements gold */
    --text-dark: #212121; /* Deep neutral for text */
    --text-light: #607d8b; /* Muted blue-grey for secondary text */
    --white: #ffffff;
    --border-color: #cfd8dc; /* Soft blue-grey border */
    --font-family: 'Inter', sans-serif;
}

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

body {
    font-family: var(--font-family);
    color: var(--text-dark);
    line-height: 1.6;
    background-color: var(--white);
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.text-center {
    text-align: center;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* --- Typography --- */
h1,
h2,
h3 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
    color: var(--text-dark);
}

h2 {
    font-size: 2rem;
    color: var(--primary-color);
}

h3 {
    font-size: 1.25rem;
}

p {
    margin-bottom: 1rem;
    color: var(--text-light);
}

ul {
    list-style-type: none;
}

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

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* --- Header & Navigation --- */
.site-header {
    background: var(--white);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

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

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

.main-nav ul {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 600;
}

.main-nav a:not(.btn):hover {
    color: var(--primary-color);
}

.hamburger {
    display: none;
    font-size: 2rem;
    background: none;
    border: none;
    cursor: pointer;
}

/* --- Sections --- */
section {
    padding: 4rem 0;
}

.section-title span {
     color: var(--secondary-color);
    font-weight: 600;
    font-style: italic;
    /* display: block; */
}

/* Hero Section */
.hero-section {
    background-color: var(--light-bg-1);
    padding: 5rem 0;
}

.hero-section .subtitle {
    max-width: 700px;
    margin: 1rem auto 0;
    font-size: 1.1rem;
}

/* Services Section */
#services {
    scroll-margin-top: 80px;

    h2 {
        text-align: center;
    }
}

.services-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

.service-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    /* Ensures content below image */
}

.service-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

/* This new class wraps all the text and the button */
.service-card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    /* Allows the button to be pushed to the bottom */
}

.service-card h3 {
    margin-top: 0;
    /* Removed previous top margin */
}

.service-card ul {
    margin-top: 1rem;
    padding-bottom: 1.5rem;
    /* Space above the button */
}

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

.service-card li::before {
    content: '✓';
    color: var(--accent-color);
    position: absolute;
    left: 0;
}

.service-card .btn {
    margin-top: auto;
    align-self: flex-start;
}

/* Why Us Section */
.why-us-section {
    background-color: var(--light-bg-2);

    & h2 {
        text-align: center;
    }
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
    text-align: center;
}

.feature-card .icon {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 60px;
    height: 60px;
    background-color: var(--white);
    border-radius: 50%;
    margin-bottom: 1rem;
    color: var(--accent-color);
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.05);
}

.feature-card .icon svg {
    width: 32px;
    height: 32px;
}

/* Team Section */
.team-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

.team-card {
    background: var(--light-bg-1);
    padding: 2rem;
    border-radius: 12px;
}

.team-card img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin: 0 auto 1rem;
    object-fit: cover;
}

.team-card .title {
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

/* CTA Section */
.cta-section {
    background-color: var(--primary-color);
    color: var(--white);
}

.cta-section h2,
.cta-section p {
    color: var(--white);
}

.cta-section h2 {
    font-size: 2.2rem;
}

.cta-section p {
    max-width: 600px;
    margin: 1rem auto 2rem;
}

.cta-section .btn {
    background-color: var(--white);
    color: var(--primary-color);
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

/* Footer */
.site-footer {
    background: var(--text-dark);
    color: var(--white);
    text-align: center;
    padding: 1.5rem 0;
}

.site-footer p {
    margin: 0;
    font-size: .85rem;
    color: var(--white)
}

.placeholder-image {
    width: 100%;
    max-width: 100%;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 600;
    border-radius: 8px 8px 0 0;
    margin: 0 auto 1rem auto;
    color: #333333;
    background: var(--light-bg-1);
}

.placeholder-image.speech-therapy {
    background: var(--light-bg-2);
}

.placeholder-text {
    text-align: center;
}

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

    h2 {
        font-size: 1.75rem;
    }

    section {
        padding: 3rem 0;
    }

    .hamburger {
        display: block;
    }

    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--white);
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }

    .main-nav.is-active {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        padding: 1rem;
        gap: 1rem;
    }

    .services-grid,
    .features-grid,
    .team-grid {
        grid-template-columns: 1fr;
    }
}

* Page Header */ .page-header {
    background-color: var(--light-bg-1);
    padding: 4rem 0;
}

/* Conditions Section */
.conditions-section {
    padding: 0;

    h2 {
        text-align: center;
    }
}

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

.condition-item {
    background-color: var(--light-bg-2);
    padding: 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    color: var(--text-dark);
    text-align: center;
    border: 1px solid var(--border-color);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.condition-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.07);
}

/* Approach Section */
.approach-section {
    background-color: var(--white);
    padding: 4rem 0;
}

.approach-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.approach-image img {
    border-radius: 12px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* --- Responsive adjustments for new sections --- */
@media (max-width: 768px) {
    .page-header {
        padding: 3rem 0;
    }

    .approach-content {
        grid-template-columns: 1fr;
    }

    .approach-image {
        /* On mobile, move the image to the top */
        grid-row: 1;
        margin-bottom: 2rem;
    }
}

/* --- Styles for Team Page --- */

.team-profiles-section {
    padding: 4rem 0;
}

.profile-card {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 3rem;
    align-items: center;
    margin-bottom: 4rem;
}

/* Modifier class to reverse the layout for visual variety */
.profile-card.reverse {
    grid-template-columns: 2fr 1fr;
}

.profile-card.reverse .profile-image {
    grid-column: 2;
    grid-row: 1;
}

.profile-card.reverse .profile-info {
    grid-column: 1;
    grid-row: 1;
}


.profile-image img {
    border-radius: 12px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.profile-info h2 {
    font-size: 2rem;
    color: var(--primary-color);
}

.profile-info h3 {
    font-size: 1.25rem;
    color: var(--text-light);
    font-weight: 600;
    margin-bottom: 1.5rem;
}

/* --- Responsive adjustments for team page --- */
@media (max-width: 768px) {

    .profile-card,
    .profile-card.reverse {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .profile-card.reverse .profile-image,
    .profile-card.reverse .profile-info {
        grid-column: 1;
        grid-row: auto;
    }

    .profile-image img {
        width: 200px;
        height: 200px;
        border-radius: 50%;
        margin: 0 auto;
    }
}

/* --- Styles for Contact Page --- */

.contact-info-section {
    padding: 4rem 0;
    background-color: var(--light-bg-2);
}

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

.location-card {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--border-color);
}

.location-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.location-card p {
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.email-link {
    font-weight: 600;
    color: var(--accent-color);
    text-decoration: none;
}

.email-link:hover {
    text-decoration: underline;
}

/* Contact Form */
.contact-form-section {
    padding: 4rem 0;
}

.contact-form {
    max-width: 700px;
    margin: 2rem auto 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: var(--font-family);
    font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.2);
}

/* --- Responsive adjustments for contact page --- */
@media (max-width: 768px) {
    .contact-form {
        grid-template-columns: 1fr;
    }
}


/* --- Styles for Detailed Service List on Interior Pages --- */

.service-details-container {
    max-width: 800px;
    margin: 2rem auto 0;
}

.service-detail-item {
    background-color: var(--white);
    padding: 2rem;
    margin-bottom: 1.5rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.service-detail-item h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.service-detail-item p {
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 0;
}

/* Mobile nav open state */
@media (max-width: 768px) {
    nav {
        display: none;
        opacity: 0;
        transform: translateY(-10px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

    nav.open {
        display: block;
        opacity: 1;
        transform: translateY(0);
    }
}

/* Utility */
.center {
    display: grid;
    place-items: center;
}