/* Desktop Services Dropdown */
.has-dropdown {
    position: relative;
}

.nav-dropdown-toggle {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
}

.nav-dropdown-toggle .dropdown-arrow {
    font-size: 0.5rem;
    transition: transform 0.25s ease;
    display: inline-block;
    opacity: 0.5;
}

.has-dropdown:hover .nav-dropdown-toggle .dropdown-arrow,
.has-dropdown.open .nav-dropdown-toggle .dropdown-arrow {
    transform: rotate(180deg);
    opacity: 1;
}

/* Dropdown panel */
.nav-dropdown {
    position: absolute;
    top: calc(100% + 14px);
    left: 50%;
    transform: translateX(-50%) translateY(-6px);
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.13), 0 4px 16px rgba(0, 0, 0, 0.06);
    padding: 8px 0;
    width: 360px;
    z-index: 1000;
    border: 1px solid rgba(0, 0, 0, 0.07);
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

/* Arrow tip */
.nav-dropdown::before {
    content: '';
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 12px;
    height: 12px;
    background: white;
    border-top: 1px solid rgba(0, 0, 0, 0.07);
    border-left: 1px solid rgba(0, 0, 0, 0.07);
}

.has-dropdown:hover .nav-dropdown,
.has-dropdown.open .nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Each item */
.nav-dropdown li {
    margin: 0;
}

.nav-dropdown li a {
    display: flex !important;
    align-items: center !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    gap: 12px;
    padding: 10px 16px;
    text-decoration: none;
    transition: background 0.15s ease;
}

.nav-dropdown li:hover {
    background: #f4f7ff;
}

/* Icon bubble */
.di-icon {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 9px;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 0.95rem;
    flex-shrink: 0;
    align-self: center;
    font-style: normal;
}

.di-icon-intro  { background: #f1f5f9; color: #64748b; font-weight: 700; font-size: 0.85rem; }
.di-icon-transform { background: #eff6ff; color: #3b82f6; }
.di-icon-heart  { background: #fff1f2; color: #f43f5e; }
.di-icon-integrate { background: #f0fdf4; color: #22c55e; font-size: 0.8rem; }

/* Text block */
.di-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.di-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.2;
    white-space: nowrap;
}

.di-desc {
    font-size: 0.75rem;
    color: #94a3b8;
    font-weight: 400;
    line-height: 1.2;
    white-space: normal;
    overflow: hidden;
}


/* Mobile Services Dropdown */
.mobile-dropdown-toggle {
    background: none;
    border: none;
    color: var(--text-dark, #333);
    font-size: 1.1rem;
    font-weight: 500;
    padding: 12px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    text-align: left;
    font-family: inherit;
}

.mobile-dropdown-toggle .dropdown-arrow {
    font-size: 0.6rem;
    transition: transform 0.3s ease;
    display: inline-block;
    margin-left: auto;
}

.has-dropdown.mobile-dropdown-open .mobile-dropdown-toggle .dropdown-arrow {
    transform: rotate(180deg);
}

.mobile-nav-dropdown {
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.has-dropdown.mobile-dropdown-open .mobile-nav-dropdown {
    max-height: 300px;
}

.mobile-nav-dropdown li a {
    display: block;
    padding: 10px 0 10px 20px;
    color: var(--text-medium, #666);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 400;
    border-left: 2px solid var(--bg-medium, #e5e7eb);
    transition: all 0.2s ease;
}

.mobile-nav-dropdown li a:hover {
    color: var(--primary, #3a7bd5);
    border-left-color: var(--primary, #3a7bd5);
}

.mobile-nav-links .has-dropdown > .mobile-dropdown-toggle {
    pointer-events: auto;
}
