/* Project Highlights Gallery Styles */

.phg-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    font-family: 'Arial', sans-serif;
}

/* Header Styles */
.phg-header {
    margin-bottom: 60px;
}

.phg-header-content {
    margin-bottom: 40px;
}

.phg-title {
    font-size: 3rem;
    font-weight: 900;
    color: #12172b;
    margin: 0 0 15px 0;
    text-transform: uppercase;
    letter-spacing: 3px;
    position: relative;
    display: inline-block;
}

.phg-title-underline {
    width: 80px;
    height: 3px;
    background: #c0392b;
    margin: 0 0 25px 0;
    position: relative;
}

.phg-title-underline::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    height: 3px;
    width: 100%;
    background: #c0392b;
    transform-origin: left;
    transform: scaleX(0);
    animation: underlineSwipe 2.4s ease-in-out infinite;
}

@keyframes underlineSwipe {
    0% { transform: scaleX(0); }
    50% { transform: scaleX(1); }
    100% { transform: scaleX(0); }
}

.phg-subtitle {
    font-size: 1.1rem;
    color: #666;
    margin: 0;
    line-height: 1.6;
    max-width: 600px;
}

/* Filter Styles */
.phg-filters-desktop {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
    margin-bottom: 50px;
}

.phg-filters-mobile {
    display: none;
}

.phg-filter-group {
    position: relative;
}

.phg-filter-btn {
    background: #fff;
    border: 1px solid #ddd;
    padding: 12px 20px;
    font-size: 14px;
    cursor: pointer;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 160px;
    justify-content: space-between;
    transition: all 0.3s ease;
    color: #333;
}

.phg-filter-btn:hover {
    border-color: #c0392b;
    color: #c0392b;
}

.phg-filter-btn.active {
    background: #f8f9fa;
    border-color: #c0392b;
    color: #c0392b;
}

.phg-arrow {
    transition: transform 0.3s ease;
    font-size: 12px;
}

.phg-filter-btn.active .phg-arrow {
    transform: rotate(180deg);
}

.phg-filter-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    z-index: 1000;
    display: none;
    max-height: 300px;
    overflow-y: auto;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.phg-filter-dropdown.active {
    display: block;
}

.phg-filter-header {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
}

.phg-filter-actions a {
    color: #c0392b;
    text-decoration: none;
    font-size: 12px;
    margin-left: 15px;
    font-weight: 500;
}

.phg-filter-actions a:hover {
    text-decoration: underline;
}

.phg-filter-options {
    padding: 8px 0;
}

.phg-filter-option {
    display: block;
    padding: 10px 15px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s ease;
    border: none;
    background: none;
}

.phg-filter-option:hover {
    background: #f8f9fa;
}

.phg-filter-option input {
    margin-right: 10px;
}

/* Masonry Grid Styles */
.phg-grid {
    columns: 3;
    column-gap: 20px;
    margin-bottom: 40px;
}

.phg-item {
    display: inline-block;
    width: 100%;
    margin-bottom: 20px;
    break-inside: avoid;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.phg-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.phg-item-image {
    position: relative;
    overflow: hidden;
    width: 100%;
}

.phg-item-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.phg-item:hover .phg-item-image img {
    transform: scale(1.03);
}

.phg-item-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: white;
    padding: 20px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.phg-item:hover .phg-item-overlay {
    transform: translateY(0);
}

.phg-item-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.phg-item-category {
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.phg-item-location {
    font-size: 12px;
    opacity: 0.9;
    text-transform: uppercase;
}

/* Lightbox Styles - Full Screen with Project Info */
.phg-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

.phg-lightbox.active {
    display: flex;
}

.phg-lightbox-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.phg-lightbox-image-container {
    position: relative;
    max-width: 80%;
    max-height: 70%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.phg-lightbox-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

.phg-lightbox-info {
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: white;
}

.phg-lightbox-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 5px 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.phg-lightbox-location {
    font-size: 1rem;
    opacity: 0.8;
    margin: 0;
    text-transform: uppercase;
}

.phg-lightbox-close {
    position: absolute;
    top: 30px;
    right: 30px;
    background: rgba(255,255,255,0.1);
    border: 2px solid rgba(255,255,255,0.3);
    color: white;
    font-size: 24px;
    width: 50px;
    height: 50px;
    cursor: pointer;
    z-index: 10001;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.phg-lightbox-close:hover {
    background: rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.5);
}

.phg-lightbox-prev,
.phg-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.1);
    border: 2px solid rgba(255,255,255,0.3);
    color: white;
    font-size: 24px;
    width: 60px;
    height: 60px;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.phg-lightbox-prev {
    left: 30px;
}

.phg-lightbox-next {
    right: 30px;
}

.phg-lightbox-prev:hover,
.phg-lightbox-next:hover {
    background: rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.5);
}

/* Load More Styles */
.phg-load-more-container {
    text-align: center;
    margin: 50px 0 20px;
    padding: 30px 0;
}

.phg-load-more-btn {
    background: #12172b;
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    min-width: 200px;
}

.phg-load-more-btn:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(192, 57, 43, 0.3);
}

