/**
 * Bright Infosystem Website
 *
 * @file latest-project-section.css
 * @description Styles for the "Our Latest Project" section with default content visibility.
 * @version 3.2 (Fix for corner rendering glitch)
 */

.latest-project-section {
    padding: 100px 20px;
}
.project-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}
.project-header {
    margin-bottom: 60px;
}
.project-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    border: 1px solid var(--dark-divider-color);
    border-radius: 50px;
    color: var(--primary-color);
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 30px;
}
.project-badge .badge-icon {
    width: 16px;
    height: 16px;
}
.project-heading {
    font-size: 44px;
    font-weight: 800;
    color: var(--primary-color);
    margin: 0 auto;
    max-width: 700px;
    line-height: 1.3;
}
.project-heading .gradient-text {
    background: linear-gradient(to right, var(--accent-color) 0%, var(--accent-secondary-color) 50%, var(--accent-color) 100%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: background-position 0.5s ease-in-out;
}
.project-heading:hover .gradient-text {
    background-position: 100% 0%;
}

/* --- Project Cards --- */
.project-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}
.project-card-link {
    text-decoration: none;
}
.project-card {
    height: 600px;
    border-radius: 20px 20px 0px 0px;
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    transition: transform 0.4s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end; /* Aligns content to the bottom */
}
.project-card-link:hover .project-card {
    transform: translateY(-10px);
}
.project-card-overlay {
    padding: 30px;
    box-sizing: border-box;
    background: linear-gradient(to top, rgba(6, 6, 6, 0.95) 30%, transparent 100%);
    opacity: 1;
    transform: translateY(0);
    /* Fix for corner rendering glitch */
    border-bottom-left-radius: 0px;
    border-bottom-right-radius: 0px;
}
.project-details {
    text-align: left;
    padding-right: 60px; /* Space for the arrow */
}
.project-details h3 {
    font-size: 24px;
    color: var(--primary-color);
    margin: 0 0 10px 0;
}
.project-details p {
    font-size: 16px;
    color: var(--text-color);
    margin: 0;
}

/* Arrow Circle with zoom-in gradient hover effect */
.arrow-circle {
    position: absolute;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: transparent;
    border: 1px solid var(--dark-divider-color);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.4s ease, border-color 0.4s ease;
    overflow: hidden;
    z-index: 5;
}
.arrow-circle::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(to right, var(--accent-color), var(--accent-secondary-color));
    border-radius: 50%;
    transform: scale(0);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 1;
}
.project-card-link:hover .arrow-circle {
    transform: scale(1.1);
    border-color: transparent;
}
.project-card-link:hover .arrow-circle::before {
    transform: scale(1);
}
.arrow-icon {
    font-size: 20px;
    color: var(--primary-color);
    position: relative;
    z-index: 2;
}

/* --- CTA Card --- */
.project-cta-card {
    margin-top: 60px;
    padding: 40px;
    border-radius: 20px;
    background: var(--secondary-color);
    border: 1px solid var(--divider-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.cta-badge {
    background: var(--accent-color);
    color: var(--primary-color);
    padding: 8px 15px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 14px;
}
.cta-text {
    font-size: 20px;
    color: var(--primary-color);
    font-weight: 500;
    margin: 0;
}
.cta-button .btn-secondary a {
    white-space: nowrap;
}


/* --- Scroll Animation Styles --- */
.fade-in-element {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}
.fade-in-element.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggering animation delays */
.project-header.is-visible { transition-delay: 0.1s; }
.project-grid > a:nth-child(1).is-visible { transition-delay: 0.2s; }
.project-grid > a:nth-child(2).is-visible { transition-delay: 0.3s; }
.project-grid > a:nth-child(3).is-visible { transition-delay: 0.4s; }
.project-cta-card.is-visible { transition-delay: 0.5s; }


/* --- Responsive Styles --- */
@media (max-width: 1024px) {
    .project-grid {
        grid-template-columns: 1fr;
    }
    .project-cta-card {
        flex-direction: column;
        gap: 25px;
        text-align: center;
    }
}
@media (max-width: 768px) {
    .project-heading { font-size: 32px; }
    .project-card {
        height: 500px;
    }
}

