/* ============================================================
   CASA E AP IMOBILIÁRIA - STYLE.CSS
   ============================================================ */

/* ============ VARIÁVEIS GLOBAIS ============ */
:root {
    --gold: #D4AF37;
    --gold-light: #E8C858;
    --gold-dark: #B8941F;
    --blue: #1a3a5c;
    --blue-light: #2c5282;
    --blue-dark: #0f2440;
    --white: #FFFFFF;
    --bg-light: #F8F9FA;
    --bg-cream: #FAF8F3;
    --text-dark: #000000;
    --text-muted: #666666;
    --border-light: #E9ECEF;
    --success: #28a745;
    --danger: #dc3545;
    --warning: #ffc107;
}

/* ============ RESET GLOBAL ============ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f5f5;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s;
}

a:hover {
    color: var(--gold);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
}

/* ============ HEADER ============ */
.header-modern,
.casaap-header {
    background: var(--white);
    border-bottom: 1px solid var(--border-light);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    width: 100%;
}

.header-content,
.casaap-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo-section img,
.casaap-logo img {
    height: 50px;
    display: block;
}

.search-bar,
.casaap-search {
    flex: 1;
    max-width: 600px;
    position: relative;
    min-width: 200px;
}

.search-bar input,
.casaap-search input {
    width: 100%;
    padding: 14px 20px 14px 50px;
    border: 2px solid var(--border-light);
    border-radius: 30px;
    font-size: 0.95rem;
    transition: all 0.3s;
    background: var(--bg-light);
    color: var(--text-dark);
    cursor: pointer;
    margin: 0;
}

.search-bar input:focus,
.casaap-search input:focus {
    outline: none;
    border-color: var(--gold);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1);
}

.search-bar i,
.casaap-search i {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gold);
    font-size: 1.1rem;
    z-index: 2;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-actions a {
    color: var(--text-dark);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    transition: color 0.3s;
}

.header-actions a:hover {
    color: var(--gold);
}

.header-actions i {
    font-size: 1.3rem;
}

.menu-btn,
.casaap-menu-btn {
    background: var(--gold);
    color: var(--white) !important;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
}

.menu-btn:hover,
.casaap-menu-btn:hover {
    background: var(--gold-dark);
    color: var(--white) !important;
    transform: translateY(-2px);
}

/* ============ CATEGORIAS ============ */
.categorias-section,
.casaap-categorias {
    padding: 40px 0;
    background: var(--blue);
    width: 100%;
}

.categorias-section h3,
.casaap-categorias h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    margin-bottom: 30px;
    color: var(--white);
    font-weight: 700;
}

.categorias-grid,
.casaap-categorias-grid {
    display: flex;
    gap: 30px;
    overflow-x: auto;
    padding: 10px 0;
    max-width: 1400px;
    margin: 0 auto;
    padding-left: 20px;
    padding-right: 20px;
}

.categoria-item,
.casaap-categoria-item {
    text-align: center;
    min-width: 100px;
    cursor: pointer;
    transition: transform 0.3s;
    flex-shrink: 0;
}

.categoria-item:hover,
.casaap-categoria-item:hover {
    transform: translateY(-5px);
}

.categoria-icon,
.casaap-categoria-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 10px;
    background: var(--white);
    border: 2px solid var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--blue);
    transition: all 0.3s;
}

.categoria-item:hover .categoria-icon,
.casaap-categoria-item:hover .casaap-categoria-icon {
    border-color: var(--gold);
    background: var(--gold);
    color: var(--white);
}

.categoria-item span,
.casaap-categoria-item span {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--white);
    display: block;
}

/* ============ BANNER DOURADO ============ */
.aluguel-destaque,
.casaap-banner {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
    padding: 60px 0;
    color: var(--white);
    position: relative;
    overflow: hidden;
    width: 100%;
}

.aluguel-destaque::before,
.casaap-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
}

.aluguel-content,
.casaap-banner-inner {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.aluguel-destaque h2,
.casaap-banner h2 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 900;
    margin-bottom: 20px;
    color: var(--white);
}

.aluguel-destaque p,
.casaap-banner p {
    font-size: 1.2rem;
    margin-bottom: 25px;
    opacity: 0.95;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    color: var(--white);
}

