/*
Theme Name: Ward Graham Mediation
Description: Professional mediation services theme with modern, clean design and full-width layouts
Author: Ward Graham Team
Version: 6.0.0
Text Domain: wardgraham
*/

/* Ward Graham Brand Colors */
:root {
    --ward-mint: #AFEADC;
    --ward-blue: #9BB7D4;
    --ward-gray: #6E767A;
    --ward-teal: #53B0AE;
    --ward-white: #FFFFFF;
    --ward-off-white: #FAFAFA;
    --ward-dark: #2C3E50;
    --ward-light-gray: #F8F9FA;
    --ward-dark-gray: #4A5458;
    --ward-charcoal: #2C3E50;
    --ward-silver: #BDC3C7;
    --ward-accent-gold: #F39C12;
}

/* Reset and Base */
* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--ward-gray);
    background: var(--ward-white);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: var(--ward-teal);
    font-weight: 400;
    line-height: 1.3;
    margin-bottom: 20px;
}

h1 { font-size: 3.5rem; font-weight: 200; }
h2 { font-size: 2.5rem; font-weight: 300; }
h3 { font-size: 1.8rem; }
h4 { font-size: 1.4rem; }

p {
    margin-bottom: 20px;
    line-height: 1.7;
}

/* Layout Structure */
.ward-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 60px;
}

.ward-full-width {
    width: 100%;
    margin: 0;
    padding: 0;
}

/* Top Utility Bar */
.ward-top-bar {
    background: var(--ward-gray);
    color: white;
    font-size: 14px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1001;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.ward-top-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.ward-top-bar-contact,
.ward-top-bar-social {
    display: flex;
    align-items: center;
    gap: 25px;
}

.ward-top-bar-item {
    color: rgba(255, 255, 255, 0.9);
}

.ward-social-link {
    color: var(--ward-mint);
    text-decoration: none;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.ward-social-link:hover {
    background: rgba(175, 234, 220, 0.1);
    color: white;
}

/* Header */
.ward-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    position: fixed;
    top: 40px;
    left: 0;
    right: 0;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(106, 118, 122, 0.08);
    transition: all 0.3s ease;
    max-height: 100px;
    overflow: visible;
}

.ward-header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    min-height: 60px;
    max-height: 100px;
}

.ward-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    flex-shrink: 0;
}

.ward-logo-img {
    height: 80px !important;
    width: auto !important;
    max-width: 160px !important;
    object-fit: contain;
    display: block;
}

.ward-nav-menu {
    display: flex;
    gap: 40px;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

/* Mobile Menu Toggle */
.ward-mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
    z-index: 1001;
}

.ward-hamburger-line {
    width: 25px;
    height: 3px;
    background: var(--ward-teal);
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
}

.ward-mobile-menu-toggle.active .ward-hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

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

.ward-mobile-menu-toggle.active .ward-hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

.ward-nav a {
    color: var(--ward-gray);
    text-decoration: none;
    font-weight: 500;
    font-size: 16px;
    padding: 10px 0;
    position: relative;
    transition: color 0.3s ease;
}

.ward-nav a:hover,
.ward-nav a.current {
    color: var(--ward-teal);
}

.ward-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--ward-teal);
    transition: width 0.3s ease;
}

.ward-nav a:hover::after,
.ward-nav a.current::after {
    width: 100%;
}

/* Main Content */
.ward-main {
    margin-top: 145px;
}

/* Hero Section */
.ward-hero {
    background: linear-gradient(135deg, var(--ward-teal) 0%, var(--ward-blue) 50%, var(--ward-mint) 100%);
    color: var(--ward-white);
    padding: 80px 0;
    height: auto;
    min-height: 500px;
    display: flex;
    align-items: center;
}

.ward-hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 100px;
    align-items: center;
}

.ward-hero h1 {
    color: var(--ward-white);
    font-size: 4rem;
    font-weight: 200;
    margin-bottom: 30px;
    line-height: 1.2;
}

