/* ============================================
   MOBILE HERO COMPACT LAYOUT
   Reduces overwhelming hero banner on mobile
   Replaces service pills with dropdown menus
   ============================================ */

@media (max-width: 768px) {
    /* ===== HIDE LOGO ON MOBILE ===== */

    /* Hide the Daf-Devs logo */
    .navbar .container a[href="#home"] img,
    .navbar-brand img,
    nav img[alt="Daf-Devs"] {
        display: none !important;
    }

    /* Adjust navbar spacing without logo */
    .navbar .container {
        justify-content: flex-end !important;
    }

    .navbar {
        padding: 10px 16px !important;
        min-height: 50px !important;
    }

    /* ===== COMPACT HERO SECTION ===== */

    /* Reduce hero section height and padding - starts right after navbar */
    .hero,
    #home.hero {
        min-height: auto !important;
        padding: 60px 16px 40px 16px !important;
        padding-top: 20px !important;
    }

    .hero .overlay {
        opacity: 0.7 !important;
    }

    /* Compact heading */
    .hero h1 {
        font-size: 1.75rem !important;
        line-height: 1.2 !important;
        margin-bottom: 16px !important;
    }

    .hero .gradient-text {
        font-size: 1.75rem !important;
        display: inline !important;
    }

    /* Compact subtitle */
    .hero p {
        font-size: 1rem !important;
        line-height: 1.5 !important;
        margin-bottom: 20px !important;
    }

    /* Hide the "AI-Powered Solutions" badge on mobile */
    .hero .flex.items-center.gap-3.mb-6 {
        display: none !important;
    }

    /* ===== HIDE SERVICE PILLS, REPLACE WITH DROPDOWN ===== */

    /* Hide the service pills grid on mobile */
    .hero .grid.grid-cols-2,
    .hero .grid-cols-2.md\:grid-cols-3,
    .hero-service-pill {
        display: none !important;
    }

    /* ===== DROPDOWN MENU CONTAINER ===== */

    /* Create container for dropdowns */
    .hero-mobile-dropdowns {
        display: flex !important;
        flex-direction: column;
        gap: 12px;
        margin-bottom: 24px;
        width: 100%;
    }

    /* Dropdown button styling */
    .hero-dropdown-btn {
        width: 100%;
        padding: 16px 20px;
        background: rgba(0, 230, 118, 0.1);
        border: 1px solid rgba(0, 230, 118, 0.3);
        border-radius: 12px;
        color: white;
        font-size: 1rem;
        font-weight: 600;
        display: flex;
        justify-content: space-between;
        align-items: center;
        cursor: pointer;
        transition: all 0.3s ease;
        position: relative;
    }

    .hero-dropdown-btn:active {
        transform: scale(0.98);
    }

    .hero-dropdown-btn i.chevron {
        transition: transform 0.3s ease;
    }

    .hero-dropdown-btn.active i.chevron {
        transform: rotate(180deg);
    }

    .hero-dropdown-btn:hover {
        background: rgba(0, 230, 118, 0.15);
        border-color: rgba(0, 230, 118, 0.5);
    }

    /* Dropdown content */
    .hero-dropdown-content {
        display: none;
        background: rgba(18, 18, 26, 0.95);
        border: 1px solid rgba(0, 230, 118, 0.2);
        border-radius: 12px;
        margin-top: 8px;
        overflow: hidden;
        max-height: 0;
        opacity: 0;
        transition: all 0.3s ease;
    }

    .hero-dropdown-content.active {
        display: block;
        max-height: 500px;
        opacity: 1;
        animation: slideDown 0.3s ease-out;
    }

    @keyframes slideDown {
        from {
            max-height: 0;
            opacity: 0;
        }
        to {
            max-height: 500px;
            opacity: 1;
        }
    }

    /* Dropdown items */
    .hero-dropdown-item {
        padding: 14px 16px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        display: flex;
        align-items: center;
        gap: 12px;
        cursor: pointer;
        transition: all 0.2s ease;
        text-decoration: none;
        color: white;
    }

    .hero-dropdown-item:last-child {
        border-bottom: none;
    }

    .hero-dropdown-item:active {
        background: rgba(0, 230, 118, 0.1);
    }

    .hero-dropdown-item .icon-wrapper {
        width: 40px;
        height: 40px;
        min-width: 40px;
        background: rgba(0, 230, 118, 0.15);
        border-radius: 8px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .hero-dropdown-item .icon-wrapper i {
        color: #00e676;
        font-size: 1.1rem;
    }

    .hero-dropdown-item .item-info {
        flex: 1;
    }

    .hero-dropdown-item .item-title {
        font-size: 0.95rem;
        font-weight: 600;
        color: white;
        margin-bottom: 2px;
    }

    .hero-dropdown-item .item-subtitle {
        font-size: 0.8rem;
        color: #9ca3af;
    }

    /* ===== COMPACT CTA BUTTONS ===== */

    .hero .flex.flex-wrap.gap-4 {
        flex-direction: column !important;
        gap: 12px !important;
        width: 100%;
    }

    .hero .btn-primary,
    .hero .btn-outline {
        width: 100% !important;
        padding: 14px 20px !important;
        font-size: 0.95rem !important;
        justify-content: center;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    /* ===== HIDE HERO IMAGE ON MOBILE ===== */

    .hero .hidden.lg\:block {
        display: none !important;
    }

    /* ===== GRID RESET FOR HERO ===== */

    .hero .grid.grid-cols-1.lg\:grid-cols-2 {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }
}

/* ===== SMALL PHONES ADJUSTMENTS ===== */
@media (max-width: 375px) {
    .hero {
        padding: 70px 12px 30px 12px !important;
    }

    .hero h1 {
        font-size: 1.5rem !important;
    }

    .hero p {
        font-size: 0.9rem !important;
        margin-bottom: 16px !important;
    }

    .hero-dropdown-btn {
        padding: 14px 16px;
        font-size: 0.9rem;
    }

    .hero-dropdown-item {
        padding: 12px 14px;
    }

    .hero-dropdown-item .icon-wrapper {
        width: 36px;
        height: 36px;
        min-width: 36px;
    }

    .hero-dropdown-item .item-title {
        font-size: 0.875rem;
    }

    .hero-dropdown-item .item-subtitle {
        font-size: 0.75rem;
    }

    .hero .btn-primary,
    .hero .btn-outline {
        padding: 12px 16px !important;
        font-size: 0.875rem !important;
    }
}

/* ===== MEDIUM TO LARGE PHONES ===== */
@media (min-width: 481px) and (max-width: 768px) {
    .hero {
        padding: 100px 20px 50px 20px !important;
    }

    .hero h1 {
        font-size: 2rem !important;
    }

    .hero p {
        font-size: 1.05rem !important;
    }

    .hero-dropdown-btn {
        padding: 18px 22px;
    }

    .hero-dropdown-item {
        padding: 16px 18px;
    }
}

/* ===== TABLET VIEWS (show service pills again) ===== */
@media (min-width: 769px) {
    .hero-mobile-dropdowns {
        display: none !important;
    }
}