.btn-white,
.casaap-banner-btn {
    background: var(--white);
    color: var(--gold);
    padding: 14px 30px;
    border-radius: 30px;
    font-weight: 700;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
    border: 2px solid var(--white);
}

.btn-white:hover,
.casaap-banner-btn:hover {
    background: transparent;
    color: var(--white);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

/* ============ SEÇÕES DE IMÓVEIS ============ */
.imoveis-section,
.casaap-secao {
    padding: 60px 0;
    background: #f5f5f5;
    width: 100%;
}

.section-header,
.casaap-secao-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border-light);
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 20px;
    padding-right: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.section-header h2,
.casaap-secao-header h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    color: var(--text-dark);
    font-weight: 700;
    margin: 0;
}

.section-header h2 span,
.casaap-secao-header h2 span {
    color: var(--gold);
}

.section-header a,
.casaap-secao-header a {
    color: var(--gold);
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s;
}

.section-header a:hover,
.casaap-secao-header a:hover {
    color: var(--gold-dark);
    transform: translateX(5px);
}

/* ============ GRID DE IMÓVEIS - CORREÇÃO PRINCIPAL ============ */
.imoveis-grid,
.casaap-grid {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 20px !important;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    align-items: start;
    width: 100%;
}

/* ============ CARD DE IMÓVEL ============ */
.imovel-card,
.casaap-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-light);
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    width: 100%;
    min-width: 0;
    height: auto;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.imovel-card:hover,
.casaap-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    border-color: var(--gold);
}

/* Header do card */
.card-header-custom,
.casaap-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: var(--white);
    border-bottom: 1px solid #f0f0f0;
    width: 100%;
}

.corretor-info,
.casaap-card-top-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.corretor-info img,
.casaap-card-top-left img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: block;
}

.corretor-info span,
.casaap-card-top-left span {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-dark);
}

.card-actions,
.casaap-card-top-right {
    display: flex;
    gap: 10px;
}

.card-actions a,
.casaap-card-top-right a {
    color: var(--text-muted);
    font-size: 1rem;
    transition: color 0.3s;
    text-decoration: none;
}

.card-actions a:hover,
.casaap-card-top-right a:hover {
    color: var(--gold);
}

/* Container da imagem */
.card-image-wrapper,
.casaap-card-img {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #f0f0f0;
    flex-shrink: 0;
}

.card-image-wrapper img,
.casaap-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
    display: block;
}

.imovel-card:hover .card-image-wrapper img,
.casaap-card:hover .casaap-card-img img {
    transform: scale(1.05);
}

/* Badge de finalidade */
.badge-finalidade,
.casaap-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--gold);
    color: var(--white);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 2;
    letter-spacing: 0.5px;
}

/* Corpo do card */
.card-body-custom,
.casaap-card-body {
    padding: 15px;
    display: flex;
    flex-direction: column;
    flex: 1;
    width: 100%;
}

.imovel-titulo,
.casaap-card-titulo {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 8px;
    line-height: 1.3;
}

.imovel-local,
.casaap-card-local {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.imovel-local i,
.casaap-card-local i {
    color: var(--gold);
    font-size: 0.85rem;
}

.imovel-preco,
.casaap-card-preco {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--gold);
    margin-bottom: 15px;
    line-height: 1.3;
}

.imovel-preco .preco-venda,
.casaap-card-preco .preco-venda {
    font-size: 1.3rem;
    margin-bottom: 5px;
}

.imovel-preco .preco-aluguel,
.casaap-card-preco .preco-aluguel {
    font-size: 1.1rem;
    opacity: 0.9;
}

.imovel-preco .periodo,
.casaap-card-preco .periodo {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* Grid de características */
.features-grid,
.casaap-card-features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 15px;
    padding: 12px 0;
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
    width: 100%;
}

.feature-item,
.casaap-card-feature {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-dark);
}

.feature-item i,
.casaap-card-feature i {
    color: var(--gold);
    font-size: 1rem;
    width: 18px;
    text-align: center;
}

.codigo-endereco,
.casaap-card-codigo {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 15px;
}

.codigo-endereco strong,
.casaap-card-codigo strong {
    color: var(--text-dark);
    font-weight: 600;
}

