/*
Theme Name: Alford Law PLLC
Theme URI: https://www.injuredtexan.com
Author: Brandon
Author URI: https://www.injuredtexan.com
Description: Modern, professional WordPress theme for Alford Law PLLC - Texas Personal Injury Lawyers
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: alford-law
Tags: law-firm, business, professional, responsive, custom-menu
*/

/* ============================================
   CSS VARIABLES
   ============================================ */

:root {
    --navy: #1F2937;
    --maroon: #8B3A3A;
    --blue: #0073E6;
    --text-dark: #1a1a1a;
    --text-light: #4a4a4a;
    --text-muted: #7a7a7a;
    --background: #FFFFFF;
    --light-gray: #F8F9FA;
    --border-color: #E8E8E8;
}

/* ============================================
   RESET & BASE STYLES
   ============================================ */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--background);
    width: 100%;
    overflow-x: hidden;
}

/* ============================================
   TOP BAR
   ============================================ */

.top-bar {
    background: var(--navy);
    color: white;
    padding: 14px 40px;
    font-size: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    letter-spacing: 0.5px;
}

.top-bar-left {
    font-weight: 600;
    letter-spacing: 1px;
}

.top-bar-right {
    display: flex;
    gap: 25px;
    align-items: center;
    font-weight: 600;
}

.social-icons {
    display: flex;
    gap: 12px;
    align-items: center;
}

.social-icons a {
    color: white;
    text-decoration: none;
    font-size: 16px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    opacity: 0.8;
}

.social-icons a:hover {
    opacity: 1;
    transform: scale(1.15);
}

/* ============================================
   HEADER
   ============================================ */

header {
    background: white;
    border-bottom: 1px solid var(--border-color);
    padding: 18px 40px;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 30px;
    flex: 0 0 auto;
}

.header-logo img {
    height: 65px;
    width: auto;
    cursor: pointer;
    transition: transform 0.3s ease;
}

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

/* AGGRESSIVE NAVIGATION FIX */
nav, nav ul, nav li {
    display: flex !important;
    align-items: center !important;
}

nav ul {
    flex-direction: row !important;
}

nav > ul > li {
    margin: 0 15px !important;
    padding: 0 !important;
}

nav a {
    padding: 10px 0 !important;
    line-height: 1.2 !important;
    vertical-align: middle !important;
}

/* Remove any default WordPress padding/margins */
.menu-item {
    margin: 0 !important;
    padding: 0 !important;
}

.menu-item a {
    display: flex !important;
    align-items: center !important;
}
```

---

## 📍 Where to Add This:

### **Option 1: In Your Theme's style.css**
1. Open `wp-content/themes/alford-law-theme/style.css`
2. Add the CSS at the bottom of the file
3. Save

### **Option 2: WordPress Customizer (Quick Test)**
1. WordPress Admin → Appearance → Customize
2. Additional CSS
3. Paste the CSS
4. See if it fixes the alignment immediately

### **Option 3: Child Theme (Best Practice)**
If you're using a child theme, add it to your child theme's CSS file.

---

## 🔍 What Was Wrong?

The issue is likely caused by:
1. **Inconsistent vertical alignment** - Items weren't centering properly
2. **Line-height differences** - Text wasn't aligned on the same baseline  
3. **Display properties** - Some items might have been `inline-block` while others were `flex`
4. **WordPress default spacing** - WordPress adds its own classes that can cause misalignment

---

## ✅ After Adding the CSS:

Your navigation should look like this:
```
[Logo]  HOME  OUR FIRM ›  PRACTICE AREAS ›  TESTIMONIALS  CONTACT US  [Phone]  [Button]
         ↕      ↕              ↕                ↕             ↕
     All items perfectly aligned on same horizontal line

/* ============================================
   NAVIGATION WITH DROPDOWNS
   ============================================ */

nav {
    display: flex;
    gap: 0;
    flex: 1;
    align-items: center;
}

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

nav li {
    position: relative;
}

