/* Custom styles for GV GRAND HOMES Real Estate */

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif !important;
    line-height: 1.6;
}

.navbar-brand img {
    height: auto;
    width: auto;
    max-width: 200px;
}

.hero {
    position: relative;
}

.hero .overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.hero .container {
    position: relative;
    z-index: 2;
}

.search-form {
    max-width: 800px;
}

.gallery-overlay-container {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
}

.carousel-img {
    height: 400px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

@media (max-width: 768px) {
    .carousel-img {
        height: 320px;
    }
}

.gallery-item {
    aspect-ratio: 1;
    overflow: hidden;
}

.gallery-item {
    aspect-ratio: 1;
    overflow: hidden;
}

.gallery-item .gallery-img {
    transition: transform 0.3s ease;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-item:hover .gallery-img {
    transform: scale(1.05);
}

.gallery-overlay-container:hover .carousel-img {
    transform: scale(1.05);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.3) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-overlay-container:hover .gallery-overlay {
    opacity: 1;
}

.overlay-content {
    text-align: center;
    color: white;
    padding: 20px;
}

.overlay-content h3 {
    font-size: 2rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.overlay-content p {
    font-size: 1.1rem;
    margin: 0;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

@media (max-width: 768px) {
    .overlay-content h3 {
        font-size: 1.5rem;
    }
    .overlay-content p {
        font-size: 1rem;
    }
    .overlay-content {
        padding: 15px;
    }
}

#galleryModal .modal-content {
    background-color: rgba(0, 0, 0, 0.9);
    border: none;
}

#galleryModal .modal-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

#galleryModal .modal-header .btn-close {
    filter: invert(1);
}

#galleryModal .modal-title {
    color: white;
}

#galleryModal .modal-dialog {
    max-height: 90vh;
    margin: 5vh auto;
}

#galleryModal .modal-content {
    max-height: 90vh;
    overflow: hidden;
}

#galleryModal .modal-body {
    background-color: white;
    overflow-y: auto;
    max-height: calc(90vh - 60px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
}

#modalImage {
    max-width: 100%;
    max-height: calc(85vh - 70px);
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

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

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

section {
    padding: 80px 0;
}

#about img {
    border-radius: 10px;
}

#mission i {
    margin-bottom: 15px;
}

footer a:hover {
    text-decoration: underline;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    .search-form .row > div {
        margin-bottom: 15px;
    }
    section {
        padding: 60px 0;
    }
}

.ribbon-container {
    display: flex;
    align-items: stretch;
    background: linear-gradient(135deg, #0F172A 0%, #1E293B 60%, #0F172A 100%);
    margin-bottom: 30px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
    width: 100%;
}

.ribbon-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
    border-right: 1px solid rgba(255, 255, 255, 0.07);
    transition: background 0.3s ease;
    text-align: center;
    cursor: default;
}

.ribbon-item:last-child {
    border-right: none;
}

.ribbon-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.ribbon-icon {
    font-size: 2rem;
    margin-bottom: 10px;
}

.ribbon-number {
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 6px;
    display: block;
    letter-spacing: -0.02em;
}

.ribbon-label {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
    display: block;
}

.ribbon-item:nth-child(1) { border-top: 3px solid #F59E0B; }
.ribbon-item:nth-child(1) .ribbon-icon,
.ribbon-item:nth-child(1) .ribbon-number { color: #F59E0B; }

.ribbon-item:nth-child(2) { border-top: 3px solid #10B981; }
.ribbon-item:nth-child(2) .ribbon-icon,
.ribbon-item:nth-child(2) .ribbon-number { color: #10B981; }

.ribbon-item:nth-child(3) { border-top: 3px solid #818CF8; }
.ribbon-item:nth-child(3) .ribbon-icon,
.ribbon-item:nth-child(3) .ribbon-number { color: #818CF8; }

.ribbon-item:nth-child(4) { border-top: 3px solid #FB7185; }
.ribbon-item:nth-child(4) .ribbon-icon,
.ribbon-item:nth-child(4) .ribbon-number { color: #FB7185; }

@media (max-width: 768px) {
    .ribbon-container {
        flex-wrap: wrap;
        border-radius: 12px;
    }
    .ribbon-item {
        flex: 1 1 50%;
        padding: 24px 12px;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    }
    .ribbon-item:nth-child(1),
    .ribbon-item:nth-child(2) {
        border-right: 1px solid rgba(255, 255, 255, 0.07);
    }
    .ribbon-item:nth-child(3),
    .ribbon-item:nth-child(4) {
        border-bottom: none;
    }
    .ribbon-number { font-size: 1.9rem; }
    .ribbon-icon { font-size: 1.6rem; }
}