/* Botão Ver Detalhes */
.btn-detalhes,
.casaap-card-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: transparent;
    border: 2px solid var(--gold);
    color: var(--gold);
    text-align: center;
    font-weight: 700;
    font-size: 0.85rem;
    border-radius: 8px;
    margin-top: auto;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none;
    cursor: pointer;
}

.btn-detalhes:hover,
.casaap-card-btn:hover {
    background: var(--gold);
    color: var(--white);
}

.btn-detalhes i,
.casaap-card-btn i {
    margin-right: 5px;
}

/* ============ SEÇÃO PRIVATE ============ */
.private-section {
    background: var(--blue-dark);
    padding: 60px 0;
    color: var(--white);
}

.private-section .section-header h2 {
    color: var(--white);
}

.private-section .section-header h2 span {
    color: var(--gold);
}

.private-section .section-header a {
    color: var(--gold);
}

.private-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.private-card {
    background: rgba(255,255,255,0.05);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(212, 175, 55, 0.2);
    transition: all 0.3s;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

.private-card:hover {
    transform: translateY(-5px);
    border-color: var(--gold);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.private-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.private-card .card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.private-card h5 {
    color: var(--gold);
    font-size: 1.2rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.private-card .price {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--white);
    margin-bottom: 15px;
}

/* ============ FOOTER ============ */
.footer-modern,
.casaap-footer {
    background: var(--blue);
    padding: 50px 0 20px;
    border-top: 3px solid var(--gold);
    width: 100%;
}

.footer-modern .logo-footer {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: var(--white);
    font-weight: 700;
    margin-bottom: 15px;
}

.footer-modern p,
.casaap-footer p {
    color: var(--white);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.footer-modern .social-links a {
    color: var(--white);
    font-size: 1.3rem;
    margin-right: 15px;
    transition: color 0.3s;
}

.footer-modern .social-links a:hover {
    color: var(--gold);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    margin-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.2);
    color: var(--white);
    font-size: 0.85rem;
}

.footer-modern h5,
.casaap-footer h5 {
    color: var(--white);
    margin-bottom: 15px;
    font-weight: 600;
}

.footer-modern a,
.casaap-footer a {
    color: var(--white) !important;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-modern a:hover,
.casaap-footer a:hover {
    color: var(--gold) !important;
}

/* ============ WHATSAPP FLUTUANTE ============ */
.whatsapp-float,
.casaap-whatsapp {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8rem;
    z-index: 999;
    box-shadow: 0 5px 20px rgba(37, 211, 102, 0.4);
    text-decoration: none;
    transition: all 0.3s;
}

.whatsapp-float:hover,
.casaap-whatsapp:hover {
    transform: scale(1.1);
    color: white;
}

/* ============ SEM RESULTADOS ============ */
.sem-resultados {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.sem-resultados i {
    font-size: 4rem;
    color: var(--gold);
    opacity: 0.5;
    margin-bottom: 20px;
}

.sem-resultados h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: var(--text-dark);
}

/* ============ PÁGINA DO IMÓVEL (imovel.php) ============ */
.header-imovel {
    background: var(--white);
    border-bottom: 1px solid var(--border-light);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.galeria-principal {
    position: relative;
    margin: 20px 0;
}

.galeria-principal img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    border-radius: 15px;
}

.imovel-header-page {
    padding: 30px 0;
}

.imovel-header-page h1 {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.imovel-preco-page {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--gold);
    margin-bottom: 20px;
}

.caracteristicas-grid-page {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    padding: 25px;
    background: var(--bg-light);
    border-radius: 15px;
    margin: 25px 0;
}

.caract-item {
    text-align: center;
    padding: 15px;
    background: var(--white);
    border-radius: 10px;
    border: 1px solid var(--border-light);
}

.caract-item i {
    font-size: 1.8rem;
    color: var(--gold);
    margin-bottom: 8px;
}

.caract-item .valor {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-dark);
    display: block;
}

.caract-item .label {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sidebar-contato {
    position: sticky;
    top: 100px;
    background: var(--white);
    border: 2px solid var(--gold);
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(212, 175, 55, 0.15);
}

.sidebar-contato h3 {
    font-family: 'Playfair Display', serif;
    color: var(--gold);
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.btn-whatsapp-page {
    background: #25D366;
    color: var(--white);
    padding: 14px;
    border-radius: 10px;
    font-weight: 700;
    text-decoration: none;
    display: block;
    text-align: center;
    margin-bottom: 15px;
    transition: all 0.3s;
}

.btn-whatsapp-page:hover {
    background: #128C7E;
    color: var(--white);
    transform: translateY(-2px);
}

/* ============ BUSCAR.PHP ============ */
.filtros-busca {
    background: var(--white);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
    border: 1px solid var(--border-light);
}

.filtros-busca .form-control,
.filtros-busca .form-select {
    padding: 10px 15px;
    border: 2px solid var(--border-light);
    border-radius: 8px;
}

.filtros-busca .form-control:focus,
.filtros-busca .form-select:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1);
}

.btn-buscar {
    background: var(--gold);
    color: var(--white);
    border: none;
    padding: 10px 25px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-buscar:hover {
    background: var(--gold-dark);
    color: var(--white);
}

/* ============ CONTATO.PHP ============ */
.contato-section {
    padding: 60px 0;
}

.contato-info {
    background: var(--white);
    padding: 30px;
    border-radius: 15px;
    border: 1px solid var(--border-light);
}

.contato-info h3 {
    font-family: 'Playfair Display', serif;
    color: var(--gold);
    margin-bottom: 20px;
}

.contato-info p {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.contato-info i {
    color: var(--gold);
    font-size: 1.2rem;
    width: 25px;
}

.form-contato {
    background: var(--white);
    padding: 30px;
    border-radius: 15px;
    border: 1px solid var(--border-light);
}

.form-contato .form-control {
    padding: 12px 15px;
    border: 2px solid var(--border-light);
    border-radius: 8px;
    margin-bottom: 15px;
}

.form-contato .form-control:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1);
}

.btn-enviar-contato {
    background: var(--gold);
    color: var(--white);
    border: none;
    padding: 14px 30px;
    border-radius: 8px;
    font-weight: 700;
    width: 100%;
    transition: all 0.3s;
}

.btn-enviar-contato:hover {
    background: var(--gold-dark);
    color: var(--white);
}

/* ============ SOBRE.PHP ============ */
.sobre-section {
    padding: 60px 0;
}

.sobre-content {
    background: var(--white);
    padding: 40px;
    border-radius: 15px;
    border: 1px solid var(--border-light);
}

.sobre-content h2 {
    font-family: 'Playfair Display', serif;
    color: var(--gold);
    margin-bottom: 20px;
}

.sobre-content p {
    margin-bottom: 15px;
    line-height: 1.8;
    color: var(--text-muted);
}

/* ============ ADMIN - PAINEL ============ */
.admin-sidebar {
    background: var(--blue-dark);
    min-height: 100vh;
    padding: 20px;
    position: fixed;
    left: 0;
    top: 0;
    width: 250px;
    z-index: 100;
}

.admin-sidebar h3 {
    color: var(--gold);
    font-family: 'Playfair Display', serif;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.3);
}

.admin-sidebar a {
    display: block;
    color: var(--white);
    padding: 12px 15px;
    margin-bottom: 5px;
    border-radius: 8px;
    transition: all 0.3s;
    text-decoration: none;
}

.admin-sidebar a:hover,
.admin-sidebar a.active {
    background: var(--gold);
    color: var(--white);
}

.admin-sidebar i {
    margin-right: 10px;
    width: 20px;
    text-align: center;
}

.admin-content {
    margin-left: 250px;
    padding: 30px;
    min-height: 100vh;
    background: var(--bg-light);
}

.admin-card {
    background: var(--white);
    padding: 25px;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    margin-bottom: 20px;
}

.admin-card h4 {
    color: var(--gold);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--gold);
}

