/*
Theme Name: Twenty Twenty-Five Child
Theme URI: https://wordpress.org/themes/twentytwentyfive/
Template: twentytwentyfive
Version: 1.0.0
Description: A child theme for the Twenty Twenty-Five default WordPress theme, providing a foundation for custom development and customization.
Author: Pimentel Solutions
Author URI: https://manteca.org
Text Domain: twentytwentyfive-child
Tags: one-column, two-columns, right-sidebar, flexible-header, accessibility-ready, custom-colors, custom-menu, custom-logo, editor-style, featured-images, footer-widgets, post-formats, rtl-language-support, sticky-post, theme-options, threaded-comments, translation-ready

License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html

This theme, like WordPress, is licensed under the GPL.
Use it to make something cool, have fun, and share what you've learned with others.
*/

/* =Theme Styles
-------------------------------------------------------------- */

/* Reset basic elements */
html {
    font-size: 16px;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    clear: both;
    line-height: 1.2;
    margin-bottom: .5em;
    margin-top: 0;
}

p {
    margin-bottom: 1.5em;
}

a:hover,
a:focus {
    color: #005177;
    text-decoration: underline;
}

header a:hover {
    color: #fff;
    text-decoration: underline;
}

/* Selective Accessibility Improvements (Sufficient Contrast Only) */

/* High-Contrast Color Normalization for WCAG 2.1 AA Compliance */
:root {
    --manteca-compliant-green: #3C6901;
    /* 4.5:1 Contrast ratio on white */
    --manteca-compliant-grey: #555555;
    /* 4.5:1 Contrast ratio on #f2f2f2 */
}

/* Override light green icons/links (#68B601) */
.gb-icon,
.member-contact-info a,
.search-filter-input-button {
    color: var(--manteca-compliant-green) !important;
}

/* SEARCH FILTER CONTRAST FIX: Phase 8 (Global Overrides) */
/* Target placeholder text specifically to meet 4.5:1 contrast across all viewports */
.search-filter-component-combobox-base .search-filter-component-combobox__selection.search-filter-component-combobox__selection-placeholder,
.search-filter-component-combobox-base .search-filter-component-combobox__selection {
    color: #222222 !important;
    /* Forces 100% compliance on white background */
    opacity: 1 !important;
    /* Overrides any plugin-level opacity which reduces contrast */
}

/* Increase specificity for active selections */
.search-filter-field__input .search-filter-component-combobox__selection {
    color: #222222 !important;
}

/* Override search reset link (#777777 on #f2f2f2) */
.search-filter-input-reset {
    color: var(--manteca-compliant-grey) !important;
}

/* Placeholder contrast (4.5:1) */
::placeholder {
    color: #636363 !important;
    opacity: 1;
}

/* Labels contrast */
.search-filter-label {
    color: #333 !important;
    font-weight: 600;
}

/* Cookie Blocker Notice Contrast Override (WCAG 2.1 AA compliance) */
.cmplz-blocked-content-container .cmplz-blocked-content-notice,
.cmplz-wp-video .cmplz-blocked-content-notice {
    background-color: rgba(0, 0, 0, 0.9) !important;
}

/* Accessibility Support Classes */
.visually-hidden {
    clip: rect(1px, 1px, 1px, 1px);
    position: absolute !important;
    height: 1px;
    width: 1px;
    overflow: hidden;
    white-space: nowrap;
}

/* Mobile-Specific Accessibility Remediation (Phase 8) */
@media (max-width: 768px) {

    /* Improve contrast for mobile-only text elements */
    .gb-text,
    .search-filter-input,
    .member-card p,
    .member-contact-info,
    .ldd-directory-entry p {
        color: #222222 !important;
        /* Ensure 4.5:1+ contrast on mobile screens */
    }

    /* Cookie Banner Buttons (Contrast Fix) */
    #cookie-law-info-bar .cli_button,
    #cookie-law-info-bar a {
        background-color: #004a99 !important;
        /* Stronger blue for better visibility */
        color: #ffffff !important;
    }

    /* mobile search inputs */
    input[type="text"],
    input[type="search"],
    select {
        font-size: 16px !important;
        /* Prevents mobile zoom-in focus which can hide context */
        min-height: 44px;
        /* Minimum tap target height */
    }

    .search-filter-component-combobox__selection {
        font-size: 16px !important;
        min-height: 44px;
    }

    /* Social Icons Contrast on mobile */
    .gb-icon svg,
    .member-contact-info a {
        color: #3C6901 !important;
        /* Manteca compliant green */
    }
}

/* =Media Queries
-------------------------------------------------------------- */

