/* ============================================
   ImóvelPRO - Estilos Premium Carmim & Dourado
   Tema Luxuoso para Imobiliárias de Alto Padrão
   Versão 1.0.5
   ============================================ */

/* Importar variáveis de cores do style.css primeiro */

/* ============================================
   Estilos do Cabeçalho - Elegante  
   ============================================ */
.site-header {
    background-color: #ffffff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    /* Fallback generic shadow */
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 2px solid #E8D4D7;
}

.header-top {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 0.5rem 0;
    font-size: 0.875rem;
}

.header-top-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-contact {
    display: flex;
    gap: 1.5rem;
}

.header-phone,
.header-email {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: white;
    font-weight: 500;
}

.header-phone svg,
.header-email svg {
    opacity: 0.95;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.15);
    color: white;
    transition: all 300ms ease-in-out;
    backdrop-filter: blur(4px);
}

.social-links a:hover {
    background: linear-gradient(135deg, var(--secondary-light) 0%, var(--secondary-color) 100%);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 4px 12px rgba(197, 165, 114, 0.3);
}

.header-main {
    padding: 1.5rem 0;
    background: #ffffff;
}

.header-main-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-branding {
    flex-shrink: 0;
}

/* Logo Sizing */
.custom-logo-link img,
.site-branding img,
.custom-logo {
    width: var(--logo-width, 200px);
    height: auto;
    max-width: 100%;
}

.site-title {
    margin: 0;
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.site-title a {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.site-description {
    margin: 0;
    font-size: 0.875rem;
    color: var(--secondary-color);
    font-weight: 600;
}

/* Navegação Premium */
.main-navigation {
    display: flex;
    align-items: center;
}

.menu-toggle {
    display: none;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.5rem;
}

.nav-menu li {
    margin: 0;
}

.nav-menu a {
    display: block;
    padding: 0.5rem 1.5rem;
    color: #404040;
    font-weight: 600;
    transition: all 300ms ease-in-out;
    border-radius: 0.5rem;
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 80%;
    height: 2px;
    background: linear-gradient(135deg, var(--secondary-light) 0%, var(--secondary-color) 100%);
    transition: transform 300ms ease-in-out;
}

.nav-menu a:hover,
.nav-menu .current-menu-item a,
.nav-menu .current_page_item a {
    color: var(--primary-color);
    background-color: #E8D4D7;
    /* Consider making this a variable too, but it's a tint */
}

.nav-menu a:hover::after,
.nav-menu .current-menu-item a::after {
    transform: translateX(-50%) scaleX(1);
}

/* ============================================
   Cards de Imóveis - Luxuosos
   ============================================ */
.property-card {
    background: #ffffff;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: all 300ms ease-in-out;
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid #e8e8e8;
}

.property-card:hover {
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08), 0 4px 12px rgba(197, 165, 114, 0.3);
    transform: translateY(-8px);
    border-color: var(--secondary-light);
}

.property-card-image {
    position: relative;
    width: 100%;
    padding-bottom: 66.67%;
    overflow: hidden;
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
}

.property-card-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 500ms ease-in-out;
}

.property-card:hover .property-card-image img {
    transform: scale(1.12);
}

.property-status-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    padding: 0.25rem 1.5rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(8px);
}

.property-status-badge.disponivel {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    color: white;
}

.property-status-badge.alugado {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.property-status-badge.vendido {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    color: white;
}

.property-card-body {
    padding: 2rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #ffffff;
}

.property-price {
    font-size: 1.875rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    letter-spacing: -0.5px;
}

.property-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #171717;
    line-height: 1.4;
}

.property-title a {
    color: inherit;
    transition: color 150ms ease-in-out;
}

.property-title a:hover {
    color: var(--primary-color);
}

.property-location {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--secondary-dark);
    font-size: 0.875rem;
    margin-bottom: 1rem;
    font-weight: 500;
}

.property-features {
    display: flex;
    gap: 1.5rem;
    list-style: none;
    padding: 0;
    margin: 1rem 0 0;
    padding-top: 1rem;
    border-top: 2px solid #E8D4D7;
}

.property-features li {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.875rem;
    color: #525252;
    font-weight: 500;
}

.property-features .icon {
    font-size: 1.25rem;
}

/* ============================================
   Filtros de Busca - Premium
   ============================================ */
