/*
 Theme Name: Montcar
 Theme URI: https://example.com/montcar
 Author: Emanoel de Oliveira
 Author URI: https://example.com
 Description: Tema WordPress para comércio de veículos
 Version: 1.0.0
 License: GNU General Public License v2 or later
 License URI: http://www.gnu.org/licenses/gpl-2.0.html
 Text Domain: montcar
 Tags: vehicles, automotive, e-commerce
*/

body {
    font-family: 'Roboto', Arial, sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* Container com Bootstrap */
.container {
    max-width: 1140px; /* Bootstrap container width */
    margin: 0 auto;
    padding: 0 15px;
}

/* Tipografia reduzida para telas maiores */
h1, .hero-title {
    font-size: 2.25rem; /* Reduzido de 3em */
    margin: 0 0 0.5rem;
}

h2, .section-title, .welcome-title {
    font-size: 1.75rem; /* Reduzido de 2rem/3rem */
    margin-bottom: 1.5rem;
}

h3, .vehicle-title {
    font-size: 1.25rem; /* Reduzido de 1.5rem */
    margin-bottom: 0.75rem;
}

.hero-subtitle {
    font-size: 1.25rem; /* Reduzido de 1.5em */
    margin: 0.5rem 0 1rem;
}

p {
    font-size: 0.9rem; /* Reduzido para melhor proporção */
    line-height: 1.7;
    margin-bottom: 1rem;
}

/* Hero Section */
.hero-section {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 400px; /* Reduzido de 500px */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    position: relative;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
}

.hero-content {
    position: relative;
    z-index: 1;
}

/* Filtros de Veículos */
.vehicle-filters {
    padding: 1.5rem 0; /* Aumentado de 20px */
    background: #f8f9fa;
    margin-bottom: 2rem;
}

.vehicle-filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 15px; /* Aumentado de 10px */
}

.filter-group {
    flex: 1 1 200px; /* Aumentado de 150px */
    min-width: 150px; /* Aumentado de 120px */
}

.filter-group label {
    font-size: 0.85rem; /* Reduzido de 0.9em */
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: #333;
}

.filter-group select,
.filter-group input {
    width: 100%;
    padding: 0.5rem; /* Reduzido de 8px */
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.85rem; /* Reduzido de 0.9em */
    background: #fff;
    transition: border-color 0.2s;
}

.filter-group select:focus,
.filter-group input:focus {
    border-color: #007bff;
    outline: none;
}

.filter-actions {
    display: flex;
    gap: 15px; /* Aumentado de 10px */
    align-items: center;
}

/* Botões com Bootstrap */
.btn {
    padding: 0.5rem 1rem; /* Reduzido de 8px 16px */
    border: none;
    border-radius: 4px;
    font-size: 0.85rem; /* Reduzido de 0.9em */
    font-weight: 500;
    transition: background 0.2s;
}

.btn-primary {
    background: #007bff;
    color: #fff;
}

.btn-primary:hover {
    background: #0056b3;
}

.btn-secondary {
    background: #6c757d;
    color: #fff;
}

.btn-secondary:hover {
    background: #5a6268;
}

/* Seções */
.welcome-section,
.service-section,
.featured-cars-section,
.contact-section,
.blog-section {
    padding: 3rem 0; /* Reduzido de 50px, aumentado espaçamento interno */
}

/* Welcome e Service Sections */
.welcome-content,
.service-content {
    display: flex;
    gap: 2rem; /* Reduzido de 30px */
    align-items: center;
}

.welcome-text,
.service-text {
    flex: 1;
}

.welcome-image,
.service-image {
    flex: 1;
}

.welcome-image img,
.service-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.service-features {
    list-style: none;
    padding: 0;
}

.service-features li {
    padding: 0.75rem 0; /* Reduzido de 10px */
    font-size: 1rem; /* Reduzido de 1.1em */
}

/* Grid de Veículos com Bootstrap */
.vehicles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* Reduzido de 350px */
    gap: 1.5rem; /* Aumentado de 20px */
}

/* Card de Veículo */
.vehicle-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.2s;
    max-width: 300px; /* Reduzido de 350px */
}

.vehicle-card:hover {
    transform: translateY(-5px);
}

.vehicle-image-container {
    position: relative;
}

.vehicle-image-container img {
    width: 100%;
    height: 200px; /* Reduzido de 250px */
    object-fit: cover;
    display: block;
}

