/* --- Global Styles --- */
:root {
    /* Colors */
    --color-dark: #242304;       /* Dark Text / Headings */
    --color-grey: #717061;       /* Subtext */
    --color-accent: #C64034;     /* Darkened for WCAG AA Contrast */
    --bg-light: #f9f9f9;
    --bg-beige: #f4f4ef;
    --hero-grey: #666666;
    --white: #ffffff;

    /* Fonts */
    --font-serif: 'EB Garamond', serif;
    --font-sans: 'Lato', sans-serif;
    --font-hero-body: 'Montserrat', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px; /* Base size */
}

body {
    font-family: var(--font-sans);
    color: var(--color-grey);
    line-height: 1.6;
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s;
}

ul {
    list-style: none;
}

h1, h2, h3, h4 {
    font-family: var(--font-serif);
    color: var(--color-dark);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Top Bar --- */
.top-bar {
    background-color: #222;
    color: #fff;
    padding: 0;
    font-family: var(--font-sans);
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
}

.top-email {
    font-size: 18px;
    display: flex;
    align-items: center;
    padding: 10px 0;
}

.top-email i {
    font-size: 22px;
    position: relative;
    top: 2px;
}

.top-bar i {
    color: var(--color-accent);
    margin-right: 8px;
}

.top-phone-box {
    background-color: var(--color-accent);
    padding: 0 20px;
    margin: 0;
    font-weight: bold;
    font-family: var(--font-sans);
    font-size: 16px;
    color: #fff;
    display: flex;
    align-items: center;
}

.top-phone-box i {
    color: #fff !important;
}

/* --- Header & Nav --- */
header {
    background: var(--white);
    padding: 15px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 60px;
}

/* --- DESKTOP NAV (Default) --- */
.desktop-nav {
    display: block; /* Visible by default on desktop */
}

nav ul {
    display: flex;
    gap: 30px;
}

nav a {
    font-family: var(--font-serif);
    font-weight: 700;
    font-size: 15px;
    color: var(--color-dark);
    text-transform: uppercase;
    letter-spacing: 1px;
}

nav a:hover, nav a.active {
    color: var(--color-accent);
}

/* --- Split Hero Section --- */
.hero-split {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

.hero-image-side {
    flex: 1;
    flex-basis: 50%;
    position: relative;
}

.hero-image-side img {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

.hero-content-side {
    flex: 1;
    flex-basis: 50%;
    background-color: var(--hero-grey);
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 60px 80px;
    text-align: center;
}

.hero-content-side h2,
.hero-content-side h1 {
    font-family: var(--font-sans);
    font-size: 21px;
    font-weight: 400;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 25px;
}

.hero-content-side p {
    font-family: var(--font-hero-body);
    font-size: 17px;
    line-height: 1.8;
    color: #fff;
    max-width: 500px;
}

/* --- Features / Intro Section --- */
.features {
    padding: 80px 0;
    background-color: var(--white);
}

.features .container {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
}

.features-intro {
    flex: 1;
    min-width: 300px;
    padding-right: 60px;
}

.features-intro h2 {
    font-family: var(--font-serif);
    color: var(--color-dark);
    font-size: 48px;
    line-height: 1.1;
    margin-bottom: 25px;
    font-weight: 400;
}

.features-intro p {
    font-family: var(--font-sans);
    color: var(--color-grey);
    font-size: 18px;
    line-height: 1.6;
}

.icon-grid {
    flex: 1.4;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 50px 30px;
}

.icon-box {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.icon-box img {
    width: auto;
    max-width: 100%;
    height: auto;
    margin-bottom: 20px;
    display: block;
}

.icon-box h3 {
    font-family: var(--font-serif);
    color: var(--color-dark);
    font-size: 28px;
    text-transform: none;
    font-weight: 500;
    line-height: 1.2;
}

/* --- Intro Text Section --- */
.intro-text-section {
    background-color: var(--bg-beige);
    padding: 90px 0;
    text-align: center;
}

.intro-text-section h2 {
    font-family: var(--font-serif);
    color: var(--color-dark);
    margin-bottom: 30px;
    font-size: 42px;
}

.intro-text-section p {
    font-family: var(--font-sans);
    color: var(--color-grey);
    max-width: 900px;
    margin: 0 auto 20px;
    font-size: 17px;
}

/* --- What Sets Us Apart --- */
.sets-us-apart-section {
    background-color: var(--white);
    padding: 90px 0;
    text-align: center;
}

.sets-us-apart-section h2 {
    font-family: var(--font-serif);
    color: var(--color-dark);
    margin-bottom: 30px;
    font-size: 42px;
}

.sets-us-apart-section p {
    font-family: var(--font-sans);
    color: var(--color-grey);
    max-width: 900px;
    margin: 0 auto 20px;
    font-size: 17px;
}

/* --- Testimonials Section --- */
.testimonials {
    background-color: #333;
    color: #fff;
    padding: 90px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.testimonials::before {
    content: "TESTIMONIALS";
    position: absolute;
    top: 30px;
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--font-serif);
    font-size: 130px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.03);
    text-transform: uppercase;
    white-space: nowrap;
    z-index: 1;
    letter-spacing: 5px;
    pointer-events: none;
}

.testimonials .container {
    position: relative;
    z-index: 2;
}

.testimonials h2 {
    font-family: var(--font-serif);
    color: #fff;
    opacity: 0.9;
    letter-spacing: 2px;
    margin-bottom: 40px;
    font-size: 32px;
}

.quote-icon {
    font-size: 3rem;
    color: var(--color-accent);
    margin-bottom: 20px;
    display: block;
}

.testimonial-slider {
    display: grid;
    grid-template-rows: 1fr;
    grid-template-columns: 1fr;
    align-items: start;
    position: relative;
}

.testimonial-slide {
    grid-row: 1;
    grid-column: 1;
    opacity: 0;
    transition: opacity 1.0s ease-in-out;
    pointer-events: none;
    width: 100%;
}

.testimonial-slide.active {
    opacity: 1;
    pointer-events: auto;
    z-index: 1;
}

.testimonial-slide p {
    font-family: var(--font-sans);
    font-style: italic;
    font-size: 19px;
    max-width: 800px;
    margin: 0 auto 30px;
    line-height: 1.8;
    color: #ddd;
}

.client-name {
    font-family: var(--font-serif);
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 1px;
    font-size: 15px;
}

/* --- Attorneys Section --- */
.attorneys {
    padding: 90px 0;
    text-align: center;
}

.attorneys-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 50px;
    text-align: left;
    border-bottom: 1px solid #ddd;
    padding-bottom: 25px;
}

.attorneys-header h2 {
    font-family: var(--font-serif);
    color: var(--color-dark);
    font-size: 46px;
    line-height: 1;
    font-weight: 400;
}

.attorneys-header div p {
     font-family: var(--font-sans);
     color: var(--color-grey);
     font-size: 16px;
     text-align: left;
}

/* Kicker text to replace h5 */
.section-kicker {
    color: var(--color-accent);
    letter-spacing: 2px;
    font-family: 'Lato', sans-serif;
    text-transform: uppercase;
    margin-bottom: 10px;
    font-weight: 700;
    font-size: 0.83em;
}

/* --- Grid Layout --- */
.attorney-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 30px;
    justify-items: start;
    align-items: start;
}

.attorney-card {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
    width: 370px;
    max-width: 100%;
    margin: 0;
    padding: 0;
    border: none;
    overflow: hidden;
}

.attorney-card img,
.attorney-image,
.overlay {
    grid-column: 1 / 2;
    grid-row: 1 / 2;
}

.attorney-card img,
.attorney-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    transition: transform 0.5s ease;
    z-index: 1;
}

