/*
Theme Name: Barry's Tire Tech
Author: Michael Staake
Author URI: https://michaelstaake.com
Version: 2025.09.03.01
*/

/* ==========================================================================
   Global Typography Styles
   ========================================================================== */

/* Base font for entire website */
body {
    font-family: 'Open Sans', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
}

/* Global heading styles */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Saira', Arial, sans-serif;
    font-weight: 600;
    line-height: 1.3;
    color: #2c3e50;
}

/* ==========================================================================
   Content Styles for .entry-content
   ========================================================================== */

.entry-content {
    font-family: 'Open Sans', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    max-width: 100%;
    word-wrap: break-word;
}

/* Headings */
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
    font-family: 'Saira', Arial, sans-serif;
    font-weight: 600;
    line-height: 1.3;
    margin: 1em 0 0.5em 0;
    color: #2c3e50;
}

/* Remove top margin from first heading in content */
.entry-content h1:first-child,
.entry-content h2:first-child,
.entry-content h3:first-child,
.entry-content h4:first-child,
.entry-content h5:first-child,
.entry-content h6:first-child {
    margin-top: 0;
}

/* ==========================================================================
   Front Page Latest Posts Card Hover Effects
   ========================================================================== */

/* Make title blue when hovering anywhere on the card */
article:hover h3 {
    color: #2563eb !important; /* Blue color */
}

/* Also target the link wrapper around cards */
a:hover article h3 {
    color: #2563eb !important; /* Blue color */
}

.entry-content h1 {
    font-size: 2.5em;
    border-bottom: 3px solid #3498db;
    padding-bottom: 0.3em;
}

.entry-content h2 {
    font-size: 2em;
    border-bottom: 2px solid #ecf0f1;
    padding-bottom: 0.25em;
}

.entry-content h3 {
    font-size: 1.5em;
}

.entry-content h4 {
    font-size: 1.25em;
}

.entry-content h5 {
    font-size: 1.1em;
}

.entry-content h6 {
    font-size: 1em;
    color: #7f8c8d;
}

/* Paragraphs */
.entry-content p {
    margin: 0 0 1.5em 0;
    font-size: 1em;
}

.entry-content p:last-child {
    margin-bottom: 0;
}

/* Lists */
.entry-content ul,
.entry-content ol {
    margin: 0 0 1.5em 0;
    padding-left: 2em;
}

.entry-content ul ul,
.entry-content ol ol,
.entry-content ul ol,
.entry-content ol ul {
    margin-bottom: 0;
}

.entry-content li {
    margin-bottom: 0.5em;
}

.entry-content ul li {
    list-style-type: disc;
}

.entry-content ul ul li {
    list-style-type: circle;
}

.entry-content ul ul ul li {
    list-style-type: square;
}

.entry-content ol li {
    list-style-type: decimal;
}

/* Tables */
.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5em 0;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.entry-content table th,
.entry-content table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.entry-content table th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #2c3e50;
    border-bottom: 2px solid #3498db;
}

.entry-content table tr:hover {
    background-color: #f5f5f5;
}

.entry-content table tr:nth-child(even) {
    background-color: #fafafa;
}

/* Blockquotes */
.entry-content blockquote {
    margin: 1.5em 0;
    padding: 1em 1.5em;
    border-left: 4px solid #3498db;
    background-color: #f8f9fa;
    font-style: italic;
    position: relative;
}

.entry-content blockquote p {
    margin: 0;
    font-size: 1.1em;
    color: #555;
}

.entry-content blockquote cite {
    display: block;
    margin-top: 0.5em;
    font-size: 0.9em;
    color: #777;
    font-style: normal;
}

.entry-content blockquote cite:before {
    content: "— ";
}

/* Code and Pre */
.entry-content code {
    background-color: #f4f4f4;
    border: 1px solid #ddd;
    border-radius: 3px;
    padding: 2px 6px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9em;
    color: #e74c3c;
}

.entry-content pre {
    background-color: #2c3e50;
    color: #ecf0f1;
    border-radius: 5px;
    padding: 1.5em;
    margin: 1.5em 0;
    overflow-x: auto;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9em;
    line-height: 1.4;
}