nav > ul > li {
    margin: 0 15px;
}

nav a {
    color: var(--text-dark);
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    transition: color 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    display: block;
    padding: 10px 0;
}

nav a:hover {
    color: var(--maroon);
}

nav > ul > li.current-menu-item > a,
nav > ul > li.current_page_item > a {
    color: var(--maroon);
}

/* Dropdown Menus */
nav ul ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: rgba(31, 41, 55, 0.98);
    min-width: 280px;
    padding: 10px 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
}

nav ul ul li {
    margin: 0;
}

nav ul ul a {
    color: white;
    padding: 10px 20px;
    font-size: 14px;
    text-transform: none;
    letter-spacing: 0;
    font-weight: 500;
}

nav ul ul a:hover {
    color: #82a8e5;
    background: rgba(255, 255, 255, 0.05);
}

/* Show dropdown on hover */
nav li:hover > ul {
    display: block;
}

/* Level 3+ dropdowns - appear to the right */
nav ul ul ul {
    top: 0;
    left: 100%;
    margin-left: -10px;
}

/* Parent indicator (arrow) */
nav li.menu-item-has-children > a::after {
    content: '›';
    margin-left: 8px;
    font-size: 16px;
    font-weight: 700;
}

nav ul ul li.menu-item-has-children > a::after {
    content: '›';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 0;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 0 0 auto;
}

.header-phone-label {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.header-phone-number {
    font-size: 20px;
    color: var(--maroon);
    font-weight: 900;
    text-decoration: none;
}

.header-phone-number:hover {
    color: var(--navy);
}

.header-cta {
    background: var(--maroon);
    color: white;
    padding: 11px 22px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 700;
    font-size: 11px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.header-cta:hover {
    background: var(--navy);
    transform: translateY(-1px);
}

/* ============================================
   MAIN CONTENT AREA
   ============================================ */

.site-content {
    width: 100%;
    overflow-x: hidden;
}

/* ============================================
   SECTIONS
   ============================================ */

.section {
    padding: 80px 40px;
    width: 100%;
}

.section-navy {
    background: var(--navy);
    color: white;
}

.section-gray {
    background: var(--light-gray);
}

.section-white {
    background: white;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 20px;
    line-height: 1.3;
}

h1 {
    font-size: 48px;
}

h2 {
    font-size: 36px;
}

h3 {
    font-size: 28px;
}

h4 {
    font-size: 22px;
}

p {
    font-size: 17px;
    line-height: 1.8;
    color: var(--text-light);
    margin-bottom: 20px;
}

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

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

/* ============================================
   BUTTONS
   ============================================ */

.btn {
    display: inline-block;
    padding: 14px 35px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    border: none;
}

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

.btn-primary:hover {
    background: var(--navy);
    transform: translateY(-2px);
}

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

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

/* ============================================
   FOOTER - 3 COLUMN LAYOUT
   ============================================ */

footer {
    background: var(--navy);
    padding: 50px 40px 30px;
    color: white;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 50px;
    margin-bottom: 30px;
}

.footer-section h4 {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
    color: #D1D5DB;
}

.footer-firm-info {
    line-height: 1.8;
}

.footer-firm-info p {
    font-size: 14px;
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.9);
}

.footer-firm-info .firm-name {
    font-weight: 700;
    color: white;
    font-size: 16px;
}

.footer-firm-info a {
    color: #82a8e5;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-firm-info a:hover {
    color: white;
}

.footer-nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-nav a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: white;
}