.property-filters {
    background: #ffffff;
    padding: 3rem;
    border-radius: 1.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05), 0 4px 12px rgba(197, 165, 114, 0.3);
    margin-bottom: 4rem;
    border: 2px solid #E8D4D7;
}

.filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.filter-submit {
    text-align: right;
}

/* Botões Premium */
.btn {
    display: inline-block;
    padding: 14px 2rem;
    font-size: 1rem;
    font-weight: 700;
    text-align: center;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 300ms ease-in-out;
    text-decoration: none;
    line-height: 1.5;
    letter-spacing: 0.3px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08);
}

.btn-secondary {
    background: linear-gradient(135deg, var(--secondary-light) 0%, var(--secondary-color) 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(197, 165, 114, 0.3);
}

.btn-secondary:hover {
    background: var(--secondary-dark);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(197, 165, 114, 0.4);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border-color: transparent;
}

.btn-lg {
    padding: 18px 3rem;
    font-size: 1.125rem;
}

/* ============================================
   Rodapé Premium
   ============================================ */
.site-footer {
    background: linear-gradient(135deg, #171717 0%, #262626 100%);
    color: #d4d4d4;
    padding: 4rem 0 2rem;
    margin-top: 4rem;
    position: relative;
}

.site-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, var(--secondary-light) 0%, var(--secondary-color) 100%);
}

.footer-widgets {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-widget .widget-title {
    color: var(--secondary-light);
    font-size: 1.125rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.footer-bottom {
    border-top: 1px solid rgba(197, 165, 114, 0.2);
    padding-top: 1.5rem;
    text-align: center;
    font-size: 0.875rem;
    color: #a3a3a3;
}

/* ============================================
   Botão Flutuante WhatsApp - Dourado
   ============================================ */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 999;
}

.whatsapp-float a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--secondary-light) 0%, var(--secondary-color) 100%);
    color: white;
    border-radius: 50%;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08), 0 4px 12px rgba(197, 165, 114, 0.3);
    transition: all 300ms ease-in-out;
}

.whatsapp-float a:hover {
    transform: scale(1.15) rotate(5deg);
    box-shadow: 0 12px 28px rgba(197, 165, 114, 0.5);
}

/* Gradientes especiais para Hero */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="40" height="40" patternUnits="userSpaceOnUse"><path d="M 40 0 L 0 0 0 40" fill="none" stroke="rgba(255,255,255,0.03)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

/* ============================================
   Grade de Imóveis
   ============================================ */
.properties-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 4rem;
}

/* ============================================
   MOBILE PRIMEIRO - 90% dos usuários
   ============================================ */

/* Touch Targets - Mínimo 44px */
.btn,
.menu-toggle,
.nav-menu a,
.property-card,
.form-control,
select.form-control {
    min-height: 44px;
}

/* Tipografia Mobile - Maior e mais legível */
body {
    font-size: 17px;
    line-height: 1.6;
}

h1 {
    font-size: 2rem;
}

h2 {
    font-size: 1.75rem;
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.25rem;
}

/* Header Mobile Simplificado */
.header-top {
    display: none;
    /* Oculto no mobile */
}

.header-main {
    padding: 1rem 0;
}

.site-title {
    font-size: 1.5rem;
}

.menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 12px;
    min-width: 44px;
    min-height: 44px;
}

.menu-icon {
    width: 28px;
    height: 3px;
    background-color: #262626;
    border-radius: 2px;
    transition: all 300ms ease-in-out;
}

.nav-menu {
    display: none;
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    bottom: 0;
    background: white;
    flex-direction: column;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    padding: 1.5rem;
    overflow-y: auto;
    z-index: 999;
}

.nav-menu.active {
    display: flex;
}

.nav-menu li {
    border-bottom: 1px solid #e8e8e8;
}

.nav-menu a {
    padding: 1.5rem 1rem;
    font-size: 1.125rem;
}

/* Mobile Search Bar */
.mobile-search-bar {
    background-color: #f5f5f5;
    padding: 1rem 0;
    border-bottom: 1px solid #e8e8e8;
}

.mobile-search-bar .search-form {
    display: flex;
    gap: 0.5rem;
}

.mobile-search-bar .search-field {
    flex: 1;
    padding: 10px 1rem;
    border: 1px solid #ddd;
    border-radius: 0.5rem;
    font-size: 1rem;
}

.mobile-search-bar .search-submit {
    padding: 0 1.25rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-weight: 600;
}