.entry-content pre code {
    background: none;
    border: none;
    padding: 0;
    color: inherit;
    font-size: inherit;
}

/* Links */
.entry-content a {
    color: #1F2937;
    text-decoration: none;
    border-bottom: 1px solid #1F2937;
    transition: all 0.3s ease;
}

.entry-content a:hover {
    color: #374151;
    border-bottom-color: transparent;
}

/* Images */
.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 3px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Horizontal Rules */
.entry-content hr {
    border: none;
    border-top: 2px solid #ecf0f1;
    margin: 2em 0;
}

/* Definition Lists */
.entry-content dl {
    margin: 1.5em 0;
}

.entry-content dt {
    font-weight: 600;
    color: #2c3e50;
    margin-top: 1em;
}

.entry-content dd {
    margin: 0.5em 0 0 2em;
}

/* Address */
.entry-content address {
    font-style: italic;
    margin: 1.5em 0;
    padding: 1em;
    background-color: #f8f9fa;
    border-left: 4px solid #95a5a6;
}

/* Small text */
.entry-content small {
    font-size: 0.85em;
    color: #777;
}

/* Mark/Highlight */
.entry-content mark {
    background-color: #fff3cd;
    padding: 2px 4px;
    border-radius: 2px;
}

/* ==========================================================================
   Footer Styles
   ========================================================================== */

footer {
    color: white !important;
}

footer * {
    color: white !important;
}

footer h1,
footer h2,
footer h3,
footer h4,
footer h5,
footer h6 {
    color: white !important;
}

footer p {
    color: white !important;
}

footer a {
    color: white !important;
    text-decoration: underline;
}

footer a:hover {
    color: #bdc3c7 !important;
}

footer ul,
footer ol,
footer li {
    color: white !important;
}

footer .menu a {
    color: white !important;
}

/* ==========================================================================
   Hero Search Form Styles
   ========================================================================== */

.hero-search button[type="submit"] {
    background-color: white !important;
    background-image: none !important; /* Override inherited background image */
    color: #1F2937 !important; /* Dark blue for icon */
    font-weight: 900 !important; /* Make icon bolder */
}

.hero-search button[type="submit"]:hover {
    background-color: #f3f4f6 !important; /* Light gray on hover */
    background-image: none !important; /* Override inherited background image */
    color: #1F2937 !important;
    font-weight: 900 !important; /* Keep bold on hover */
}

/* ==========================================================================
   Search Form Focus Styles
   ========================================================================== */

input[type="search"]:focus {
    outline: none !important;
    border-color: #1F2937 !important;
    box-shadow: 0 0 0 2px rgba(31, 41, 55, 0.2) !important;
}

/* Specific targeting for search forms */
form[role="search"] input[type="search"]:focus,
.search-form input[type="search"]:focus {
    outline: none !important;
    border-color: #1F2937 !important;
    box-shadow: 0 0 0 2px rgba(31, 41, 55, 0.2) !important;
}

/* ==========================================================================
   Sidebar Widget Styles
   ========================================================================== */

/* Sidebar container */
aside {
    font-family: 'Open Sans', Arial, sans-serif;
    background-color: #ffffff;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: box-shadow 0.3s ease;
    align-self: start; /* Make sidebar only as tall as content */
}

aside:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* Widget containers - remove individual backgrounds */
.widget {
    background: none;
    border: none;
    border-radius: 0;
    padding: 0;
    margin-bottom: 1.5rem;
    box-shadow: none;
}

/* Widget headings */
.widget h2,
.widget .wp-block-heading {
    font-family: 'Saira', Arial, sans-serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: #1F2937;
    margin: 0 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #f3f4f6;
}

/* Search widget specific styling */
.widget_search .wp-block-search__label {
    font-family: 'Saira', Arial, sans-serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: #1F2937;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #f3f4f6;
    display: block;
}

/* Search form styling */
.wp-block-search__inside-wrapper {
    display: flex;
    gap: 0.5rem;
}

