/*
Theme Name: Twenty Twenty-Five Child
Theme URI: http://example.com/
Description: My custom child theme for Twenty Twenty-Five.
Author: Your Name
Author URI: http://example.com/
Template: twentytwentyfive
Version: 1.0.0
*/

@import "../twentytwentyfive/style.css"; /* THIS LINE MUST BE AT THE VERY TOP, AND END WITH A SEMICOLON */









/* -------------------------------------------------------------------- */
/* --- A. GLOBAL RESETS & TYPOGRAPHY SCALES --- */
/* -------------------------------------------------------------------- */


/* --- 1. Global Base Typography (Applies to ALL Devices) --- */

html {
    /* Ensures 1rem = 16px (browser default), which is crucial for accessibility. */
    font-size: 100%; 
}

body {
    /* TEXT FONT SIZE IS SET TO 1rem (16px) FOR BOTH MOBILE AND DESKTOP */
    font-size: 1rem; 
    line-height: 1.5; /* Good line height for body text readability. */
}

/* --- 2. Desktop Headings (Base Sizes) --- */

h1 { font-size: 2.23rem; line-height: 1.2; margin-top: 1.5em; margin-bottom: 0.5em; }
h2 { font-size: 1.6rem; line-height: 1.2; margin-top: 2.5em; margin-bottom: 0.5em; }
h3 { font-size: 1.4rem; line-height: 1.3; margin-top: 1.5em; margin-bottom: 0.5em; }
h4 { font-size: 1.2rem; line-height: 1.3; margin-top: 1.2em; margin-bottom: 0.4em; }
h5 { font-size: 1.1rem; line-height: 1.4; margin-top: 1.2em; margin-bottom: 0.4em; }
h6 { font-size: 1rem; line-height: 1.4; margin-top: 1em; margin-bottom: 0.3em; }

/* --- 3. Mobile Headings (Max-Width 768px Overrides) --- */

@media (max-width: 768px) {
    /* Scales down larger headings for mobile screen readability */
    h1 { font-size: 1.9rem; } 
    h2 { font-size: 1.33rem; }
    h3 { font-size: 1.19rem; }
    h4 { font-size: 1.05rem; }
    /* Accessibility Fix: Ensure H5 and H6 stay at 1rem minimum */
    h5 { font-size: 1rem; } 
    h6 { font-size: 1rem; } 
}






/* --- New Rule to Force Bold Weight for B and STRONG elements --- */
b, strong, .has-text-weight-bold {
    font-weight: 700 !important;
}







/* -------------------------------------------------------------------- */
/* --- C. CONTACT FORM 7 - OPTIMIZED STYLES --- */
/* Brand Colors: Blue (#1e3a8a), Orange (#F97316) */
/* -------------------------------------------------------------------- */

/* --- BASE FORM CONTAINER --- */
.wpcf7 form {
    max-width: 1340px !important;
    margin: 0 auto;
    padding: 20px;
    background-color: #f9f9f9;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

/* --- COLOR CODING & HEADINGS (BLUE BRAND COLOR) --- */

/* Headings and all Labels (Base Blue Style) */
.wpcf7 h3,
.form-row-services-details h4,
.wpcf7 label {
    color: #1e3a8a !important; /* PRIMARY BRAND BLUE */
    font-weight: 400;
    font-size: 1rem;
    display: block;
}

/* Headings Specific Styles */
.wpcf7 h3,
.form-row-services-details h4 {
    margin-top: 8px;
    margin-bottom: 3px;
    font-size: 1.25rem;
}

/* Label Spacing */
.wpcf7 label {
    margin-bottom: 3px !important;
}

/* Highlight Message Box Label (ORANGE BRAND COLOR) */
.form-message-box label {
    color: #F97316 !important; /* SECONDARY BRAND ORANGE */
}

/* --- FIELD APPEARANCE & SPACING --- */

/* Consolidated input/select/textarea styles */
.wpcf7 input:not([type="submit"]):not([type="checkbox"]):not([type="radio"]),
.wpcf7 select,
.wpcf7 textarea {
    box-sizing: border-box;
    width: 100%;
    padding: 8px 12px;
    margin-bottom: 0 !important;
    border: 1px solid #ddd;
    border-radius: 6px;
}
.wpcf7 textarea {
    min-height: 220px;
}
.separator {
    display: none;
}

/* --- ROW CONTAINER STYLING (Shadows, Backgrounds, Layout Base) --- */

.form-grid, .form-grid-three, .form-services-wide-options, .form-message-box {
    border: 1px solid #eee;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 55px !important;
    align-items: start;
    display: grid !important;
    gap: 12px 15px;
}

/* Distinct Background Colors and Specific Columns */
.form-grid {
    background-color: #f0f7ff;
    grid-template-columns: repeat(5, 1fr);
}
.form-grid-three {
    background-color: #fff9ed;
    grid-template-columns: repeat(3, 1fr);
}
.form-services-wide-options {
    background-color: #f5fff5;
}
.form-message-box {
    background-color: #ffe6e6;
    grid-template-columns: 1fr;
}

/* Services Checkbox Grid */
.services-grid-new {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px 20px;
}

.services-grid-new .wpcf7-list-item-label {
    white-space: nowrap;
}

/* --- SUBMIT BUTTON STYLING --- */

.button-container {
    text-align: center;
    padding-bottom: 20px;
}

.wpcf7 input[type="submit"] {
    /* Base style: Branded Orange */
    background-color: #F97316 !important;
    color: white !important;
    border: none !important;
    padding: 12px 25px;
    font-size: 1.1rem;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    
    box-sizing: border-box;
    width: auto;
    display: inline-block;
    margin-top: 10px;
}

.wpcf7 input[type="submit"]:hover {
    /* Hover style: Branded Blue */
    background-color: #1e3a8a !important;
}

/* --- MOBILE OPTIMIZATION (Contact Form) --- */
@media (max-width: 600px) {
    /* Force 1-column stack and reduced bottom margin for all row containers */
    .form-grid, .form-grid-three, .form-services-wide-options, .form-message-box {
        grid-template-columns: 1fr !important;
        margin-bottom: 15px !important;
        gap: 8px;
    }
    .services-grid-new {
        grid-template-columns: 1fr;
    }
    .services-grid-new .wpcf7-list-item-label {
        white-space: normal;
    }
}
















/* -------------------------------------------------------------------- */
/* --- B. HEADER & MOBILE LAYOUT FIXES (Sticky Header & Image Centering) --- */
/* -------------------------------------------------------------------- */

/* GLOBAL STICKY HEADER (Applies to ALL devices) */
#site-header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 9999; 
    background-color: #ffffff;
}