/* Property Cards Mobile */
.property-card-body {
    padding: 1.5rem;
}

.property-price {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.property-title {
    font-size: 1.375rem;
}

.property-location {
    font-size: 1.125rem;
    margin-bottom: 1rem;
}

.property-features {
    gap: 1rem;
    flex-wrap: wrap;
}

.property-features li {
    font-size: 1rem;
}

/* Filtros Mobile */
.property-filters {
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.filters-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-label {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    display: block;
    color: #404040;
}

.form-control {
    padding: 14px 1rem;
    font-size: 1rem;
    border-radius: 0.5rem;
    border: 2px solid #e8e8e8;
    width: 100%;
}

.form-control:focus {
    border-color: var(--primary-color);
    outline: none;
}

select.form-control {
    padding: 14px 1rem;
    background-size: 16px;
}

.filter-submit {
    text-align: center;
    margin-top: 1rem;
}

.filter-submit .btn {
    width: 100%;
}

/* WhatsApp Mobile - Maior */
.whatsapp-float {
    bottom: 20px;
    right: 20px;
}

.whatsapp-float a {
    width: 60px;
    height: 60px;
}

/* Footer Mobile */
.footer-widgets {
    grid-template-columns: 1fr;
    gap: 2rem;
}

.site-footer {
    padding: 3rem 0 2rem;
}

/* Container Mobile */
.container {
    padding-left: 1rem;
    padding-right: 1rem;
}

/* Single Property Mobile */
.property-details-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
}

.property-main-info {
    padding: 1.5rem;
}

.property-sidebar {
    position: static;
}

.property-contact-card {
    position: sticky;
    bottom: 0;
    z-index: 100;
    margin: 0;
    border-radius: 0;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.15);
    padding: 1.5rem;
}

/* Gallery Mobile */
.property-gallery {
    grid-template-columns: 1fr;
    gap: 0.5rem;
}

.gallery-main {
    grid-column: 1;
}

.gallery-thumb {
    display: none;
    /* Oculto no mobile */
}

.property-features-list {
    grid-template-columns: 1fr;
}

/* ============================================
   TABLET (768px - 1024px)
   ============================================ */
@media (min-width: 768px) {

    /* 2 colunas no tablet */
    .properties-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .filters-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-widgets {
        grid-template-columns: repeat(2, 1fr);
    }

    .gallery-thumb {
        display: block;
    }

    .property-gallery {
        grid-template-columns: repeat(2, 1fr);
    }

    .gallery-main {
        grid-column: span 2;
    }

    .property-features-list {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ============================================
   DESKTOP (1024px+)
   ============================================ */
@media (min-width: 1024px) {

    /* Header Desktop */
    .header-top {
        display: block;
    }

    .menu-toggle {
        overflow-y: visible;
    }

    .mobile-search-bar {
        display: none;
    }

    .nav-menu {
        display: flex;
        position: static;
        flex-direction: row;
        background: transparent;
        box-shadow: none;
        padding: 0;
        gap: 0.5rem;
    }

    .nav-menu li {
        border-bottom: none;
    }

    .nav-menu a {
        padding: 0.5rem 1.5rem;
        font-size: 1rem;
    }

    /* Grid Desktop - 3 colunas */
    .properties-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .filters-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    /* Property Details Desktop */
    .property-details-grid {
        grid-template-columns: 2fr 1fr;
    }

    .property-sidebar {
        position: sticky;
        top: 100px;
    }

    .property-contact-card {
        position: static;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
        border-radius: 1rem;
        padding: 2rem;
    }

    /* Gallery Desktop */
    .property-gallery {
        grid-template-columns: repeat(4, 1fr);
    }

    .gallery-main {
        grid-column: span 4;
    }

    /* Footer Desktop */
    .footer-widgets {
        grid-template-columns: repeat(4, 1fr);
    }

    /* Container Desktop */
    .container {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
        max-width: 1280px;
        margin: 0 auto;
    }

    /* Tipografia Desktop */
    body {
        font-size: 16px;
    }

    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    h3 {
        font-size: 1.75rem;
    }
}

/* ============================================
   Performance Mobile
   ============================================ */
html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

img {
    image-rendering: -webkit-optimize-contrast;
}

button:active,
.btn:active,
a:active {
    opacity: 0.8;
}

* {
    -webkit-tap-highlight-color: transparent;
}

button,
.btn,
a {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
}