/* Responsive Design */
@media (max-width: 992px) {
    .about-content, .contact-content, .post-layout {
        grid-template-columns: 1fr;
    }
    .post-sidebar {
        position: static;
        margin-top: 3rem;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
        z-index: 1001;
    }

    .hamburger .bar {
        background-color: var(--text-dark);
    }
    
    .navbar.scrolled .hamburger .bar {
         background-color: var(--text-dark);
    }

    .navbar:not(.scrolled) .hamburger .bar {
        background-color: var(--white);
    }

    .hamburger.active .bar:nth-child(2) {
      opacity: 0;
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(6px) rotate(45deg);
        background-color: var(--text-dark);
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-6px) rotate(-45deg);
        background-color: var(--text-dark);
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 0;
        flex-direction: column;
        justify-content: flex-start;
        align-items: flex-start;
        background: var(--white);
        width: 100%;
        height: 100vh;
        text-align: left;
        transition: left 0.4s cubic-bezier(0.77, 0, 0.175, 1);
        box-shadow: none;
        padding: 6rem 2rem 2rem;
        gap: 0;
        overflow-y: auto;
    }

    .nav-menu.active {
        left: 0;
    }
    
    .nav-item {
        width: 100%;
    }

    .nav-link {
        color: var(--text-dark) !important;
        font-size: 1.2rem;
        text-shadow: none !important;
        width: 100%;
        padding: 1rem;
        display: flex;
        justify-content: space-between;
    }
    
    .nav-link::after {
        display: none;
    }

    .dropdown-content, .mega-menu {
        position: static !important;
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
        box-shadow: none !important;
        border: none !important;
        min-width: unset !important;
        width: 100%;
        padding: 0 0 0 1rem;
        background: transparent !important;
        display: none; /* Controlled by JS */
    }

    .mega-menu {
        flex-direction: column;
        gap: 0;
    }
    
    .mega-menu-section {
        padding-bottom: 1rem;
    }

    .mega-menu-section h4 {
        font-size: 0.9rem;
        text-transform: uppercase;
        color: var(--text-muted);
        padding-bottom: 0.25rem;
        margin-bottom: 0.5rem;
    }

    .mega-menu ul li a, .dropdown-content a {
        padding: 0.75rem;
        font-size: 1.1rem;
        color: var(--text-light);
    }
    
    .dropdown-content a:hover, .mega-menu ul li a:hover {
        background: var(--bg-light);
    }

    .dropdown .fa-chevron-down {
        transition: transform 0.3s ease;
    }

    .hero-title {
        font-size: clamp(2.5rem, 10vw, 4rem);
    }

    .hero-subtitle {
        font-size: clamp(1.1rem, 4vw, 1.4rem);
    }

    .hero-description {
        display: none;
    }
    
    .hero-content {
        margin-bottom: 0;
    }

    .hero-stats {
        position: static;
        transform: none;
        flex-direction: column;
        gap: 1rem;
        padding: 2rem 0;
        background: rgba(15, 23, 42, 0.7);
    }
    .stat {
        padding: 0.5rem;
    }
    .stat:not(:last-child)::after {
        display: none;
    }

    .hero-section {
        justify-content: space-between;
        flex-direction: column;
        padding-top: 100px; /* space for navbar */
    }

    .section-title {
        font-size: clamp(1.75rem, 7vw, 2.5rem);
    }
    section {
        padding: 4rem 0;
    }

    .service-card,
    .app-card,
    .blog-card,
    .contact-form {
        padding: 2rem;
    }
    .hero-scroll-down {
        display: none;
    }

    .service-tab-button span {
        display: none;
    }
    .service-tab-button {
        font-size: 1rem;
        padding: 1rem 0.5rem;
    }
    .service-tab-pane {
        grid-template-columns: 1fr;
        padding: 2rem;
        gap: 2rem;
    }
    .tab-pane-image {
        order: -1;
    }
    .tab-pane-content h3 {
        font-size: 1.75rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }

    .nav-container {
        padding: 1rem 1rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    .btn {
        width: 100%;
        max-width: 300px;
        padding: 1rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
}

/* Animations Keyframes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    0% {
        opacity: 0;
        transform: translateX(-50px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    0% {
        opacity: 0;
        transform: translateX(50px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-15px);
    }
    60% {
        transform: translateX(-50%) translateY(-7px);
    }
}

@keyframes expandLine {
    0% { width: 0; }
    100% { width: 100px; }
}