/* ========== PORTFOLIO PAGE HEADER ========== */
.portfolio-header {
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.8) 0%, rgba(30, 41, 59, 0.85) 50%, rgba(79, 70, 229, 0.8) 100%);
    padding: 150px 20px 100px 20px;
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
    margin-top: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 450px;
}

.portfolio-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 25% 45%, rgba(79, 70, 229, 0.25) 0%, transparent 50%);
    animation: pulseOrb1 4s ease-in-out infinite;
    z-index: 0;
}

.portfolio-header::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 75% 85%, rgba(79, 70, 229, 0.15) 0%, transparent 50%);
    animation: pulseOrb2 5.5s ease-in-out infinite;
    animation-delay: 0.2s;
    z-index: 0;
}

.portfolio-header-content {
    position: relative;
    z-index: 2;
}

.portfolio-header-content h1 {
    font-size: clamp(2.5rem, 6vw, 3.5rem);
    font-weight: 800;
    margin-bottom: 15px;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.portfolio-header-content p {
    font-size: clamp(0.95rem, 2.5vw, 1.1rem);
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
    font-weight: 400;
}

@keyframes pulseOrb1 {
    0%, 100% { opacity: 0.3; transform: scale(1) translate(0, 0); }
    50% { opacity: 0.5; transform: scale(1.1) translate(5px, -5px); }
}

@keyframes pulseOrb2 {
    0%, 100% { opacity: 0.2; transform: scale(1) translate(0, 0); }
    50% { opacity: 0.35; transform: scale(1.15) translate(-8px, 8px); }
}

@media (max-width: 768px) {
    .portfolio-header {
        padding: 120px 20px 80px 20px;
        min-height: 380px;
    }

    .portfolio-header-content h1 {
        margin-bottom: 12px;
    }
}

/* ========== PORTFOLIO PAGE SECTION ========== */
.portfolio-page {
    padding: 80px 20px 40px 20px;
    background: linear-gradient(180deg, #0f0f1e 0%, #1a1a2e 100%);
    margin-bottom: 0;
    position: relative;
    z-index: 1;
}

.portfolio-page .container {
    max-width: 1200px;
    margin: 0 auto;
}

/* ========== PORTFOLIO FILTERS ========== */
.portfolio-page .portfolio-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 4rem;
}

.portfolio-page .filter-btn {
    padding: 10px 25px;
    color: rgba(255, 255, 255, 0.7);
    border-radius: 16px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.95rem;
    position: relative;
    z-index: 1;
    border: none;
    background: transparent;
}

.portfolio-page .filter-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: -1;
    transition: all 0.3s ease;
    pointer-events: none;
}

.portfolio-page .filter-btn:hover::before,
.portfolio-page .filter-btn.active::before {
    background: rgba(79, 70, 229, 0.8);
    border-color: rgba(255, 255, 255, 0.2);
}

.portfolio-page .filter-btn:hover,
.portfolio-page .filter-btn.active {
    color: white;
}

@media (max-width: 768px) {
    .portfolio-page .portfolio-filters {
        gap: 0.75rem;
    }

    .portfolio-page .filter-btn {
        padding: 9px 20px;
        font-size: 0.9rem;
    }
}

/* ========== PORTFOLIO GRID - DETAILED ========== */
.portfolio-grid-detailed {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

@media (max-width: 1024px) {
    .portfolio-grid-detailed {
        grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
        gap: 25px;
    }
}

@media (max-width: 768px) {
    .portfolio-grid-detailed {
        grid-template-columns: 1fr;
        gap: 25px;
    }
}

/* ========== PORTFOLIO CARD ========== */
.portfolio-card {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    border: 1px solid rgba(79, 70, 229, 0.2);
    display: flex;
    flex-direction: column;
    height: 100%;
    opacity: 1;
    transform: scale(1);
}

.portfolio-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 30px 60px rgba(79, 70, 229, 0.3);
    border-color: rgba(79, 70, 229, 0.5);
}