.ward-hero .subtitle {
    font-size: 1.3rem;
    opacity: 0.95;
    margin-bottom: 40px;
    line-height: 1.7;
}

/* Buttons */
.ward-btn {
    background: var(--ward-white);
    color: var(--ward-teal);
    padding: 18px 40px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    margin: 10px 20px 10px 0;
    transition: all 0.3s ease;
    cursor: pointer;
}

.ward-btn:hover {
    background: var(--ward-dark);
    color: var(--ward-white);
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(0,0,0,0.2);
}

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

.ward-btn-secondary:hover {
    background: var(--ward-white);
    color: var(--ward-teal);
}

/* Image Placeholders */
.ward-image-placeholder {
    background: rgba(255, 255, 255, 0.1);
    border: 2px dashed rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
}

.ward-image-placeholder:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Sections - Reduced padding */
.ward-section {
    padding: 60px 0;
}

.ward-section-alt {
    background: var(--ward-off-white);
}

.ward-section-tight {
    padding: 40px 0;
}

.ward-section-title {
    text-align: center;
    font-size: 3rem;
    color: var(--ward-teal);
    font-weight: 200;
    margin-bottom: 30px;
}

.ward-section-subtitle {
    text-align: center;
    font-size: 1.3rem;
    color: var(--ward-gray);
    max-width: 800px;
    margin: 0 auto 60px;
    line-height: 1.7;
}

/* Three Columns */
.ward-three-cols {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 60px;
    margin-top: 60px;
}

.ward-col {
    text-align: center;
    padding: 50px 30px;
    background: var(--ward-white);
    border-radius: 16px;
    box-shadow: 0 8px 30px rgba(106, 118, 122, 0.06);
    transition: all 0.3s ease;
}

.ward-col:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(106, 118, 122, 0.12);
}

.ward-col h3 {
    color: var(--ward-teal);
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.ward-col-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: white;
}

/* Footer */
.ward-footer {
    background: var(--ward-gray);
    color: var(--ward-white);
    padding: 50px 0 30px;
}

.ward-footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 30px;
}

.ward-footer-section h4 {
    color: var(--ward-mint);
    font-size: 18px;
    margin-bottom: 20px;
}

.ward-footer-section p,
.ward-footer-section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    line-height: 1.8;
    display: block;
    margin-bottom: 8px;
}

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

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

/* Responsive Design */
@media (max-width: 1024px) {
    .ward-container {
        padding: 0 40px;
    }
    
    .ward-hero-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }
    
    .ward-hero h1 {
        font-size: 3rem;
    }
    
    .ward-three-cols {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .ward-footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }
}

