/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #dc2626;
    --primary-dark: #b91c1c;
    --secondary-color: #ef4444;
    --accent-color: #fca5a5;
    --text-primary: #ffffff;
    --text-secondary: #d1d5db;
    --text-light: #9ca3af;
    --bg-primary: #000000;
    --bg-secondary: #111111;
    --bg-dark: #0a0a0a;
    --border-color: #374151;
    --shadow-sm: 0 1px 2px 0 rgb(220 38 38 / 0.1);
    --shadow-md: 0 4px 6px -1px rgb(220 38 38 / 0.2), 0 2px 4px -2px rgb(220 38 38 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(220 38 38 / 0.3), 0 4px 6px -4px rgb(220 38 38 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(220 38 38 / 0.4), 0 8px 10px -6px rgb(220 38 38 / 0.1);
    --gradient-primary: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    --gradient-secondary: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    --gradient-accent: linear-gradient(135deg, #fca5a5 0%, #f87171 100%);
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-tap-highlight-color: transparent;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav-link {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo .logo-text {
    font-size: 24px;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 40px;
}

.nav-link {
    text-decoration: none;
    color: #000000;
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background: #000000;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    background: linear-gradient(135deg, #000000 0%, #1a1a1a 50%, #000000 100%);
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.floating-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
}

.shape {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    animation: float 6s ease-in-out infinite;
}

.shape-1 {
    width: 80px;
    height: 80px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.shape-2 {
    width: 120px;
    height: 120px;
    top: 60%;
    right: 15%;
    animation-delay: 2s;
}

.shape-3 {
    width: 60px;
    height: 60px;
    top: 80%;
    left: 20%;
    animation-delay: 4s;
}

.shape-4 {
    width: 100px;
    height: 100px;
    top: 30%;
    right: 30%;
    animation-delay: 1s;
}

.shape-5 {
    width: 140px;
    height: 140px;
    top: 10%;
    right: 10%;
    animation-delay: 3s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-text {
    color: white;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 24px;
}

.title-line {
    display: block;
    opacity: 0;
    animation: slideInUp 0.8s ease forwards;
}

.title-line:nth-child(1) { animation-delay: 0.2s; }
.title-line:nth-child(2) { animation-delay: 0.4s; }
.title-line:nth-child(3) { animation-delay: 0.6s; }

.highlight {
    background: linear-gradient(45deg, #dc2626, #ef4444);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 32px;
    opacity: 0.9;
    animation: fadeIn 1s ease 0.8s forwards;
    opacity: 0;
}

@keyframes fadeIn {
    to { opacity: 0.9; }
}

.hero-buttons {
    display: flex;
    gap: 20px;
    animation: slideInUp 0.8s ease 1s forwards;
    opacity: 0;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    min-height: 44px; /* Touch-friendly minimum size */
    -webkit-tap-highlight-color: transparent;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    box-shadow: var(--shadow-lg);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
    background: var(--primary-dark);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
}

.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.code-window {
    background: rgba(0, 0, 0, 0.8);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    animation: slideInRight 1s ease 0.5s forwards;
    opacity: 0;
    transform: translateX(50px);
}

@keyframes slideInRight {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.window-header {
    background: #2d3748;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.window-controls {
    display: flex;
    gap: 8px;
}

.control {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.control.red { background: #ff5f56; }
.control.yellow { background: #ffbd2e; }
.control.green { background: #27ca3f; }

.window-title {
    color: #a0aec0;
    font-size: 14px;
}

.code-content {
    padding: 20px;
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 14px;
    line-height: 1.6;
}

.code-line {
    display: flex;
    margin-bottom: 4px;
}

.line-number {
    color: #4a5568;
    margin-right: 16px;
    min-width: 20px;
}

.keyword { color: #c792ea; }
.variable { color: #82aaff; }
.property { color: #7fdbca; }
.string { color: #c3e88d; }

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.scroll-arrow {
    width: 24px;
    height: 24px;
    border-right: 2px solid white;
    border-bottom: 2px solid white;
    transform: rotate(45deg);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) rotate(45deg) translateY(0); }
    40% { transform: translateX(-50%) rotate(45deg) translateY(-10px); }
    60% { transform: translateX(-50%) rotate(45deg) translateY(-5px); }
}

/* Section Styles */
section {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

/* About Section */
.about {
    background: var(--bg-secondary);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-card {
    background: #1a1a1a;
    padding: 40px;
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    margin-bottom: 40px;
}

.about-card h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.about-card p {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.experience-section {
    margin-top: 40px;
}

.experience-section h3 {
    font-size: 1.5rem;
    margin-bottom: 24px;
    color: var(--text-primary);
}

.experience-timeline {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.experience-item {
    display: flex;
    gap: 20px;
    padding: 24px;
    background: #1a1a1a;
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    border-left: 4px solid var(--primary-color);
}

.experience-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.experience-logo {
    flex-shrink: 0;
}

.placeholder-logo {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.experience-content {
    flex: 1;
}

.experience-content h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.company {
    font-weight: 500;
    color: var(--primary-color);
    margin-bottom: 4px;
}

.duration {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
    font-style: italic;
}

.description {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}

.about-image {
    display: flex;
    flex-direction: column;
    gap: 40px;
    align-items: center;
}

.image-container {
    position: relative;
}

.profile-photo {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: var(--shadow-lg);
    border: 4px solid var(--primary-color);
}

.image-decoration {
    position: absolute;
    top: -20px;
    right: -20px;
    width: 100px;
    height: 100px;
    background: var(--gradient-secondary);
    border-radius: 50%;
    opacity: 0.3;
    animation: pulse 2s infinite;
}

.resume-container {
    text-align: center;
    max-width: 400px;
}

.resume-container h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.resume-preview {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s ease;
}

.resume-preview:hover {
    transform: translateY(-5px);
}

.resume-image {
    width: 100%;
    height: auto;
    display: block;
}

.resume-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.resume-preview:hover .resume-overlay {
    opacity: 1;
}

.resume-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: white;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.3s ease;
}

.resume-link:hover {
    transform: scale(1.1);
}

.resume-link i {
    font-size: 2rem;
    color: var(--primary-color);
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Skills Section */
.skills-unified {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    max-width: 1000px;
    margin: 0 auto;
}

.skill-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    border-radius: 12px;
    background: var(--bg-secondary);
    transition: all 0.3s ease;
}

.skill-item:hover {
    background: var(--primary-color);
    color: white;
    transform: scale(1.05);
}

.skill-item i {
    font-size: 2rem;
    margin-bottom: 8px;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.skill-item:hover i {
    color: white;
}

.skill-item span {
    font-weight: 500;
    text-align: center;
}

/* Projects Section */
.projects {
    background: var(--bg-secondary);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
}

.project-card {
    background: #1a1a1a;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
}

.project-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.project-preview-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.project-preview-image.square {
    object-fit: cover;
}

.project-card:hover .project-preview-image {
    transform: scale(1.05);
}

.project-image .placeholder-image {
    width: 100%;
    height: 100%;
    background: var(--gradient-accent);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
}

.project-image .placeholder-image i {
    font-size: 2.5rem;
    margin-bottom: 12px;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-link {
    width: 50px;
    height: 50px;
    background: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    text-decoration: none;
    transition: transform 0.3s ease;
    border: none;
    cursor: pointer;
}

.project-link:hover {
    transform: scale(1.1);
}

.project-content {
    padding: 24px;
}

.project-content h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.project-content p {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tech-tag {
    background: var(--bg-secondary);
    color: var(--text-primary);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Contact Section */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.contact-details h4 {
    font-size: 1.1rem;
    margin-bottom: 4px;
    color: var(--text-primary);
}

.contact-details p {
    color: var(--text-secondary);
}

.social-links {
    display: flex;
    gap: 20px;
    margin-top: 40px;
}

.social-link {
    width: 50px;
    height: 50px;
    background: var(--bg-secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

.contact-form {
    background: #1a1a1a;
    padding: 40px;
    border-radius: 16px;
    box-shadow: var(--shadow-md);
}

.form-group {
    margin-bottom: 24px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Footer */
.footer {
    background: var(--bg-dark);
    color: white;
    padding: 40px 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-links {
    display: flex;
    gap: 30px;
}

.footer-links a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow-md);
        padding: 20px 0;
    }
    
    .nav-menu .nav-link {
        color: #000000;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        justify-content: center;
        flex-wrap: wrap;
        gap: 15px;
    }
    
    .btn {
        padding: 12px 24px;
        font-size: 0.9rem;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .about-image {
        flex-direction: column;
        gap: 30px;
    }
    
    .profile-photo {
        width: 250px;
        height: 250px;
    }
    
    .resume-container {
        max-width: 350px;
    }
    
    .experience-item {
        flex-direction: column;
        text-align: center;
        padding: 25px;
    }
    
    .experience-logo {
        align-self: center;
        margin-bottom: 15px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    .project-card {
        margin: 0;
    }
    
    .contact-form {
        padding: 25px;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 12px 16px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .social-links {
        justify-content: center;
        gap: 20px;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 10px;
    }
    
    .hero-title {
        font-size: 2rem;
        line-height: 1.1;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 25px;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.85rem;
    }
    
    .experience-item {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .placeholder-logo {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .profile-photo {
        width: 200px;
        height: 200px;
    }
    
    .resume-container {
        max-width: 300px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .project-card {
        margin: 0;
    }
    
    .skills-unified {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
        gap: 12px;
    }
    
    .skill-item {
        padding: 15px;
    }
    
    .contact-form {
        padding: 20px;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 10px 14px;
        font-size: 16px;
    }
    
    .modal-content {
        width: 98%;
        margin: 2% auto;
        max-height: 90vh;
    }
}

/* Animation Classes */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.6s ease;
}

.slide-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.slide-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.6s ease;
}

.slide-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Project Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background-color: #1a1a1a;
    margin: 2% auto;
    padding: 0;
    border-radius: 16px;
    width: 90%;
    max-width: 1000px;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideInUp 0.3s ease;
    box-shadow: var(--shadow-xl);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 32px;
    border-bottom: 1px solid var(--border-color);
    background: var(--gradient-primary);
    color: white;
    border-radius: 16px 16px 0 0;
}

.modal-header h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.close-modal {
    background: none;
    border: none;
    font-size: 2rem;
    color: white;
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.3s ease;
}

.close-modal:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.modal-body {
    padding: 32px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

/* Project Gallery */
.project-gallery {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.gallery-main {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: var(--bg-secondary);
    aspect-ratio: 9/16; /* Default mobile aspect ratio */
}

.gallery-main.landscape {
    aspect-ratio: 16/9; /* Landscape aspect ratio for desktop/web apps */
}

.gallery-main img,
.gallery-main video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.gallery-controls {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    padding: 0 16px;
    transform: translateY(-50%);
    pointer-events: none;
}

.gallery-btn {
    background: rgba(0, 0, 0, 0.7);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    pointer-events: all;
}

.gallery-btn:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: scale(1.1);
}

.gallery-thumbnails {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 8px 0;
}

.thumbnail {
    width: 80px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.thumbnail:hover,
.thumbnail.active {
    border-color: var(--primary-color);
    transform: scale(1.05);
}

.thumbnail img,
.thumbnail video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    pointer-events: none;
}

/* Project Details */
.project-details {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.project-details h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.project-description p {
    color: var(--text-secondary);
    line-height: 1.6;
}

.project-features ul {
    list-style: none;
    padding: 0;
}

.project-features li {
    color: var(--text-secondary);
    margin-bottom: 8px;
    padding-left: 20px;
    position: relative;
}

.project-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
}

.project-tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.project-links {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 24px;
}

.project-links .btn-primary,
.project-links .btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    min-width: 140px;
    justify-content: center;
}

.project-links .btn-primary {
    background: var(--primary-color);
    color: white;
}

.project-links .btn-primary:hover {
    background: #b91c1c;
    transform: translateY(-2px);
}

.project-links .btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--text-secondary);
}

.project-links .btn-secondary:hover {
    background: var(--text-secondary);
    color: var(--bg-primary);
    transform: translateY(-2px);
}

/* Modal Responsive Design */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        margin: 5% auto;
        max-height: 85vh;
    }
    
    .modal-header {
        padding: 20px;
    }
    
    .modal-body {
        padding: 20px;
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .project-links {
        flex-direction: column;
    }
    
    .project-links .btn {
        flex: none;
    }
}

@media (max-width: 480px) {
    .modal-content {
        width: 98%;
        margin: 2% auto;
        max-height: 95vh;
    }
    
    .modal-header {
        padding: 16px;
    }
    
    .modal-header h2 {
        font-size: 1.2rem;
    }
    
    .modal-body {
        padding: 16px;
    }
    
    .gallery-thumbnails {
        gap: 6px;
    }
    
    .thumbnail {
        width: 60px;
        height: 45px;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}