.phg-load-more-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.phg-load-more-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s ease-in-out infinite;
    margin-left: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.phg-load-more-info {
    margin-top: 15px;
    color: #666;
    font-size: 14px;
}

.phg-showing-count,
.phg-total-count {
    font-weight: 600;
    color: #12172b;
}

.phg-no-results {
    text-align: center;
    color: #666;
    font-size: 18px;
    padding: 60px 20px;
    width: 100%;
    column-span: all;
}

/* Mobile Styles */
@media (max-width: 1024px) {
    .phg-grid {
        columns: 2;
        column-gap: 15px;
    }
}

@media (max-width: 768px) {
    .phg-container {
        padding: 20px 15px;
    }
    
    .phg-title {
        font-size: 2.2rem;
        letter-spacing: 2px;
    }
    
    .phg-filters-desktop {
        display: none;
    }
    
    .phg-filters-mobile {
        display: block;
        text-align: center;
        margin-bottom: 40px;
    }
    
    .phg-mobile-filter-btn {
        background: #12172b;
        color: white;
        border: none;
        padding: 15px 30px;
        border-radius: 25px;
        font-size: 14px;
        cursor: pointer;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 1px;
    }
    
    .phg-grid {
        columns: 1;
        column-gap: 0;
    }
    
    .phg-item {
        margin-bottom: 15px;
    }
    
    .phg-lightbox-prev {
        left: 15px;
        width: 50px;
        height: 50px;
    }
    
    .phg-lightbox-next {
        right: 15px;
        width: 50px;
        height: 50px;
    }
    
    .phg-lightbox-close {
        top: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .phg-lightbox-image-container {
        max-width: 95%;
        max-height: 60%;
    }
    
    .phg-lightbox-info {
        bottom: 40px;
    }
    
    .phg-lightbox-title {
        font-size: 1.2rem;
    }
    
    .phg-lightbox-location {
        font-size: 0.9rem;
    }
    
    .phg-load-more-container {
        margin: 30px 0 15px;
        padding: 20px 0;
    }
    
    .phg-load-more-btn {
        padding: 12px 30px;
        font-size: 13px;
        min-width: 180px;
    }
    
    .phg-load-more-info {
        font-size: 13px;
        margin-top: 12px;
    }
}

/* Mobile Filter Panel */
.phg-mobile-filter-panel {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    z-index: 9999;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
}

.phg-mobile-filter-panel.active {
    transform: translateX(0);
}

.phg-mobile-filter-content {
    padding: 30px 20px;
}

.phg-mobile-filter-content h3 {
    margin: 0 0 30px 0;
    color: #12172b;
    font-size: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
}

.phg-mobile-filter-section {
    margin-bottom: 40px;
}

.phg-mobile-filter-section h4 {
    margin: 0 0 20px 0;
    color: #666;
    font-size: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.phg-mobile-filter-option {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    font-size: 14px;
}

.phg-mobile-filter-option input {
    margin-right: 12px;
}

.phg-apply-filters {
    background: #c0392b;
    color: white;
    border: none;
    padding: 18px 30px;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    width: 100%;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}