/* inspiration.css */

/* Header */
.inspiration-header {
    height: 400px;
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.inspiration-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    /* Slightly darker for luxury contrast */
}

.inspiration-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 0 1rem;
}

/* Masonry Grid replacement with standard flex/grid for fixed cards */
.masonry-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
}

@media (max-width: 991px) {
    .masonry-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 767px) {
    .masonry-grid {
        grid-template-columns: 1fr;
    }
}

/* Card Design with fixed sizing */
.gallery-item {
    margin-bottom: 0;
    /* Handled by grid gap */
}

.gallery-card {
    background: white;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.gallery-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
}

/* Image Wrapper with fixed height */
.image-wrapper {
    position: relative;
    width: 100%;
    height: 300px;
    /* Fixed height for visual uniformity */
    background-color: #ededed;
    overflow: hidden;
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Crucial for fixed sizes */
    display: block;
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.gallery-image.loaded {
    opacity: 1;
}

.gallery-card:hover .gallery-image {
    transform: scale(1.08);
}

/* Content Styling with fixed heights and truncation logic */
.gallery-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-category {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 700;
    color: #c8102e;
    display: block;
    margin-bottom: 0.5rem;
}

.project-name {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
    color: #1a1a1a;
    line-height: 1.2;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    height: 1.4rem;
    /* Fixed height for 2 lines */
}

.product-info {
    font-size: 0.85rem;
    color: #777;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #f0f0f0;
}

.product-name {
    color: #333;
    font-weight: 600;
}

.client-review {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    color: #555;
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 1.5rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    /* Limit visible lines */
    -webkit-box-orient: vertical;
    min-height: 4.5rem;
    /* Maintain consistent space */
}

/* More Button */
.read-more-btn {
    background: none;
    border: none;
    color: #c8102e;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: -1rem;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

.read-more-btn:hover {
    color: #a00d25;
}

/* Reviewer & Meta - Aligned at bottom */
.reviewer-section {
    display: flex;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
}

.reviewer-avatar {
    width: 40px;
    height: 40px;
    background: #1a1a1a;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.reviewer-details {
    margin-left: 0.85rem;
    overflow: hidden;
}

.reviewer-name {
    font-size: 0.85rem;
    font-weight: 700;
    color: #1a1a1a;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.review-meta {
    font-size: 0.7rem;
    color: #999;
    display: block;
}

/* Modal Styling */
.inspiration-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    /* Premium glassmorphism backdrop */
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.inspiration-modal.active {
    display: flex;
    opacity: 1;
}

.modal-container {
    background: white;
    width: 100%;
    max-width: 700px;
    border-radius: 12px;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.5);
}

.modal-close {
    position: sticky;
    top: 1rem;
    right: 1.5rem;
    float: right;
    z-index: 10;
    background: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    font-size: 1.5rem;
    line-height: 1;
}

.modal-body {
    padding: 3rem;
}

.modal-review-text {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 1.4rem;
    line-height: 1.8;
    color: #333;
    margin-bottom: 2rem;
}

/* Skeleton animation refine */
@keyframes shimmer {
    100% {
        transform: translateX(100%);
    }
}