@media (max-width: 768px) {
    .ward-container {
        padding: 0 20px;
    }
    
    .ward-top-bar-inner {
        flex-direction: column;
        gap: 8px;
        padding: 10px 0;
    }
    
    .ward-top-bar-contact,
    .ward-top-bar-social {
        gap: 15px;
    }
    
    .ward-header {
        top: 60px;
    }
    
    .ward-main {
        margin-top: 110px;
    }
    
    .ward-header-inner {
        padding: 12px 0;
        min-height: 70px;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    
    .ward-logo {
        display: flex;
        align-items: center;
        height: 55px;
    }
    
    .ward-logo-img {
        height: 55px !important;
        width: auto !important;
        max-width: 110px !important;
        vertical-align: middle;
    }
    
    /* Mobile Menu Toggle */
    .ward-mobile-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        height: 55px;
        padding: 15px 10px;
    }
    
    /* Hide desktop navigation on mobile */
    .ward-nav {
        position: fixed;
        top: 101px;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        box-shadow: 0 4px 20px rgba(106, 118, 122, 0.1);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 999;
        padding: 0;
        margin: 0;
        border-top: 1px solid rgba(106, 118, 122, 0.1);
    }
    
    .ward-nav.active {
        transform: translateY(-1px);
        opacity: 1;
        visibility: visible;
    }
    
    .ward-nav-menu {
        flex-direction: column;
        gap: 0;
        padding: 20px;
        margin: 0;
    }
    
    .ward-nav-menu li {
        border-bottom: 1px solid rgba(106, 118, 122, 0.1);
        margin: 0;
    }
    
    .ward-nav-menu li:last-child {
        border-bottom: none;
    }
    
    .ward-nav a {
        display: block;
        padding: 18px 0;
        font-size: 18px;
        font-weight: 500;
        margin: 0;
    }
    
    .ward-nav a::after {
        display: none;
    }
    
    /* Prevent body scroll when mobile menu is open */
    body.mobile-menu-open {
        overflow: hidden;
    }
    
    .ward-hero h1 {
        font-size: 2.2rem;
        margin-top: 20px;
        margin-bottom: 20px;
        line-height: 1.3;
    }
    
    .ward-hero .subtitle {
        font-size: 1.1rem;
        margin-bottom: 30px;
        padding: 0 10px;
    }
    
    .ward-hero-actions {
        margin-top: 30px;
        display: flex;
        flex-direction: column;
        gap: 15px;
        align-items: center;
    }
    
    .ward-btn {
        width: 100%;
        max-width: 280px;
        text-align: center;
    }
    
    .ward-hero-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    
    .ward-hero {
        padding: 40px 0 60px 0;
        min-height: auto;
        height: auto;
        margin-top: 0;
    }
    
    .ward-hero-content {
        order: 1;
        z-index: 1;
    }
    
    .ward-hero-image {
        order: 2;
        margin-top: 30px;
    }
    
    .ward-hero-image img {
        max-height: 250px;
        width: 100%;
        object-fit: cover;
    }
    
    .ward-section {
        padding: 80px 0;
    }
    
    .ward-col {
        padding: 40px 25px;
    }
    
    .ward-footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* Modern Contact Form Styling */
.ward-contact-form {
    width: 100%;
    background: var(--ward-white);
    padding: 0;
}

.ward-form-row {
    margin-bottom: 32px;
    position: relative;
}

.ward-form-row:last-of-type {
    margin-bottom: 0;
}

/* Modern floating label design */
.ward-form-group {
    position: relative;
    margin-bottom: 32px;
}

.ward-form-label {
    position: absolute;
    top: 18px;
    left: 20px;
    font-size: 16px;
    color: var(--ward-gray);
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--ward-white);
    padding: 0 8px;
    font-weight: 500;
    z-index: 1;
}

.ward-form-input,
.ward-form-textarea {
    width: 100%;
    padding: 18px 20px;
    border: 2px solid #E5E7EB;
    border-radius: 12px;
    font-size: 16px;
    font-family: inherit;
    background: var(--ward-white);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 0;
}

.ward-form-input:focus,
.ward-form-textarea:focus,
.ward-form-input:not(:placeholder-shown),
.ward-form-textarea:not(:placeholder-shown) {
    outline: none;
    border-color: var(--ward-teal);
    box-shadow: 0 0 0 4px rgba(83, 176, 174, 0.08);
}

.ward-form-input:focus + .ward-form-label,
.ward-form-textarea:focus + .ward-form-label,
.ward-form-input:not(:placeholder-shown) + .ward-form-label,
.ward-form-textarea:not(:placeholder-shown) + .ward-form-label {
    top: -8px;
    left: 16px;
    font-size: 13px;
    color: var(--ward-teal);
    font-weight: 600;
}

.ward-form-textarea {
    resize: vertical;
    min-height: 140px;
    font-family: inherit;
    line-height: 1.6;
}

/* Select dropdown styling */
select.ward-form-input {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2353B0AE' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 20px center;
    background-size: 20px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding-right: 50px;
    cursor: pointer;
}

select.ward-form-input:focus {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2353B0AE' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,15 12,9 18,15'%3e%3c/polyline%3e%3c/svg%3e");
}