.overlay {
    z-index: 2;
    background-color: rgba(30, 33, 36, 0.95);
    opacity: 0;
    transition: opacity 0.4s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 20px;
    font-size: 16px;
    line-height: 1.5;
}

.attorney-card:hover .overlay {
    opacity: 1;
}

.attorney-card:hover img,
.attorney-card:hover .attorney-image {
    transform: scale(1.05);
}

.attorney-name {
    color: #C5A670;
    font-family: 'Georgia', serif;
    font-size: 22px;
    text-transform: uppercase;
    margin-bottom: 5px;
    letter-spacing: 1px;
    margin-top: 0;
    line-height: 1.2;
}

.attorney-title {
    color: #ffffff;
    font-family: sans-serif;
    font-size: 11px;
    font-style: italic;
    text-transform: uppercase;
    margin-bottom: 15px;
    font-weight: 600;
    letter-spacing: 0.5px;
    line-height: 1.2;
}

.attorney-bio {
    color: #ffffff;
    font-family: sans-serif;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 25px;
    padding: 0 10px;
}

.linkedin-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    border: 1px solid white;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
}

.linkedin-btn:hover {
    background-color: white;
    color: #333;
}

.linkedin-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* --- Navigation Dropdown --- */
.dropdown {
    position: relative;
    display: flex;
    align-items: center;
    height: 100%;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--white);
    min-width: 140px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.15);
    z-index: 2000;
    top: 100%;
    left: 0;
    padding: 0;
    border-top: 3px solid var(--color-accent);
}

