/* ====================================================
   BEST AUTO SALES - BUY & RENT LISTINGS STYLES
==================================================== */

/* --- Forced Structural Realignment Utilities --- */
.text-center-forced {
    text-align: center !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
}

/* --- Hero Section (Guaranteed Center) --- */
.inventory-hero {
    position: relative;
    height: 60vh;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-top: 90px;
}

.hero-bg {
    position: absolute;
    inset: -10%; 
    z-index: 1;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transform: scale(1.1);
}

.hero-overlay-dark {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10,10,10,0.85) 0%, #0a0a0a 100%);
    z-index: 2;
}

.hero-text-container {
    position: relative;
    z-index: 3;
    text-align: center !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.gold-subtitle {
    color: var(--gold, #D4AF37);
    text-transform: uppercase;
    letter-spacing: 4px;
    font-size: 1rem;
    font-weight: 700;
    display: block;
    margin-bottom: 15px;
    text-align: center;
}

.massive-title {
    font-size: 4rem;
    font-weight: 900;
    line-height: 1.1;
    color: #ffffff;
    text-shadow: 0 10px 30px rgba(0,0,0,0.8);
    text-align: center;
}

.hero-desc {
    color: var(--text-muted, #9ca3af);
    font-size: 1.2rem;
    margin-top: 20px;
    text-align: center;
}

/* --- Inventory Section & 5-Column Grid --- */
.inventory-section {
    padding: 80px 0;
    background-color: var(--bg-dark, #0a0a0a);
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(5, 1fr); 
    gap: 20px;
}

@media (max-width: 1400px) { .grid-container { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 1100px) { .grid-container { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 768px)  { .grid-container { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px)  { .grid-container { grid-template-columns: 1fr; } }

/* --- Centered Card Details --- */
.inv-card {
    background: var(--bg-panel, #121212);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    transform-style: preserve-3d;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.inv-card:hover {
    border-color: var(--gold, #D4AF37);
    transform: translateY(-10px);
}

.card-link {
    text-decoration: none;
    display: block;
    color: inherit;
}

.img-placeholder {
    width: 100%;
    height: 180px;
    background: #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    border-bottom: 2px solid #222;
    overflow: hidden;
}

.img-placeholder span {
    color: #444;
    font-weight: 700;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hover-overlay {
    position: absolute;
    inset: 0;
    background: rgba(212, 175, 55, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.hover-overlay p {
    color: #000;
    font-weight: 900;
    font-size: 1rem;
    text-transform: uppercase;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.inv-card:hover .hover-overlay { opacity: 1; }
.inv-card:hover .hover-overlay p { transform: translateY(0); }

.inv-details {
    padding: 25px 15px;
    text-align: center; 
}

.inv-details h3 {
    color: white;
    font-size: 1.15rem;
    margin-bottom: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.inv-specs {
    color: var(--text-muted, #9ca3af);
    font-size: 0.85rem;
    margin-bottom: 0;
}

/* --- Centered Load More Controls --- */
.load-more-container {
    margin-top: 60px;
    display: flex;
    justify-content: center;
    width: 100%;
}

.btn-load-more {
    background: transparent;
    color: var(--gold, #D4AF37);
    border: 2px solid var(--gold, #D4AF37);
    padding: 14px 40px;
    font-size: 0.95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-load-more:hover {
    background: var(--gold, #D4AF37);
    color: black;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
}

.is-hidden { display: none !important; }

@media (max-width: 768px) {
    .massive-title { font-size: 2.8rem; }
}
