/* ==========================================================================
   PREMIUM EDITORIAL PROJECTS LISTING TEMPLATE STYLES
   ========================================================================== */

/* Main Page Wrapper */
.projects-page-wrapper {
    background-color: #FFFFFF;
    padding: 0 0 3rem 0;
    /* top padding handled by the hero section */
    min-height: 80vh;
}

/* 1. Hero Section (Deep Petrol Blue-Teal Header) */
.projects-hero-section {
    background-color: #1E3E4B;
    background-image: url("data:image/svg+xml,%3Csvg width='52' height='52' viewBox='0 0 52 52' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M26 1 L51 26 L26 51 L1 26 Z' fill='none' stroke='rgba(191%2C162%2C118%2C0.38)' stroke-width='0.6'/%3E%3C/svg%3E");
    background-size: 52px 52px;
    padding-top: 7rem;
    padding-bottom: 3rem;
    position: relative;
    overflow: hidden;
}

.projects-hero-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    z-index: 2;
    margin-top: 30px;
}

.hero-eyebrow {
    font-family: var(--font-body);
    font-size: 11px;
    font-weight: 700;
    color: var(--color-accent);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 1.25rem;
    opacity: 0;
    transform: translateY(10px);
    animation: revealText 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2.5rem, 2rem + 2.5vw, 4.5rem);
    font-weight: 700;
    color: #FFFFFF;
    line-height: 1.15;
    margin: 0;
    opacity: 0;
    transform: translateY(30px);
    animation: revealText 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 0.1s;
}

.hero-line {
    width: 0;
    height: 1px;
    background-color: var(--color-accent);
    margin: 1.5rem 0;
    animation: drawLine 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 0.2s;
}

.hero-desc {
    font-family: var(--font-body);
    font-size: clamp(15px, 14px + 0.2vw, 17px);
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.85;
    max-width: 720px;
    margin: 0;
    opacity: 0;
    transform: translateY(20px);
    animation: revealText 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 0.3s;
}

/* Background Glow Effects */
.projects-hero-section .hero-glow-1,
.projects-hero-section .hero-glow-2 {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.22;
    pointer-events: none;
    z-index: 1;
    mix-blend-mode: screen;
    animation: floatGlow 14s infinite alternate ease-in-out;
}

.projects-hero-section .hero-glow-1 {
    width: 300px;
    height: 300px;
    background-color: var(--color-accent);
    top: -50px;
    left: 10%;
}

.projects-hero-section .hero-glow-2 {
    width: 250px;
    height: 250px;
    background-color: #3b7c91;
    bottom: -30px;
    right: 15%;
    animation-delay: -7s;
}

@keyframes floatGlow {
    0% {
        transform: translate(0, 0) scale(1);
    }

    50% {
        transform: translate(40px, -20px) scale(1.08);
    }

    100% {
        transform: translate(-20px, 30px) scale(0.92);
    }
}

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

@keyframes drawLine {
    to {
        width: 60px;
    }
}

/* 2. Grid Section */
.projects-grid-section {
    position: relative;
}

.projects-grid-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 4rem;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.project-card-wrapper {
    width: 100%;
}

.project-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    border-radius: 6px;
    overflow: hidden;
    background-color: #FDFCFA;
    border: 1px solid rgba(40, 86, 101, 0.08);
    box-shadow: 0 10px 30px rgba(17, 37, 44, 0.03);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    height: 100%;
}

.project-card-img-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
}

.project-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card-overlay {
    position: absolute;
    inset: 0;
    background: rgba(17, 37, 44, 0.4);
    opacity: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .project-card-overlay {
    opacity: 1;
}

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

.explore-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.8rem 1.8rem;
    background-color: var(--color-accent);
    color: #FFFFFF;
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border-radius: 4px;
    box-shadow: 0 10px 25px rgba(191, 162, 118, 0.2);
    transform: translateY(15px);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .explore-btn {
    transform: translateY(0);
}

.explore-btn svg {
    width: 16px;
    height: 16px;
    transition: transform 0.4s ease;
}

.explore-btn:hover svg {
    transform: translateX(4px);
}

.project-card-content {
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.project-card-tag {
    font-family: var(--font-body);
    font-size: 10px;
    font-weight: 700;
    color: var(--color-accent);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
}

.project-card-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.4rem, 1.6vw, 1.7rem);
    font-weight: 700;
    color: var(--color-primary);
    margin: 0 0 1rem 0;
    line-height: 1.35;
    transition: color 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .project-card-title {
    color: var(--color-accent-dark);
}

.project-card-desc {
    font-family: var(--font-body);
    font-size: 14px;
    color: var(--color-text-muted);
    line-height: 1.7;
    margin: 0 0 2rem 0;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;               /* Clamp to maximum 3 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.project-card-action {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-body);
    font-size: 11px;
    font-weight: 700;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .project-card-action {
    color: var(--color-accent);
}

.action-arrow {
    width: 14px;
    height: 14px;
    transition: transform 0.4s ease;
}

.project-card:hover .action-arrow {
    transform: translateX(4px);
}

.no-projects-fallback {
    text-align: center;
    padding: 6rem 0;
    font-family: var(--font-body);
    color: var(--color-text-muted);
}

/* Animations support */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.animate-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
    margin-top: 3rem;
}

/* Responsive */
@media (max-width: 992px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2.5rem;
    }

    .projects-header-container,
    .projects-grid-container {
        padding: 0 2rem;
    }
}

@media (max-width: 768px) {
    .projects-page-wrapper {
        padding: 0 0 2rem 0;
    }

    .projects-hero-section {
        padding-top: 6.5rem;
        padding-bottom: 2.5rem;
    }

    .projects-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .projects-hero-container,
    .projects-grid-container {
        padding: 0 1.5rem;
    }
}