/*!
Theme Name: Payless Tire
Description: Modern, clean WordPress theme for Payless Tire Services (lesstires.com). Features thin header design, mobile optimization, and tire service business functionality.
Version: 1.0
Author: Custom Theme
Text Domain: payless-tire
*/

/* CSS Variables for consistent theming */
:root {
    --primary-color: #1a365d;      /* Deep blue for professionalism */
    --secondary-color: #e53e3e;    /* Red accent for urgency/action */
    --accent-color: #38a169;       /* Green for trust/success */
    --text-primary: #1a202c;       /* Dark gray for main text */
    --text-secondary: #718096;     /* Light gray for secondary text */
    --bg-primary: #ffffff;         /* White background */
    --bg-secondary: #f7fafc;       /* Light gray background */
    --border-color: #e2e8f0;       /* Light border color */
    --header-height: 60px;         /* Very thin header as requested */
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    font-display: swap; /* Improve font loading performance */
}

/* Very thin header design */
.site-header {
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    height: var(--header-height);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.site-logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.site-logo:hover {
    color: var(--secondary-color);
}

/* Navigation */
.main-nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    padding: 5px 0;
    transition: color 0.3s ease;
}

.main-nav a:hover {
    color: var(--secondary-color);
}

/* Phone number in header */
.header-phone {
    color: var(--primary-color);
    font-weight: bold;
    text-decoration: none;
}

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

/* Main content area */
.main-content {
    min-height: calc(100vh - var(--header-height) - 200px);
}

/* Container and layout utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, #2d5aa0 100%);
    color: white;
    padding: 40px 0; /* Reduced padding for mobile LCP optimization */
    text-align: center;
    will-change: transform; /* Optimize for animations */
}

.hero-title {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 20px;
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.cta-button {
    background: var(--secondary-color);
    color: white;
    padding: 15px 30px;
    border: none;
    border-radius: 5px;
    font-size: 1.1rem;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    cursor: pointer;
}

.cta-button:hover {
    background: #c53030;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(229, 62, 62, 0.3);
}

/* Services grid */
.services-section {
    padding: 80px 0;
    background: var(--bg-secondary);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.service-card {
    background: var(--bg-primary);
    padding: 40px 30px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.service-icon {
    font-size: 3rem;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.service-title {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.service-description {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Blog grid for Tire Info page - 3 posts per line, 6 visible without scrolling */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 30px;
    margin: 40px 0;
    min-height: 600px; /* Ensures 2 rows are visible without scrolling */
}

.blog-post-card {
    background: var(--bg-primary);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.blog-post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.blog-post-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.blog-post-content {
    padding: 25px;
}

.blog-post-title {
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.blog-post-excerpt {
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.read-more {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: bold;
}

.read-more:hover {
    text-decoration: underline;
}

/* Contact form */
.contact-section {
    padding: 60px 0;
    background: var(--bg-secondary);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    margin-top: 40px;
}

.contact-form {
    background: var(--bg-primary);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(26, 54, 93, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Contact info */
.contact-info {
    background: var(--bg-primary);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.contact-item {
    margin-bottom: 25px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
}

.contact-icon {
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-top: 2px;
}

.contact-details h4 {
    font-weight: bold;
    margin-bottom: 5px;
    color: var(--primary-color);
}

.contact-details p {
    color: var(--text-secondary);
    margin: 0;
}

/* Map container */
.map-container {
    margin-top: 30px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.map-placeholder {
    width: 100%;
    height: 300px;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    font-style: italic;
}

/* Footer */
.site-footer {
    background: var(--primary-color);
    color: white;
    padding: 40px 0 20px;
    margin-top: 60px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-section h3 {
    margin-bottom: 20px;
    color: white;
}

.footer-section p,
.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    line-height: 1.6;
}

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

.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);
}

/* Mobile responsiveness - optimized for LCP */
@media (max-width: 768px) {
    .header-container {
        padding: 0 15px;
    }
    
    .main-nav {
        display: none; /* Will implement mobile menu */
    }
    
    .hero-title {
        font-size: 2rem;
        margin-bottom: 15px; /* Reduced margin for faster paint */
    }
    
    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 20px; /* Reduced margin for faster paint */
    }
    
    .services-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .hero-section {
        padding: 30px 0; /* Further reduced for mobile LCP */
    }
    
    .services-section,
    .contact-section {
        padding: 40px 0;
    }
    
    /* Optimize service cards for mobile LCP */
    .service-card {
        padding: 25px 20px;
        transform: none; /* Remove transforms on mobile for faster paint */
    }
    
    .service-card:hover {
        transform: none; /* Disable hover effects on mobile */
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.8rem;
        margin-bottom: 10px; /* Further reduced for mobile LCP */
    }
    
    .hero-subtitle {
        font-size: 0.9rem;
        margin-bottom: 15px; /* Further reduced for mobile LCP */
    }
    
    .hero-section {
        padding: 25px 0; /* Minimal padding for fastest mobile LCP */
    }
    
    .service-card,
    .contact-form,
    .contact-info {
        padding: 25px 20px;
    }
    
    /* Optimize button for mobile LCP */
    .cta-button {
        font-size: 1rem;
        padding: 12px 24px;
    }
}

/* Section headings */
.section-title {
    font-size: 2.5rem;
    font-weight: bold;
    text-align: center;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.section-subtitle {
    font-size: 1.2rem;
    text-align: center;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* Utility classes */
.text-center { text-align: center; }
.mb-40 { margin-bottom: 40px; }
.mt-40 { margin-top: 40px; }
.hidden { display: none; }