.dropdown:hover .dropdown-content,
.dropdown:focus-within .dropdown-content {
    display: block;
}

.dropdown-content a {
    color: var(--color-dark);
    padding: 12px 15px;
    text-decoration: none;
    display: block;
    text-align: left;
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 400;
    text-transform: none;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #f0f0f0;
    white-space: nowrap;
}

.dropdown-content a:last-child {
    border-bottom: none;
}

.dropdown-content a:hover {
    background-color: var(--bg-light);
    color: var(--color-accent);
}

/* --- HAMBURGER MENU (Global: Definition only) --- */
button.hamburger-menu {
    /* Initially display: none is handled by desktop media query below */
    display: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--color-dark);
    background: none;
    border: none;
    padding: 0;
}

.mobile-overlay {
    height: 100%;
    width: 0;
    position: fixed;
    z-index: 9999;
    top: 0;
    left: 0;
    background-color: var(--color-grey);
    overflow-x: hidden;
    transition: 0.5s;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.mobile-overlay-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    opacity: 0;
    transition: opacity 0.3s 0.3s;
}

.mobile-logo img {
    height: 50px;
}

/* Accessibility Fix: Close button styles */
button.closebtn {
    color: #fff;
    font-family: var(--font-sans);
    font-size: 16px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    background: none;
    border: none;
    cursor: pointer;
}

.closebtn i {
    font-size: 20px;
}

.mobile-overlay-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    opacity: 0;
    transition: opacity 0.3s 0.3s;
}

.mobile-overlay-content a {
    text-decoration: none;
    font-size: 28px;
    color: #fff;
    display: block;
    margin: 15px 0;
    font-family: var(--font-serif);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
    transition: 0.3s;
}

.mobile-overlay-content a.mobile-active {
    color: var(--color-accent);
}

.mobile-overlay-content a:hover {
    color: var(--color-accent);
}

.mobile-overlay-footer {
    display: flex;
    justify-content: center;
    padding-bottom: 40px;
    gap: 25px;
    opacity: 0;
    transition: opacity 0.3s 0.3s;
}

.mobile-overlay-footer a {
    color: #fff;
    font-size: 18px;
}

.mobile-overlay.open {
    width: 100%;
}

.mobile-overlay.open .mobile-overlay-header,
.mobile-overlay.open .mobile-overlay-content,
.mobile-overlay.open .mobile-overlay-footer {
    opacity: 1;
}

/* --- Footer & Misc --- */

.footer-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-branding h2 {
    font-family: var(--font-serif);
    color: #fff;
    font-size: 26px;
    margin-bottom: 20px;
    line-height: 1.3;
}

.footer-col h4 {
    font-family: var(--font-serif);
    color: #fff;
    margin-bottom: 20px;
    font-size: 17px;
    letter-spacing: 1.5px;
}

.footer-col p {
    font-family: var(--font-sans);
    margin-bottom: 12px;
}

.footer-col a {
    color: var(--color-accent);
}

.social-icons {
    margin-top: 20px;
}

.social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 38px;
    height: 38px;
    background: #444;
    color: #fff;
    border-radius: 50%;
    margin-right: 10px;
    font-size: 15px;
}

