/* Project Detail Page - Premium Level Elegance & Professional Design */

/* Project Detail Wrapper - Full Width */
.project-detail-wrapper {
    width: 100%;
    background: #f8f9fa;
    overflow-x: hidden;
}

/* Hero Section */
.project-hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    color: white;
    overflow: hidden;
}

.project-hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
}

.project-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.75) 0%, rgba(0, 0, 0, 0.5) 50%, rgba(0, 0, 0, 0.75) 100%);
    z-index: 2;
}

.project-hero-content {
    position: relative;
    z-index: 3;
    width: 100%;
    padding: 5rem 2rem;
}

.project-hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.project-hero-text {
    text-align: left;
}

/* Project Badges */
.project-badges {
    display: flex;
    gap: 1.2rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.project-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.75rem 1.25rem;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.95rem;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.project-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
}

.project-badge-emergency {
    background: rgba(220, 53, 69, 0.95);
    color: white;
}

.project-badge-category {
    background: rgba(255, 255, 255, 0.25);
    color: white;
}

/* Project Hero Title */
.project-hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 2rem;
    text-shadow: 0 4px 8px rgba(0,0,0,0.4);
    line-height: 1.1;
    letter-spacing: -0.02em;
}

/* Project Meta */
.project-meta {
    display: flex;
    gap: 2.5rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.project-meta-item {
    display: flex;
    align-items: center;
    font-size: 1.2rem;
    opacity: 0.95;
    font-weight: 500;
}

.project-meta-item i {
    font-size: 1.4rem;
    margin-right: 0.75rem;
    color: #00b590;
}

/* Hero Actions */
.project-hero-actions {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-top: 2.5rem;
}

/* Project Buttons */
.project-btn {
    display: inline-flex;
    align-items: center;
    padding: 1rem 2rem;
    border-radius: 30px;
    font-weight: 600;
    font-size: 1.05rem;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    cursor: pointer;
    letter-spacing: 0.01em;
    position: relative;
    z-index: 4;
}

.project-btn-primary {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    border-color: #28a745;
}

.project-btn-primary:hover {
    background: linear-gradient(135deg, #218838 0%, #1ea085 100%);
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(40, 167, 69, 0.4);
    color: white;
}

.project-btn-outline {
    background: transparent;
    color: white;
    border-color: white;
}

.project-btn-outline:hover {
    background: white;
    color: #333;
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(255, 255, 255, 0.3);
}

.project-btn-large {
    padding: 1.25rem 2.5rem;
    font-size: 1.15rem;
}

/* Hero Image */
.project-hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-image-container {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 25px 80px rgba(0,0,0,0.5);
    transition: transform 0.3s ease;
}

.hero-image-container:hover {
    transform: scale(1.02);
}

.hero-img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Main Content */
.project-main-content {
    width: 100%;
    padding: 0;
    max-width: none;
    box-sizing: border-box;
}

/* Project Sections */
.project-section {
    padding: 5rem 2rem;
    background: #f8fafc;
    margin-bottom: 0;
}

.project-section-gallery {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
}

.project-section-cta {
    background: linear-gradient(135deg, #00b590 0%, #006905 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.project-section-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="50" cy="10" r="0.5" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
    z-index: 1;
}

.project-section-content {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
}

.project-section-header {
    margin-bottom: 4rem;
}

.project-section-header h2 {
    font-size: 3rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1.5rem;
}

.project-section-subtitle {
    font-size: 1.3rem;
    color: #6b7280;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Project Content Grid */
.project-content-grid {
    display: grid;
    grid-template-columns: 2.5fr 1fr;
    gap: 4rem;
    align-items: start;
}

.project-content-main {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

/* Content Titles */
.content-title {
    font-size: 2rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1.5rem;
    border-bottom: 3px solid #e5e7eb;
    padding-bottom: 0.75rem;
}

/* Content Text */
.content-text {
    font-size: 1.15rem;
    line-height: 1.8;
    color: #374151;
}

.content-text p {
    margin-bottom: 1.8rem;
}

.content-text p:last-child {
    margin-bottom: 0;
}

/* Project Quote - Fixed Styling */
.project-quote {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 20px;
    padding: 3rem 2.5rem 2.5rem 3rem;
    border-left: 8px solid #00b590;
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
    margin: 1rem 0;
    position: relative;
}

.quote-container {
    position: relative;
    padding-left: 1rem;
}

.quote-icon {
    position: absolute;
    top: -20px;
    left: -25px;
    font-size: 3.5rem;
    color: #00b590;
    opacity: 0.3;
    z-index: 1;
}

.quote-text {
    font-size: 1.4rem;
    font-style: italic;
    color: #1f2937;
    margin: 0;
    line-height: 1.7;
    font-weight: 500;
    position: relative;
    z-index: 2;
}

/* Project Video */
.project-video {
    margin-top: 1.5rem;
}

.video-container {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}

.video-frame {
    width: 100%;
    height: 500px;
    border: none;
}

/* Sidebar - Improved Styling */
.project-content-sidebar {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.sidebar-card {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    border: 1px solid #e5e7eb;
}

.sidebar-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
}

.sidebar-title i {
    color: #00b590;
    font-size: 1.3rem;
    margin-right: 0.5rem;
}

/* Stats List - Fixed Styling */
.stats-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 1.2rem 0;
    border-bottom: 1px solid #f3f4f6;
    min-height: 3rem;
}

.stat-item:last-child {
    border-bottom: none;
}

.stat-label {
    font-weight: 500;
    color: #6b7280;
    font-size: 1rem;
    flex: 0 0 40%;
    line-height: 1.4;
}

.stat-value {
    font-weight: 600;
    color: #1f2937;
    font-size: 1rem;
    flex: 0 0 55%;
    text-align: right;
    line-height: 1.4;
    word-wrap: break-word;
}

/* Sidebar CTA - Prefixed Classes */
.pd-sidebar-cta {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border: 2px solid #00b590;
}

.pd-cta-text {
    color: #374151;
    margin-bottom: 2rem;
    line-height: 1.7;
    font-size: 1.05rem;
}

.pd-sidebar-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 1rem 1.5rem;
    background: #00b590;
    color: white;
    border-radius: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 1.05rem;
}

.pd-sidebar-btn:hover {
    background: #009d7e;
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(0, 181, 144, 0.4);
    color: white;
}

/* Project Gallery - High Standard Professional */
.project-gallery {
    margin-top: 4rem;
}

.gallery-section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.gallery-section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1rem;
}

.gallery-section-subtitle {
    font-size: 1.2rem;
    color: #6b7280;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.gallery-item {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: white;
    aspect-ratio: 4/3;
    cursor: pointer;
}

.gallery-item:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

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

.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) 50%, rgba(0, 0, 0, 0.7) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.4s ease;
}

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