.footer-social {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.footer-social a {
    color: white;
    text-decoration: none;
    font-size: 18px;
    transition: all 0.3s ease;
    opacity: 0.8;
}

.footer-social a:hover {
    opacity: 1;
    transform: scale(1.15);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    text-align: center;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.footer-widgets {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    margin-bottom: 30px;
}

/* Responsive */
@media (max-width: 768px) {
    .footer-container {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    
    .footer-nav {
        align-items: center;
    }
    
    .footer-social {
        justify-content: center;
    }
}

/* ============================================
   WORDPRESS SPECIFIC
   ============================================ */

.alignleft {
    float: left;
    margin: 0 20px 20px 0;
}

.alignright {
    float: right;
    margin: 0 0 20px 20px;
}

.aligncenter {
    display: block;
    margin: 20px auto;
}

.wp-caption {
    max-width: 100%;
}

.wp-caption-text {
    font-size: 14px;
    color: var(--text-muted);
    text-align: center;
    padding: 10px 0;
}

.sticky {
    /* Add sticky post styling if needed */
}

.bypostauthor {
    /* Add author styling if needed */
}

/* ============================================
   MOBILE MENU TOGGLE
   ============================================ */

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    padding: 10px;
    cursor: pointer;
    z-index: 1001;
    position: relative;
    width: 40px;
    height: 40px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 6px;
}

.hamburger-line {
    width: 30px;
    height: 3px;
    background: var(--navy);
    border-radius: 2px;
    transition: all 0.3s ease;
    display: block;
}

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

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

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

/* Mobile menu active state */
body.mobile-menu-open {
    overflow: hidden;
}

/* ============================================
   SCROLL ANIMATIONS
   ============================================ */

.fade-in-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   BACK TO TOP BUTTON
   ============================================ */

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--maroon);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--navy);
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* ============================================
   ENHANCED HEADER SCROLL STATE
   ============================================ */

