/* Product Selection Area - Layout Fix */
/* Add this to your main.css file OR upload as separate file */

.product-selection-area {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

/* Additional styles for better product buttons */
.product-item-icon {
    font-size: 28px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-main);
    border-radius: 12px;
}

.product-item-content {
    flex: 1;
}

.product-item-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.product-item-subtitle {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

.product-dropdown-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border);
}

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

.product-dropdown-item:hover {
    background: var(--bg-main);
}

.product-dropdown-item.selected {
    background: rgba(99, 102, 241, 0.1);
    border-left: 4px solid var(--primary);
}

/* Learning Mode Styles */
.learning-mode-dropdown-wrapper {
    position: relative;
}

.learning-mode-btn {
    background: transparent;
    border: none;
    padding: 8px 12px;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s;
    min-width: 220px;
}

.learning-mode-btn:hover {
    background: var(--bg-card);
}

.learning-mode-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    flex: 1;
}

.learning-mode-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.learning-mode-subtitle {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1;
    margin-top: 4px;
}

.mode-dropdown-arrow {
    transition: transform 0.3s;
    color: var(--text-secondary);
}

.learning-mode-btn.active .mode-dropdown-arrow {
    transform: rotate(180deg);
}

/* Learning Mode Menu */
.learning-mode-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    min-width: 320px;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 8px;
}

.learning-mode-menu.active {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0);
}

.mode-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 4px;
}

.mode-option:last-child {
    margin-bottom: 0;
}

.mode-option:hover {
    background: var(--bg-main);
}

.mode-option.active {
    background: rgba(99, 102, 241, 0.1);
}

.mode-info {
    flex: 1;
}

.mode-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.mode-desc {
    font-size: 13px;
    color: var(--text-secondary);
}

.mode-check {
    color: var(--primary);
    opacity: 0;
    transition: opacity 0.2s;
}

.mode-option.active .mode-check {
    opacity: 1;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .product-selection-area {
        flex-direction: column;
        width: 100%;
    }
    
    .product-dropdown-wrapper {
        width: 100%;
    }
    
    .product-btn {
        width: 100%;
        justify-content: space-between;
    }
    
    .product-dropdown {
        width: 100%;
    }
    
    .learning-mode-btn {
        min-width: 180px;
    }
    
    .learning-mode-menu {
        min-width: 280px;
    }
}
