/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-padding {
    padding: 100px 0;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    font-weight: 500;
    line-height: 1.2;
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
}

.section-tag {
    display: inline-block;
    padding: 8px 20px;
    background: rgba(108, 117, 125, 0.1);
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-radius: 50px;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s ease forwards;
}

.section-title {
    font-size: 3rem;
    color: #2c3e50;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease 0.2s forwards;
}

/* Tech badges for portfolio */
.project-tech {
    margin: 15px 0;
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.tech-badge {
    padding: 4px 12px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 0.8rem;
    border-radius: 15px;
    font-weight: 500;
}

/* Form success message */
.form-success {
    margin-top: 20px;
    padding: 20px;
    background: rgba(40, 167, 69, 0.1);
    border: 1px solid rgba(40, 167, 69, 0.3);
    border-radius: 10px;
    text-align: center;
    color: #28a745;
}

.form-success i {
    font-size: 2rem;
    margin-bottom: 10px;
    display: block;
}

/* 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);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    margin: 5% auto;
    padding: 40px;
    border-radius: 20px;
    width: 80%;
    max-width: 600px;
    position: relative;
    max-height: 80vh;
    overflow-y: auto;
}

.close {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 28px;
    font-weight: bold;
    color: #6c757d;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover {
    color: #2c3e50;
}

/* Enhanced floating elements with icons */
.floating-cube,
.floating-circle,
.floating-triangle {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    font-size: 2rem;
    transition: all 0.3s ease;
}

.floating-cube:hover,
.floating-circle:hover,
.floating-triangle:hover {
    color: #2c3e50;
    transform: scale(1.1);
}

/* Enhanced placeholder for portfolio */
.placeholder-img {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(108, 117, 125, 0.1) 0%,
        rgba(173, 181, 189, 0.2) 50%,
        rgba(108, 117, 125, 0.1) 100%);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: rgba(108, 117, 125, 0.5);
}

/* Services grid enhancement for 4 cards */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 20px 0;
    transition: all 0.3s ease;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    background: rgba(248, 249, 250, 0.95);
}

.navbar.scrolled {
    padding: 15px 0;
    background: rgba(248, 249, 250, 0.98);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    letter-spacing: 2px;
    font-weight: 600;
}

.nav-subtitle {
    font-size: 0.8rem;
    color: #6c757d;
    font-weight: 300;
    letter-spacing: 1px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 40px;
}

.nav-link {
    text-decoration: none;
    color: #495057;
    font-weight: 500;
    position: relative;
    transition: all 0.3s ease;
}

