/* Achievement Cards with 3D Hover Effect (Aceternity-inspired) */
/* v2.0 - White theme for mobile - Cache refresh */
.achievement-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin: 40px 0;
    perspective: 1000px;
}

.achievement-card {
    position: relative;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 30px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
    cursor: pointer;
    overflow: hidden;
}

.achievement-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(255, 255, 255, 0.1), transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.achievement-card:hover::before {
    opacity: 1;
}

.achievement-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateZ(20px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.achievement-card-title {
    font-size: 20px;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 12px;
    font-family: 'JetBrains Mono', monospace;
}

.achievement-card-description {
    font-size: 14px;
    line-height: 1.6;
    color: #d0d0d0;
    margin-bottom: 20px;
    font-family: 'Inter', sans-serif;
}

.achievement-card-meta {
    font-size: 12px;
    color: #a0a0a0;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'JetBrains Mono', monospace;
}

/* Smooth Scroll Enhancement */
html {
    scroll-padding-top: 100px;
}

@media (max-width: 768px) {
    .achievement-cards {
        grid-template-columns: 1fr;
        gap: 25px;
        margin: 35px 0;
    }

    .achievement-card {
        /* White color with glow on mobile */
        background: rgba(255, 255, 255, 0.08);
        border: 2px solid rgba(255, 255, 255, 0.6);
        padding: 28px;
        box-shadow: 0 4px 24px rgba(255, 255, 255, 0.25),
                    0 0 40px rgba(255, 255, 255, 0.15),
                    inset 0 1px 0 rgba(255, 255, 255, 0.2);
        /* Better touch feedback */
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .achievement-card:active {
        transform: scale(0.98);
        background: rgba(255, 255, 255, 0.12);
        border-color: rgba(255, 255, 255, 0.8);
        box-shadow: 0 4px 32px rgba(255, 255, 255, 0.35),
                    0 0 50px rgba(255, 255, 255, 0.25),
                    inset 0 1px 0 rgba(255, 255, 255, 0.3);
    }

    .achievement-card-title {
        font-size: 20px;
        color: #ffffff;
        margin-bottom: 14px;
    }

    .achievement-card-description {
        font-size: 14px;
        color: #c0c0c0; /* Brighter text */
        line-height: 1.7;
        margin-bottom: 16px;
    }

    .achievement-card-meta {
        font-size: 12px;
        color: rgba(255, 255, 255, 0.9);
        margin-bottom: 8px;
    }

    /* Add visual indicator to tap - bottom of panel */
    .achievement-card::after {
        content: 'Tap to view details';
        position: absolute;
        bottom: 15px;
        left: 50%;
        transform: translateX(-50%);
        font-size: 11px;
        color: rgba(255, 255, 255, 0.8);
        font-family: 'JetBrains Mono', monospace;
        text-transform: uppercase;
        letter-spacing: 1.5px;
        pointer-events: none;
        font-weight: 600;
        text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
    }
}

@media (max-width: 480px) {
    .achievement-cards {
        gap: 20px;
        margin: 30px 0;
    }

    .achievement-card {
        padding: 24px;
    }

    .achievement-card-title {
        font-size: 18px;
    }

    .achievement-card-description {
        font-size: 13px;
    }

    .achievement-card::after {
        font-size: 10px;
        bottom: 12px;
        left: 50%;
        transform: translateX(-50%);
    }
}

/* Achievement Detail Modal */
.achievement-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
}

.achievement-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}

.achievement-modal-close {
    position: fixed;
    top: 30px;
    right: 40px;
    font-size: 40px;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    z-index: 10001;
    transition: all 0.3s ease;
    background: none;
    border: none;
}

.achievement-modal-close:hover {
    color: rgba(255, 255, 255, 0.95);
    transform: rotate(90deg);
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
}

.achievement-modal-content {
    background: rgba(10, 10, 10, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    max-width: 1200px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    padding: 50px;
    transform: scale(0.9) translateY(30px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.achievement-modal.active .achievement-modal-content {
    transform: scale(1) translateY(0);
    opacity: 1;
}

/* Custom Scrollbar */
.achievement-modal-content::-webkit-scrollbar {
    width: 8px;
}

.achievement-modal-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.achievement-modal-content::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
}

.achievement-modal-content::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

.achievement-modal-header {
    margin-bottom: 40px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 20px;
}

.achievement-modal-header h2 {
    font-size: 36px;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 10px;
    font-family: 'JetBrains Mono', monospace;
}

.achievement-modal-meta-tag {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-family: 'JetBrains Mono', monospace;
}

.achievement-modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.achievement-modal-media {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.achievement-media-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.achievement-media-item img,
.achievement-media-item video {
    max-width: 100%;
    max-height: 500px;
    width: auto;
    height: auto;
    display: block;
    object-fit: contain;
}

.achievement-media-item:empty {
    display: none;
}

.achievement-modal-text {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.achievement-modal-text h3 {
    font-size: 18px;
    color: #ffffff;
    font-family: 'JetBrains Mono', monospace;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.achievement-modal-text p {
    font-size: 15px;
    line-height: 1.8;
    color: #d0d0d0;
    font-family: 'Inter', sans-serif;
    margin-bottom: 15px;
}

.achievement-modal-text ul {
    list-style: none;
    padding: 0;
}

.achievement-modal-text ul li {
    font-size: 14px;
    line-height: 1.8;
    color: #d0d0d0;
    font-family: 'Inter', sans-serif;
    padding-left: 25px;
    margin-bottom: 10px;
    position: relative;
}

.achievement-modal-text ul li::before {
    content: '▹';
    position: absolute;
    left: 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: 18px;
}

.achievement-tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.tech-tag {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Mobile Responsive for Achievement Modal */
@media (max-width: 968px) {
    .achievement-modal-body {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .achievement-modal-content {
        padding: 35px 25px;
        width: 95%;
        max-height: 90vh;
    }

    .achievement-modal-header {
        margin-bottom: 30px;
        padding-bottom: 18px;
    }

    .achievement-modal-header h2 {
        font-size: 26px;
        margin-bottom: 8px;
    }

    .achievement-modal-meta-tag {
        font-size: 11px;
    }

    .achievement-modal-close {
        top: 15px;
        right: 15px;
        font-size: 36px;
        background: rgba(0, 0, 0, 0.9);
        width: 50px;
        height: 50px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 50%;
    }

    /* Brighter text on mobile */
    .achievement-modal-text p {
        color: #c0c0c0;
        font-size: 14px;
    }

    .achievement-modal-text ul li {
        color: #c0c0c0;
        font-size: 13px;
    }

    .achievement-modal-text h3 {
        font-size: 16px;
    }

    .tech-tag {
        font-size: 11px;
        padding: 5px 12px;
    }

    /* Better media display on mobile */
    .achievement-media-item {
        min-height: 180px;
    }
}

@media (max-width: 480px) {
    .achievement-modal-content {
        padding: 30px 20px;
        width: 98%;
    }

    .achievement-modal-header h2 {
        font-size: 22px;
    }

    .achievement-modal-close {
        top: 12px;
        right: 12px;
        width: 45px;
        height: 45px;
        font-size: 32px;
    }

    .achievement-modal-text p {
        font-size: 13px;
    }

    .achievement-modal-text ul li {
        font-size: 12px;
    }

    .tech-tag {
        font-size: 10px;
        padding: 4px 10px;
    }
}