.btn-gold {
    background: var(--gold);
    color: var(--white);
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn-gold:hover {
    background: var(--gold-dark);
    color: var(--white);
}

.btn-outline-gold {
    background: transparent;
    color: var(--gold);
    border: 2px solid var(--gold);
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn-outline-gold:hover {
    background: var(--gold);
    color: var(--white);
}

/* ============ TABELAS ADMIN ============ */
.table-admin {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
}

.table-admin th {
    background: var(--gold);
    color: var(--white);
    padding: 12px 15px;
    text-align: left;
    font-weight: 600;
}

.table-admin td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--border-light);
}

.table-admin tr:hover {
    background: var(--bg-light);
}

.table-admin .btn-sm {
    padding: 5px 10px;
    font-size: 0.85rem;
    border-radius: 5px;
}

/* ============ FORMULÁRIOS ADMIN ============ */
.form-section {
    background: var(--white);
    padding: 25px;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    margin-bottom: 20px;
}

.form-section h4 {
    color: var(--gold);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--gold);
}

.form-section .form-control,
.form-section .form-select {
    padding: 10px 15px;
    border: 2px solid var(--border-light);
    border-radius: 8px;
    margin-bottom: 15px;
}

.form-section .form-control:focus,
.form-section .form-select:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1);
}

