/* ==========================================================================
   1. PORTFOLIO PAGE LAYOUT & INTRO
   ========================================================================== */
.portfolio-page {
    min-height: 100vh;
    padding: 10vh 5vw 10vh 5vw;
    max-width: 1200px;
    margin: 0 auto;
}

.page-title {
    font-size: clamp(2.5rem, 4vw, 4rem);
    text-align: center;
    margin-bottom: 60px;
}

.portfolio-intro {
    text-align: justify;
    margin-bottom: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.intro-text {
    max-width: 800px;
    color: var(--text-muted);
    line-height: 1.8;
    font-size: 1.1rem;
}

/* ==========================================================================
   2. PORTFOLIO GRID
   ========================================================================== */
.portfolio-grid {
    display: grid;
    /* Automatically creates responsive columns based on the 350px minimum width */
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

/* ==========================================================================
   3. PROJECT CARDS (Base Styles & Hover Effects)
   ========================================================================== */
.project-card {
    background: #151515;
    border: 1px solid #222;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-color);
    box-shadow: 0 10px 30px rgba(0, 255, 102, 0.1);
}

/* ==========================================================================
   4. CARD HEADER: IMAGE, BADGES & ICONS
   ========================================================================== */
.card-img-wrapper {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
}

.project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.role-badge {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(10, 10, 10, 0.85);
    backdrop-filter: blur(5px);
    color: var(--text-main);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid #333;
}

.card-badges {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* -------- Platform Icons -------- */
.platform-icon {
    font-size: 1.3rem;
    color: #555; 
    transition: color 0.3s ease, transform 0.3s ease;
}

.project-card:hover .platform-icon {
    transform: scale(1.1);
}

/* Brand Colors on Hover */
.project-card:hover .platform-icon.steam { color: #66c0f4; }
.project-card:hover .platform-icon.itch { color: #fa5c5c; }
.project-card:hover .platform-icon.github { color: #ffffff; }

/* ==========================================================================
   5. CARD CONTENT & TYPOGRAPHY
   ========================================================================== */
.project-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.project-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 5px;
}

.project-title {
    color: var(--text-main);
    font-size: 1.4rem;
    margin: 0;
    line-height: 1.2;
}

.project-year {
    font-family: var(--font-code);
    color: var(--accent-color);
    font-size: 0.9rem;
    font-weight: 600;
    background: rgba(0, 255, 102, 0.1);
    padding: 4px 8px;
    border-radius: 4px;
}

.studio-name {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 1.05rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.studio-name i {
    color: #888;
    font-size: 0.9rem;
}

/* ==========================================================================
   6. SYNTAX-STYLE TECH TAGS
   ========================================================================== */
.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: auto;
}

.tag {
    font-family: var(--font-code);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 6px 10px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tag-engine {
    color: #00d2ff;
    background: rgba(0, 210, 255, 0.1);
    border: 1px solid rgba(0, 210, 255, 0.2);
}

.tag-lang {
    color: #ff3366;
    background: rgba(255, 51, 102, 0.1);
    border: 1px solid rgba(255, 51, 102, 0.2);
}

.tag-tool {
    color: #ffaa00;
    background: rgba(255, 170, 0, 0.1);
    border: 1px solid rgba(255, 170, 0, 0.2);
}

.tag-team {
    color: var(--accent-color);
    background: rgba(0, 255, 102, 0.1);
    border: 1px solid rgba(0, 255, 102, 0.2);
}

/* ==========================================================================
   7. CALL TO ACTION (View Details)
   ========================================================================== */
.view-project-action {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #222;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s ease;
}

.view-project-action i {
    transition: transform 0.3s ease;
}

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

.project-card:hover .view-project-action i {
    transform: translateX(8px);
}


/* ==========================================================================
   7. FOOTER HOOK
   ========================================================================== */
.portfolio-footer-hook {
    text-align: center;
    margin-top: 80px;
    padding: 40px;
    border-top: 1px solid #222;
}

.portfolio-footer-hook p {
    font-family: var(--font-code);
    color: var(--text-muted);
    font-size: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
}

.portfolio-footer-hook b {
    color: var(--accent-color);
    font-style: normal;
}

.portfolio-footer-hook p::before {
    content: "\f110"; 
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    color: var(--accent-color);
    animation: fa-spin 2s linear infinite;
    font-size: 0.9rem;
}