/* ========== PORTFOLIO CARD IMAGE ========== */
.portfolio-card-image {
    position: relative;
    width: 100%;
    aspect-ratio: 1500 / 800;
    overflow: hidden;
    background: linear-gradient(135deg, #0f0f1e 0%, #1a1a2e 100%);
}

.portfolio-card-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: linear-gradient(135deg, #0f0f1e 0%, #1a1a2e 100%);
    transition: transform 0.4s ease;
}

.portfolio-card:hover .portfolio-card-image img {
    transform: scale(1.1);
}

/* ========== PORTFOLIO CARD BADGE ========== */
.portfolio-card-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, #4F46E5 0%, #7C3AED 100%);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 8px 20px rgba(79, 70, 229, 0.4);
}

/* ========== PORTFOLIO CARD CONTENT ========== */
.portfolio-card-content {
    padding: 30px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.portfolio-card-content h3 {
    font-size: 1.5rem;
    color: white;
    margin-bottom: 8px;
    font-weight: 700;
}

.portfolio-card-category {
    color: #7C3AED;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ========== PORTFOLIO STATS ========== */
.portfolio-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 20px;
    padding: 20px 0;
    border-top: 1px solid rgba(79, 70, 229, 0.2);
    border-bottom: 1px solid rgba(79, 70, 229, 0.2);
}

.portfolio-stats .stat {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.portfolio-stats .stat-label {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.portfolio-stats .stat-value {
    font-size: 1.2rem;
    font-weight: 700;
    color: #7C3AED;
}

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

    .portfolio-stats .stat-value {
        font-size: 1rem;
    }
}

/* ========== PORTFOLIO CARD DESCRIPTION ========== */
.portfolio-card-description {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
    flex-grow: 1;
}

/* ========== PORTFOLIO CARD TAGS ========== */
.portfolio-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.portfolio-card-tags .tag {
    background: rgba(79, 70, 229, 0.15);
    color: #7C3AED;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    border: 1px solid rgba(79, 70, 229, 0.3);
    transition: all 0.3s ease;
}

.portfolio-card:hover .portfolio-card-tags .tag {
    background: rgba(79, 70, 229, 0.25);
    border-color: rgba(79, 70, 229, 0.5);
}

/* ========== PORTFOLIO CARD LINK ========== */
.portfolio-card-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #7C3AED;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 0.95rem;
    padding-top: 10px;
}

.portfolio-card-link i {
    transition: transform 0.3s ease;
}

.portfolio-card:hover .portfolio-card-link {
    color: #9f7aea;
    gap: 12px;
}

.portfolio-card:hover .portfolio-card-link i {
    transform: translateX(5px);
}

/* ========== CTA SECTION ========== */
.cta-section {
    background: linear-gradient(to bottom, rgba(26, 26, 46, 1) 0%, rgba(30, 41, 59, 0.85) 50%, rgba(79, 70, 229, 0.8) 100%);
    padding: 50px 20px;
    text-align: center;
    color: white;
    margin-bottom: 0;
    position: relative;
    overflow: hidden;
    display: block !important;
    visibility: visible !important;
    z-index: 10 !important;
    opacity: 1 !important;
}

.cta-section .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: block !important;
    visibility: visible !important;
    z-index: 11 !important;
}

.cta-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 25% 45%, rgba(79, 70, 229, 0.25) 0%, transparent 50%);
    animation: pulseOrb1 4s ease-in-out infinite;
    z-index: 0;
    pointer-events: none;
}

.cta-section::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 75% 85%, rgba(79, 70, 229, 0.15) 0%, transparent 50%);
    animation: pulseOrb2 5.5s ease-in-out infinite;
    animation-delay: 0.2s;
    z-index: 0;
    pointer-events: none;
}

.cta-content {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 11;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100%;
}

.cta-content h2 {
    font-size: clamp(1.8rem, 4vw, 2.2rem);
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.3;
}

.cta-content p {
    font-size: clamp(0.95rem, 2vw, 1.05rem);
    margin-bottom: 25px;
    opacity: 0.95;
    max-width: 500px;
    line-height: 1.6;
}

.cta-section .btn-primary {
    color: white;
}