/* Submit button with modern design */
.ward-form-submit {
    background: linear-gradient(135deg, var(--ward-teal) 0%, #4A9B99 100%);
    color: var(--ward-white);
    border: none;
    padding: 20px 40px;
    font-size: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: 100%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(83, 176, 174, 0.25);
}

.ward-form-submit::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.6s;
}

.ward-form-submit:hover::before {
    left: 100%;
}

.ward-form-submit:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(83, 176, 174, 0.4);
    background: linear-gradient(135deg, #4A9B99 0%, var(--ward-teal) 100%);
}

.ward-form-submit:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(83, 176, 174, 0.3);
}

/* Modern Form Messages */
.ward-form-message {
    padding: 20px 24px;
    margin-bottom: 32px;
    border-radius: 12px;
    font-weight: 500;
    font-size: 15px;
    border: none;
    position: relative;
    overflow: hidden;
    animation: slideInFromTop 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.ward-form-message::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
}

.ward-form-message.success {
    background: linear-gradient(135deg, #d4edda, #c8e6c9);
    color: #2e7d32;
    box-shadow: 0 4px 20px rgba(76, 175, 80, 0.15);
}

.ward-form-message.success::before {
    background: linear-gradient(90deg, #4caf50, #8bc34a);
}

.ward-form-message.error {
    background: linear-gradient(135deg, #ffebee, #ffcdd2);
    color: #c62828;
    box-shadow: 0 4px 20px rgba(244, 67, 54, 0.15);
}

.ward-form-message.error::before {
    background: linear-gradient(90deg, #f44336, #e57373);
}

/* Enhanced Form Validation */
.ward-form-input.error,
.ward-form-textarea.error {
    border-color: #f44336 !important;
    box-shadow: 0 0 0 4px rgba(244, 67, 54, 0.1) !important;
    animation: shake 0.5s ease-in-out;
}

.ward-form-input.valid,
.ward-form-textarea.valid {
    border-color: #4caf50 !important;
    box-shadow: 0 0 0 4px rgba(76, 175, 80, 0.08) !important;
}

/* Field Error Messages */
.field-error {
    color: #f44336;
    font-size: 13px;
    margin-top: 8px;
    font-weight: 500;
    animation: fadeInUp 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 6px;
}

.field-error::before {
    content: '⚠';
    font-size: 14px;
}

/* Loading State Enhancement */
.ward-form-submit.loading {
    opacity: 0.8;
    cursor: not-allowed;
    pointer-events: none;
    transform: scale(0.98);
}

.ward-form-submit.loading span {
    opacity: 0;
}

.ward-form-submit.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* Animations */
@keyframes slideInFromTop {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Focus Effects */
.ward-form-input:focus,
.ward-form-textarea:focus {
    transform: scale(1.01);
}

/* Enhanced Select Styling */
select.ward-form-input option {
    padding: 12px;
    font-size: 15px;
    color: var(--ward-dark-gray);
    background: var(--ward-white);
}

select.ward-form-input option:hover,
select.ward-form-input option:checked {
    background: var(--ward-teal);
    color: white;
}

/* Progress indicator for form completion */
.ward-form::before {
    content: '';
    position: absolute;
    top: -2px;
    left: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--ward-teal), var(--ward-mint));
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 1px;
}

/* Responsive Enhancements */
@media (max-width: 768px) {
    .ward-form-row {
        margin-bottom: 28px;
    }
    
    .ward-form-input,
    .ward-form-textarea {
        padding: 16px 18px;
        font-size: 16px; /* Prevent zoom on iOS */
        border-radius: 10px;
    }
    
    .ward-form-submit {
        padding: 18px 32px;
        font-size: 15px;
        border-radius: 10px;
    }
    
    .ward-form-message {
        padding: 18px 20px;
        font-size: 14px;
        border-radius: 10px;
    }
}