/* ===== PORTFOLIO/PROJECTS SECTION STYLES ===== */

/* Portfolio Section */
.portfolio.section {
    background: var(--bg-primary);
    min-height: 100vh;
    padding: 80px 0;
}

.portfolio .section-title {
    text-align: center;
    margin-bottom: 60px;
    padding: 0 30px;
}

.portfolio .section-title h2 {
    font-size: 48px;
    font-weight: 700;
    color: var(--text-primary);
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Portfolio Content */
.portfolio .portfolio-content {
    margin-top: 40px;
    padding-top: 20px;
}

.portfolio .padd-15 {
    padding-left: 15px;
    padding-right: 15px;
}

/* View Details Button Styling */
.btn-expand {
    background: var(--primary-gradient);
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 25px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 6px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.btn-expand::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.btn-expand:hover::before {
    left: 100%;
}

.btn-expand:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 122, 204, 0.4);
    background: var(--secondary-gradient);
}

.btn-expand:hover i {
    transform: translateX(3px);
}

.btn-expand:active {
    transform: translateY(0) scale(0.98);
}

.btn-expand i {
    font-size: 12px;
    transition: transform 0.3s ease;
}

.expand-text {
    font-weight: 600;
}

/* GitHub Button Styling */
.btn-github {
    background: #24292e;
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 25px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(36, 41, 46, 0.3);
    white-space: nowrap;
}

.btn-github:hover {
    background: #1a1e22;
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(36, 41, 46, 0.4);
    color: white;
    text-decoration: none;
}

.btn-github:active {
    transform: translateY(0) scale(0.98);
}

.btn-github i {
    font-size: 16px;
}

/* Project Actions Container */
.project-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
}

/* Live Demo Button Styling */
.btn-demo {
    background: var(--accent-gradient);
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 25px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.btn-demo::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.btn-demo:hover::before {
    left: 100%;
}

.btn-demo:hover {
    background: var(--accent-gradient);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(108, 123, 127, 0.4);
    color: white;
    text-decoration: none;
}

.btn-demo:hover i {
    transform: translateX(3px);
}

.btn-demo:active {
    transform: translateY(0) scale(0.98);
}

.btn-demo i {
    font-size: 12px;
    transition: transform 0.3s ease;
}

/* ===== Modern Project Cards ===== */
.projects-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.project-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 1.5rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    box-shadow: var(--shadow-glass);
    backdrop-filter: blur(20px);
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-large);
    border-color: rgba(102, 126, 234, 0.3);
}

/* Project card styling is now handled by CSS variables for consistent theming */

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s;
}

.project-card:hover::before {
    left: 100%;
}