.cta-section .btn-primary::before {
    background: rgba(255, 255, 255, 0.15);
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.cta-section .btn-primary:hover::before {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.cta-section .btn-primary:hover {
    transform: translateY(-3px);
}

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

    .cta-content h2 {
        margin-bottom: 10px;
    }

    .cta-content p {
        margin-bottom: 20px;
    }
}

/* ========== FOOTER ADJUSTMENTS FOR PORTFOLIO PAGE ========== */
.portfolio-page ~ .cta-section ~ .footer {
    margin-top: 0;
    padding: 1.5rem 0;
}

.cta-section ~ .footer {
    border-top: none;
    margin-top: 0;
}

/* ========== ANIMATIONS ========== */
@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

/* ========== IMAGE SLIDER ========== */
.image-slider {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.slider-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.slider-image {
    position: absolute;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: linear-gradient(135deg, #0f0f1e 0%, #1a1a2e 100%);
    opacity: 0;
    transition: opacity 0.6s ease;
}

.slider-image.active {
    opacity: 1;
}

.slider-controls {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.slider-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-dot.active {
    background: white;
    width: 30px;
    border-radius: 5px;
}

.slider-dot:hover {
    background: rgba(255, 255, 255, 0.8);
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(79, 70, 229, 0.7);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    opacity: 0;
    z-index: 9;
}

.image-slider:hover .slider-arrow {
    opacity: 1;
}

.slider-arrow:hover {
    background: rgba(79, 70, 229, 1);
    transform: translateY(-50%) scale(1.1);
}

.slider-arrow.prev {
    left: 10px;
}

.slider-arrow.next {
    right: 10px;
}

/* ========== SOCIAL EMBED SLIDER ========== */
.social-embed-slider {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.embed-container {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.6s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.embed-container.active {
    opacity: 1;
}

.embed-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.embed-wrapper iframe,
.embed-wrapper blockquote {
    max-height: 100%;
    height: 100% !important;
    width: 100% !important;
}

.instagram-embed-wrapper iframe {
    min-height: 100%;
}

.linkedin-embed-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
}

.linkedin-embed-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.tiktok-embed-wrapper {
    background: linear-gradient(135deg, #000000 0%, #25f4ee 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.tiktok-embed-wrapper blockquote {
    color: white;
    text-align: center;
}

.youtube-embed-wrapper {
    background: linear-gradient(135deg, #ff0000 0%, #dd0000 100%);
}

.embed-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0);
    text-decoration: none;
    transition: background 0.3s ease;
    z-index: 15;
    cursor: default;
    pointer-events: none;
}

.embed-overlay:hover {
    background: rgba(0, 0, 0, 0.4);
}

.visit-btn {
    background: rgba(255, 255, 255, 0.95);
    color: #1a1a2e;
    padding: 12px 24px;
    border-radius: 25px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    opacity: 0;
    pointer-events: auto;
    cursor: pointer;
}

.embed-wrapper:hover .embed-overlay {
    background: rgba(0, 0, 0, 0.4);
}

.embed-wrapper:hover .visit-btn {
    opacity: 1;
    transform: scale(1.05);
}

.visit-btn:hover {
    background: white;
    transform: scale(1.1);
}

.social-embed-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.social-embed-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    gap: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.social-embed-placeholder i {
    font-size: 3.5rem;
    transition: transform 0.3s ease;
}

.social-embed-placeholder span {
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
}

.social-embed-placeholder small {
    font-size: 0.85rem;
    opacity: 0.8;
}

.social-embed-placeholder.instagram {
    background: linear-gradient(135deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    color: white;
}

.social-embed-placeholder.linkedin {
    background: linear-gradient(135deg, #0077B5 0%, #005885 100%);
    color: white;
}

.social-embed-placeholder.tiktok {
    background: linear-gradient(135deg, #000000 0%, #25f4ee 100%);
    color: white;
}

.social-embed-placeholder.youtube {
    background: linear-gradient(135deg, #ff0000 0%, #dd0000 100%);
    color: white;
}

.social-embed-link:hover .social-embed-placeholder {
    transform: scale(1.05);
}

.social-embed-link:hover .social-embed-placeholder i {
    transform: scale(1.2);
}

.embed-controls {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.embed-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.embed-dot.active {
    background: white;
    width: 30px;
    border-radius: 5px;
}

.embed-dot:hover {
    background: rgba(255, 255, 255, 0.8);
}

.embed-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(79, 70, 229, 0.7);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    opacity: 0;
    z-index: 9;
}

.social-embed-slider:hover .embed-arrow {
    opacity: 1;
}

.embed-arrow:hover {
    background: rgba(79, 70, 229, 1);
    transform: translateY(-50%) scale(1.1);
}

.embed-arrow.prev {
    left: 10px;
}

.embed-arrow.next {
    right: 10px;
}