.nav-link:hover {
    color: #2c3e50;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: #6c757d;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: #2c3e50;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.parallax-bg {
    position: absolute;
    top: -20%;
    left: -20%;
    width: 140%;
    height: 140%;
    background: linear-gradient(45deg, 
        rgba(248, 249, 250, 0.9) 0%,
        rgba(233, 236, 239, 0.8) 25%,
        rgba(206, 212, 218, 0.7) 50%,
        rgba(173, 181, 189, 0.8) 75%,
        rgba(248, 249, 250, 0.9) 100%);
    background-size: 400% 400%;
    animation: gradientShift 20s ease-in-out infinite;
    transform: translateZ(0);
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.hero-text {
    opacity: 0;
    transform: translateX(-50px);
    animation: slideInLeft 1s ease 0.5s forwards;
}

.hero-title {
    margin-bottom: 30px;
}

.title-line {
    display: block;
    font-size: 4.5rem;
    font-weight: 600;
    color: #2c3e50;
    letter-spacing: 3px;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.title-subtitle {
    display: block;
    font-size: 1.2rem;
    color: #6c757d;
    font-weight: 300;
    font-style: italic;
    letter-spacing: 1px;
}

.hero-description {
    font-size: 1.1rem;
    color: #495057;
    margin-bottom: 40px;
    line-height: 1.8;
    max-width: 500px;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.btn {
    padding: 15px 30px;
    border: none;
    border-radius: 50px;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, #495057, #6c757d);
    color: white;
    box-shadow: 0 10px 30px rgba(73, 80, 87, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(73, 80, 87, 0.4);
}

.btn-secondary {
    background: transparent;
    color: #495057;
    border: 2px solid #dee2e6;
}

.btn-secondary:hover {
    background: #f8f9fa;
    border-color: #adb5bd;
    transform: translateY(-3px);
}

/* Hero Visual */
.hero-visual {
    position: relative;
    opacity: 0;
    transform: translateX(50px);
    animation: slideInRight 1s ease 0.7s forwards;
}

.floating-elements {
    position: relative;
    width: 400px;
    height: 400px;
    margin: 0 auto;
}

.floating-cube,
.floating-circle,
.floating-triangle {
    position: absolute;
    background: rgba(108, 117, 125, 0.1);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(108, 117, 125, 0.2);
}

.floating-cube {
    width: 80px;
    height: 80px;
    top: 20%;
    left: 10%;
    animation: float 6s ease-in-out infinite;
    border-radius: 10px;
}

.floating-circle {
    width: 60px;
    height: 60px;
    top: 60%;
    right: 20%;
    border-radius: 50%;
    animation: float 4s ease-in-out infinite reverse;
}

.floating-triangle {
    width: 0;
    height: 0;
    top: 40%;
    left: 60%;
    border-left: 30px solid transparent;
    border-right: 30px solid transparent;
    border-bottom: 52px solid rgba(108, 117, 125, 0.1);
    background: transparent;
    animation: float 5s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #6c757d;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 1px;
}

.scroll-line {
    width: 2px;
    height: 40px;
    background: #6c757d;
    margin-bottom: 10px;
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; transform: scaleY(1); }
    50% { opacity: 1; transform: scaleY(1.5); }
}

/* About Section */
.about {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    position: relative;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-text h3 {
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 30px;
    font-style: italic;
}

.about-text p {
    font-size: 1.1rem;
    color: #495057;
    margin-bottom: 25px;
    line-height: 1.8;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
}

.stat {
    text-align: center;
    padding: 30px 20px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 15px;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(108, 117, 125, 0.1);
    transition: transform 0.3s ease;
}

.stat:hover {
    transform: translateY(-10px);
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 10px;
}

.stat-label {
    font-size: 0.9rem;
    color: #6c757d;
    font-weight: 500;
    letter-spacing: 1px;
}

.about-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.mystery-box {
    position: relative;
    width: 300px;
    height: 300px;
}

.box-layer {
    position: absolute;
    border-radius: 20px;
    background: rgba(108, 117, 125, 0.05);
    border: 1px solid rgba(108, 117, 125, 0.1);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.layer-1 {
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    animation: rotateLayer 20s linear infinite;
}

.layer-2 {
    width: 80%;
    height: 80%;
    top: 10%;
    left: 10%;
    animation: rotateLayer 15s linear infinite reverse;
}

.layer-3 {
    width: 60%;
    height: 60%;
    top: 20%;
    left: 20%;
    animation: rotateLayer 10s linear infinite;
}

.mystery-symbol {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 4rem;
    color: #6c757d;
    animation: pulse 3s ease-in-out infinite;
}

@keyframes rotateLayer {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
}

/* Services Section */
.services {
    background: linear-gradient(135deg, #e9ecef 0%, #f8f9fa 100%);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
}

.service-card {
    background: rgba(255, 255, 255, 0.8);
    padding: 50px 40px;
    border-radius: 20px;
    text-align: center;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(108, 117, 125, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(108, 117, 125, 0.05) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.service-card:hover::before {
    opacity: 1;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.service-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 30px;
    background: linear-gradient(135deg, #495057, #6c757d);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    position: relative;
    z-index: 2;
}

.service-card h3 {
    font-size: 1.5rem;
    color: #2c3e50;
    margin-bottom: 20px;
    position: relative;
    z-index: 2;
}

.service-card p {
    color: #495057;
    line-height: 1.8;
    margin-bottom: 30px;
    position: relative;
    z-index: 2;
}

.service-features {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    position: relative;
    z-index: 2;
}

.service-features span {
    padding: 5px 15px;
    background: rgba(108, 117, 125, 0.1);
    color: #6c757d;
    font-size: 0.9rem;
    border-radius: 20px;
    font-weight: 500;
}

/* Portfolio Section */
.portfolio {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
}

.portfolio-item {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.portfolio-item:hover {
    transform: scale(1.05);
}

.portfolio-image {
    position: relative;
    height: 300px;
    overflow: hidden;
}

.placeholder-img {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(108, 117, 125, 0.1) 0%,
        rgba(173, 181, 189, 0.2) 50%,
        rgba(108, 117, 125, 0.1) 100%);
    position: relative;
}

.placeholder-img::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(108, 117, 125, 0.3);
    border-radius: 10px;
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(44, 62, 80, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-content {
    text-align: center;
    color: white;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.portfolio-item:hover .portfolio-content {
    transform: translateY(0);
}

.portfolio-content h4 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.portfolio-content p {
    margin-bottom: 20px;
    opacity: 0.8;
}

.view-project {
    padding: 10px 25px;
    background: transparent;
    color: white;
    border: 2px solid white;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.view-project:hover {
    background: white;
    color: #2c3e50;
}

/* Contact Section */
.contact {
    background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
}

.contact-info h3 {
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 20px;
}

.contact-info p {
    color: #495057;
    margin-bottom: 40px;
    line-height: 1.8;
}

.contact-items {
    margin-bottom: 40px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    color: #495057;
}

.contact-item i {
    width: 20px;
    color: #6c757d;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-link {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    text-decoration: none;
    transition: all 0.3s ease;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.social-link:hover {
    background: #6c757d;
    color: white;
    transform: translateY(-5px);
}

.contact-form {
    background: rgba(255, 255, 255, 0.8);
    padding: 50px;
    border-radius: 20px;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(108, 117, 125, 0.1);
}

.form-group {
    margin-bottom: 25px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid rgba(108, 117, 125, 0.2);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #6c757d;
    background: white;
}

.form-group textarea {
    height: 120px;
    resize: vertical;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    padding: 50px 0 30px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.footer-logo h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.footer-logo p {
    opacity: 0.8;
    font-style: italic;
}

.footer-links {
    display: flex;
    gap: 30px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    opacity: 0.8;
}

/* Particles */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(108, 117, 125, 0.3);
    border-radius: 50%;
    animation: floatParticle 10s linear infinite;
}

@keyframes floatParticle {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100px) rotate(360deg);
        opacity: 0;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: rgba(248, 249, 250, 0.98);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        padding: 50px 0;
        -webkit-backdrop-filter: blur(10px);
        backdrop-filter: blur(10px);
    }

    .nav-menu.active {
        left: 0;
    }

    .hamburger {
        display: flex;
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .title-line {
        font-size: 3rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .about-content,
    .contact-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .services-grid,
    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .section-title {
        font-size: 2.5rem;
    }

    .stats {
        grid-template-columns: 1fr;
    }

    .floating-elements {
        width: 300px;
        height: 300px;
    }

    .contact-form {
        padding: 30px;
    }

    .footer-content {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .title-line {
        font-size: 2.5rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .btn {
        padding: 12px 25px;
        font-size: 0.9rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .service-card,
    .contact-form {
        padding: 30px 20px;
    }
}

/* Scroll triggered animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.8s ease;
}

.slide-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.slide-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.8s ease;
}

.slide-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Parallax effect for scroll */
.parallax-element {
    transition: transform 0.1s ease-out;
}