/* --- CRITICAL FIX: Push the site content down to clear the fixed header. --- */
/* Target the top-level content wrapper (e.g., the block that starts after the header) */
/* Using margin-top ensures it pushes down all content below the fixed header. */
.wp-site-blocks, 
.site-content {
    /* FINAL DESKTOP MARGIN: Increased to 4.5rem for maximum comfortable spacing (approx 72px) */
    margin-top: 4.5rem !important; 
    /* Also ensure the body padding is not interfering if it has a conflicting default */
    padding-top: 0 !important;
}

/* Adjusts the top margin when the WordPress Admin Bar is present (Logged In) */
body.logged-in .wp-site-blocks,
body.logged-in .site-content {
    /* 4.5rem + 32px Admin Bar */
    margin-top: calc(4.5rem + 32px) !important;
}


/* Adjusts for the WordPress Admin Bar (Header top position fix) */
body.logged-in #site-header {
    top: 32px;
}


/* --- MOBILE-SPECIFIC MARGIN ADJUSTMENT --- */
@media (max-width: 768px) {
    /* MOBILE MARGIN: 4.5rem for reliable mobile clearance (Matches new desktop margin) */
    .wp-site-blocks, 
    .site-content {
        margin-top: 4.5rem !important;
    }

    /* Targets images and image blocks within content */
    .entry-content img,
    .entry-content figure,
    .entry-content .wp-block-image {
        /* Overrides alignment and centers the image */
        display: block;
        margin-left: auto;
        margin-right: auto;
        
        /* Applies the desired 1rem vertical spacing */
        margin-top: 1rem;
        margin-bottom: 1rem;
        
        /* Cleanup inherited padding */
        padding-top: 0;
        padding-bottom: 0;
        
        /* Safety rules */
        max-width: 100%;
        box-sizing: border-box;
    }
}












/* GLOBAL BEST PRACTICE: Ensures all images are fully responsive and proportional */
img {
    /* This line prevents the image from stretching out of its container */
    max-width: 100%; 
    /* This line prevents the image from getting squashed or stretched vertically */
    height: auto; 
}


















/* -------------------------------------------------------------------- */
/* --- D. GENERAL CONTENT CLEANUP (List, Quotes, and HR Spacing) --- */
/* -------------------------------------------------------------------- */

/* Improves readability and spacing for standard content elements */

/* 1. List/Bullet Indentation Cleanup */
/* This helps prevent list items from shifting too far to the left on some themes/browsers. */
.entry-content ul,
.entry-content ol {
    margin-left: 1.5em; /* Ensures minimum padding from the edge */
}

/* 2. Blockquote Styling */
/* Adds subtle visual separation for quoted text, improving distinction from body copy. */
.entry-content blockquote {
    border-left: 4px solid #1e3a8a; /* Use your primary brand color (Blue) */
    padding-left: 20px;
    margin: 1.5em 0;
    font-style: italic;
    color: #555;
}

/* 3. Horizontal Rule (HR) Styling */
/* Gives the default separator line a cleaner, less harsh look. */
.entry-content hr {
    border: 0;
    border-top: 1px solid #ddd;
    margin: 3em auto;
    width: 50%; /* Makes it a visual break, not a full line across the screen */
}














/* -------------------------------------------------------------------- */
/* --- E. ACCESSIBILITY & FOCUS FIXES (Skip Link and Outline) --- */
/* -------------------------------------------------------------------- */

/* 1. Global Focus Outline Fix (Crucial for Keyboard Navigation) */
/* Ensures elements have a visible focus outline when navigating by keyboard. */
*:focus {
    outline: 2px solid #F97316 !important; /* Use brand orange for high contrast */
    outline-offset: 2px;
}

/* 2. Skip to Content Link (WordPress Standard) */
/* This link is essential for screen readers and keyboard users. */
.skip-link {
    position: absolute !important;
    clip: rect(1px, 1px, 1px, 1px);
    padding: 0;
    border: 0;
    height: 1px;
    width: 1px;
    overflow: hidden;
    text-decoration: none;
}

/* Make the skip link visible and styled when it receives keyboard focus */
.skip-link:focus {
    clip: auto;
    width: auto;
    height: auto;
    top: 5px;
    left: 5px;
    background: #1e3a8a; /* Primary brand color */
    color: white;
    padding: 10px 15px;
    z-index: 100000; /* Ensure it is always on top */
    text-align: center;
    border-radius: 4px;
}









/* 4. Global Paragraph Spacing */
.entry-content p {
    margin-top: 0;
    margin-bottom: 0.5rem; /* Ensures consistent vertical space below paragraphs */
}







