/* ======== PORTOFOLIO SLIDER ======== */

.portfolio-section {
    padding: 3rem 0;
    background-color: #f7f8fa;
}

.portfolio-section.is-hidden {
    display: none;
}

.portfolio-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.portfolio-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.portfolio-title {
    font-size: 2rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 0.5rem;
}

.portfolio-subtitle {
    font-size: 0.98rem;
    color: #6b7280;
    max-width: 640px;
    margin: 0.25rem auto 0;
}

.portfolio-meta {
    font-size: 0.9rem;
    color: #6b7280;
    margin-bottom: 1.25rem;
}

.portfolio-meta strong {
    color: #111827;
}

/* WRAPPER + SLIDER */

.portfolio-slider-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.portfolio-slider {
    position: relative;
    flex: 1;
    display: flex;
    gap: 1.25rem;
    overflow-x: auto;
    overflow-y: visible;
    padding: 0.75rem 0.25rem 0.5rem;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
}

/* Hilangkan scrollbar di beberapa browser (opsional) */
.portfolio-slider {
    scrollbar-width: thin;
    scrollbar-color: #cbd5f5 transparent;
}

.portfolio-slider::-webkit-scrollbar {
    height: 6px;
}

.portfolio-slider::-webkit-scrollbar-track {
    background: transparent;
}

.portfolio-slider::-webkit-scrollbar-thumb {
    background: #cbd5f5;
    border-radius: 999px;
}

/* CARD */

.portfolio-card {
    flex: 0 0 280px;
    background-color: #ffffff;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.04);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
    scroll-snap-align: start;
}

.portfolio-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.10);
    border-color: #d1d5db;
}

.portfolio-image-wrap {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
}

.portfolio-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.22s ease;
}

.portfolio-card:hover .portfolio-image {
    transform: scale(1.04);
}

.portfolio-image-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(17,24,39,0.55), transparent 50%);
    opacity: 0;
    transition: opacity 0.22s ease;
}

.portfolio-card:hover .portfolio-image-overlay {
    opacity: 1;
}

.portfolio-category-badge {
    position: absolute;
    left: 0.9rem;
    bottom: 0.9rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 500;
    background-color: rgba(243, 244, 246, 0.92);
    color: #111827;
    backdrop-filter: blur(4px);
}

.portfolio-info {
    padding: 0.85rem 1rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    flex: 1;
}

.portfolio-title-text {
    font-size: 0.98rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
    line-height: 1.4;
}

.portfolio-location {
    font-size: 0.82rem;
    color: #6b7280;
    margin: 0;
}

.portfolio-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.35rem;
    gap: 0.75rem;
    font-size: 0.8rem;
}

.portfolio-date {
    color: #6b7280;
}

.portfolio-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background-color: #f3f4f6;
    color: #4b5563;
    font-size: 0.72rem;
    white-space: nowrap;
}

/* PANAH NAVIGASI */

.portfolio-nav {
    border: none;
    background-color: #ffffff;
    color: #111827;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.16);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    font-size: 1.4rem;
    line-height: 1;
    transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.portfolio-nav:hover {
    background-color: #111827;
    color: #f9fafb;
    transform: translateY(-1px);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.25);
}

.portfolio-nav:disabled {
    opacity: 0.4;
    cursor: default;
    transform: none;
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.12);
}

/* PAGINATION */

.portfolio-pagination {
    margin-top: 2rem;
    display: flex;
    justify-content: center;
    gap: 0.35rem;
    font-size: 0.9rem;
}

.portfolio-pagination a,
.portfolio-pagination span {
    min-width: 32px;
    padding: 0.45rem 0.7rem;
    text-align: center;
    border-radius: 999px;
    text-decoration: none;
    border: 1px solid transparent;
    color: #374151;
    background-color: #ffffff;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.portfolio-pagination a:hover {
    background-color: #111827;
    color: #f9fafb;
    border-color: #111827;
}

.portfolio-pagination .is-current {
    background-color: #111827;
    color: #f9fafb;
    border-color: #111827;
    cursor: default;
}

/* RESPONSIVE */

@media (max-width: 640px) {
    .portfolio-section {
        padding: 2.25rem 0;
    }

    .portfolio-title {
        font-size: 1.6rem;
    }

    .portfolio-subtitle {
        font-size: 0.92rem;
    }

    .portfolio-slider-wrapper {
        gap: 0.5rem;
    }

    /* Opsional: sembunyikan panah di mobile, user cukup swipe */
    .portfolio-nav {
        display: none;
    }

    .portfolio-card {
        flex: 0 0 240px;
    }
}