.gallery-view-btn {
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
}

.gallery-view-btn:hover {
    background: white;
    transform: scale(1.15);
    box-shadow: 0 12px 35px rgba(0,0,0,0.3);
}

.gallery-view-btn i {
    font-size: 2rem;
    color: #1f2937;
    transition: color 0.3s ease;
}

.gallery-view-btn:hover i {
    color: #00b590;
}

.gallery-item-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.7) 100%);
    color: white;
    padding: 1.5rem;
    transform: translateY(100%);
    transition: transform 0.4s ease;
}

.gallery-item:hover .gallery-item-info {
    transform: translateY(0);
}

.gallery-item-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: white;
}

.gallery-item-description {
    font-size: 0.95rem;
    opacity: 0.9;
    line-height: 1.4;
}

/* Enhanced Image Modal - Professional Standard */
.image-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        backdrop-filter: blur(0px);
    }
    to {
        opacity: 1;
        backdrop-filter: blur(8px);
    }
}

.image-modal-content {
    position: relative;
    max-width: 95%;
    max-height: 95%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.image-modal-close {
    position: absolute;
    top: -60px;
    right: 0;
    color: white;
    font-size: 3rem;
    font-weight: 300;
    cursor: pointer;
    z-index: 10000;
    transition: all 0.3s ease;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.image-modal-close:hover {
    color: #00b590;
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.modal-image {
    max-width: 100%;
    max-height: 100%;
    border-radius: 16px;
    box-shadow: 0 25px 80px rgba(0,0,0,0.6);
    transition: transform 0.3s ease;
}

.modal-image:hover {
    transform: scale(1.02);
}

.image-modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    color: white;
    font-size: 1.5rem;
}

.image-modal-nav:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.image-modal-prev {
    left: 30px;
}

.image-modal-next {
    right: 30px;
}

.image-modal-counter {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    font-size: 1.1rem;
    font-weight: 500;
    background: rgba(0, 0, 0, 0.7);
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    backdrop-filter: blur(10px);
}

.modal-image-title {
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    font-size: 1.3rem;
    font-weight: 600;
    text-align: center;
    max-width: 80%;
    background: rgba(0, 0, 0, 0.7);
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    backdrop-filter: blur(10px);
}

/* Gallery Loading States */
.gallery-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 4rem 2rem;
}

.gallery-loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f4f6;
    border-top: 4px solid #00b590;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Gallery Empty State */
.gallery-empty {
    text-align: center;
    padding: 4rem 2rem;
    color: #6b7280;
}

.gallery-empty-icon {
    font-size: 4rem;
    color: #d1d5db;
    margin-bottom: 1rem;
}

.gallery-empty-text {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.gallery-empty-subtext {
    font-size: 1rem;
    opacity: 0.7;
}

/* CTA Section - Prefixed Classes */
.pd-cta-content {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.pd-cta-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.pd-cta-subtitle {
    font-size: 1.3rem;
    opacity: 0.95;
    margin-bottom: 3rem;
    line-height: 1.7;
}

.pd-cta-actions {
    display: flex;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
    position: relative;
    z-index: 3;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .project-hero-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }
    
    .project-content-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .project-hero-title {
        font-size: 3.2rem;
    }
    
    .project-meta {
        justify-content: center;
    }
    
    .project-hero-actions {
        justify-content: center;
    }
    
    .project-section {
        padding: 4rem 2rem;
    }
}

@media (max-width: 768px) {
    .project-hero {
        min-height: 70vh;
    }
    
    .project-hero-content {
        padding: 3rem 1.5rem;
    }
    
    .project-hero-title {
        font-size: 2.5rem;
    }
    
    .project-section {
        padding: 3rem 1.5rem;
    }
    
    .project-section-header h2 {
        font-size: 2.2rem;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .pd-cta-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .project-btn {
        width: 100%;
        max-width: 350px;
        justify-content: center;
    }
    
    .project-meta {
        flex-direction: column;
        gap: 1.5rem;
        align-items: center;
    }
    
    .project-badges {
        justify-content: center;
    }
    
    /* Mobile quote adjustments */
    .project-quote {
        padding: 2.5rem 2rem 2rem 2.5rem;
    }
    
    .quote-icon {
        font-size: 3rem;
        top: -15px;
        left: -20px;
    }
    
    .quote-text {
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .project-hero-title {
        font-size: 2rem;
    }
    
    .project-section-header h2 {
        font-size: 1.8rem;
    }
    
    .content-title {
        font-size: 1.6rem;
    }
    
    .sidebar-card {
        padding: 2rem;
    }
    
    .project-hero-content {
        padding: 2rem 1rem;
    }
    
    .project-section {
        padding: 2rem 1rem;
    }
    
    /* Small mobile quote adjustments */
    .project-quote {
        padding: 2rem 1.5rem 1.5rem 2rem;
    }
    
    .quote-icon {
        font-size: 2.5rem;
        top: -12px;
        left: -18px;
    }
    
    .quote-text {
        font-size: 1.2rem;
    }
    
    /* Small mobile stats adjustments */
    .stat-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
        min-height: auto;
    }
    
    .stat-label,
    .stat-value {
        flex: none;
        text-align: left;
    }
}

/* Responsive Gallery */
@media (max-width: 1200px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 1rem;
    }
    
    .gallery-section-title {
        font-size: 2rem;
    }
    
    .gallery-item-info {
        padding: 1rem;
    }
    
    .gallery-item-title {
        font-size: 1rem;
    }
    
    .gallery-item-description {
        font-size: 0.9rem;
    }
    
    .image-modal-nav {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .image-modal-prev {
        left: 20px;
    }
    
    .image-modal-next {
        right: 20px;
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .gallery-section-title {
        font-size: 1.8rem;
    }
    
    .gallery-item {
        aspect-ratio: 3/2;
    }
    
    .gallery-view-btn {
        width: 70px;
        height: 70px;
    }
    
    .gallery-view-btn i {
        font-size: 1.6rem;
    }
    
    .image-modal-close {
        top: -50px;
        font-size: 2.5rem;
        width: 45px;
        height: 45px;
    }
}
