/* =============================================
   Nasci Portfolio Grid Widget
   ============================================= */

/* === FILTERS === */
.nasci-pf-header { position: relative; z-index: 2; }

.nasci-pf-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 32px;
    justify-content: center;
}

.nasci-pf-filter {
    padding: 10px 24px;
    border: 1px solid #e2e8f0;
    border-radius: 50px;
    background: transparent;
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: inherit;
    line-height: 1;
}

.nasci-pf-filter:hover {
    border-color: var(--nasci-accent, #90E509);
    color: var(--nasci-accent, #90E509);
}

.nasci-pf-filter.active {
    background: var(--nasci-accent, #90E509);
    border-color: var(--nasci-accent, #90E509);
    color: #00181C;
    font-weight: 600;
}

/* === GRID === */
.nasci-pf-grid {
    display: grid;
    gap: 24px;
}

.nasci-pf-cols--2 { grid-template-columns: repeat(2, 1fr); }
.nasci-pf-cols--3 { grid-template-columns: repeat(3, 1fr); }
.nasci-pf-cols--4 { grid-template-columns: repeat(4, 1fr); }

/* === CARD === */
.nasci-pf-card {
    display: flex;
    flex-direction: column;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.nasci-pf-grid .nasci-pf-card:hover {
    transform: translateY(-4px);
}

.nasci-pf-card.nasci-pf-hidden {
    display: none !important;
}

/* === IMAGE WRAP === */
.nasci-pf-img-wrap {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    display: block;
}

.nasci-pf-ratio--1-1 .nasci-pf-img-wrap  { aspect-ratio: 1 / 1; }
.nasci-pf-ratio--4-3 .nasci-pf-img-wrap  { aspect-ratio: 4 / 3; }
.nasci-pf-ratio--16-9 .nasci-pf-img-wrap { aspect-ratio: 16 / 9; }
.nasci-pf-ratio--3-4 .nasci-pf-img-wrap  { aspect-ratio: 3 / 4; }
.nasci-pf-ratio--fixed-275 .nasci-pf-img-wrap { aspect-ratio: auto; height: 275px; }

.nasci-pf-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.nasci-pf-card:hover .nasci-pf-img {
    transform: scale(1.05);
}

.nasci-pf-placeholder {
    background: #1a2332;
}

/* === OVERLAY === */
.nasci-pf-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}

/* === IMAGE CONTENT === */
.nasci-pf-img-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
}

/* === PILL === */
.nasci-pf-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: rgba(var(--nasci-accent-rgb, 144,229,9), 0.12);
    border: 1px solid rgba(var(--nasci-accent-rgb, 144,229,9), 0.25);
    border-radius: 100px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.nasci-pf-pill-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--nasci-accent, #90E509);
    flex-shrink: 0;
    box-shadow: 0 0 6px rgba(var(--nasci-accent-rgb, 144,229,9), 0.5);
}

.nasci-pf-pill-text {
    font-size: 12px;
    font-weight: 600;
    color: #ffffff;
    white-space: nowrap;
    letter-spacing: 0.02em;
}

/* === TITLE === */
.nasci-pf-title {
    font-size: 22px;
    font-weight: 700;
    line-height: 1.25;
    color: #ffffff;
    margin: 0;
    padding: 0;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* === BODY === */
.nasci-pf-body {
    padding: 16px 4px 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
    flex-grow: 1;
}

.nasci-pf-excerpt {
    font-size: 14px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.75);
    margin: 0;
    padding: 0;
    flex-grow: 1;
}

/* === BUTTON === */
.nasci-pf-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    background: var(--nasci-accent, #90E509);
    color: #00181C;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.01em;
    align-self: flex-start;
}

.nasci-pf-btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.nasci-pf-btn-icon svg,
.nasci-pf-btn-icon i {
    width: 1em;
    height: 1em;
    fill: currentColor;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.nasci-pf-btn--icon-right:hover .nasci-pf-btn-icon { transform: translateX(3px); }
.nasci-pf-btn--icon-left:hover  .nasci-pf-btn-icon { transform: translateX(-3px); }

.nasci-pf-btn:hover {
    filter: brightness(1.1);
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(var(--nasci-accent-rgb, 144,229,9), 0.35);
    text-decoration: none;
    color: #00181C;
}

.nasci-pf-btn:active {
    transform: translateY(0);
}

/* =============================================
   FULLWIDTH CAROUSEL BREAKOUT
   ============================================= */
.nasci-pf-wrapper {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    overflow: hidden;
}

.nasci-pf-carousel-fullwidth {
    position: relative;
    width: 100%;
    margin: 0 auto;
    padding-top: 0;
    padding-bottom: 0;
}

.swiper.nasci-pf-carousel {
    overflow: visible;
    padding: 8px 0 16px;
}

.nasci-pf-carousel .swiper-wrapper {
    align-items: stretch;
}

.nasci-pf-carousel .swiper-slide {
    height: auto;
    display: flex;
    transition: opacity 0.4s ease, transform 0.4s ease;
    opacity: 0.55;
}

.nasci-pf-carousel .swiper-slide-active {
    opacity: 1;
}

.nasci-pf-carousel .nasci-pf-card {
    width: 100%;
    height: 100%;
    opacity: 1;
    animation: none;
    transform: none;
}

.nasci-pf-carousel .nasci-pf-card:hover { transform: none; }

/* Slide breedtes per breakpoint */
@media (max-width: 767px) {
    .nasci-pf-carousel .swiper-slide {
        width: 82vw;
        max-width: 380px;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .nasci-pf-carousel .swiper-slide {
        width: 60vw;
        max-width: 520px;
    }
}

/*
 * Desktop: 3 hele kaarten in het midden + halve peeks links en rechts.
 * - .nasci-pf-wrapper houdt de 100vw breakout (basis CSS, overflow:hidden).
 * - Container = 75vw zodat 3 hele slides + 2 gaps erin passen.
 * - Empty viewport-zijdes = (100vw - 75vw)/2 = 12.5vw per kant
 *   → slides naast container peeken voor exact ~halve-slide breed.
 * - Carousel houdt overflow:visible voor het peek-effect.
 */
@media (min-width: 1024px) {
    .nasci-pf-carousel-fullwidth {
        width: 75vw;
        max-width: 1440px;
        margin: 0 auto;
    }

    .swiper.nasci-pf-carousel {
        overflow: visible;
    }

    .nasci-pf-carousel .swiper-slide {
        width: calc(25vw - 12px);
        max-width: 480px;
        opacity: 1;
    }
}

@media (min-width: 1600px) {
    .nasci-pf-carousel-fullwidth {
        max-width: 1600px;
    }

    .nasci-pf-carousel .swiper-slide {
        max-width: 520px;
    }
}

/* =============================================
   ARROW NAVIGATIE
   ============================================= */
.nasci-pf-arrow {
    position: absolute;
    top: 30%;
    transform: translateY(-50%);
    z-index: 10;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 24, 28, 0.08);
    color: #00181C;
}

.nasci-pf-arrow svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.nasci-pf-arrow:hover {
    background: var(--nasci-accent, #90E509);
    border-color: var(--nasci-accent, #90E509);
    transform: translateY(-50%) scale(1.05);
    box-shadow: 0 6px 24px rgba(var(--nasci-accent-rgb, 144,229,9), 0.35);
}

.nasci-pf-arrow.swiper-button-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

.nasci-pf-arrow-prev { left: 24px; }
.nasci-pf-arrow-next { right: 24px; }

/* Op desktop is .nasci-pf-carousel-fullwidth smaller dan viewport (66.66vw).
   Pijlen moeten echter aan de viewport-randen staan, dus negatieve offset om de
   peek-zone in te schuiven, plus 24px afstand van viewport-edge. */
@media (min-width: 1024px) {
    .nasci-pf-arrow-prev { left: calc((100% - 100vw) / 2 + 24px); }
    .nasci-pf-arrow-next { right: calc((100% - 100vw) / 2 + 24px); }
}

@media (max-width: 767px) {
    .nasci-pf-arrow { width: 36px; height: 36px; top: 32%; }
    .nasci-pf-arrow svg { width: 16px; height: 16px; }
    .nasci-pf-arrow-prev { left: 8px; }
    .nasci-pf-arrow-next { right: 8px; }
}

/* === EMPTY === */
.nasci-pf-empty {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
    font-size: 15px;
    border: 2px dashed #e2e8f0;
    border-radius: 12px;
}

/* === STAGGER (alleen grid) === */
.nasci-pf-grid .nasci-pf-card {
    opacity: 0;
    transform: translateY(24px);
    animation: nasciCardFadeIn 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.nasci-pf-grid .nasci-pf-card:nth-child(1) { animation-delay: 0.05s; }
.nasci-pf-grid .nasci-pf-card:nth-child(2) { animation-delay: 0.1s; }
.nasci-pf-grid .nasci-pf-card:nth-child(3) { animation-delay: 0.15s; }
.nasci-pf-grid .nasci-pf-card:nth-child(4) { animation-delay: 0.2s; }
.nasci-pf-grid .nasci-pf-card:nth-child(5) { animation-delay: 0.25s; }
.nasci-pf-grid .nasci-pf-card:nth-child(6) { animation-delay: 0.3s; }
.nasci-pf-grid .nasci-pf-card:nth-child(7) { animation-delay: 0.35s; }
.nasci-pf-grid .nasci-pf-card:nth-child(8) { animation-delay: 0.4s; }
.nasci-pf-grid .nasci-pf-card:nth-child(9) { animation-delay: 0.45s; }

@keyframes nasciCardFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* === RESPONSIVE GRID === */
@media (max-width: 1024px) {
    .nasci-pf-cols--4 { grid-template-columns: repeat(3, 1fr); }
    .nasci-pf-title { font-size: 20px; }
}

@media (max-width: 768px) {
    .nasci-pf-cols--3,
    .nasci-pf-cols--4 { grid-template-columns: repeat(2, 1fr); }

    .nasci-pf-grid { gap: 16px; }
    .nasci-pf-img-content { padding: 18px; }
    .nasci-pf-title { font-size: 18px; }
    .nasci-pf-excerpt { font-size: 13px; }
    .nasci-pf-body { padding: 12px 2px 0; gap: 12px; }
    .nasci-pf-btn { padding: 12px 24px; font-size: 13px; }
    .nasci-pf-filters { gap: 8px; }
    .nasci-pf-filter { padding: 8px 18px; font-size: 13px; }
}

@media (max-width: 480px) {
    .nasci-pf-cols--2,
    .nasci-pf-cols--3,
    .nasci-pf-cols--4 { grid-template-columns: 1fr; }

    .nasci-pf-title { font-size: 20px; }
    .nasci-pf-img-content { padding: 20px; }
}