.form-section label {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 5px;
    display: block;
}

/* ============ PREVIEW DE IMAGENS ============ */
.preview-img {
    max-width: 200px;
    max-height: 150px;
    border-radius: 8px;
    border: 2px solid var(--border-light);
}

.img-preview-box {
    position: relative;
    width: 150px;
    height: 150px;
    margin: 10px;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid var(--border-light);
}

.img-preview-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.btn-remove-img {
    position: absolute;
    top: 5px;
    right: 5px;
    background: var(--danger);
    color: var(--white);
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.btn-remove-img:hover {
    background: #c82333;
    transform: scale(1.1);
}

.btn-remove-img.active {
    background: var(--success);
}

/* ============ LIGHTBOX ============ */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.lightbox.active {
    display: flex;
}

.lightbox img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 2rem;
    cursor: pointer;
}

/* ============ RESPONSIVO ============ */
@media (max-width: 1400px) {
    .imoveis-grid,
    .casaap-grid,
    .private-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 1200px) {
    .imoveis-grid,
    .casaap-grid,
    .private-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 992px) {
    .imoveis-grid,
    .casaap-grid,
    .private-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    .header-content,
    .casaap-header-inner {
        flex-wrap: wrap;
    }
    
    .search-bar,
    .casaap-search {
        order: 3;
        width: 100%;
        max-width: 100%;
    }
    
    .admin-sidebar {
        width: 100%;
        position: relative;
        min-height: auto;
    }
    
    .admin-content {
        margin-left: 0;
    }
}

@media (max-width: 768px) {
    .imoveis-grid,
    .casaap-grid,
    .private-grid {
        grid-template-columns: 1fr !important;
    }
    
    .section-header,
    .casaap-secao-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .section-header h2,
    .casaap-secao-header h2 {
        font-size: 1.6rem;
    }
    
    .header-actions span {
        display: none;
    }
    
    .galeria-principal img {
        height: 300px;
    }
    
    .imovel-header-page h1 {
        font-size: 1.6rem;
    }
    
    .imovel-preco-page {
        font-size: 1.8rem;
    }
    
    .sidebar-contato {
        position: static;
        margin-top: 30px;
    }
    
    .aluguel-destaque h2,
    .casaap-banner h2 {
        font-size: 1.8rem;
    }
}

@media (max-width: 576px) {
    .card-image-wrapper,
    .casaap-card-img {
        height: 180px;
    }
    
    .imovel-titulo,
    .casaap-card-titulo {
        font-size: 1rem;
    }
    
    .imovel-preco,
    .casaap-card-preco {
        font-size: 1.2rem;
    }
}

/* ============ UTILITÁRIOS ============ */
.text-gold { color: var(--gold) !important; }
.bg-gold { background: var(--gold) !important; }
.border-gold { border-color: var(--gold) !important; }

.section-title {
    color: var(--gold);
    border-bottom: 2px solid var(--gold);
    padding-bottom: 10px;
    margin: 25px 0 20px;
    font-size: 1.3rem;
    font-weight: 700;
}

.counter-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.item-row {
    background: var(--bg-light);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    border-left: 3px solid var(--gold);
}

/* ============ ANIMAÇÕES ============ */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.imovel-card,
.casaap-card {
    animation: fadeIn 0.5s ease-out;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}

.stories-container {
    animation: slideIn 0.5s ease-out;
}