:root {
    --bg-main: #0F0F0F;
    --bg-secondary: #1A1A1A;
    --accent-gold: #FFCC00;
    --text-light: #FFFFFF;
    --text-muted: #B0B0B0;
    --card-glass: rgba(255, 255, 255, 0.03);
    --border-glass: rgba(255, 255, 255, 0.08);
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

/* Ensure these don't break global layout, but apply to page content */
.projects-page-body {
    background-color: var(--bg-main);
    color: var(--text-light);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
}

.projects-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* --- Page Header --- */
.page-header {
    text-align: center;
    padding: 60px 0;
    background: linear-gradient(to bottom, rgba(255, 204, 0, 0.05), transparent);
    margin-bottom: 40px;
}

.page-header h1 {
    font-family: 'Poppins', sans-serif;
    font-size: 3rem;
    margin-bottom: 10px;
    color: var(--text-light);
}

/* --- Modern Filter Bar --- */
.filter-container {
    background: var(--card-glass);
    border: 1px solid var(--border-glass);
    padding: 15px;
    border-radius: 50px;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 60px;
    backdrop-filter: blur(10px);
}

.filter-btn {
    padding: 10px 25px;
    border-radius: 30px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Inter', sans-serif;
}

.filter-btn.active,
.filter-btn:hover {
    background: var(--accent-gold);
    color: var(--bg-main);
    box-shadow: 0 5px 15px rgba(255, 204, 0, 0.3);
}

/* --- Projects Grid --- */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

.project-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
    border: 1px solid var(--border-glass);
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition);
    position: relative;
    display: block;
    backdrop-filter: blur(15px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 20px;
    padding: 1px;
    background: linear-gradient(135deg, transparent, transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    opacity: 0;
    transition: var(--transition);
    pointer-events: none;
}

.project-card.hidden {
    display: none;
}

.project-card:hover {
    transform: translateY(-10px);
    border-color: rgba(255, 204, 0, 0.6);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5),
        0 0 40px rgba(255, 204, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
}

.project-card:hover::before {
    opacity: 1;
    background: linear-gradient(135deg, var(--accent-gold), rgba(255, 204, 0, 0.3));
}

.project-img-wrapper {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.project-img-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(15, 15, 15, 0.7) 100%);
    opacity: 0.6;
    transition: var(--transition);
}

.project-card:hover .project-img-wrapper::after {
    opacity: 0.3;
}

.project-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
    filter: brightness(0.9);
}

.project-card:hover .project-img-wrapper img {
    transform: scale(1.1);
    filter: brightness(1.1);
}

.project-info {
    padding: 25px;
    position: relative;
}

.project-info::before {
    content: '';
    position: absolute;
    top: 0;
    left: 25px;
    right: 25px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 204, 0, 0.3), transparent);
}

.category-badge {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--bg-main);
    background: linear-gradient(135deg, var(--accent-gold), #FFD700);
    letter-spacing: 1px;
    font-weight: 700;
    margin-bottom: 12px;
    display: inline-block;
    padding: 6px 14px;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(255, 204, 0, 0.3);
}

.project-info h3 {
    font-size: 1.4rem;
    margin-bottom: 12px;
    font-family: 'Poppins', sans-serif;
    color: var(--text-light);
    line-height: 1.3;
    transition: var(--transition);
}

.project-card:hover .project-info h3 {
    color: var(--accent-gold);
}

.project-info p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.6;
}

.view-link {
    display: inline-flex;
    align-items: center;
    color: var(--accent-gold);
    font-weight: 700;
    text-decoration: none;
    gap: 8px;
    transition: var(--transition);
    position: relative;
    padding-bottom: 2px;
}

.view-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-gold), #FFD700);
    transition: var(--transition);
}

.view-link:hover {
    gap: 12px;
    color: #FFD700;
}

.view-link:hover::after {
    width: 100%;
}

/* --- Footer CTA --- */
.cta-bottom {
    margin-top: 100px;
    text-align: center;
    background: var(--bg-secondary);
    padding: 60px 20px;
    border-radius: 30px;
    border: 1px solid var(--border-glass);
}

.cta-bottom h2 {
    font-size: 2rem;
    margin-bottom: 30px;
    color: var(--text-light);
}

.btn-group {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.btn {
    padding: 15px 35px;
    border-radius: 50px;
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-gold {
    background: var(--accent-gold);
    color: var(--bg-main);
}

.btn-gold:hover {
    background: #fff;
    transform: scale(1.05);
}

.btn-whatsapp {
    background: #25D366;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-whatsapp:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(37, 211, 102, 0.2);
}

@media (max-width: 768px) {
    .page-header h1 {
        font-size: 2.2rem;
    }

    .filter-container {
        border-radius: 20px;
    }
}