/* ════════════════════════════════════════
   PORTFOLIO SECTION
════════════════════════════════════════ */
.portfolio-section {
    padding: 100px 80px;
    background: #fff;
    background-image:
        linear-gradient(rgba(0,147,255,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,147,255,0.04) 1px, transparent 1px);
    background-size: 60px 60px;
}

/* ── Header ── */
.portfolio-section__header {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    margin-bottom: 50px;
}

/* ── Tabs ── */
.portfolio-tabs {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 48px;
    border: 1.5px solid #dde5f0;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    overflow: hidden;
}

.portfolio-tab {
    padding: 14px 32px;
    background: #fff;
    border: none;
    border-right: 1.5px solid #dde5f0;
    font-family: 'TTFirsNeue', sans-serif;
    font-weight: 700;
    font-size: 14px;
    color: #5a6a82;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
    white-space: nowrap;
}

.portfolio-tab:last-child {
    border-right: none;
}

.portfolio-tab:hover {
    background: #f4f8ff;
    color: #0093ff;
}

.portfolio-tab--active {
    background: #0093ff;
    color: #ffffff;
}

.portfolio-tab--active:hover {
    background: #0080e0;
    color: #fff;
}

/* ── Panels ── */
.portfolio-panel {
    display: none;
    animation: fadeInPanel 0.35s ease;
}

.portfolio-panel--active {
    display: block;
}

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

/* ── Grid ── */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

/* ── Card ── */
.portfolio-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.portfolio-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0,147,255,0.13);
}

/* ── Card Image ── */
.portfolio-card__img {
    position: relative;
    overflow: hidden;
}

.portfolio-card__img img {
    width: 100%;
    height: 280px;
    object-fit: contain;
    display: block;
    transition: transform 0.4s ease;
    background: #f4f8ff;
}

.portfolio-card:hover .portfolio-card__img img {
    transform: scale(1.06);
}

/* Overlay on hover */
.portfolio-card__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 147, 255, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.portfolio-card:hover .portfolio-card__overlay {
    opacity: 1;
}

.portfolio-card__view {
    width: 52px;
    height: 52px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #0093ff;
    text-decoration: none;
    transform: scale(0.7);
    transition: transform 0.3s ease;
}

.portfolio-card:hover .portfolio-card__view {
    transform: scale(1);
}

/* Audio badge */
.portfolio-card__audio-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #0093ff;
    color: #fff;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    z-index: 1;
}

/* ── Card Info ── */
.portfolio-card__info {
    display: none;
}

/* ════════════════════════════════════════
   RESPONSIVE
════════════════════════════════════════ */
@media (max-width: 1100px) {
    .portfolio-section {
        padding: 70px 40px;
    }

    .portfolio-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .portfolio-section {
        padding: 60px 20px;
    }

    .portfolio-tabs {
        flex-wrap: wrap;
        width: 100%;
    }

    .portfolio-tab {
        flex: 1 1 45%;
        border-bottom: 1.5px solid #dde5f0;
        text-align: center;
    }

    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .portfolio-card__img img {
        height: 220px;
        object-fit: contain;
    }
}

@media (max-width: 480px) {
    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-tab {
        flex: 1 1 100%;
    }
}