.vehicle-image-container img.lazy {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.vehicle-image-container img.loaded {
    opacity: 1;
}

.vehicle-image {
    position: relative;
    width: 100%;
    max-width: 300px;
    height: 200px;
    overflow: hidden;
}

.vehicle-image img.vehicle-thumbnail,
.vehicle-image img.wp-post-image,
.vehicle-image img.default-image {
    width: 300px;
    height: 200px;
    object-fit: cover;
}

.vehicle-badge {
    position: absolute;
    top: 0.75rem; /* Reduzido de 1rem */
    left: 0.75rem;
    padding: 0.4rem 0.8rem; /* Reduzido de 0.5rem 1rem */
    border-radius: 20px;
    font-size: 0.75rem; /* Reduzido de 0.8rem */
    font-weight: 600;
    text-transform: uppercase;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.badge-featured {
    background: #ffc107;
}

.badge-sold {
    background: #dc3545;
}

.vehicle-info {
    padding: 1rem; /* Reduzido de 15px */
}

.vehicle-title {
    font-size: 1.25rem; /* Reduzido de 1.5em */
    margin: 0 0 0.5rem;
}

.vehicle-price {
    font-size: 1.1rem; /* Reduzido de 1.2em */
    color: #28a745;
    margin: 0.5rem 0;
}

.vehicle-details {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem; /* Aumentado de 10px */
    margin-bottom: 0.75rem;
}

.vehicle-detail {
    font-size: 0.85rem; /* Reduzido de 0.9em */
    color: #666;
}

.vehicle-detail span {
    font-weight: 500;
    margin-right: 5px;
}

.vehicle-actions {
    display: flex;
    gap: 0.75rem; /* Aumentado de 10px */
    align-items: center;
}

.favorite-button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem; /* Reduzido de 1.2em */
    color: #ff6b6b;
}

.favorite-button:hover {
    color: #e63737;
}

.btn-view {
    background: #007bff;
    color: #fff;
    text-decoration: none;
}

/* Contato */
.contact-section {
    text-align: center;
    background: #f8f9fa;
}

.contact-phone {
    display: inline-block;
    margin-top: 0.75rem; /* Reduzido de 10px */
    font-size: 1.25rem; /* Reduzido de 1.5em */
    color: #007bff;
    text-decoration: none;
}

/* Blog */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Reduzido de 300px */
    gap: 1.5rem; /* Aumentado de 20px */
}

.blog-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
}

.blog-image {
    width: 100%;
    height: 180px; /* Reduzido de 200px */
    object-fit: cover;
}

.blog-content {
    padding: 1rem; /* Reduzido de 15px */
}

.blog-title {
    font-size: 1.2rem; /* Reduzido de 1.3em */
    margin: 0 0 0.5rem;
}

.blog-excerpt {
    color: #666;
    margin-bottom: 0.5rem;
}

.blog-meta {
    color: #999;
    font-size: 0.85rem; /* Reduzido de 0.9em */
}

/* Paginação com Bootstrap */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1.5rem; /* Reduzido de 20px */
}

.pagination .page-item .page-link {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: #007bff;
}

.pagination .page-item .page-link:hover {
    background: #007bff;
    color: #fff;
}

.pagination .page-item.active .page-link {
    background: #007bff;
    color: #fff;
    border-color: #007bff;
}

/* Sem Resultados */
.no-results {
    text-align: center;
    padding: 1.5rem; /* Aumentado de 20px */
}

/* Voltar ao Topo */
.back-to-top {
    bottom: 1.5rem; /* Reduzido de 20px */
    right: 1.5rem;
    width: 36px; /* Reduzido de 40px */
    height: 36px;
    font-size: 1rem; /* Reduzido de 1.2rem */
}

/* Ações do Card */
.vehicle-actions-bottom {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem; /* Aumentado de 10px */
    margin-top: 0.75rem;
}

.vehicle-actions button,
.vehicle-actions-bottom .btn {
    padding: 0.5rem 1rem; /* Reduzido */
    font-size: 0.85rem; /* Reduzido */
}

/* Meta do Card */
.vehicle-meta {
    padding: 0.75rem 1rem; /* Reduzido de 10px 15px */
    background: #f9f9f9;
    font-size: 0.8rem; /* Reduzido de 12px */
    color: #666;
}

/* Animações */
.fade-in-up {
    animation: fadeInUp 0.5s ease-in;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(15px); } /* Reduzido de 20px */
    to { opacity: 1; transform: translateY(0); }
}

/* Responsividade para telas grandes */
@media (min-width: 992px) {
    h1, .hero-title { font-size: 2rem; } /* Reduzido */
    h2, .section-title, .welcome-title { font-size: 1.5rem; }
    h3, .vehicle-title { font-size: 1.1rem; }
    .hero-subtitle { font-size: 1.1rem; }
    p { font-size: 0.85rem; }
    .vehicle-card { max-width: 300px; }
    .vehicle-image-container img { height: 200px; }
    .vehicle-image img.vehicle-thumbnail { width: 300px; height: 200px; }
    .vehicle-price { font-size: 1rem; }
    .vehicle-details { gap: 0.5rem; }
    .vehicle-detail { font-size: 0.8rem; }
    .btn { padding: 0.4rem 0.8rem; font-size: 0.8rem; }
}

/* Responsividade para telas menores */
@media (max-width: 768px) {
    .vehicle-filter-form {
        flex-direction: column;
        align-items: stretch;
    }
    .filter-group {
        flex: 1 1 100%;
    }
    .filter-actions {
        justify-content: center;
    }
    .welcome-content,
    .service-content {
        flex-direction: column;
        gap: 1.5rem;
    }
    .hero-title {
        font-size: 1.75rem;
    }
    .hero-subtitle {
        font-size: 1rem;
    }
    .vehicles-grid {
        grid-template-columns: 1fr;
    }
    .vehicle-card {
        max-width: 100%;
    }
    .vehicle-image-container img {
        height: auto;
    }
    .blog-grid {
        grid-template-columns: 1fr;
    }
}