/* Small screen (tablet) - Mobile Specific Accessibility */
@media (max-width: 600px) {
    body {
        font-size: 1rem;
        /* Better default legibility */
    }

    h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    /* Fix internal vertical scrollbars (double scroll effect) */
    .wp-block-group,
    .is-layout-flow {
        overflow: visible !important;
    }

    /* Cookie Center Mobile Fix */
    .cky-preference-center,
    .cky-modal {
        max-width: 100vw !important;
        width: 100% !important;
        left: 0 !important;
        right: 0 !important;
        box-sizing: border-box !important;
    }

    /* Increase Tap Target Sizes (Min 44-48px height/width) */

    /* Search Form Inputs & Buttons */
    .search-filter-input-text__input,
    .search-filter-component-combobox-base__actions-input {
        min-height: 48px !important;
        height: 48px !important;
        box-sizing: border-box !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
    }

    .search-filter-input-button,
    .search-filter-input-reset {
        min-height: 48px !important;
        height: 48px !important;
        box-sizing: border-box !important;
        padding: 0 20px !important;
        display: inline-flex !important;
        align-items: center;
        justify-content: center;
    }

    /* Pagination Wrapping & Size */
    .pagination {
        flex-wrap: wrap !important;
        justify-content: center !important;
        gap: 8px !important;
    }

    .page-numbers {
        min-width: 44px !important;
        height: 44px !important;
        box-sizing: border-box !important;
        padding: 0 10px !important;
        display: inline-flex !important;
        align-items: center;
        justify-content: center;
        margin: 0 4px 8px !important;
        font-size: 16px !important;
    }

    /* Read More Links in Grid */
    .wp-block-read-more {
        height: 44px !important;
        box-sizing: border-box !important;
        padding: 0 20px !important;
        display: inline-flex !important;
        align-items: center;
        font-size: 16px !important;
    }

    /* Cookie Consent Toggle (if present) */
    .cky-btn-revisit {
        min-width: 44px !important;
        min-height: 44px !important;
    }
}

/* Medium screen (desktop) */
@media (min-width: 601px) and (max-width: 1024px) {
    /* Tablet-specific styles */
}

/* Large screen (desktop) */
@media (min-width: 1025px) {
    /* Desktop-specific styles */
}

/* =Custom Component Styles
-------------------------------------------------------------- */

/* Button styles */
.button,
button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
    background-color: #0073aa;
    border: none;
    border-radius: 3px;
    color: #fff;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1.5;
    padding: 0.6875em 1em 0.75em;
    text-decoration: none;
}

.button:hover,
button:hover,
input[type="button"]:hover,
input[type="reset"]:hover,
input[type="submit"]:hover {
    background-color: #005177;
    color: #fff;
}

.button:focus,
button:focus,
input[type="button"]:focus,
input[type="reset"]:focus,
input[type="submit"]:focus {
    box-shadow: 0 0 0 2px #0073aa;
    color: #fff;
}

/* Navigation menu styles */
.main-navigation {
    display: block;
    width: 100%;
}

.main-navigation ul {
    display: flex;
    flex-direction: column;
    list-style: none;
    margin: 0;
    padding-left: 0;
}

.main-navigation li {
    position: relative;
}

.main-navigation a {
    color: #333;
    display: block;
    padding: 0.75em 1em;
    text-decoration: none;
}

.main-navigation a:hover,
.main-navigation a:focus {
    background-color: #f9f9f9;
    color: #0073aa;
}

/* Footer styles */
.site-footer {
    border-top: 1px solid #eaeaea;
    margin-top: 2em;
    padding-top: 2em;
}

.site-info {
    font-size: 0.875rem;
    text-align: center;
}

/* =WordPress Core Classes
-------------------------------------------------------------- */

/* Social Links - Nextdoor Brand Colors */
.wp-social-link-nextdoor {
    background-color: #1B8751;
    color: #fff;
}

/* Alignments */
.alignleft {
    display: inline;
    float: left;
    margin-right: 1.5em;
}

.alignright {
    display: inline;
    float: right;
    margin-left: 1.5em;
}

.aligncenter {
    clear: both;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

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

.wp-caption img[class*="wp-image-"] {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.wp-caption-text {
    margin-bottom: 0;
}

/* Gallery */
.gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5em;
    justify-content: center;
}

.gallery-item {
    display: inline-block;
    text-align: center;
    width: 100%;
}

.gallery-columns-2 .gallery-item {
    max-width: 50%;
}

.gallery-columns-3 .gallery-item {
    max-width: 33.33%;
}

.gallery-columns-4 .gallery-item {
    max-width: 25%;
}

.gallery-columns-5 .gallery-item {
    max-width: 20%;
}

.gallery-columns-6 .gallery-item {
    max-width: 16.66%;
}

.gallery-columns-7 .gallery-item {
    max-width: 14.28%;
}

.gallery-columns-8 .gallery-item {
    max-width: 12.5%;
}

.gallery-columns-9 .gallery-item {
    max-width: 11.11%;
}

/* Pagination */
.pagination {
    clear: both;
    display: flex;
    justify-content: center;
    list-style: none;
    margin: 1em 0;
    padding: 0;
}

.pagination li {
    margin: 0;
    padding: 0;
}

.pagination a,
.pagination span {
    background-color: #f9f9f9;
    border: 1px solid #eaeaea;
    color: #333;
    display: block;
    float: left;
    margin-right: 0.5em;
    padding: 0.5em 1em;
    text-decoration: none;
}

.pagination a:hover,
.pagination a:focus {
    background-color: #0073aa;
    color: #fff;
}

/* =Accessibility
-------------------------------------------------------------- */

/* Text meant only for screen readers */
.screen-reader-text {
    clip: rect(1px, 1px, 1px, 1px);
    position: absolute !important;
    height: 1px;
    width: 1px;
    border: 0;
    padding: 0;
    margin: 0;
    overflow: hidden;
}

.screen-reader-text:focus {
    background-color: #f1f1f1;
    clip: auto !important;
    color: #21759b;
    display: block;
    font-size: 1em;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    width: auto;
    z-index: 100000;
}

/* Do not show the outline on focus when it is also visible on hover */
a:focus:hover {
    outline: none;
}

/* =Print Styles
-------------------------------------------------------------- */

@media print {
    body {
        font-size: 12pt;
        color: #000;
        background: #fff;
    }

    a {
        text-decoration: underline;
    }

    a[href]::after {
        content: " (" attr(href) ")";
    }

    .no-print {
        display: none !important;
    }
}