/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #ffffff;
    --secondary-color: #f8fafb;
    --text-primary: #1a1a1a;
    --text-secondary: #666666;
    --accent-color: #000000;
    --accent-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --border-color: #e5e7eb;
    --shadow-light: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
    --shadow-medium: 0 4px 6px rgba(0, 0, 0, 0.07), 0 2px 4px rgba(0, 0, 0, 0.06);
    --shadow-heavy: 0 10px 25px rgba(0, 0, 0, 0.15), 0 4px 10px rgba(0, 0, 0, 0.1);
    --shadow-glow: 0 20px 40px rgba(102, 126, 234, 0.15);
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --border-radius: 16px;
    --max-width: 1200px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--primary-color);
    font-weight: 400;
    overflow-x: hidden;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(25px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: var(--transition);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-color);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* Hero Section */
.hero {
    padding: 120px 0 80px;
    text-align: center;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafb 50%, #ffffff 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(ellipse at center top, rgba(102, 126, 234, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: clamp(2.8rem, 5vw, 4.5rem);
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--text-primary);
    letter-spacing: -0.03em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-weight: 400;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Projects Section */
.projects-section {
    padding: 80px 0;
    background: var(--primary-color);
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
}

.project-card {
    background: var(--primary-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid var(--border-color);
    position: relative;
}

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

.project-thumbnail {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: var(--transition);
}

.project-card:hover .project-thumbnail {
    transform: scale(1.02);
}

.project-info {
    padding: 1.25rem;
}

.project-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
    color: var(--text-primary);
}

.project-description {
    color: var(--text-secondary);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.project-type {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255, 255, 255, 0.98);
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border: 1px solid rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.project-type.commission {
    background: linear-gradient(135deg, #1a1a1a 0%, #333333 100%);
    color: white;
    border: 2px solid #000000;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    transform: scale(1.05);
}

.project-type.own {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: 2px solid #667eea;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    transform: scale(1.05);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--primary-color);
    margin: 5% auto;
    padding: 0;
    border-radius: var(--border-radius);
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: var(--shadow-heavy);
}

.close {
    position: absolute;
    top: 15px;
    right: 20px;
    color: var(--text-secondary);
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1;
    background: rgba(255, 255, 255, 0.9);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.close:hover {
    background: var(--accent-color);
    color: white;
}

.modal-body {
    padding: 2rem;
}

#modal-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

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

.modal-image {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.modal-image:hover {
    transform: scale(1.02);
    border-color: var(--text-secondary);
}

#modal-description {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-secondary);
}

/* Lightbox Styles */
.lightbox {
    display: none;
    position: fixed;
    z-index: 3000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1;
}

.lightbox-img {
    display: block;
    margin: auto;
    max-width: 90%;
    max-height: 80%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: var(--border-radius);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
}

.lightbox-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 2rem;
    padding: 10px 15px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.lightbox-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Pricing Section */
.pricing-section {
    padding: 60px 0;
    background: var(--secondary-color);
    text-align: center;
}

.pricing-content h2 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.pricing-content p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.pricing-info {
    display: inline-block;
    background: var(--primary-color);
    padding: 1.8rem 2.2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-medium);
    border: 1px solid var(--border-color);
    text-align: center;
    max-width: 350px;
    margin: 0 auto;
}

.pricing-info h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.8rem;
    text-transform: capitalize;
}

.price-range {
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-bottom: 0.4rem;
    line-height: 1.4;
}

.price-range strong {
    font-weight: 700;
    color: var(--accent-color);
}

.per-project {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: lowercase;
}

/* Reviews Section */
.reviews-section {
    padding: 80px 0;
    background: var(--secondary-color);
}

.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.review-card {
    background: var(--primary-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-light);
    border: 1px solid var(--border-color);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.review-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.review-card:hover::before {
    transform: scaleX(1);
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}

.review-stars {
    font-size: 1.2rem;
    color: #fbbf24;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

.review-text {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-style: italic;
}

.review-author {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.review-author strong {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.review-author span {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Contact Section */
.contact-section {
    padding: 80px 0;
    background: var(--primary-color);
    text-align: center;
}

.contact-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.contact-content p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.contact-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.contact-btn {
    display: inline-block;
    padding: 14px 28px;
    background: var(--accent-gradient);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: var(--transition);
    box-shadow: var(--shadow-medium);
    position: relative;
    overflow: hidden;
}

.contact-btn::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;
}

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

.contact-btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
}

/* Footer */
.footer {
    padding: 2rem 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    background: var(--primary-color);
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-links {
        gap: 1rem;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .hero-stats {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        max-width: 300px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .contact-links {
        flex-direction: column;
        align-items: center;
    }
    
    .lightbox-img {
        max-width: 95%;
        max-height: 70%;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .modal-body {
        padding: 1.5rem;
    }
    
    .modal-images {
        grid-template-columns: 1fr;
    }
    
    .hero-stats {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Scroll animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

.slide-in-left {
    animation: slideInLeft 0.6s ease-out forwards;
}

/* Enhanced project cards */
.project-card {
    opacity: 0;
    transform: translateY(20px);
    transition: var(--transition);
}

.project-card.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Loading state */
.projects-grid.loading .project-card {
    opacity: 0.5;
}

/* Improved focus styles */
.project-card:focus,
.contact-btn:focus,
.review-card:focus {
    outline: 2px solid rgba(102, 126, 234, 0.5);
    outline-offset: 4px;
}

/* Focus styles for accessibility */
a:focus,
button:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

/* Products Section */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
}

.product-card {
    background: var(--primary-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    border: 1px solid var(--border-color);
    position: relative;
    opacity: 0;
    transform: translateY(20px);
}

.product-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.product-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: var(--shadow-medium);
    border-color: rgba(102, 126, 234, 0.2);
}

.product-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: var(--transition);
}

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

.product-info {
    padding: 1.25rem;
}

.product-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.product-description {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-price {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: var(--transition);
}

.product-price.free {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
    animation: pulse-green 2s infinite;
}

.product-price.paid {
    background: var(--accent-gradient);
    color: white;
    box-shadow: var(--shadow-glow);
}

@keyframes pulse-green {
    0%, 100% {
        box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
    }
    50% {
        box-shadow: 0 4px 16px rgba(16, 185, 129, 0.5);
        transform: scale(1.05);
    }
}

/* No projects/products messages */
.no-projects,
.no-products {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    padding: 3rem 2rem;
    background: var(--secondary-color);
    border-radius: var(--border-radius);
    border: 2px dashed var(--border-color);
    margin: 2rem 0;
}

.no-projects::before,
.no-products::before {
    content: '📁';
    display: block;
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Enhanced project type animations */
.project-type {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card:hover .project-type.commission {
    transform: scale(1.1) rotate(-1deg);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.project-card:hover .project-type.own {
    transform: scale(1.1) rotate(1deg);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}