.project-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.project-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-gradient);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.project-meta h3 {
    font-size: 1.4rem;
    margin: 0 0 0.5rem 0;
    background: linear-gradient(135deg, var(--text-black-900), var(--skin-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.project-subtitle {
    color: var(--text-black-700);
    font-size: 0.9rem;
    margin-bottom: 0.8rem;
    font-weight: 500;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background: var(--primary-gradient);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.project-preview {
    margin: 1.5rem 0;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.project-preview img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.4s ease;
}

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

.project-summary {
    margin: 1rem 0;
    color: var(--text-black-700);
    line-height: 1.6;
}

.project-details {
    margin-top: 1.5rem;
    animation: slideDown 0.3s ease-out;
}

.detail-section {
    margin-bottom: 1.5rem;
}

.detail-section h4 {
    color: var(--skin-color);
    font-size: 1.1rem;
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.detail-section ul {
    list-style: none;
    padding: 0;
}

.detail-section li {
    padding: 0.4rem 0;
    position: relative;
    padding-left: 1.5rem;
    color: var(--text-black-700);
    line-height: 1.5;
}

.detail-section li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--skin-color);
    font-weight: bold;
}

.modal-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.modal-result-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-result-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--skin-color);
    margin-bottom: 0.5rem;
}

.modal-result-label {
    color: white;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.modal-result-description {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

/* ===== Project Detail Modal ===== */
.project-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.project-modal.active {
    display: flex;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    cursor: pointer;
}

.modal-content {
    position: relative;
    width: 95%;
    max-width: 1200px;
    max-height: 90vh;
    background: var(--primary-gradient);
    border-radius: 20px;
    overflow: hidden;
    z-index: 10001;
    animation: slideInUp 0.4s ease;
}

.modal-header {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 10002;
}

.modal-close {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.modal-body {
    padding: 2rem;
    max-height: 90vh;
    overflow-y: auto;
    color: white;
}

.modal-body::-webkit-scrollbar {
    width: 8px;
}

.modal-body::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

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

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

/* Modal Project Hero */
.modal-project-hero {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 3rem;
    margin-bottom: 3rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.modal-project-hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #fff, #f0f0f0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.modal-project-hero .subtitle {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
    font-weight: 500;
}

.modal-meta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.modal-meta-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-meta-item i {
    font-size: 2rem;
    color: var(--skin-color);
    margin-bottom: 0.5rem;
}

.modal-meta-item h4 {
    color: white;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.modal-meta-item p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

.modal-tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin: 2rem 0;
}

.modal-tech-item {
    background: var(--primary-gradient);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    font-size: 1rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.modal-tech-item:hover {
    transform: translateY(-3px);
}

.modal-project-image {
    width: 100%;
    border-radius: 15px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
    margin: 2rem 0;
}

.modal-action-buttons {
    display: flex;
    gap: 1.5rem;
    margin: 3rem 0;
    flex-wrap: wrap;
}

.modal-btn-action {
    padding: 1rem 2rem;
    border-radius: 15px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    border: none;
    cursor: pointer;
}

.modal-btn-primary {
    background: var(--primary-gradient);
    color: white;
}

.modal-btn-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.modal-btn-demo {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
}

.modal-btn-action:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

/* Modal Detail Sections */
.modal-detail-section {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 3rem;
    margin-bottom: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-detail-section h2 {
    color: white;
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.modal-detail-section h3 {
    color: var(--skin-color);
    font-size: 1.8rem;
    margin: 2rem 0 1rem 0;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.modal-detail-section p, .modal-detail-section li {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.8;
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.modal-detail-section ul {
    list-style: none;
    padding: 0;
}

.modal-detail-section li {
    position: relative;
    padding-left: 2rem;
    margin-bottom: 1rem;
}

.modal-detail-section li::before {
    content: '▶';
    position: absolute;
    left: 0;
    color: var(--skin-color);
    font-weight: bold;
}

/* Modal Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(100px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    /* Portfolio Section Mobile Header */
    .portfolio.section {
        padding: 80px 20px;
    }
    
    .portfolio .section-title {
        padding: 0 15px;
    }
    
    .portfolio .section-title h2 {
        font-size: 36px;
    }
    
    .modal-content {
        width: 98%;
        max-height: 95vh;
        border-radius: 15px;
    }
    
    .modal-project-hero {
        padding: 2rem;
    }
    
    .modal-project-hero h1 {
        font-size: 2.5rem;
    }
    
    .modal-detail-section {
        padding: 2rem;
    }
    
    .modal-action-buttons {
        flex-direction: column;
    }
    
    .modal-meta-grid {
        grid-template-columns: 1fr;
    }
    
    /* Projects Section Mobile Fixes */
    .projects-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin-top: 1.5rem;
        padding-right: 0;
    }
    
    .project-card {
        margin-right: 0;
        padding: 1.25rem;
    }
    
    /* Ensure portfolio section has consistent padding */
    .portfolio .container {
        padding-left: 0;
        padding-right: 0;
    }
}

@media (max-width: 480px) {
    /* Ultra-small mobile devices */
    .portfolio .section-title h2 {
        font-size: 28px;
        letter-spacing: 1px;
    }
    
    .projects-container {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .project-card {
        padding: 1rem;
    }
}
