/* Example CSS file */

/* News Layout Styles */
.news-item {
    margin-bottom: 2rem;
    padding: 1.5rem;
    border: 1px solid #eee;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.news-item-content {
    display: flex;
    gap: 2rem;
    align-items: start;
}

.news-item .card-image {
    flex: 0 0 300px;
}

.news-item .image.is-16by9 img {
    object-fit: cover;
    width: 100%;
    height: 100%;
}

.news-item .news-text {
    flex: 1;
}

.news-item .excerpt {
    color: #666;
    line-height: 1.6;
}

.news-item .meta {
    font-size: 0.9rem;
    color: #888;
}

/* News Archive List */
.news-archive .news-list {
    margin-bottom: 2rem;
}

/* Single News Page */
.pagination-nav {
  margin-top: 2rem;
}

.pagination-nav .field {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.pagination-nav .button {
  flex: 1;
  min-width: 180px;
}

.news-single .meta {
    display: block;
    font-style: italic;
    margin-bottom: 1.5rem;
    color: #666;
}

/* Image Gallery */
.news-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.news-gallery-item {
    position: relative;
    margin: 0;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.news-gallery-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: opacity 0.2s ease;
}

.news-gallery-item:hover img {
    opacity: 0.9;
}

.gallery-counter {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: 12px;
}

/* Lightbox */
.news-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
}

.news-lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
}

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

.news-lightbox-img {
    max-width: 90%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.4);
}

.news-lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 2.5rem;
    color: #fff;
    cursor: pointer;
    z-index: 10002;
    line-height: 1;
    text-decoration: none;
    transition: opacity 0.2s;
}

.news-lightbox-close:hover {
    opacity: 0.7;
}

.news-lightbox-prev,
.news-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 3rem;
    color: #fff;
    cursor: pointer;
    z-index: 10002;
    text-decoration: none;
    padding: 1rem;
    transition: opacity 0.2s;
    user-select: none;
}

.news-lightbox-prev:hover,
.news-lightbox-next:hover {
    opacity: 0.7;
}

.news-lightbox-prev {
    left: 20px;
}

.news-lightbox-next {
    right: 20px;
}

.news-lightbox-counter {
    position: absolute;
    bottom: 20px;
    color: #fff;
    font-size: 0.9rem;
    background: rgba(0,0,0,0.5);
    padding: 4px 12px;
    border-radius: 12px;
}

/* Responsive */
@media screen and (max-width: 768px) {
    .news-gallery {
        grid-template-columns: 1fr;
    }

    .news-gallery-item img {
        height: 180px;
    }

    .news-lightbox-prev {
        left: 10px;
    }

    .news-lightbox-next {
        right: 10px;
    }
}