.social-icons a:hover {
    background: var(--color-accent);
}

.copyright {
    font-family: var(--font-sans);
    border-top: 1px solid #444;
    padding-top: 20px;
    text-align: right;
    font-size: 13px;
}

footer {
    background-color: #2a2a2a;
    color: #bbb;
    padding: 70px 0 20px;
    font-size: 15px;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    padding: 80px 0;
}

.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 15px;
    margin-bottom: 20px;
    border: none;
    border-bottom: 1px solid #ddd;
    font-family: var(--font-sans);
    font-size: 15px;
}

.contact-form button {
    background: var(--color-accent);
    color: #fff;
    border: none;
    padding: 15px 35px;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
    font-family: var(--font-sans);
    font-size: 14px;
    letter-spacing: 1px;
}

.map-section {
    width: 100%;
    height: 450px;
    border: none;
}

/* =========================================
   MEDIA QUERIES (Responsive Logic)
   ========================================= */

@media (max-width: 1060px) {
    .hero-content-side { padding: 40px 30px; }
    .hero-content-side h2 { margin-bottom: 15px; }
    .hero-content-side p { font-size: 15px; line-height: 1.4; }
}

@media (max-width: 992px) {
    .features-intro h2 { font-size: 42px; }
    .intro-text-section h2 { font-size: 36px; }
    .sets-us-apart-section h2 { font-size: 36px; }
    .attorneys-header h2 { font-size: 38px; }
    .testimonials::before { font-size: 90px; top: 20px; }
}

@media (max-width: 945px) {
    .features-intro h2 { font-size: 34px; }
}

@media (max-width: 810px) {
    .hero-split { flex-direction: column; }
    .hero-image-side, .hero-content-side { flex-basis: 100%; width: 100%; }
    .hero-content-side { padding: 60px 20px; }
}

/* --- STRICT DESKTOP RULES (min-width: 769px) --- */
@media (min-width: 769px) {
    /* Ensure Desktop Nav is ALWAYS visible */
    .desktop-nav {
        display: block !important;
    }
    /* Ensure Hamburger is ALWAYS hidden */
    button.hamburger-menu {
        display: none !important;
    }
}

/* --- MOBILE NAVIGATION TOGGLE (max-width: 768px) --- */
@media (max-width: 768px) {
    /* 1. Show the Hamburger Button */
    button.hamburger-menu {
        display: block !important;
    }

    /* 2. Hide the Desktop Nav */
    .desktop-nav {
        display: none !important;
    }

    /* 3. Global Adjustments for Mobile */

    /* HIDE THE EMAIL */
    .top-email {
        display: none;
    }

    /* HIDE the 'Hands On' description in Attorney Header */
    .attorneys-header div:last-child {
        display: none;
    }

    /* LEFT ALIGN the copyright */
    .copyright {
        text-align: left;
    }

    /* Right align the remaining phone number in the bar AND remove padding */
    .top-bar .container {
        justify-content: flex-end;
        padding-right: 0; /* Remove right padding to hit the edge */
    }

    .top-phone-box { font-size: 14px; padding: 6px 12px; }

    .features .container, .footer-content, .contact-grid, .attorney-grid {
        grid-template-columns: 1fr;
        flex-direction: column;
    }

    .attorney-grid { justify-items: center; }
    .attorney-card { width: 100%; max-width: 370px; }

    .features-intro { padding-right: 0; margin-bottom: 40px; }
    .features-intro h2 { font-size: 36px; }
    .features-intro p { font-size: 16px; }

    .icon-grid { margin-top: 0; gap: 40px; }
    .icon-box h3 { font-size: 24px; }

    .intro-text-section h2 { font-size: 28px; }
    .sets-us-apart-section h2 { font-size: 28px; }
    .testimonials h2 { font-size: 24px; }
    .attorneys-header h2 { font-size: 32px; }

    .testimonials::before { font-size: 50px; letter-spacing: 2px; top: 15px; }

    /* PADDING for Get In Touch section AND Form on Mobile */
    .contact-info,
    .contact-form-wrapper {
        padding: 0 15px;
    }
}