.wp-block-search__input {
    flex: 1;
    padding: 0.75rem;
    border: 2px solid #e5e5e5;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.wp-block-search__input:focus {
    outline: none;
    border-color: #1F2937;
    box-shadow: 0 0 0 2px rgba(31, 41, 55, 0.2);
}

.wp-block-search__button {
    background-color: #1F2937;
    color: white;
    border: none;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.wp-block-search__button:hover {
    background-color: #374151;
}

/* Latest Posts widget */
.wp-block-latest-posts__list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.wp-block-latest-posts__list li {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f3f4f6;
}

.wp-block-latest-posts__list li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

/* Post titles in sidebar */
.wp-block-latest-posts__post-title {
    font-weight: 600;
    color: #1F2937;
    text-decoration: none;
    display: block;
    margin-bottom: 0.25rem;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.wp-block-latest-posts__post-title:hover {
    color: #374151;
    text-decoration: underline;
}

/* Post dates in sidebar */
.wp-block-latest-posts__post-date {
    font-size: 0.875rem;
    color: #6b7280;
    font-style: italic;
}

/* General widget lists */
.widget ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.widget li {
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #f3f4f6;
}

.widget li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

/* Widget links */
.widget a {
    color: #1F2937;
    text-decoration: none;
    transition: color 0.3s ease;
}

.widget a:hover {
    color: #374151;
    text-decoration: underline;
}

/* ==========================================================================
   Textured Background Styles
   ========================================================================== */

/* Hero sections with textured background */
.hero-section {
    background-image: 
        linear-gradient(rgba(31, 41, 55, 0.85), rgba(31, 41, 55, 0.85)),
        url('textured-background.jpg');
    background-size: auto;
    background-position: top left;
    background-repeat: repeat;
}

/* Page title headers with textured background */
.page-title-header,
.archive-header,
.search-header {
    background-image: 
        linear-gradient(rgba(31, 41, 55, 0.85), rgba(31, 41, 55, 0.85)),
        url('textured-background.jpg');
    background-size: auto;
    background-position: top left;
    background-repeat: repeat;
}

/* Footer with textured background */
footer {
    background-image: 
        linear-gradient(rgba(31, 41, 55, 0.9), rgba(31, 41, 55, 0.9)),
        url('textured-background.jpg') !important;
    background-size: auto !important;
    background-position: top left !important;
    background-repeat: repeat !important;
}

/* Alternative selectors for hero sections if using different classes */
.bg-gray-800,
.bg-gray-900 {
    background-image: 
        linear-gradient(rgba(31, 41, 55, 0.85), rgba(31, 41, 55, 0.85)),
        url('textured-background.jpg');
    background-size: auto;
    background-position: top left;
    background-repeat: repeat;
}

/* ==========================================================================
   Mobile Responsive Styles
   ========================================================================== */

/* Header Navigation Styles */
.menu a,
nav a {
    color: #1F2937 !important;
    text-decoration: none;
    padding-bottom: 2px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.menu a:hover,
nav a:hover {
    color: #1F2937 !important;
    border-bottom-color: #1F2937;
}

/* Current/Active menu item styles */
.menu .current-menu-item > a,
.menu .current_page_item > a,
.menu .current-page-ancestor > a,
nav .current-menu-item > a,
nav .current_page_item > a,
nav .current-page-ancestor > a {
    font-weight: bold !important;
    border-bottom-color: #1F2937 !important;
    color: #1F2937 !important;
}

/* Reduce hero section padding on mobile devices */
@media (max-width: 768px) {
    /* Center navigation menu items on mobile */
    nav,
    .menu {
        text-align: center;
    }
    
    nav ul,
    .menu ul {
        justify-content: center;
        align-items: center;
    }
    
    .hero {
        padding-top: 3rem !important; /* Reduce from py-20 (5rem) to 3rem */
        padding-bottom: 3rem !important;
    }
    
    /* Specifically target hero sections with classes */
    .hero-section,
    .hero-section-default,
    .hero-section-custom,
    section.hero {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }
    
    /* Also target sections with hero-related background classes */
    .bg-gray-800.py-20,
    .bg-gray-900.py-20 {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }
}