/* Roof Project Preview Plugin Styles */

.roof-project-preview-container {
    font-family: 'NotoSansThai-regular', sans-serif;
    width: 100%;
}

.roof-project-preview-wrapper {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    margin-bottom: 20px;
}

/* Left Section: Main Image */
.roof-project-preview-main {
    flex: 1;
    position: relative;
}

.main-image-container {
    width: 100%;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    min-height: 500px;
    position: relative;
    background: #f8f9fa;
}

.main-image-container img {
    width: 100%;
    height: 100%;
    max-height: 500px;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: opacity 0.3s ease;
}

/* Right Section: Project Info */
.roof-project-preview-info {
    flex: 1;
    color: #0d223b;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.project-header {
    margin-bottom: 30px;
}

.project-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #0d223b;
    margin-bottom: 0px !important;
    line-height: 1.2;
}

.project-subtitle {
    font-size: 2rem;
    color: #0d223b;
    margin: 0 0 10px 0;
    font-weight: 500;
}

.project-location {
    font-size: 1.2rem;
    color: #6b7280;
    margin: 0 0 15px 0;
}

.divider {
    height: 1px;
    background: linear-gradient(to right, #e5e7eb, transparent);
    margin: 15px 0;
}

.project-description {
    margin-bottom: 30px;
    flex: 1;
}

.project-description p {
    font-size: 1rem;
    line-height: 1.6;
    color: #374151;
    margin: 0;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 15px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    flex: 1;
    justify-content: center;
}

.btn-primary {
    background: #0d223b;
    color: white;
}

.btn-primary:hover {
    background: #1e40af;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.3);
}

.btn-primary svg {
    transition: transform 0.3s ease;
}

.btn-primary:hover svg {
    transform: translateX(2px);
}

/* Bottom Section: Navigation and Thumbnails */
.roof-project-preview-bottom {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
    position: relative;
}

/* Navigation Buttons (Left) */
.navigation-buttons {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.nav-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid #0d223b;
    background: white;
    color: #0d223b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    padding: 0;
}

.nav-btn:hover:not(:disabled) {
    background: #0d223b;
    color: white;
    transform: scale(1.1);
}

.nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Thumbnail Gallery (Right) */
.thumbnail-gallery-container {
    flex: 1;
    overflow: hidden;
}

.thumbnail-gallery {
    display: flex;
    flex-direction: row;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 10px 0;
    scroll-behavior: smooth;
}

.thumbnail-gallery::-webkit-scrollbar {
    height: 6px;
}

.thumbnail-gallery::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.thumbnail-gallery::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.thumbnail-gallery::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.thumbnail-item {
    flex-shrink: 0;
    width: 100px;
    height: 100px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 4px;
}

.thumbnail-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.thumbnail-item.active {
    border-color: #0d223b;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(13, 34, 59, 0.3);
}

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

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

/* Error Message */
.roof-project-preview-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
}

/* Responsive Design */

/* Large Desktops */
@media (min-width: 1400px) {
    .roof-project-preview-wrapper {
        gap: 50px;
    }
    
    .project-title {
        font-size: 3rem;
    }
    
    .project-subtitle {
        font-size: 2.2rem;
    }
    
    .main-image-container {
        min-height: 600px;
    }
    
    .main-image-container img {
        max-height: 600px;
    }
}

/* Medium Desktops */
@media (max-width: 1200px) {
    .roof-project-preview-wrapper {
        gap: 30px;
    }
    
    .project-title {
        font-size: 2.4rem;
    }
    
    .project-subtitle {
        font-size: 1.9rem;
    }
    
    .main-image-container {
        min-height: 450px;
    }
    
    .main-image-container img {
        max-height: 450px;
    }
}

/* Large Tablets and Small Desktops */
@media (max-width: 1024px) {
    .roof-project-preview-wrapper {
        gap: 25px;
    }
    
    .project-title {
        font-size: 2.2rem;
    }
    
    .project-subtitle {
        font-size: 1.8rem;
    }
    
    .main-image-container {
        min-height: 400px;
    }
    
    .main-image-container img {
        max-height: 400px;
    }
}

/* Tablets */
@media (max-width: 768px) {
    .roof-project-preview-wrapper {
        flex-direction: column;
        gap: 25px;
    }
    
    .roof-project-preview-main,
    .roof-project-preview-info {
        width: 100%;
    }
    
    .project-title {
        font-size: 2rem;
    }
    
    .project-subtitle {
        font-size: 1.6rem;
    }
    
    .main-image-container {
        min-height: 350px;
    }
    
    .main-image-container img {
        max-height: 350px;
    }
    
    .roof-project-preview-bottom {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .navigation-buttons {
        justify-content: center;
    }
    
    .thumbnail-gallery {
        max-height: 120px;
    }
    
    .thumbnail-item {
        width: 80px;
        height: 80px;
    }
}

/* Mobile Landscape */
@media (max-width: 640px) {
    .roof-project-preview-container {
        padding: 10px;
    }
    
    .roof-project-preview-wrapper {
        gap: 20px;
    }
    
    .project-title {
        font-size: 1.8rem;
    }
    
    .project-subtitle {
        font-size: 1.4rem;
    }
    
    .project-location {
        font-size: 1rem;
    }
    
    .main-image-container {
        min-height: 300px;
    }
    
    .main-image-container img {
        max-height: 300px;
    }
    
    .thumbnail-item {
        width: 70px;
        height: 70px;
    }
}

/* Mobile Portrait */
@media (max-width: 480px) {
    .roof-project-preview-container {
        padding: 8px;
    }
    
    .roof-project-preview-wrapper {
        gap: 15px;
    }
    
    .project-title {
        font-size: 1.6rem;
        line-height: 1.3;
    }
    
    .project-subtitle {
        font-size: 1.2rem;
    }
    
    .project-location {
        font-size: 0.9rem;
    }
    
    .project-description p {
        font-size: 0.9rem;
    }
    
    .btn {
        padding: 12px 16px;
        font-size: 0.9rem;
    }
    
    .main-image-container {
        min-height: 280px;
    }
    
    .main-image-container img {
        max-height: 280px;
    }
    
    .nav-btn {
        width: 40px;
        height: 40px;
    }
    
    .nav-btn svg {
        width: 20px;
        height: 20px;
    }
    
    .thumbnail-item {
        width: 60px;
        height: 60px;
    }
}

/* Extra Small Mobile */
@media (max-width: 360px) {
    .project-title {
        font-size: 1.4rem;
    }
    
    .project-subtitle {
        font-size: 1.1rem;
    }
    
    .main-image-container {
        min-height: 250px;
    }
    
    .main-image-container img {
        max-height: 250px;
    }
    
    .thumbnail-item {
        width: 50px;
        height: 50px;
    }
}