header.scrolled {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* ============================================
   CONTACT FORM 7 STYLING
   ============================================ */

.wpcf7-form {
    max-width: 600px;
    margin: 0 auto;
}

.wpcf7-form p {
    margin-bottom: 20px;
}

.wpcf7-form-control-wrap {
    display: block;
    position: relative;
}

.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form input[type="tel"],
.wpcf7-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: 5px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.wpcf7-form input[type="text"]:focus,
.wpcf7-form input[type="email"]:focus,
.wpcf7-form input[type="tel"]:focus,
.wpcf7-form textarea:focus {
    outline: none;
    border-color: var(--maroon);
}

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

.wpcf7-form input[type="submit"] {
    background: var(--maroon);
    color: white;
    padding: 14px 30px;
    border: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.wpcf7-form input[type="submit"]:hover {
    background: var(--navy);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.wpcf7-response-output {
    margin: 20px 0;
    padding: 15px;
    border-radius: 5px;
}

.wpcf7-not-valid-tip {
    color: #dc3545;
    font-size: 12px;
    margin-top: 5px;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1024px) {
    header {
        padding: 15px 30px;
    }

    nav > ul > li {
        margin: 0 10px;
    }

    nav a {
        font-size: 11px;
    }

    .section {
        padding: 60px 30px;
    }

    .header-right {
        gap: 15px;
    }

    .header-phone-number {
        font-size: 18px;
    }

    .header-cta {
        padding: 10px 18px;
        font-size: 10px;
    }
}

/* ============================================
   MOBILE & TABLET (991px and below)
   ============================================ */

@media (max-width: 991px) {
    /* Show mobile menu toggle */
    .mobile-menu-toggle {
        display: flex;
    }

    /* Hide navigation by default on mobile */
    header nav {
        position: fixed;
        top: 0;
        left: -100%;
        width: 320px;
        max-width: 85%;
        height: 100vh;
        background: white;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
        overflow-y: auto;
        transition: left 0.3s ease;
        z-index: 1000;
        padding: 80px 0 20px 0;
    }

    header nav.mobile-active {
        left: 0;
    }

    /* Mobile menu overlay */
    header nav.mobile-active::before {
        content: '';
        position: fixed;
        top: 0;
        left: 320px;
        width: calc(100vw - 320px);
        height: 100vh;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }

    nav > ul {
        flex-direction: column;
        width: 100%;
        align-items: stretch;
    }

    nav > ul > li {
        margin: 0;
        border-bottom: 1px solid var(--border-color);
    }

    nav > ul > li:last-child {
        border-bottom: none;
    }

    nav > ul > li > a {
        padding: 16px 25px;
        font-size: 14px;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    /* Mobile dropdown styling */
    nav ul ul {
        position: static;
        display: none;
        width: 100%;
        box-shadow: none;
        background: var(--light-gray);
        padding: 0;
        margin: 0;
    }

    nav ul ul a {
        color: var(--text-dark);
        padding: 14px 25px 14px 45px;
        font-size: 13px;
    }

    nav ul ul ul {
        background: #e8e8e8;
    }

    nav ul ul ul a {
        padding-left: 65px;
    }

    nav ul ul ul ul a {
        padding-left: 85px;
    }

    /* Mobile submenu indicators */
    nav li.menu-item-has-children.submenu-open > a::after {
        transform: rotate(90deg);
    }

    nav ul ul li.menu-item-has-children > a::after {
        right: 25px;
    }

    /* Header adjustments */
    header {
        padding: 12px 20px;
    }

    .header-left {
        gap: 15px;
        flex: 1;
    }

    .header-logo img {
        height: 50px;
    }

    .header-right {
        gap: 10px;
    }

    .header-phone-label {
        display: none;
    }

    .header-phone-number {
        font-size: 16px;
    }

    .header-cta {
        padding: 10px 16px;
        font-size: 10px;
    }

    /* Section adjustments */
    .section {
        padding: 50px 25px;
    }

    /* Back to top button */
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 20px;
    }
}

/* ============================================
   MOBILE (768px and below)
   ============================================ */

@media (max-width: 768px) {
    .top-bar {
        flex-direction: column;
        gap: 10px;
        padding: 12px 20px;
        font-size: 10px;
    }

    .top-bar-left,
    .top-bar-right {
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    .social-icons {
        justify-content: center;
    }

    header {
        gap: 20px;
    }

    .header-right {
        flex-direction: row;
        gap: 12px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .section {
        padding: 40px 20px;
    }

    .container {
        padding: 0 10px;
    }

    /* Footer adjustments */
    .footer-container {
        flex-direction: column;
        text-align: center;
        gap: 25px;
    }

    .footer-nav {
        flex-direction: column;
        gap: 15px;
    }

    /* Typography */
    h1 {
        font-size: 36px;
        line-height: 1.2;
    }

    h2 {
        font-size: 28px;
    }

    h3 {
        font-size: 22px;
    }

    /* Buttons */
    .btn {
        padding: 14px 28px;
        font-size: 13px;
    }

    /* Mobile-specific nav width */
    header nav {
        width: 280px;
    }

    /* Contact form adjustments */
    .wpcf7-form {
        padding: 0 10px;
    }
}

/* ============================================
   SMALL MOBILE (600px and below)
   ============================================ */

@media (max-width: 600px) {
    h1 {
        font-size: 28px;
    }

    h2 {
        font-size: 24px;
    }

    h3 {
        font-size: 20px;
    }

    .btn {
        padding: 12px 25px;
        font-size: 12px;
    }

    .header-logo img {
        height: 45px;
    }

    .header-phone-number {
        font-size: 14px;
    }

    .header-cta {
        padding: 8px 14px;
        font-size: 9px;
    }

    header nav {
        width: 260px;
    }

    .section {
        padding: 30px 15px;
    }

    .back-to-top {
        width: 40px;
        height: 40px;
        font-size: 18px;
        bottom: 15px;
        right: 15px;
    }
}

/* ============================================
   EXTRA SMALL SCREENS (400px and below)
   ============================================ */

@media (max-width: 400px) {
    .top-bar {
        padding: 10px 15px;
        font-size: 9px;
    }

    .header-cta {
        display: none; /* Hide on very small screens */
    }

    header nav {
        width: 240px;
    }

    h1 {
        font-size: 24px;
    }

    h2 {
        font-size: 20px;
    }

    h3 {
        font-size: 18px;
    }
}
