/* ==========================================
   projects.css
   Page-specific styling for the Projects page.
   This file extends the global design system without
   changing the shared homepage project cards.
========================================== */

/* ==========================================
   Projects Page Atmosphere
   Reuses the site's dark-blue palette with a slightly
   more technical, diagram-like gradient treatment.
========================================== */
.projects-page {
    position: relative;
    overflow-x: hidden;
    background:
        radial-gradient(circle at top left, rgba(56, 189, 248, 0.08), transparent 36%),
        radial-gradient(circle at 85% 18%, rgba(59, 130, 246, 0.08), transparent 24%),
        linear-gradient(180deg, #09111f 0%, #0f172a 42%, #111827 100%);
}

.projects-page main {
    position: relative;
    z-index: 1;
}

.projects-page::before,
.projects-page::after {
    content: "";
    position: fixed;
    width: 30rem;
    height: 30rem;
    border-radius: 999px;
    pointer-events: none;
    filter: blur(88px);
    opacity: 0.3;
    z-index: -1;
}

.projects-page::before {
    top: 8%;
    left: -10%;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.18) 0%, rgba(56, 189, 248, 0.04) 44%, transparent 72%);
}

.projects-page::after {
    right: -10%;
    bottom: 10%;
    background: radial-gradient(circle, rgba(148, 163, 184, 0.16) 0%, rgba(37, 99, 235, 0.05) 48%, transparent 76%);
}

/* ==========================================
   Page Intro
========================================== */
.projects-page-title {
    padding-top: 72px;
    padding-bottom: 22px;
}

.projects-hero-title {
    max-width: 12ch;
}

.projects-intro {
    max-width: 760px;
}

.projects-section {
    padding-top: 18px;
}

.projects-section-heading {
    margin-bottom: 32px;
}

.projects-section-text {
    max-width: 760px;
}

/* ==========================================
   Projects Layout
   Uses a grid now so the page can scale to multiple
   cards later without restructuring the HTML.
========================================== */
.projects-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

/* ==========================================
   Featured Project Card
   This card keeps a technical, minimal tone and uses
   subtle motion so interaction feels intentional.
========================================== */
.project-card-featured {
    position: relative;
    display: flex;
    min-height: 320px;
    padding: 32px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 24px;
    background:
        linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(15, 23, 42, 0.78)),
        linear-gradient(135deg, rgba(56, 189, 248, 0.1), transparent 52%);
    box-shadow: 0 24px 60px rgba(2, 6, 23, 0.32);
    overflow: hidden;
    isolation: isolate;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.project-card-featured::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(56, 189, 248, 0.08) 1px, transparent 1px),
        linear-gradient(rgba(56, 189, 248, 0.06) 1px, transparent 1px);
    background-size: 28px 28px;
    opacity: 0.18;
    z-index: -1;
    transform: translateY(0);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.project-card-featured:hover {
    transform: translateY(-6px);
    border-color: rgba(56, 189, 248, 0.36);
    box-shadow: 0 28px 72px rgba(2, 6, 23, 0.42);
}

.project-card-featured:hover::before {
    opacity: 0.28;
    transform: translateY(-4px);
}

.project-card-content {
    display: flex;
    flex-direction: column;
    gap: 22px;
    width: 100%;
}

.project-kicker {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #7dd3fc;
}

.project-card-header {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.project-title {
    max-width: 16ch;
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    line-height: 1.08;
    letter-spacing: -0.03em;
    color: #f8fafc;
}

.project-description {
    max-width: 60ch;
    font-size: 1.02rem;
    line-height: 1.85;
    color: #cbd5e1;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    list-style: none;
}

.project-tag {
    padding: 8px 14px;
    border: 1px solid rgba(125, 211, 252, 0.16);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.66);
    color: #dbeafe;
    font-size: 0.9rem;
    letter-spacing: 0.01em;
}

.project-actions {
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: 14px;
    padding-top: 8px;
}

.project-link {
    box-shadow: 0 10px 24px rgba(14, 165, 233, 0.18);
}

.project-link:hover {
    box-shadow: 0 14px 28px rgba(14, 165, 233, 0.24);
}

/* ==========================================
   Responsive Refinements
========================================== */
@media (max-width: 768px) {
    .projects-page-title {
        padding-top: 56px;
        padding-bottom: 16px;
    }

    .projects-container {
        grid-template-columns: 1fr;
    }

    .project-card-featured {
        min-height: auto;
        padding: 26px 22px;
        border-radius: 20px;
    }

    .project-title {
        max-width: 100%;
    }

    .project-description {
        max-width: 100%;
    }

    .project-actions {
        align-items: stretch;
    }

    .project-link {
        width: 100%;
        text-align: center;
    }
}
