/**
 * Responsive Styles
 * 
 * @package Raaco_Starter
 * @since 1.0.0
 */

/* ============================================
   Tablet (max-width: 1024px)
   ============================================ */
@media (max-width: 1024px) {
    .header-nav {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .hero-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .hero-title {
        font-size: var(--text-4xl);
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* ============================================
   Mobile (max-width: 768px)
   ============================================ */
@media (max-width: 768px) {
    .hero-title {
        font-size: var(--text-3xl);
    }

    .hero-subtitle {
        font-size: var(--text-base);
    }

    .hero-buttons {
        flex-direction: column;
    }

    .services-grid,
    .projects-grid,
    .testimonials-slider {
        grid-template-columns: 1fr;
    }

    .contact-cards {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .section-title {
        font-size: var(--text-2xl);
    }
}

/* ============================================
   Mobile Menu
   ============================================ */
/* ============================================
   Mobile Menu (Slide Down & Improvements)
   ============================================ */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
    /* Above menu */
    position: relative;
}

.mobile-menu-toggle .bar {
    width: 100%;
    height: 3px;
    background-color: var(--text-color, #fff);
    border-radius: 3px;
    transition: all 0.3s ease-in-out;
}

/* Close Icon Animation (X shape) */
.mobile-menu-toggle.active .bar:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
    background-color: #fff;
}

.mobile-menu-toggle.active .bar:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active .bar:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
    background-color: #fff;
}

.mobile-menu {
    display: block;
    /* Always block for transform */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: var(--bg-darker, #0f172a);
    padding: 80px 2rem 2rem;
    /* Top padding for header space */
    border-bottom: 2px solid var(--primary-color, #BC923E);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    z-index: 999999;
    /* Highest priority */

    /* Animation: Slide Down */
    transform: translateY(-150%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    visibility: hidden;
    max-height: 100vh;
    overflow-y: auto;
}

.mobile-menu.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.mobile-menu-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-menu-list li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.mobile-menu-list li a {
    display: block;
    padding: 15px 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
    text-decoration: none;
    transition: color 0.2s;
}

.mobile-menu-list li a:hover {
    color: var(--primary-color, #BC923E);
    padding-inline-start: 10px;
}

/* Sub-menus (Always Visible & Indented) */
.mobile-menu-list .sub-menu {
    display: block;
    background: rgba(0, 0, 0, 0.2);
    margin: 0 -2rem;
    /* Full width bg */
    padding: 0 3rem;
    /* Indented content */
    list-style: none;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.mobile-menu-list .sub-menu li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.mobile-menu-list .sub-menu li:last-child {
    border-bottom: none;
}

.mobile-menu-list .sub-menu a {
    font-size: 0.95rem;
    padding: 12px 0;
    color: #ccc;
    font-weight: 400;
}

.mobile-menu-list .sub-menu a:before {
    content: "— ";
    color: var(--primary-color, #BC923E);
    opacity: 0.5;
}