/* Wix Blog Embed Styles */

.wix-blog-embed {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 0;
}

/* Grid Layout */
.wix-blog-posts.grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

/* List Layout */
.wix-blog-posts.list-layout {
    display: flex;
    flex-direction: column;
    gap: 30px;
    margin-bottom: 30px;
}

.wix-blog-posts.list-layout .wix-blog-post {
    display: flex;
    flex-direction: row;
    gap: 20px;
}

.wix-blog-posts.list-layout .post-image {
    flex: 0 0 300px;
    max-width: 300px;
}

.wix-blog-posts.list-layout .post-content {
    flex: 1;
}

/* Individual Post Card */
.wix-blog-post {
    background: #ffffff;
    border: 1px solid rgba(192, 202, 210, 0.75);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.wix-blog-post:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Post Image */
.post-image {
    width: 100%;
    overflow: hidden;
    position: relative;
    padding-top: 60%; /* 5:3 aspect ratio */
    background: #f5f5f5;
}

.post-image a {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.post-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.wix-blog-post:hover .post-image img {
    transform: scale(1.05);
}

/* Post Content */
.post-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.post-title {
    margin: 0 0 12px 0;
    font-size: 22px;
    font-weight: 600;
    line-height: 1.4;
}

.post-title a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-title a:hover {
    color: #3498db;
}

.post-description {
    color: #555;
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 16px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Post Meta */
.post-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 16px;
    font-size: 13px;
    color: #777;
}

.post-author {
    font-weight: 500;
    color: #555;
}

.post-read-time::before {
    content: "•";
    margin-right: 10px;
    color: #ccc;
}

/* Read More Link */
.read-more {
    display: inline-flex;
    align-items: center;
    color: #3498db;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: color 0.3s ease;
}

.read-more:hover {
    color: #2980b9;
}

/* Loading Indicator */
.wix-blog-loading {
    text-align: center;
    padding: 20px;
    color: #777;
    font-size: 14px;
}

.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .wix-blog-posts.grid-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .wix-blog-posts.list-layout .wix-blog-post {
        flex-direction: column;
    }
    
    .wix-blog-posts.list-layout .post-image {
        flex: 1;
        max-width: 100%;
    }
    
    .post-content {
        padding: 20px;
    }
    
    .post-title {
        font-size: 20px;
    }
    
    .post-description {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .wix-blog-embed {
        padding: 10px;
    }
    
    .post-content {
        padding: 16px;
    }
    
    .post-title {
        font-size: 18px;
    }
}

/* Fade-in animation for new posts */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.wix-blog-post {
    animation: fadeIn 0.5s ease-out;
}

/* Update notification */
.wix-blog-update-notice {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 12px 20px;
    border-radius: 4px;
    margin-bottom: 20px;
    text-align: center;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
