/* ============================================================
   Laboratories & Workshops Showcase Page Styling
   ============================================================ */

.labs-page-shell {
    margin-top: 0.5rem;
    margin-bottom: 3.5rem;
}

/* Hero Section */
.labs-hero {
    background: linear-gradient(145deg, #ffffff, #fdf8fa);
    border: 1px solid rgba(133, 0, 62, 0.12);
    border-radius: 18px;
    padding: clamp(1.5rem, 3vw, 2.5rem);
    margin-bottom: 2rem;
    box-shadow: 0 10px 28px rgba(133, 0, 62, 0.05);
    text-align: center;
}

.labs-hero__kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(133, 0, 62, 0.08);
    color: #85003e;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 0.3rem 0.9rem;
    border-radius: 20px;
    margin-bottom: 0.85rem;
}

.labs-hero__title {
    font-size: clamp(1.4rem, 2.5vw, 1.85rem);
    font-weight: 800;
    color: #1a1216;
    margin: 0 0 0.85rem 0;
    line-height: 1.45;
}

.labs-hero__lead {
    font-size: 1rem;
    line-height: 1.9;
    color: #4b5563;
    max-width: 820px;
    margin: 0 auto 1.5rem auto;
    text-align: justify;
    text-align-last: center;
}

.labs-hero__stats {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.85rem;
}

.labs-hero__stat-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: #ffffff;
    border: 1px solid rgba(133, 0, 62, 0.14);
    border-radius: 12px;
    padding: 0.55rem 1rem;
    font-size: 0.86rem;
    font-weight: 700;
    color: #334155;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.labs-hero__stat-pill svg {
    color: #85003e;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* Category Filter Bar */
.labs-filter-bar {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.6rem;
    margin: 0 0 2.25rem 0;
}

.labs-filter-btn {
    border: 1px solid rgba(133, 0, 62, 0.15);
    background: #ffffff;
    color: #475569;
    padding: 0.5rem 1.15rem;
    border-radius: 24px;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.labs-filter-btn:hover {
    border-color: #85003e;
    color: #85003e;
    background: rgba(133, 0, 62, 0.04);
}

.labs-filter-btn.is-active {
    background: #85003e;
    border-color: #85003e;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(133, 0, 62, 0.25);
}

.labs-filter-btn__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.08);
    font-size: 0.74rem;
    font-weight: 800;
    padding: 0.15rem 0.5rem;
    border-radius: 12px;
}

.labs-filter-btn.is-active .labs-filter-btn__count {
    background: rgba(255, 255, 255, 0.25);
    color: #ffffff;
}

/* Labs Showcase Grid */
.labs-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.lab-card {
    background: #ffffff;
    border: 1px solid rgba(133, 0, 62, 0.12);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(26, 18, 22, 0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    display: grid;
    grid-template-columns: 40% 60%;
}

.lab-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 34px rgba(133, 0, 62, 0.1);
    border-color: rgba(133, 0, 62, 0.28);
}

.lab-card--reverse {
    grid-template-columns: 60% 40%;
}

.lab-card--reverse .lab-card__media {
    order: 2;
}

.lab-card--reverse .lab-card__content {
    order: 1;
}

/* Media Frame */
.lab-card__media {
    position: relative;
    background: #f1f5f9;
    cursor: pointer;
    overflow: hidden;
    min-height: 280px;
}

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

.lab-card:hover .lab-card__media img {
    transform: scale(1.05);
}

.lab-card__zoom-badge {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(4px);
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.3rem 0.65rem;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    opacity: 0.9;
    transition: opacity 0.2s ease, background 0.2s ease;
}

.lab-card:hover .lab-card__zoom-badge {
    opacity: 1;
    background: rgba(133, 0, 62, 0.9);
}

.lab-card__zoom-badge svg {
    width: 14px;
    height: 14px;
}

/* Content Area */
.lab-card__content {
    padding: clamp(1.25rem, 2.5vw, 1.85rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.lab-card__badge {
    align-self: flex-start;
    background: rgba(133, 0, 62, 0.08);
    color: #85003e;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    margin-bottom: 0.5rem;
}

.lab-card__title {
    font-size: clamp(1.15rem, 2vw, 1.35rem);
    font-weight: 800;
    color: #1a1216;
    margin: 0 0 0.75rem 0;
    line-height: 1.4;
}

.lab-card__desc {
    font-size: 0.92rem;
    line-height: 1.88;
    color: #475569;
    margin: 0 0 1rem 0;
    text-align: justify;
}

.lab-card__equip {
    margin-top: auto;
    padding-top: 0.9rem;
    border-top: 1px dashed rgba(133, 0, 62, 0.14);
}

.lab-card__equip-title {
    font-size: 0.82rem;
    font-weight: 800;
    color: #85003e;
    margin-bottom: 0.45rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.lab-card__equip-title svg {
    width: 16px;
    height: 16px;
}

.lab-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.lab-card__tag {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.2rem 0.6rem;
    font-size: 0.78rem;
    color: #334155;
    font-weight: 600;
}

/* Lightbox Modal */
.labs-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.labs-lightbox.is-open {
    opacity: 1;
    pointer-events: auto;
}

.labs-lightbox__dialog {
    position: relative;
    max-width: 92vw;
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.labs-lightbox__img {
    max-width: 100%;
    max-height: 82vh;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    object-fit: contain;
}

.labs-lightbox__caption {
    color: #ffffff;
    margin-top: 0.85rem;
    font-size: 1rem;
    font-weight: 700;
    text-align: center;
}

.labs-lightbox__close {
    position: absolute;
    top: -46px;
    left: 0;
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    border: none;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    transition: background 0.2s ease;
}

.labs-lightbox__close:hover {
    background: rgba(255, 255, 255, 0.4);
}

@media (max-width: 860px) {
    .lab-card,
    .lab-card--reverse {
        grid-template-columns: 1fr;
    }
    .lab-card--reverse .lab-card__media {
        order: 1;
    }
    .lab-card--reverse .lab-card__content {
        order: 2;
    }
    .lab-card__media {
        min-height: 220px;
        aspect-ratio: 16 / 10;
    }
}
